iOS:如何删除uiviewController影子的变化,因为另一个uiviewController被推/弹出

发布于 2025-01-21 15:55:52 字数 502 浏览 1 评论 0原文

我有两个带有白色背景颜色的uiviewController 对象。当我通过uinavigationController推开页面B上的页面时,我注意到iOS在页面过渡期间在页面B上添加了一个阴影。同样,当弹出页面A时,页面B会缓慢恢复其阴影变化。

在Page/Pop Action时,是否可以删除阴影动画?

我发现 uinavigation-vc“> uinavigation controller在过渡到另一个vc 这有点相似,但似乎是在第A页面的边缘添加的滴阴影。另外,正如其中一条评论所暗示的那样,失去向后滑动的能力并不是我的选择。

我在iOS 15.4上,想知道是否有一种禁用阴影的方法。

I have two UIViewController objects with a white background color. When I push page A over page B through a UINavigationController, I notice that iOS is adding a shadow on page B during page transition. Similarly, when page A is being popped, page B reverts its shadow change slowly.

Is it possible to remove shadow animations during page push/pop actions?

I found UINavigationController remove drop shadow when transitioning to another VC which is somewhat similar, but it seems to be about a drop shadow added to the edge of page A. Also, as one of the comments suggests, losing the ability to swipe back is not an option for me.

I'm on iOS 15.4 and would like to know if there is a way to disable shadows.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文