<small id='eZfup'></small><noframes id='eZfup'>

  • <legend id='eZfup'><style id='eZfup'><dir id='eZfup'><q id='eZfup'></q></dir></style></legend>

    1. <tfoot id='eZfup'></tfoot>
      <i id='eZfup'><tr id='eZfup'><dt id='eZfup'><q id='eZfup'><span id='eZfup'><b id='eZfup'><form id='eZfup'><ins id='eZfup'></ins><ul id='eZfup'></ul><sub id='eZfup'></sub></form><legend id='eZfup'></legend><bdo id='eZfup'><pre id='eZfup'><center id='eZfup'></center></pre></bdo></b><th id='eZfup'></th></span></q></dt></tr></i><div id='eZfup'><tfoot id='eZfup'></tfoot><dl id='eZfup'><fieldset id='eZfup'></fieldset></dl></div>
        <bdo id='eZfup'></bdo><ul id='eZfup'></ul>

        如何禁用 UIButton 的高亮控制状态?

        时间:2023-07-08

            <tbody id='B9vo6'></tbody>
            <bdo id='B9vo6'></bdo><ul id='B9vo6'></ul>

            <small id='B9vo6'></small><noframes id='B9vo6'>

              • <i id='B9vo6'><tr id='B9vo6'><dt id='B9vo6'><q id='B9vo6'><span id='B9vo6'><b id='B9vo6'><form id='B9vo6'><ins id='B9vo6'></ins><ul id='B9vo6'></ul><sub id='B9vo6'></sub></form><legend id='B9vo6'></legend><bdo id='B9vo6'><pre id='B9vo6'><center id='B9vo6'></center></pre></bdo></b><th id='B9vo6'></th></span></q></dt></tr></i><div id='B9vo6'><tfoot id='B9vo6'></tfoot><dl id='B9vo6'><fieldset id='B9vo6'></fieldset></dl></div>
                <legend id='B9vo6'><style id='B9vo6'><dir id='B9vo6'><q id='B9vo6'></q></dir></style></legend>

                1. <tfoot id='B9vo6'></tfoot>

                  本文介绍了如何禁用 UIButton 的高亮控制状态?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我有一个 UIButton,当它被选中时,它不应该在被触摸时改变状态.默认行为是它在被触摸时处于 UIControlStateHighlighted 状态,这让我很生气.

                  I've got a UIButton that, when selected, shouldn't change state when being touched. The default behaviour is for it to be in UIControlStateHighlighted while being touched, and this is making me angry.

                  建议?

                  推荐答案

                  您的按钮必须将其 buttonType 设置为 Custom.

                  Your button must have its buttonType set to Custom.

                  在 IB 中,您可以取消选中突出显示调整图像".

                  In IB you can uncheck "Highlight adjusts image".

                  您可以通过编程方式使用 theButton.adjustsImageWhenHighlighted = NO;

                  Programmatically you can use theButton.adjustsImageWhenHighlighted = NO;

                  类似的选项也可用于禁用"状态.

                  Similar options are available for the "disabled" state as well.

                  这篇关于如何禁用 UIButton 的高亮控制状态?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:访问 cellForRowAtIndexPath 之外的自定义单元格属性 下一篇:UIButton 底部阴影

                  相关文章

                  <legend id='kQeZK'><style id='kQeZK'><dir id='kQeZK'><q id='kQeZK'></q></dir></style></legend>

                  <small id='kQeZK'></small><noframes id='kQeZK'>

                  <i id='kQeZK'><tr id='kQeZK'><dt id='kQeZK'><q id='kQeZK'><span id='kQeZK'><b id='kQeZK'><form id='kQeZK'><ins id='kQeZK'></ins><ul id='kQeZK'></ul><sub id='kQeZK'></sub></form><legend id='kQeZK'></legend><bdo id='kQeZK'><pre id='kQeZK'><center id='kQeZK'></center></pre></bdo></b><th id='kQeZK'></th></span></q></dt></tr></i><div id='kQeZK'><tfoot id='kQeZK'></tfoot><dl id='kQeZK'><fieldset id='kQeZK'></fieldset></dl></div>

                  <tfoot id='kQeZK'></tfoot>
                  • <bdo id='kQeZK'></bdo><ul id='kQeZK'></ul>