1. <small id='MNjv4'></small><noframes id='MNjv4'>

    2. <tfoot id='MNjv4'></tfoot>
    3. <legend id='MNjv4'><style id='MNjv4'><dir id='MNjv4'><q id='MNjv4'></q></dir></style></legend>
    4. <i id='MNjv4'><tr id='MNjv4'><dt id='MNjv4'><q id='MNjv4'><span id='MNjv4'><b id='MNjv4'><form id='MNjv4'><ins id='MNjv4'></ins><ul id='MNjv4'></ul><sub id='MNjv4'></sub></form><legend id='MNjv4'></legend><bdo id='MNjv4'><pre id='MNjv4'><center id='MNjv4'></center></pre></bdo></b><th id='MNjv4'></th></span></q></dt></tr></i><div id='MNjv4'><tfoot id='MNjv4'></tfoot><dl id='MNjv4'><fieldset id='MNjv4'></fieldset></dl></div>

        <bdo id='MNjv4'></bdo><ul id='MNjv4'></ul>

      在 UITableView 中执行 commitEditingStyle 时,如何制作“删除按钮"的自定义视图

      How can I make a custom view of the #39;delete-button#39; when performing commitEditingStyle within a UITableView(在 UITableView 中执行 commitEditingStyle 时,如何制作“删除按钮的自定义视图)
    5. <small id='jJmFK'></small><noframes id='jJmFK'>

    6. <tfoot id='jJmFK'></tfoot>

          <legend id='jJmFK'><style id='jJmFK'><dir id='jJmFK'><q id='jJmFK'></q></dir></style></legend>
            • <bdo id='jJmFK'></bdo><ul id='jJmFK'></ul>
                <tbody id='jJmFK'></tbody>
              <i id='jJmFK'><tr id='jJmFK'><dt id='jJmFK'><q id='jJmFK'><span id='jJmFK'><b id='jJmFK'><form id='jJmFK'><ins id='jJmFK'></ins><ul id='jJmFK'></ul><sub id='jJmFK'></sub></form><legend id='jJmFK'></legend><bdo id='jJmFK'><pre id='jJmFK'><center id='jJmFK'></center></pre></bdo></b><th id='jJmFK'></th></span></q></dt></tr></i><div id='jJmFK'><tfoot id='jJmFK'></tfoot><dl id='jJmFK'><fieldset id='jJmFK'></fieldset></dl></div>
              1. 本文介绍了在 UITableView 中执行 commitEditingStyle 时,如何制作“删除按钮"的自定义视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我想自定义在表格视图单元格上执行向左滑动"操作时显示的删除按钮.我目前设置了 UITableViewCell 的子类,但还想自定义正在显示的删除按钮.

                I would like to customize the delete button which is shown when performing the 'swipe to left'-action on a tableview cell. I currently set up a subclass of a UITableViewCell but also want to customize the delete-button which is being shown.

                我的目标是在滑动时放置三个按钮.

                My goal is to place three buttons when swiping.

                我选择了另一种实现,我在每个单元格中使用 UIScrollview.

                I choose for another implementation where I was using a UIScrollview in each cell.

                http://www.teehanlax.com/blog/reproduce-the-ios-7-mail-apps-interface/

                推荐答案

                这可能对你有帮助.

                - (void)willTransitionToState:(UITableViewCellStateMask)state
                    {
                        [super willTransitionToState:state];
                        if ((state & UITableViewCellStateShowingDeleteConfirmationMask) == UITableViewCellStateShowingDeleteConfirmationMask)
                        {
                            for (UIView *subview in self.subviews)
                            {
                                if ([NSStringFromClass([subview class]) isEqualToString:@"UITableViewCellDeleteConfirmationControl"])
                                {
                                    UIImageView *deleteBtn = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, 64, 33)];
                                    [deleteBtn setImage:[UIImage imageNamed:@"arrow_left_s11.png"]];
                                    [[subview.subviews objectAtIndex:0] addSubview:deleteBtn];
                                }
                            }
                        }
                    }
                

                引用自:

                自定义UITableView中的删除按钮

                为uitableview创建自定义删除按钮

                自定义删除按钮在 UITableView 单元格中编辑

                这篇关于在 UITableView 中执行 commitEditingStyle 时,如何制作“删除按钮"的自定义视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                UIButton title text color(UIButton 标题文本颜色)
                How can I change UIButton title color?(如何更改 UIButton 标题颜色?)
                Minimum sensible button size on iPhone(iPhone 上的最小合理按钮大小)
                iPhone UIButton - image position(iPhone UIButton - 图像位置)
                How to get click event from a button added over MKAnnotationView(如何从通过 MKAnnotationView 添加的按钮获取点击事件)
                How to override -drawrect in UIButton subclass?(如何在 UIButton 子类中覆盖 -drawrect?)

                  <tbody id='xhqtE'></tbody>
                <tfoot id='xhqtE'></tfoot>

              2. <small id='xhqtE'></small><noframes id='xhqtE'>

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