菜鸟教程小白 发表于 2022-12-12 10:47:00

iphone - 如何制作可扩展的 UITableViewCell


                                            <p><div>
            <aside class="s-notice s-notice__info post-notice js-post-notice mb16"role="status">
      <div class="d-flex fd-column fw-nowrap">
            <div class="d-flex fw-nowrap">
                <div class="flex--item wmn0 fl1 lh-lg">
                  <div class="flex--item fl1 lh-lg">
                        <b>这个问题在这里已经有了答案</b>:
                        
                  <br><hr><h1><strong>Best Answer-推荐答案</ strong></h1><br>
                                            <p><p>当单击任何单元格时,您可以增加特定单元格的高度以显示所有详细信息,您可以按以下方式执行此操作:</p>

<blockquote>
<ol>
<li>Initially all cells will have same height so in heightForRowAtIndexPath will return same height say 40.</li>
<li>When user clicks on any cell, store that index path in some variable and call reloadData for tableView, which will call
heightForRowAtIndexPath, in this you check for selected cell index
path and return height say 100, which will display user info also.</li>
</ol>
</blockquote>

<p>希望这能满足您的要求。</p></p>
                                   
                                                <p style="font-size: 20px;">关于iphone - 如何制作可扩展的 UITableViewCell,我们在Stack Overflow上找到一个类似的问题:
                                                        <a href="https://stackoverflow.com/questions/16301157/" rel="noreferrer noopener nofollow" style="color: red;">
                                                                https://stackoverflow.com/questions/16301157/
                                                        </a>
                                                </p>
                                       
页: [1]
查看完整版本: iphone - 如何制作可扩展的 UITableViewCell