- fix the issue of previous selected on-screen widget get deleted when deleting legacy osc button

- coding improvements for on-screen widget deletion
This commit is contained in:
TrueZhuangjia committed 2025-03-02 21:47:57 +08:00
1 parent ebec9877b0
commit 70e5b3520c
6 files changed
+39 -21

No files matched your search

-2
View File
@@ -20,7 +20,6 @@ import UIKit
}
@objc static public var editMode: Bool = false
@objc static public var timestampOfButtonBeingDragged: TimeInterval = 0
@objc public var keyLabel: String
@objc public var keyString: String
@objc public var timestamp: TimeInterval
@@ -937,7 +936,6 @@ import UIKit
override func touchesMoved(_ touches: Set<UITouch>, with event: UIEvent?) {
super.touchesMoved(touches, with: event)
OnScreenWidgetView.timestampOfButtonBeingDragged = self.timestamp
if !OnScreenWidgetView.editMode {
if CommandManager.touchPadCmds.contains(self.keyString){