gpt4 book ai didi

ios - 在编辑模式下检查双击

转载 作者:塔克拉玛干 更新时间:2023-11-02 20:21:38 24 4
gpt4 key购买 nike

我正在做一个调整,每当用户在编辑模式下双击一个图标时都会弹出一个警告。我试过连接到

- (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event

SBIcon 然后

{
%orig;
UITouch *touch = [touches anyObject];
if (touch.tapCount == 2 && [[objc_getClass("SBIconController") sharedInstance] isEditing])
{
//pop an alert and do stuff
}
}

但这似乎根本行不通。谁能告诉我以上内容有什么问题并建议实现此目标的替代方法?

编辑:如果重要的话,我正在使用 theos。

最佳答案

我会建议您使用 Tap 手势识别器。它更具体并且工作非常准确。

有关更多信息,您可以查看此链接: http://developer.apple.com/library/ios/#documentation/EventHandling/Conceptual/EventHandlingiPhoneOS/GestureRecognizers/GestureRecognizers.html

关于ios - 在编辑模式下检查双击,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10966225/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com