gui widgetPicker
This commit is contained in:
@@ -35,6 +35,8 @@
|
||||
18E4BCEA2E891895000A8657 /* MotionHandler.swift in Sources */ = {isa = PBXBuildFile; fileRef = 18E4BCE92E891895000A8657 /* MotionHandler.swift */; };
|
||||
18FCADAF2ECAC23200787A96 /* PencilHandler.swift in Sources */ = {isa = PBXBuildFile; fileRef = 18FCADAE2ECAC23200787A96 /* PencilHandler.swift */; };
|
||||
2A7113FD2F5A6C65001D852D /* ThemeManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A7113FC2F5A6C65001D852D /* ThemeManager.swift */; };
|
||||
2AAA4E822F7666C5001E20DC /* ControllerUtil.swift in Sources */ = {isa = PBXBuildFile; fileRef = 18A765BC2ECD51FB004784AA /* ControllerUtil.swift */; };
|
||||
2AAA4E842F7666EE001E20DC /* SwiftLocalizationHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84E1CDF92C4FE83400547904 /* SwiftLocalizationHelper.swift */; };
|
||||
2AC1E3832F507D80004F76C0 /* GenericUtils.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2AC1E3822F507D80004F76C0 /* GenericUtils.swift */; };
|
||||
840751B32BF49C050096B657 /* CustomTapGestureRecognizer.m in Sources */ = {isa = PBXBuildFile; fileRef = 840751B22BF49C050096B657 /* CustomTapGestureRecognizer.m */; };
|
||||
84203F232C5F24C00032EEED /* OnScreenWidgetView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84203F222C5F24C00032EEED /* OnScreenWidgetView.swift */; };
|
||||
@@ -199,6 +201,7 @@
|
||||
18D43D7E2F050240008C326F /* PressureCurve.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PressureCurve.swift; sourceTree = "<group>"; };
|
||||
18E4BCE92E891895000A8657 /* MotionHandler.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MotionHandler.swift; sourceTree = "<group>"; };
|
||||
18FCADAE2ECAC23200787A96 /* PencilHandler.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PencilHandler.swift; sourceTree = "<group>"; };
|
||||
2A039E562F72892B00546768 /* VoidLinkSwiftUI.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = VoidLinkSwiftUI.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
2A7113FC2F5A6C65001D852D /* ThemeManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ThemeManager.swift; sourceTree = "<group>"; };
|
||||
2AC1E3822F507D80004F76C0 /* GenericUtils.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GenericUtils.swift; sourceTree = "<group>"; };
|
||||
693B3A9A218638CD00982F7B /* Settings.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = Settings.bundle; sourceTree = "<group>"; };
|
||||
@@ -414,11 +417,39 @@
|
||||
FBDE86E519F82297001C18A8 /* UIAppView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIAppView.m; sourceTree = "<group>"; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
/* Begin PBXFileSystemSynchronizedBuildFileExceptionSet section */
|
||||
2A93D5662F7D016C00C2207F /* PBXFileSystemSynchronizedBuildFileExceptionSet */ = {
|
||||
isa = PBXFileSystemSynchronizedBuildFileExceptionSet;
|
||||
membershipExceptions = (
|
||||
WidgetPickerViewController.swift,
|
||||
);
|
||||
target = 2A039E552F72892B00546768 /* VoidLinkSwiftUI */;
|
||||
};
|
||||
2AAA4E862F76BDC6001E20DC /* PBXFileSystemSynchronizedBuildFileExceptionSet */ = {
|
||||
isa = PBXFileSystemSynchronizedBuildFileExceptionSet;
|
||||
membershipExceptions = (
|
||||
AbstractGamepadView.swift,
|
||||
VirtualKeyboardView.swift,
|
||||
WidgetPickerView.swift,
|
||||
WidgetPickerViewController.swift,
|
||||
);
|
||||
target = FB290CED19B2C406004C83CF /* VoidLink */;
|
||||
};
|
||||
/* End PBXFileSystemSynchronizedBuildFileExceptionSet section */
|
||||
|
||||
/* Begin PBXFileSystemSynchronizedRootGroup section */
|
||||
18A0EE282EFBCBFB00BA853A /* SVGs */ = {isa = PBXFileSystemSynchronizedRootGroup; explicitFileTypes = {}; explicitFolders = (); path = SVGs; sourceTree = "<group>"; };
|
||||
2A039E572F72892B00546768 /* VoidLinkSwiftUI */ = {isa = PBXFileSystemSynchronizedRootGroup; exceptions = (2AAA4E862F76BDC6001E20DC /* PBXFileSystemSynchronizedBuildFileExceptionSet */, 2A93D5662F7D016C00C2207F /* PBXFileSystemSynchronizedBuildFileExceptionSet */, ); explicitFileTypes = {}; explicitFolders = (); path = VoidLinkSwiftUI; sourceTree = "<group>"; };
|
||||
/* End PBXFileSystemSynchronizedRootGroup section */
|
||||
|
||||
/* Begin PBXFrameworksBuildPhase section */
|
||||
2A039E532F72892B00546768 /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
FB290CEB19B2C406004C83CF /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
@@ -590,6 +621,7 @@
|
||||
98AB2E7F1CAD46830089BB98 /* moonlight-common.xcodeproj */,
|
||||
FB290CF919B2C406004C83CF /* VoidLink */,
|
||||
FB1A67542132419700507771 /* Moonlight TV */,
|
||||
2A039E572F72892B00546768 /* VoidLinkSwiftUI */,
|
||||
FB290CF019B2C406004C83CF /* Frameworks */,
|
||||
FB290CEF19B2C406004C83CF /* Products */,
|
||||
);
|
||||
@@ -599,6 +631,7 @@
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
FB290CEE19B2C406004C83CF /* VoidLink.app */,
|
||||
2A039E562F72892B00546768 /* VoidLinkSwiftUI.app */,
|
||||
);
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
@@ -938,6 +971,28 @@
|
||||
/* End PBXGroup section */
|
||||
|
||||
/* Begin PBXNativeTarget section */
|
||||
2A039E552F72892B00546768 /* VoidLinkSwiftUI */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 2A039E5E2F72892C00546768 /* Build configuration list for PBXNativeTarget "VoidLinkSwiftUI" */;
|
||||
buildPhases = (
|
||||
2A039E522F72892B00546768 /* Sources */,
|
||||
2A039E532F72892B00546768 /* Frameworks */,
|
||||
2A039E542F72892B00546768 /* Resources */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
dependencies = (
|
||||
);
|
||||
fileSystemSynchronizedGroups = (
|
||||
2A039E572F72892B00546768 /* VoidLinkSwiftUI */,
|
||||
);
|
||||
name = VoidLinkSwiftUI;
|
||||
packageProductDependencies = (
|
||||
);
|
||||
productName = VoidLinkSwiftUI;
|
||||
productReference = 2A039E562F72892B00546768 /* VoidLinkSwiftUI.app */;
|
||||
productType = "com.apple.product-type.application";
|
||||
};
|
||||
FB290CED19B2C406004C83CF /* VoidLink */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = FB290D2019B2C406004C83CF /* Build configuration list for PBXNativeTarget "VoidLink" */;
|
||||
@@ -965,10 +1020,13 @@
|
||||
FB290CE619B2C406004C83CF /* Project object */ = {
|
||||
isa = PBXProject;
|
||||
attributes = {
|
||||
LastSwiftUpdateCheck = 0730;
|
||||
LastSwiftUpdateCheck = 2620;
|
||||
LastUpgradeCheck = 1400;
|
||||
ORGANIZATIONNAME = "Moonlight Game Streaming Project";
|
||||
TargetAttributes = {
|
||||
2A039E552F72892B00546768 = {
|
||||
CreatedOnToolsVersion = 26.2;
|
||||
};
|
||||
FB290CED19B2C406004C83CF = {
|
||||
LastSwiftMigration = 1140;
|
||||
};
|
||||
@@ -1002,6 +1060,7 @@
|
||||
projectRoot = "";
|
||||
targets = (
|
||||
FB290CED19B2C406004C83CF /* VoidLink */,
|
||||
2A039E552F72892B00546768 /* VoidLinkSwiftUI */,
|
||||
);
|
||||
};
|
||||
/* End PBXProject section */
|
||||
@@ -1024,6 +1083,13 @@
|
||||
/* End PBXReferenceProxy section */
|
||||
|
||||
/* Begin PBXResourcesBuildPhase section */
|
||||
2A039E542F72892B00546768 /* Resources */ = {
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
FB290CEC19B2C406004C83CF /* Resources */ = {
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
@@ -1043,6 +1109,15 @@
|
||||
/* End PBXResourcesBuildPhase section */
|
||||
|
||||
/* Begin PBXSourcesBuildPhase section */
|
||||
2A039E522F72892B00546768 /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
2AAA4E842F7666EE001E20DC /* SwiftLocalizationHelper.swift in Sources */,
|
||||
2AAA4E822F7666C5001E20DC /* ControllerUtil.swift in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
FB290CEA19B2C406004C83CF /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
@@ -1206,6 +1281,102 @@
|
||||
/* End PBXVariantGroup section */
|
||||
|
||||
/* Begin XCBuildConfiguration section */
|
||||
2A039E5F2F72892C00546768 /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
|
||||
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
|
||||
CLANG_ENABLE_OBJC_WEAK = YES;
|
||||
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
|
||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||
CODE_SIGN_STYLE = Automatic;
|
||||
CURRENT_PROJECT_VERSION = 1;
|
||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||
DEVELOPMENT_TEAM = FRL23UV4N9;
|
||||
ENABLE_PREVIEWS = YES;
|
||||
ENABLE_USER_SCRIPT_SANDBOXING = YES;
|
||||
GCC_C_LANGUAGE_STANDARD = gnu17;
|
||||
GENERATE_INFOPLIST_FILE = YES;
|
||||
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
|
||||
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
|
||||
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
|
||||
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
|
||||
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
|
||||
MARKETING_VERSION = 1.0;
|
||||
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
||||
MTL_FAST_MATH = YES;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = com.trzj.VoidLinkSwiftUI;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
STRING_CATALOG_GENERATE_SYMBOLS = YES;
|
||||
SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)";
|
||||
SWIFT_APPROACHABLE_CONCURRENCY = YES;
|
||||
SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor;
|
||||
SWIFT_EMIT_LOC_STRINGS = YES;
|
||||
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
|
||||
SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES;
|
||||
SWIFT_VERSION = 5.0;
|
||||
TARGETED_DEVICE_FAMILY = "1,2";
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
2A039E602F72892C00546768 /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
|
||||
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
|
||||
CLANG_ENABLE_OBJC_WEAK = YES;
|
||||
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
|
||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||
CODE_SIGN_STYLE = Automatic;
|
||||
COPY_PHASE_STRIP = NO;
|
||||
CURRENT_PROJECT_VERSION = 1;
|
||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||
DEVELOPMENT_TEAM = FRL23UV4N9;
|
||||
ENABLE_PREVIEWS = YES;
|
||||
ENABLE_USER_SCRIPT_SANDBOXING = YES;
|
||||
GCC_C_LANGUAGE_STANDARD = gnu17;
|
||||
GENERATE_INFOPLIST_FILE = YES;
|
||||
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
|
||||
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
|
||||
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
|
||||
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
|
||||
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
|
||||
MARKETING_VERSION = 1.0;
|
||||
MTL_ENABLE_DEBUG_INFO = NO;
|
||||
MTL_FAST_MATH = YES;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = com.trzj.VoidLinkSwiftUI;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
STRING_CATALOG_GENERATE_SYMBOLS = YES;
|
||||
SWIFT_APPROACHABLE_CONCURRENCY = YES;
|
||||
SWIFT_COMPILATION_MODE = wholemodule;
|
||||
SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor;
|
||||
SWIFT_EMIT_LOC_STRINGS = YES;
|
||||
SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES;
|
||||
SWIFT_VERSION = 5.0;
|
||||
TARGETED_DEVICE_FAMILY = "1,2";
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
FB290D1E19B2C406004C83CF /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
@@ -1451,6 +1622,15 @@
|
||||
/* End XCBuildConfiguration section */
|
||||
|
||||
/* Begin XCConfigurationList section */
|
||||
2A039E5E2F72892C00546768 /* Build configuration list for PBXNativeTarget "VoidLinkSwiftUI" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
2A039E5F2F72892C00546768 /* Debug */,
|
||||
2A039E602F72892C00546768 /* Release */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
FB290CE919B2C406004C83CF /* Build configuration list for PBXProject "VoidLink" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
||||
+123
-100
@@ -163,8 +163,11 @@ import UIKit
|
||||
"BRUSH": 0xFF,
|
||||
"ERASER": 0xFF,
|
||||
"CTRL": 0x11, // VK_CONTROL
|
||||
"RCTRL": 0xA3, // VK_RCONTROL
|
||||
"SHIFT": 0x10, // VK_SHIFT
|
||||
"RSHIFT": 0xA1, // VK_RSHIFT
|
||||
"ALT": 0x12, // VK_MENU
|
||||
"RALT": 0xA5, // VK_MENU
|
||||
"F1": 0x70, // VK_F1
|
||||
"F2": 0x71, // VK_F2
|
||||
"F3": 0x72, // VK_F3
|
||||
@@ -300,111 +303,131 @@ import UIKit
|
||||
"LAUNCHAPP2": 0xB7, // VK_LAUNCH_APP2
|
||||
"WIN": 0x5B,
|
||||
"LEFT_WIN": 0x5B, // VK_LWIN
|
||||
"LEFTWIN": 0x5B, // VK_LWIN
|
||||
"LWIN": 0x5B, // VK_LWIN
|
||||
"RIGHT_WIN": 0x5C, // VK_RWIN
|
||||
"RIGHTWIN": 0x5C, // VK_RWIN
|
||||
"RWIN": 0x5C, // VK_RWIN
|
||||
"APPS": 0x5D, // VK_APPS
|
||||
|
||||
// macOS Key Codes
|
||||
"CMD": 0x37, // ⌘ Command
|
||||
"OPT": 0x3A, // ⌥ Option
|
||||
"CONTROL": 0x3B, // ⌃ Control
|
||||
"FUNCTION": 0x3F, // fn
|
||||
"SHIFTMAC": 0x38, // ⇧ Shift
|
||||
"DELETEMAC": 0x75, // Forward Delete
|
||||
"RETURNMAC": 0x24, // Return
|
||||
"ENTERMAC": 0x4C, // Enter
|
||||
"ESCAPEMAC": 0x35, // Escape
|
||||
"TABMAC": 0x30, // Tab
|
||||
"SPACEMAC": 0x31, // Space
|
||||
"UPARRMAC": 0x7E, // Up Arrow
|
||||
"DOWNARRMAC": 0x7D, // Down Arrow
|
||||
"LEFTARRMAC": 0x7B, // Left Arrow
|
||||
"RIGHTARRMAC": 0x7C, // Right Arrow
|
||||
"F1MAC": 0x7A, // F1
|
||||
"F2MAC": 0x78, // F2
|
||||
"F3MAC": 0x63, // F3
|
||||
"F4MAC": 0x76, // F4
|
||||
"F5MAC": 0x60, // F5
|
||||
"F6MAC": 0x61, // F6
|
||||
"F7MAC": 0x62, // F7
|
||||
"F8MAC": 0x64, // F8
|
||||
"F9MAC": 0x65, // F9
|
||||
"F10MAC": 0x6D, // F10
|
||||
"F11MAC": 0x67, // F11
|
||||
"F12MAC": 0x6F, // F12
|
||||
"0MAC": 0x52, // 0
|
||||
"1MAC": 0x53, // 1
|
||||
"2MAC": 0x54, // 2
|
||||
"3MAC": 0x55, // 3
|
||||
"4MAC": 0x56, // 4
|
||||
"5MAC": 0x57, // 5
|
||||
"6MAC": 0x58, // 6
|
||||
"7MAC": 0x59, // 7
|
||||
"8MAC": 0x5A, // 8
|
||||
"9MAC": 0x5B, // 9
|
||||
"NUMPAD0MAC": 0x4F, // Numpad 0
|
||||
"NUMPAD1MAC": 0x50, // Numpad 1
|
||||
"NUMPAD2MAC": 0x51, // Numpad 2
|
||||
"NUMPAD3MAC": 0x52, // Numpad 3
|
||||
"NUMPAD4MAC": 0x53, // Numpad 4
|
||||
"NUMPAD5MAC": 0x54, // Numpad 5
|
||||
"NUMPAD6MAC": 0x55, // Numpad 6
|
||||
"NUMPAD7MAC": 0x56, // Numpad 7
|
||||
"NUMPAD8MAC": 0x57, // Numpad 8
|
||||
"NUMPAD9MAC": 0x58, // Numpad 9
|
||||
"NUMPADADDMAC": 0x45, // Numpad Add
|
||||
"NUMPADSUBTRACTMAC": 0x4A, // Numpad Subtract
|
||||
"NUMPADMULTIPLYMAC": 0x43, // Numpad Multiply
|
||||
"NUMPADDIVIDEMAC": 0x4B, // Numpad Divide
|
||||
"NUMPADDECIMALMAC": 0x41, // Numpad Decimal
|
||||
"SHIFT_MAC": 0x38, // ⇧ Shift
|
||||
"DELETE_MAC": 0x75, // Forward Delete
|
||||
"RETURN_MAC": 0x24, // Return
|
||||
"ENTER_MAC": 0x4C, // Enter
|
||||
"ESCAPE_MAC": 0x35, // Escape
|
||||
"TAB_MAC": 0x30, // Tab
|
||||
"SPACE_MAC": 0x31, // Space
|
||||
"UP_ARROW_MAC": 0x7E, // Up Arrow
|
||||
"DOWN_ARROW_MAC": 0x7D, // Down Arrow
|
||||
"LEFT_ARROW_MAC": 0x7B, // Left Arrow
|
||||
"RIGHT_ARROW_MAC": 0x7C, // Right Arrow
|
||||
"F1_MAC": 0x7A, // F1
|
||||
"F2_MAC": 0x78, // F2
|
||||
"F3_MAC": 0x63, // F3
|
||||
"F4_MAC": 0x76, // F4
|
||||
"F5_MAC": 0x60, // F5
|
||||
"F6_MAC": 0x61, // F6
|
||||
"F7_MAC": 0x62, // F7
|
||||
"F8_MAC": 0x64, // F8
|
||||
"F9_MAC": 0x65, // F9
|
||||
"F10_MAC": 0x6D, // F10
|
||||
"F11_MAC": 0x67, // F11
|
||||
"F12_MAC": 0x6F, // F12
|
||||
"0_MAC": 0x52, // 0
|
||||
"1_MAC": 0x53, // 1
|
||||
"2_MAC": 0x54, // 2
|
||||
"3_MAC": 0x55, // 3
|
||||
"4_MAC": 0x56, // 4
|
||||
"5_MAC": 0x57, // 5
|
||||
"6_MAC": 0x58, // 6
|
||||
"7_MAC": 0x59, // 7
|
||||
"8_MAC": 0x5A, // 8
|
||||
"9_MAC": 0x5B, // 9
|
||||
"NUMPAD0_MAC": 0x4F, // Numpad 0
|
||||
"NUMPAD1_MAC": 0x50, // Numpad 1
|
||||
"NUMPAD2_MAC": 0x51, // Numpad 2
|
||||
"NUMPAD3_MAC": 0x52, // Numpad 3
|
||||
"NUMPAD4_MAC": 0x53, // Numpad 4
|
||||
"NUMPAD5_MAC": 0x54, // Numpad 5
|
||||
"NUMPAD6_MAC": 0x55, // Numpad 6
|
||||
"NUMPAD7_MAC": 0x56, // Numpad 7
|
||||
"NUMPAD8_MAC": 0x57, // Numpad 8
|
||||
"NUMPAD9_MAC": 0x58, // Numpad 9
|
||||
"NUMPAD_ADD_MAC": 0x45, // Numpad Add
|
||||
"NUMPAD_SUBTRACT_MAC": 0x4A, // Numpad Subtract
|
||||
"NUMPAD_MULTIPLY_MAC": 0x43, // Numpad Multiply
|
||||
"NUMPAD_DIVIDE_MAC": 0x4B, // Numpad Divide
|
||||
"NUMPAD_DECIMAL_MAC": 0x41, // Numpad Decimal
|
||||
"ESCAPEMAC": 0x35,
|
||||
"TABMAC": 0x30,
|
||||
"RETURNMAC": 0x24,
|
||||
"BACKSPACEMAC": 0x33,
|
||||
"SPACEMAC": 0x31,
|
||||
|
||||
"F1MAC": 0x7A,
|
||||
"F2MAC": 0x78,
|
||||
"F3MAC": 0x63,
|
||||
"F4MAC": 0x76,
|
||||
"F5MAC": 0x60,
|
||||
"F6MAC": 0x61,
|
||||
"F7MAC": 0x62,
|
||||
"F8MAC": 0x64,
|
||||
"F9MAC": 0x65,
|
||||
"F10MAC": 0x6D,
|
||||
"F11MAC": 0x67,
|
||||
"F12MAC": 0x6F,
|
||||
"F13MAC": 0x69,
|
||||
"F14MAC": 0x6B,
|
||||
"F15MAC": 0x71,
|
||||
|
||||
"GRAVEACCENTMAC": 0x32,
|
||||
"1MAC": 0x12,
|
||||
"2MAC": 0x13,
|
||||
"3MAC": 0x14,
|
||||
"4MAC": 0x15,
|
||||
"5MAC": 0x17,
|
||||
"6MAC": 0x16,
|
||||
"7MAC": 0x1A,
|
||||
"8MAC": 0x1C,
|
||||
"9MAC": 0x19,
|
||||
"0MAC": 0x1D,
|
||||
"MINUSMAC": 0x1B,
|
||||
"EQUALSMAC": 0x18,
|
||||
|
||||
"QMAC": 0x0C,
|
||||
"WMAC": 0x0D,
|
||||
"EMAC": 0x0E,
|
||||
"RMAC": 0x0F,
|
||||
"TMAC": 0x11,
|
||||
"YMAC": 0x10,
|
||||
"UMAC": 0x20,
|
||||
"IMAC": 0x22,
|
||||
"OMAC": 0x1F,
|
||||
"PMAC": 0x23,
|
||||
"OPENBRACKETMAC": 0x21,
|
||||
"CLOSEBRACKETMAC": 0x1E,
|
||||
"BACKSLASHMAC": 0x2A,
|
||||
|
||||
"CAPSLOCKMAC": 0x39,
|
||||
"AMAC": 0x00,
|
||||
"SMAC": 0x01,
|
||||
"DMAC": 0x02,
|
||||
"FMAC": 0x03,
|
||||
"GMAC": 0x05,
|
||||
"HMAC": 0x04,
|
||||
"JMAC": 0x26,
|
||||
"KMAC": 0x28,
|
||||
"LMAC": 0x25,
|
||||
"SEMICOLONMAC": 0x29,
|
||||
"SINGLEQUOTEMAC": 0x27,
|
||||
|
||||
"SHIFTMAC": 0x38,
|
||||
"ZMAC": 0x06,
|
||||
"XMAC": 0x07,
|
||||
"CMAC": 0x08,
|
||||
"VMAC": 0x09,
|
||||
"BMAC": 0x0B,
|
||||
"NMAC": 0x2D,
|
||||
"MMAC": 0x2E,
|
||||
"COMMAMAC": 0x2B,
|
||||
"PERIODMAC": 0x2F,
|
||||
"FORWARDSLASHMAC": 0x2C,
|
||||
|
||||
"CONTROL": 0x3B,
|
||||
"RIGHTCONTROL": 0x3E,
|
||||
"OPT": 0x3A,
|
||||
"RIGHTOPT": 0x3D,
|
||||
"CMD": 0x37,
|
||||
"RIGHTCMD": 0x36,
|
||||
"FUNCTION": 0x3F,
|
||||
|
||||
"HOMEMAC": 0x73,
|
||||
"ENDMAC": 0x77,
|
||||
"PGUPMAC": 0x74,
|
||||
"PGDNMAC": 0x79,
|
||||
|
||||
"LEFTARRMAC": 0x7B,
|
||||
"RIGHTARRMAC": 0x7C,
|
||||
"DOWNARRMAC": 0x7D,
|
||||
"UPARRMAC": 0x7E,
|
||||
|
||||
"DELMAC": 0x75,
|
||||
|
||||
"CONTEXTMAC": 0x72,
|
||||
|
||||
"NUMPADCLEARMAC": 0x47,
|
||||
"NUMPADDIVIDEMAC": 0x4B,
|
||||
"NUMPADMULTIPLYMAC": 0x43,
|
||||
"NUMPADSUBTRACTMAC": 0x4E,
|
||||
"NUMPADADDMAC": 0x45,
|
||||
|
||||
"NUMPAD0MAC": 0x4F,
|
||||
"NUMPAD1MAC": 0x50,
|
||||
"NUMPAD2MAC": 0x51,
|
||||
"NUMPAD3MAC": 0x52,
|
||||
"NUMPAD4MAC": 0x53,
|
||||
"NUMPAD5MAC": 0x54,
|
||||
"NUMPAD6MAC": 0x55,
|
||||
"NUMPAD7MAC": 0x56,
|
||||
"NUMPAD8MAC": 0x57,
|
||||
"NUMPAD9MAC": 0x58,
|
||||
|
||||
"NUMPADDECIMALMAC": 0x41,
|
||||
"NUMPADEQUALMAC": 0x51,
|
||||
"ENTERMAC": 0x4C,
|
||||
]
|
||||
|
||||
private var commands: [RemoteCommand] = []
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -21,7 +21,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
/**
|
||||
This view controller provides the user interface which allows the user to position on screen controller buttons anywhere they'd like on the screen. It also provides the user with the abilities to undo a change, save the on screen controller layout for later retrieval, and load previously saved controller layouts
|
||||
*/
|
||||
@interface LayoutOnScreenControlsViewController : UIViewController <OnScreenWidgetGuidelineUpdateDelegate,UITextFieldDelegate>
|
||||
@interface LayoutOnScreenControlsViewController : UIViewController <OnScreenWidgetGuidelineUpdateDelegate,UITextFieldDelegate, WidgetPickerViewControllerDelegate>
|
||||
- (void)profileRefresh;
|
||||
- (void)reloadOnScreenWidgetViews;
|
||||
- (void)presentProfilesTableViewWithPickProfile:(bool)pickProfile;
|
||||
|
||||
+47
-1
@@ -19,7 +19,7 @@
|
||||
// #import "ThemeManager.h"
|
||||
#import "DataManager.h"
|
||||
|
||||
@interface LayoutOnScreenControlsViewController ()
|
||||
@interface LayoutOnScreenControlsViewController () <WidgetPickerViewControllerDelegate>
|
||||
|
||||
typedef NS_ENUM(NSUInteger, AlphaSliderMode) {
|
||||
widgetAlpha,
|
||||
@@ -661,6 +661,18 @@ typedef NS_ENUM(NSUInteger, DecelerationRateSliderMode) {
|
||||
- (IBAction) addTapped:(id)sender{
|
||||
GenericUtils.autoPopSoftKeyboard = false;
|
||||
|
||||
if (@available(iOS 13.0, *)) {
|
||||
WidgetPickerViewController *pickerViewController = [[WidgetPickerViewController alloc] init];
|
||||
pickerViewController.delegate = self;
|
||||
pickerViewController.tabIdentifiers = @[@"gamepad", @"keyboard", @"functional"];
|
||||
pickerViewController.initialTabIdentifier = @"gamepad";
|
||||
|
||||
UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:pickerViewController];
|
||||
navigationController.modalPresentationStyle = UIModalPresentationOverFullScreen;
|
||||
[self presentViewController:navigationController animated:YES completion:nil];
|
||||
return;
|
||||
}
|
||||
|
||||
NSMutableDictionary* widgetInitParams = [NSMutableDictionary dictionary];
|
||||
|
||||
UIAlertController *alertController = [UIAlertController alertControllerWithTitle:[LocalizationHelper localizedStringForKey:@""]
|
||||
@@ -745,6 +757,24 @@ typedef NS_ENUM(NSUInteger, DecelerationRateSliderMode) {
|
||||
[self presentViewController:alertController animated:YES completion:nil];
|
||||
}
|
||||
|
||||
- (void)widgetPickerViewController:(WidgetPickerViewController *)controller didCreateWidget:(NSDictionary *)payload {
|
||||
NSMutableDictionary *widgetInitParams = [payload mutableCopy];
|
||||
NSString *pickerAction = [widgetInitParams[@"pickerAction"] lowercaseString];
|
||||
[widgetInitParams removeObjectForKey:@"pickerAction"];
|
||||
|
||||
if ([pickerAction isEqualToString:@"modify"] && self->selectedWidgetView != nil) {
|
||||
[self updateWidget:self->selectedWidgetView byParams:widgetInitParams createNew:false];
|
||||
return;
|
||||
}
|
||||
|
||||
if ([pickerAction isEqualToString:@"create"] && controller.isEditMode && self->selectedWidgetView != nil) {
|
||||
[self updateWidget:self->selectedWidgetView byParams:widgetInitParams createNew:true];
|
||||
return;
|
||||
}
|
||||
|
||||
[self createWidgetFromParams:widgetInitParams];
|
||||
}
|
||||
|
||||
|
||||
- (IBAction) editTapped:(id)sender{
|
||||
GenericUtils.autoPopSoftKeyboard = false;
|
||||
@@ -768,6 +798,22 @@ typedef NS_ENUM(NSUInteger, DecelerationRateSliderMode) {
|
||||
return;
|
||||
};
|
||||
|
||||
if (@available(iOS 13.0, *)) {
|
||||
WidgetPickerViewController *pickerViewController = [[WidgetPickerViewController alloc] init];
|
||||
pickerViewController.delegate = self;
|
||||
pickerViewController.tabIdentifiers = @[@"gamepad", @"keyboard", @"functional"];
|
||||
pickerViewController.initialTabIdentifier = @"gamepad";
|
||||
pickerViewController.isEditMode = true;
|
||||
pickerViewController.initialCmdString = self->selectedWidgetView.cmdString;
|
||||
pickerViewController.initialButtonLabel = self->selectedWidgetView.widgetLabel;
|
||||
pickerViewController.initialShape = self->selectedWidgetView.shape;
|
||||
|
||||
UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:pickerViewController];
|
||||
navigationController.modalPresentationStyle = UIModalPresentationOverFullScreen;
|
||||
[self presentViewController:navigationController animated:YES completion:nil];
|
||||
return;
|
||||
}
|
||||
|
||||
[alertController addTextFieldWithConfigurationHandler:^(UITextField *textField) {
|
||||
UILabel *label = [[UILabel alloc] init];
|
||||
label.text = [LocalizationHelper localizedStringForKey:@"Command: "];
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,11 @@
|
||||
import SwiftUI
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
@main
|
||||
struct VoidLinkSwiftUIApp: App {
|
||||
var body: some Scene {
|
||||
WindowGroup {
|
||||
WidgetPickerView()
|
||||
}
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,76 @@
|
||||
import SwiftUI
|
||||
import UIKit
|
||||
|
||||
@available(iOS 13.0, *)
|
||||
@objc public protocol WidgetPickerViewControllerDelegate: AnyObject {
|
||||
func widgetPickerViewController(_ controller: WidgetPickerViewController, didCreateWidget payload: NSDictionary)
|
||||
@objc optional func widgetPickerViewControllerDidCancel(_ controller: WidgetPickerViewController)
|
||||
}
|
||||
|
||||
@available(iOS 13.0, *)
|
||||
@objcMembers
|
||||
public final class WidgetPickerViewController: UIViewController {
|
||||
public weak var delegate: WidgetPickerViewControllerDelegate?
|
||||
public var isEditMode: Bool = false
|
||||
public var initialCmdString: String?
|
||||
public var initialButtonLabel: String?
|
||||
public var initialShape: String?
|
||||
public var tabIdentifiers: [String] = []
|
||||
public var initialTabIdentifier: String?
|
||||
|
||||
private var hostingViewController: UIHostingController<WidgetPickerView>?
|
||||
|
||||
public override func viewDidLoad() {
|
||||
super.viewDidLoad()
|
||||
|
||||
view.backgroundColor = .systemBackground
|
||||
|
||||
let rootView = WidgetPickerView(
|
||||
isEditMode: isEditMode,
|
||||
initialCmdString: initialCmdString,
|
||||
initialButtonLabel: initialButtonLabel,
|
||||
initialShape: initialShape,
|
||||
availableTabs: resolvedTabs(),
|
||||
preferredInitialTab: resolvedInitialTab(),
|
||||
onWidgetCreated: { [weak self] payload in
|
||||
guard let self else { return }
|
||||
self.delegate?.widgetPickerViewController(self, didCreateWidget: payload as NSDictionary)
|
||||
self.dismiss(animated: true)
|
||||
},
|
||||
onCloseRequested: { [weak self] in
|
||||
self?.dismiss(animated: true)
|
||||
}
|
||||
)
|
||||
let hostingViewController = UIHostingController(rootView: rootView)
|
||||
self.hostingViewController = hostingViewController
|
||||
|
||||
addChild(hostingViewController)
|
||||
hostingViewController.view.translatesAutoresizingMaskIntoConstraints = false
|
||||
view.addSubview(hostingViewController.view)
|
||||
hostingViewController.didMove(toParent: self)
|
||||
|
||||
NSLayoutConstraint.activate([
|
||||
hostingViewController.view.topAnchor.constraint(equalTo: view.safeAreaLayoutGuide.topAnchor),
|
||||
hostingViewController.view.bottomAnchor.constraint(equalTo: view.bottomAnchor),
|
||||
hostingViewController.view.leadingAnchor.constraint(equalTo: view.leadingAnchor),
|
||||
hostingViewController.view.trailingAnchor.constraint(equalTo: view.trailingAnchor),
|
||||
])
|
||||
|
||||
preferredContentSize = CGSize(width: 1120, height: 760)
|
||||
}
|
||||
|
||||
public override func viewWillAppear(_ animated: Bool) {
|
||||
super.viewWillAppear(animated)
|
||||
navigationController?.setNavigationBarHidden(true, animated: false)
|
||||
}
|
||||
|
||||
private func resolvedTabs() -> [WidgetPickerTab] {
|
||||
let tabs = tabIdentifiers.compactMap(WidgetPickerTab.init(identifier:))
|
||||
return tabs.isEmpty ? WidgetPickerTab.allCases : tabs
|
||||
}
|
||||
|
||||
private func resolvedInitialTab() -> WidgetPickerTab? {
|
||||
guard let initialTabIdentifier else { return nil }
|
||||
return WidgetPickerTab(identifier: initialTabIdentifier)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user