- feat: auto tap for on-screen widget.

- fixed: on-screen widget button stuck.
This commit is contained in:
TrueZhuanjia
2025-09-10 03:02:28 +08:00
parent d818f8a7ce
commit 4e65abf6b1
16 changed files with 628 additions and 234 deletions
+4
View File
@@ -7,6 +7,7 @@
objects = {
/* Begin PBXBuildFile section */
1817B61E2E6FD04D000D938D /* SafeTimer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1817B61D2E6FD04D000D938D /* SafeTimer.swift */; };
1829CE3F2E2154DF0074A99A /* SceneDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 1829CE3E2E2154DF0074A99A /* SceneDelegate.m */; };
18341A042DEB662C0094E5F2 /* FixedTintImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = 18341A032DEB662C0094E5F2 /* FixedTintImageView.m */; };
1850C82A2E667E4000845308 /* MicHandler.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1850C8292E667E4000845308 /* MicHandler.swift */; };
@@ -152,6 +153,7 @@
/* End PBXContainerItemProxy section */
/* Begin PBXFileReference section */
1817B61D2E6FD04D000D938D /* SafeTimer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SafeTimer.swift; sourceTree = "<group>"; };
1829CE3D2E2154DF0074A99A /* SceneDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SceneDelegate.h; sourceTree = "<group>"; };
1829CE3E2E2154DF0074A99A /* SceneDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SceneDelegate.m; sourceTree = "<group>"; };
18341A022DEB65AB0094E5F2 /* FixedTintImageView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = FixedTintImageView.h; sourceTree = "<group>"; };
@@ -692,6 +694,7 @@
1850C8292E667E4000845308 /* MicHandler.swift */,
84E1CDEB2C4F67D300547904 /* CommandManager.swift */,
84203F222C5F24C00032EEED /* OnScreenWidgetView.swift */,
1817B61D2E6FD04D000D938D /* SafeTimer.swift */,
);
path = Input;
sourceTree = "<group>";
@@ -1024,6 +1027,7 @@
9777AAF32E2CF7A400D7FBAF /* Shaders-Linear.metal in Sources */,
84FD0B512C31338D006B5BE5 /* LocalizationHelper.m in Sources */,
97E20DEA2E216532000D5DCA /* SceneDelegate.m in Sources */,
1817B61E2E6FD04D000D938D /* SafeTimer.swift in Sources */,
FBD3495019FF2174002D2A60 /* SettingsViewController.m in Sources */,
843CC7F02C1E757D00BBC475 /* NativeTouchPointer.m in Sources */,
FB89462C19F646E200339C8A /* HttpManager.m in Sources */,
+86 -47
View File
@@ -1420,7 +1420,7 @@
</constraints>
</view>
<stackView opaque="NO" contentMode="scaleToFill" ambiguous="YES" axis="vertical" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="z5Q-bW-WQ8" userLabel="widgetPanelStack" customClass="WidgetPanelStackView">
<rect key="frame" x="325" y="156" width="650" height="379.5"/>
<rect key="frame" x="325" y="156" width="650" height="549"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Profile:" textAlignment="center" lineBreakMode="tailTruncation" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="iel-xl-xd9">
<rect key="frame" x="0.0" y="0.0" width="650" height="37"/>
@@ -1434,72 +1434,88 @@
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Tap any widget to load configuration (per widget)" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xfv-K0-1CO">
<rect key="frame" x="0.0" y="42" width="650" height="20.5"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="toF-yb-f3V" userLabel="tipTitleLabel">
<rect key="frame" x="0.0" y="42" width="650" height="30"/>
<constraints>
<constraint firstAttribute="height" relation="greaterThanOrEqual" constant="30" id="X2q-0M-PFg"/>
</constraints>
<string key="text">Tap any widget to load configuration (per widget)
</string>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xfv-K0-1CO" userLabel="tipContentLabel">
<rect key="frame" x="0.0" y="77" width="650" height="120"/>
<constraints>
<constraint firstAttribute="height" relation="greaterThanOrEqual" constant="120" id="fmj-pd-wkh"/>
</constraints>
<string key="text">Tap any widget to load configuration (per widget)
</string>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="GOp-1e-oUF" userLabel="widgetSizeStack">
<rect key="frame" x="0.0" y="67.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="202" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZuV-4A-0Zb" userLabel="widgetSizeLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Size" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZuV-4A-0Zb" userLabel="widgetSizeLabel">
<rect key="frame" x="0.0" y="0.0" width="105" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="vaE-Tf-vep"/>
<constraint firstAttribute="width" constant="105" id="vaE-Tf-vep"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="1" minValue="0.60000002384185791" maxValue="6" translatesAutoresizingMaskIntoConstraints="NO" id="Xzq-VC-hP3" userLabel="Size Slider">
<rect key="frame" x="158" y="0.0" width="494" height="31"/>
<rect key="frame" x="103" y="0.0" width="549" height="31"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="9Zz-kb-7Ej" userLabel="widgetHeightStack">
<rect key="frame" x="0.0" y="102.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="237" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="sbd-0j-KWS" userLabel="widgetHeightLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Height" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="sbd-0j-KWS" userLabel="widgetHeightLabel">
<rect key="frame" x="0.0" y="0.0" width="105" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="0Ce-y1-K5s"/>
<constraint firstAttribute="width" constant="105" id="0Ce-y1-K5s"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="1" minValue="0.60000002384185791" maxValue="6" translatesAutoresizingMaskIntoConstraints="NO" id="aZp-Dq-RTr" userLabel="Height Slider">
<rect key="frame" x="158" y="0.0" width="494" height="31"/>
<rect key="frame" x="103" y="0.0" width="549" height="31"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="9ZS-28-txW" userLabel="borderWidthAlphaStack">
<rect key="frame" x="0.0" y="137.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="272" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Pwa-YK-6Q2" userLabel="widgetAlphaLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Alpha" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Pwa-YK-6Q2" userLabel="widgetAlphaLabel">
<rect key="frame" x="0.0" y="0.0" width="101" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="1ru-Nd-cf4"/>
<constraint firstAttribute="width" constant="101" id="1ru-Nd-cf4"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="0.83300000429153442" minValue="0.0010000000474974513" maxValue="0.99900001287460327" translatesAutoresizingMaskIntoConstraints="NO" id="ii1-Iq-jI4" userLabel="Alpha Slider">
<rect key="frame" x="163" y="0.0" width="169" height="31"/>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="leading" contentVerticalAlignment="center" value="0.83300000429153442" minValue="0.0010000000474974513" maxValue="0.99900001287460327" translatesAutoresizingMaskIntoConstraints="NO" id="ii1-Iq-jI4" userLabel="Alpha Slider">
<rect key="frame" x="104" y="0.0" width="169" height="31"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="165" id="tRM-SO-nlr"/>
</constraints>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="r8L-dl-yLZ" userLabel="widgetBorderLabel">
<rect key="frame" x="335" y="0.0" width="150" height="30"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="BorderWidth" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="r8L-dl-yLZ" userLabel="widgetBorderLabel">
<rect key="frame" x="276" y="0.0" width="150" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="150" id="ZWS-S0-FRB"/>
</constraints>
@@ -1508,16 +1524,35 @@
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" minValue="0.0" maxValue="8" translatesAutoresizingMaskIntoConstraints="NO" id="aOV-38-CQt" userLabel="Widget Border Width Slider">
<rect key="frame" x="488" y="0.0" width="164" height="31"/>
<rect key="frame" x="429" y="0.0" width="223" height="31"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="e4b-0v-36Z" userLabel="autoTapStack">
<rect key="frame" x="0.0" y="307" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Auto tap: 100ms" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="And-W9-9NR" userLabel="autoTapLabel">
<rect key="frame" x="0.0" y="0.0" width="145" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="145" id="GyN-qS-EHz"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="200" minValue="0.0" maxValue="1000" translatesAutoresizingMaskIntoConstraints="NO" id="ksz-Dq-bUf" userLabel="autoTapSlider">
<rect key="frame" x="143" y="0.0" width="509" height="31"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
</subviews>
</stackView>
<stackView contentMode="scaleToFill" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="zfD-bd-GEN" userLabel="stickIndicatorOffsetStack">
<rect key="frame" x="0.0" y="172.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="342" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="tG7-oX-P9b" userLabel="stickIndicatorOffsetLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Stick Indicator" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="tG7-oX-P9b" userLabel="stickIndicatorOffsetLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="Am2-6L-a26"/>
@@ -1534,9 +1569,9 @@
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="80D-qe-E5D" userLabel="sensitivityFactorXStack">
<rect key="frame" x="0.0" y="207.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="377" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="vJs-pg-hHe" userLabel="sensitivityFactorLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="SensitivityX" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="vJs-pg-hHe" userLabel="sensitivityFactorLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="pI1-IG-YhP"/>
@@ -1553,9 +1588,9 @@
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="CT5-Ap-Gh0" userLabel="sensitivityFactorYStack">
<rect key="frame" x="0.0" y="242.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="412" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="NZO-BM-nef" userLabel="sensitivityFactorYLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="SensitivityY" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="NZO-BM-nef" userLabel="sensitivityFactorYLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="PVs-bg-tFM"/>
@@ -1572,9 +1607,9 @@
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="KXB-uJ-onx" userLabel="decelerationRateStack">
<rect key="frame" x="0.0" y="277.5" width="650" height="30"/>
<rect key="frame" x="0.0" y="447" width="650" height="30"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Pbt-Tw-dnV" userLabel="decelerationRateLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="DecelerationRate" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Pbt-Tw-dnV" userLabel="decelerationRateLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="a62-Bk-bZR"/>
@@ -1591,19 +1626,19 @@
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="GMQ-EQ-Hum" userLabel="mouseDownButtonStack">
<rect key="frame" x="0.0" y="312.5" width="650" height="31"/>
<rect key="frame" x="0.0" y="482" width="650" height="31"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Down Button" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="c1r-Hf-b7t" userLabel="mouseDownButtonLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="31"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Down button" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="c1r-Hf-b7t" userLabel="mouseDownButtonLabel">
<rect key="frame" x="0.0" y="0.0" width="130" height="31"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="eNs-gl-lQc"/>
<constraint firstAttribute="width" constant="130" id="eNs-gl-lQc"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<segmentedControl opaque="NO" alpha="0.77000000000000002" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="top" segmentControlStyle="plain" selectedSegmentIndex="0" translatesAutoresizingMaskIntoConstraints="NO" id="H8S-aI-EBo">
<rect key="frame" x="160" y="0.0" width="490" height="32"/>
<rect key="frame" x="130" y="0.0" width="520" height="32"/>
<color key="backgroundColor" white="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<segments>
<segment title="hovering"/>
@@ -1618,19 +1653,19 @@
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="LGW-oJ-5Zf" userLabel="slidableStack">
<rect key="frame" x="0.0" y="348.5" width="650" height="31"/>
<rect key="frame" x="0.0" y="518" width="650" height="31"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Slide Activated" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="qNQ-fB-jhY" userLabel="uiLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="31"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Slide activated" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="qNQ-fB-jhY" userLabel="uiLabel">
<rect key="frame" x="0.0" y="0.0" width="130" height="31"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="P7b-Jz-LEK"/>
<constraint firstAttribute="width" constant="130" id="P7b-Jz-LEK"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<segmentedControl opaque="NO" alpha="0.76999998092651367" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="top" segmentControlStyle="plain" selectedSegmentIndex="0" translatesAutoresizingMaskIntoConstraints="NO" id="cKS-fy-Zpg">
<rect key="frame" x="160" y="0.0" width="367" height="32"/>
<rect key="frame" x="130" y="0.0" width="335" height="32"/>
<color key="backgroundColor" white="0.33333333329999998" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<segments>
<segment title="slide to release"/>
@@ -1641,9 +1676,9 @@
<color key="selectedSegmentTintColor" red="0.23087820410000001" green="0.4576539993" blue="0.51765710119999997" alpha="1" colorSpace="custom" customColorSpace="displayP3"/>
</segmentedControl>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" " textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dOF-FW-cBU" userLabel="uiLabel">
<rect key="frame" x="527" y="0.0" width="123" height="31"/>
<rect key="frame" x="465" y="0.0" width="185" height="31"/>
<constraints>
<constraint firstAttribute="width" constant="123" id="hfV-um-PjK"/>
<constraint firstAttribute="width" constant="185" id="hfV-um-PjK"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
@@ -1670,6 +1705,9 @@
<size key="freeformSize" width="1300" height="1194"/>
<connections>
<outlet property="addButton" destination="fKN-ja-TRi" id="R2n-QF-aSj"/>
<outlet property="autoTapLabel" destination="And-W9-9NR" id="r5A-4a-XZP"/>
<outlet property="autoTapSlider" destination="ksz-Dq-bUf" id="nbG-ye-X7e"/>
<outlet property="autoTapStack" destination="e4b-0v-36Z" id="PZd-KE-lPb"/>
<outlet property="borderWidthAlphaStack" destination="9ZS-28-txW" id="qxV-2E-g8m"/>
<outlet property="chevronImageView" destination="iVZ-Fd-dY7" id="403-Nj-wRx"/>
<outlet property="chevronView" destination="hKp-ds-86I" id="Og9-aT-zNH"/>
@@ -1680,7 +1718,6 @@
<outlet property="editButton" destination="R45-lM-YPl" id="DNS-7N-3Kh"/>
<outlet property="exitButton" destination="7bp-Wn-j9n" id="Kku-3T-RSO"/>
<outlet property="loadButton" destination="OId-gk-Wkg" id="adP-54-1ir"/>
<outlet property="loadConfigTipLabel" destination="xfv-K0-1CO" id="GeX-Qc-CLA"/>
<outlet property="mouseButtonDownSelector" destination="H8S-aI-EBo" id="em1-fK-Cpb"/>
<outlet property="mouseDownButtonStack" destination="GMQ-EQ-Hum" id="sxb-40-3NI"/>
<outlet property="saveButton" destination="uda-zt-xrG" id="FyB-WY-rri"/>
@@ -1695,6 +1732,8 @@
<outlet property="stickIndicatorOffsetLabel" destination="tG7-oX-P9b" id="jBx-ii-091"/>
<outlet property="stickIndicatorOffsetSlider" destination="aPX-7o-N3l" id="gLv-c3-3JG"/>
<outlet property="stickIndicatorOffsetStack" destination="zfD-bd-GEN" id="oeb-Vk-2mw"/>
<outlet property="tipContentLabel" destination="xfv-K0-1CO" id="GeX-Qc-CLA"/>
<outlet property="tipTitleLabel" destination="toF-yb-f3V" id="9W0-Sb-vqb"/>
<outlet property="toolbarRootView" destination="fZU-G0-fgM" id="txP-M2-GKi"/>
<outlet property="toolbarStackView" destination="YLK-IE-ajS" id="j4o-Kp-7Z8"/>
<outlet property="toolbarTopConstraintiPad" destination="Ppb-J1-lXg" id="laN-Zh-lHm"/>
@@ -1810,7 +1849,7 @@
<image name="tray.full.fill" catalog="system" width="128" height="88"/>
<image name="video.and.waveform" catalog="system" width="128" height="94"/>
<systemColor name="linkColor">
<color red="0.0" green="0.47843137250000001" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.0" green="0.47843137254901963" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
<systemColor name="secondarySystemGroupedBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
@@ -1819,13 +1858,13 @@
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
<systemColor name="systemBrownColor">
<color red="0.63529411759999999" green="0.51764705879999995" blue="0.36862745099999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.63529411764705879" green="0.51764705882352946" blue="0.36862745098039218" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
<systemColor name="systemGray3Color">
<color red="0.78039215689999997" green="0.78039215689999997" blue="0.80000000000000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.7803921568627451" green="0.7803921568627451" blue="0.80000000000000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
<systemColor name="systemTealColor">
<color red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.18823529411764706" green="0.69019607843137254" blue="0.7803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
</resources>
</document>
+82 -40
View File
@@ -315,40 +315,56 @@
</constraints>
</view>
<stackView opaque="NO" contentMode="scaleToFill" ambiguous="YES" axis="vertical" spacing="7" translatesAutoresizingMaskIntoConstraints="NO" id="BVp-3O-vZ7" userLabel="widgetPanelStack" customClass="WidgetPanelStackView">
<rect key="frame" x="375" y="132" width="550" height="325.5"/>
<rect key="frame" x="375" y="132" width="550" height="597"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Profile:" textAlignment="center" lineBreakMode="tailTruncation" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="f46-Pt-0Pv">
<rect key="frame" x="0.0" y="0.0" width="550" height="28"/>
<color key="backgroundColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="tintColor" red="0.81533776120000001" green="0.85979419950000002" blue="0.91372549020000005" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="28" id="4Ej-Nm-Urf"/>
<constraint firstAttribute="height" constant="28" id="4Ej-Nm-Urf" userLabel="height = 20"/>
<constraint firstAttribute="width" constant="650" id="r1C-Ih-J6Q"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Tap any widget to load configuration (per widget)" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="9Gg-66-UdB">
<rect key="frame" x="0.0" y="35" width="550" height="20.5"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Profile:" textAlignment="center" lineBreakMode="tailTruncation" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="jh9-zs-2EL">
<rect key="frame" x="0.0" y="35" width="550" height="28"/>
<color key="tintColor" red="0.81533776120000001" green="0.85979419950000002" blue="0.91372549020000005" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="650" id="7t4-2A-JvF"/>
<constraint firstAttribute="height" constant="28" id="IHm-cv-sNr" userLabel="height = 20"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Profile:" textAlignment="center" lineBreakMode="tailTruncation" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zCC-w1-yXO">
<rect key="frame" x="0.0" y="70" width="550" height="230"/>
<color key="tintColor" red="0.81533776120000001" green="0.85979419950000002" blue="0.91372549020000005" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="650" id="MiG-j3-uoQ"/>
<constraint firstAttribute="height" constant="230" id="w7R-Bs-Sf6" userLabel="height = 20"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="xoH-wS-SS1" userLabel="widgetSizeStack">
<rect key="frame" x="0.0" y="62.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="307" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="kva-gQ-CZh" userLabel="widgetSizeLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Size" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="kva-gQ-CZh" userLabel="widgetSizeLabel">
<rect key="frame" x="0.0" y="0.0" width="105" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="AU1-B5-zIN"/>
<constraint firstAttribute="width" constant="105" id="AU1-B5-zIN"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="1" minValue="0.60000002384185791" maxValue="6" translatesAutoresizingMaskIntoConstraints="NO" id="Eke-rc-DVp" userLabel="Size Slider">
<rect key="frame" x="158" y="0.0" width="394" height="21"/>
<rect key="frame" x="103" y="0.0" width="449" height="21"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
@@ -358,19 +374,19 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="4Vo-Zh-48b" userLabel="widgetHeightStack">
<rect key="frame" x="0.0" y="89.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="334" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Idx-O1-5dn" userLabel="widgetHeightLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Height" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Idx-O1-5dn" userLabel="widgetHeightLabel">
<rect key="frame" x="0.0" y="0.0" width="105" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="HZV-hv-obw"/>
<constraint firstAttribute="width" constant="105" id="HZV-hv-obw"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="1" minValue="0.60000002384185791" maxValue="6" translatesAutoresizingMaskIntoConstraints="NO" id="ssl-ip-Ckz" userLabel="Height Slider">
<rect key="frame" x="158" y="0.0" width="394" height="21"/>
<rect key="frame" x="103" y="0.0" width="449" height="21"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
@@ -380,27 +396,27 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="50p-sC-ObU" userLabel="borderWidthAlphaStack">
<rect key="frame" x="0.0" y="116.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="361" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="qPQ-U2-aSg" userLabel="widgetAlphaLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Alpha" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="qPQ-U2-aSg" userLabel="widgetAlphaLabel">
<rect key="frame" x="0.0" y="0.0" width="101" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="F3F-cO-OPA"/>
<constraint firstAttribute="width" constant="101" id="F3F-cO-OPA"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="0.83300000429153442" minValue="0.0010000000474974513" maxValue="0.99900001287460327" translatesAutoresizingMaskIntoConstraints="NO" id="8Dt-CC-xry" userLabel="Alpha Slider">
<rect key="frame" x="163" y="0.0" width="144" height="21"/>
<rect key="frame" x="104" y="0.0" width="144" height="21"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="140" id="6X9-AU-vgE"/>
</constraints>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="eiL-iX-G3Z" userLabel="widgetBorderLabel">
<rect key="frame" x="310" y="0.0" width="150" height="20"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="BorderWidth" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="eiL-iX-G3Z" userLabel="widgetBorderLabel">
<rect key="frame" x="251" y="0.0" width="150" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="150" id="Dyc-3P-v0o"/>
</constraints>
@@ -409,7 +425,7 @@
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" minValue="0.0" maxValue="8" translatesAutoresizingMaskIntoConstraints="NO" id="m00-jb-sl5" userLabel="Widget Border Width Slider">
<rect key="frame" x="463" y="0.0" width="89" height="21"/>
<rect key="frame" x="404" y="0.0" width="148" height="21"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
@@ -418,10 +434,32 @@
<constraint firstAttribute="height" constant="20" id="kge-ua-7K0"/>
</constraints>
</stackView>
<stackView contentMode="scaleToFill" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="Ejp-Jq-phL" userLabel="stickIndicatorOffsetStack">
<rect key="frame" x="0.0" y="143.5" width="550" height="20"/>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="tDJ-cy-BYU" userLabel="autoTapStack">
<rect key="frame" x="0.0" y="388" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="fcy-zp-LGa" userLabel="stickIndicatorOffsetLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Autotap: 100ms" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="IuG-44-1Je" userLabel="autoTapLabel">
<rect key="frame" x="0.0" y="0.0" width="135" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="135" id="zBL-cf-cIx"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<slider clearsContextBeforeDrawing="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="200" minValue="0.0" maxValue="1000" translatesAutoresizingMaskIntoConstraints="NO" id="tsE-QI-xLw" userLabel="autoTapSlider">
<rect key="frame" x="133" y="0.0" width="419" height="21"/>
<color key="tintColor" red="0.18823529410000001" green="0.69019607839999997" blue="0.78039215689999997" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
<color key="maximumTrackTintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</slider>
</subviews>
<constraints>
<constraint firstAttribute="height" constant="20" id="hW1-mw-apj"/>
</constraints>
</stackView>
<stackView contentMode="scaleToFill" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="Ejp-Jq-phL" userLabel="stickIndicatorOffsetStack">
<rect key="frame" x="0.0" y="415" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Stick Indicator" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="fcy-zp-LGa" userLabel="stickIndicatorOffsetLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="2JU-sF-hdJ"/>
@@ -441,9 +479,9 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="fem-TG-vr3" userLabel="sensitivityFactorXStack">
<rect key="frame" x="0.0" y="170.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="442" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dJh-Ck-ugh" userLabel="sensitivityFactorLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="SensitivityX" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dJh-Ck-ugh" userLabel="sensitivityFactorLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="jOI-vE-DiQ"/>
@@ -463,9 +501,9 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="50h-xK-Lq0" userLabel="sensitivityFactorYStack">
<rect key="frame" x="0.0" y="197.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="469" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="R9C-JW-nkF" userLabel="sensitivityFactorYLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="SensitivityY" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="R9C-JW-nkF" userLabel="sensitivityFactorYLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="MQ6-xc-8mf"/>
@@ -485,9 +523,9 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="3Bf-uN-nLa">
<rect key="frame" x="0.0" y="224.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="496" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="test" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="znE-Lv-uWV">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="DecelerationRate" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="znE-Lv-uWV">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="exf-Gl-23x"/>
@@ -507,9 +545,9 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="gsG-6n-BAb" userLabel="vibrationStyleStack">
<rect key="frame" x="0.0" y="251.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="523" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Vibration Style" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="u3w-Se-xzH" userLabel="sensitivityFactorLabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Vibration style" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="u3w-Se-xzH" userLabel="sensitivityFactorLabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="jAW-3B-uPL"/>
@@ -538,9 +576,9 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="lEZ-1a-89J" userLabel="mouseButtonDownStack">
<rect key="frame" x="0.0" y="278.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="550" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Button Down" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ozU-7C-qKE" userLabel="uilabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Button down" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ozU-7C-qKE" userLabel="uilabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="Sii-hk-yFR"/>
@@ -568,9 +606,9 @@
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="jE7-IB-GTS" userLabel="slidableStack">
<rect key="frame" x="0.0" y="305.5" width="550" height="20"/>
<rect key="frame" x="0.0" y="577" width="550" height="20"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Slide Activated" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="o9I-Gt-YRd" userLabel="uilabel">
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Slide activated" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="o9I-Gt-YRd" userLabel="uilabel">
<rect key="frame" x="0.0" y="0.0" width="160" height="20"/>
<constraints>
<constraint firstAttribute="width" constant="160" id="W2q-kp-7ce"/>
@@ -620,6 +658,9 @@
</view>
<size key="freeformSize" width="1300" height="896"/>
<connections>
<outlet property="autoTapLabel" destination="IuG-44-1Je" id="YWb-0d-zbB"/>
<outlet property="autoTapSlider" destination="tsE-QI-xLw" id="WlR-z2-iXM"/>
<outlet property="autoTapStack" destination="tDJ-cy-BYU" id="moT-DJ-jwF"/>
<outlet property="borderWidthAlphaStack" destination="50p-sC-ObU" id="2Xq-p7-31z"/>
<outlet property="chevronImageView" destination="76O-3K-aa8" id="yGv-fM-Ohf"/>
<outlet property="chevronView" destination="Zll-IP-PFt" id="MGR-C0-h57"/>
@@ -627,7 +668,6 @@
<outlet property="decelerationRateLabel" destination="znE-Lv-uWV" id="2Ud-O4-DD8"/>
<outlet property="decelerationRateSlider" destination="MFc-8O-wdZ" id="8Sh-vO-fqQ"/>
<outlet property="decelerationRateStack" destination="3Bf-uN-nLa" id="WaW-YW-Q7p"/>
<outlet property="loadConfigTipLabel" destination="9Gg-66-UdB" id="cMS-ly-En0"/>
<outlet property="mouseButtonDownSelector" destination="tE5-Bm-4OB" id="9fh-99-8pu"/>
<outlet property="mouseDownButtonStack" destination="lEZ-1a-89J" id="R6t-gC-kcD"/>
<outlet property="sensitivityXLabel" destination="dJh-Ck-ugh" id="vso-QW-vxX"/>
@@ -641,6 +681,8 @@
<outlet property="stickIndicatorOffsetLabel" destination="fcy-zp-LGa" id="lZP-Uv-mMH"/>
<outlet property="stickIndicatorOffsetSlider" destination="DCr-vG-gM7" id="aYH-VM-p5l"/>
<outlet property="stickIndicatorOffsetStack" destination="Ejp-Jq-phL" id="HNM-4A-VmN"/>
<outlet property="tipContentLabel" destination="zCC-w1-yXO" id="fXD-zh-6jg"/>
<outlet property="tipTitleLabel" destination="jh9-zs-2EL" id="aXT-Uc-XQU"/>
<outlet property="toolbarRootView" destination="Jnu-63-bcf" id="Y17-e2-18R"/>
<outlet property="toolbarStackView" destination="4he-pe-kYB" id="eVm-jM-dcv"/>
<outlet property="toolbarTopConstraintiPhone" destination="wNr-7F-S0i" id="iXe-d3-R7i"/>
@@ -663,7 +705,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="ORo-HP-JDj" userLabel="First Responder" customClass="UIResponder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="667" y="1325"/>
<point key="canvasLocation" x="158" y="1246"/>
</scene>
<!--Profiles Table View Controller-->
<scene sceneID="C7c-yg-gQK">
BIN
View File
Binary file not shown.
@@ -379,6 +379,7 @@ static CGRect layoutViewBounds;
buttonState.heightFactor = [self normalizeSizeHeightFactor:widgetView];
buttonState.backgroundAlpha = widgetView.backgroundAlpha;
buttonState.borderWidth = widgetView.borderWidth;
buttonState.autoTapInterval = widgetView.autoTapInterval;
buttonState.vibrationStyle = widgetView.vibrationStyle;
buttonState.mouseButtonAction = widgetView.mouseButtonAction;
buttonState.sensitivityFactorX = widgetView.sensitivityFactorX;
@@ -39,9 +39,10 @@ NS_ASSUME_NONNULL_BEGIN
@property NSString* widgetShape; // for OnScreenWidgetView
@property (nonatomic, assign) CGFloat oscLayerSizeFactor; // for OnScreenController CALayer
@property (nonatomic, assign) CGFloat backgroundAlpha; // for OnScreenController CALayer
@property (nonatomic, assign) uint8_t vibrationStyle; // for OnScreenController CALayer
@property (nonatomic, assign) uint8_t mouseButtonAction; // for OnScreenController CALayer
@property (nonatomic, assign) CGFloat backgroundAlpha;
@property (nonatomic, assign) uint8_t vibrationStyle;
@property (nonatomic, assign) uint8_t mouseButtonAction;
@property (nonatomic, assign) uint16_t autoTapInterval;
// @property (nonatomic, assign) BOOL hasValidPosition;
@@ -36,6 +36,7 @@
[encoder encodeInt:self.vibrationStyle forKey:@"vibrationStyle"];
[encoder encodeInt:self.mouseButtonAction forKey:@"mouseButtonAction"];
[encoder encodeInt:self.slideMode forKey:@"slideMode"];
[encoder encodeInt:self.autoTapInterval forKey:@"autoTapInterval"];
[encoder encodeCGPoint:self.position forKey:@"position"];
[encoder encodeBool:self.isHidden forKey:@"isHidden"];
[encoder encodeFloat:self.widthFactor forKey:@"widthFactor"];
@@ -59,6 +60,7 @@
self.vibrationStyle = [decoder decodeIntForKey:@"vibrationStyle"];
self.mouseButtonAction = [decoder decodeIntForKey:@"mouseButtonAction"];
self.slideMode = [decoder containsValueForKey:@"slideMode"] ? [decoder decodeIntForKey:@"slideMode"] : 0;
self.autoTapInterval = [decoder containsValueForKey:@"autoTapInterval"] ? [decoder decodeIntForKey:@"autoTapInterval"] : 45;
self.position = [decoder decodeCGPointForKey:@"position"];
self.isHidden = [decoder decodeBoolForKey:@"isHidden"];
self.widthFactor = [decoder decodeFloatForKey:@"widthFactor"];
+9 -26
View File
@@ -69,6 +69,11 @@ static CGFloat screenWidthInPoints;
- (void)touchesEnded:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event {
// [super touchesEnded:touches withEvent:event];
if(OnScreenWidgetView.tapGestureShallBeCancelled){
self.state = UIGestureRecognizerStateFailed;
OnScreenWidgetView.tapGestureShallBeCancelled = false;
return;
}
if(_immediateTriggering) return;
uint8_t allTouchesCount = [[event allTouches] count];
@@ -76,7 +81,7 @@ static CGFloat screenWidthInPoints;
_gestureCaptured = false;
self.state = UIGestureRecognizerStateFailed;
}
else if(_gestureCaptured && allTouchesCount == [touches count] && !_isOnScreenControllerBeingPressed && ![self isOnScreenWidgetViewBeingPressed]){ //must exclude virtual controller & onscreen button taps here to prevent stucked button, _areVirtualControllerTaps flag is set by onscreencontrols, containOnScreenButtonsTaps will be returned by iterating all widget views in streamframeview
else if(_gestureCaptured && allTouchesCount == [touches count] && !_isOnScreenControllerBeingPressed){ //must exclude virtual controller & onscreen button taps here to prevent stucked button, _areVirtualControllerTaps flag is set by onscreencontrols, containOnScreenButtonsTaps will be returned by iterating all widget views in streamframeview
_gestureCaptured = false; //reset for next recognition
if((CACurrentMediaTime() - _gestureCapturedTime) < _tapDownTimeThreshold){
lowestTouchPointYCoord = 0.0; //reset for next recognition
@@ -84,32 +89,10 @@ static CGFloat screenWidthInPoints;
// NSLog(@"gen _lowestTouchPointHeight %f markmark touchesEnd", _lowestTouchPointHeight);
}
}
if (allTouchesCount == [touches count]) _isOnScreenControllerBeingPressed = false; // need to reset this flag anyway, when all fingers are lefting
}
// it was a not a perfect choice to code OnScreenWidgetView in Swift...
// we're unable to import this class to swift codebase by the bridging header,and have to exlucde the onscreen button taps here
// by iterating every widget view instances. but it's basically ok since the number of widgetViews are always limited.
// and this method will only be called when the recognizer is active & and the taps passes all the checks and is about to ge triggered.
- (bool)isOnScreenWidgetViewBeingPressed {
NSTimeInterval allFingersTapDownTime = CACurrentMediaTime() - _gestureCapturedTime; //RIGHTCLICK_TAP_DOWN_TIME_THRESHOLD_S has been passed to this recognizer as _tapDownTimeShreshold, we'll decide how to deal with pressed flag of on-screen widget views based on tapDownTime
bool gotOneWidgetPressed = false;
// the tap gestures are all added to the streamFrameTopLayerView, where all the OnScreenWidgetViews are added. so we can iterate them in this way:
for(UIView* view in self.view.subviews){
if ([view isKindOfClass:[OnScreenWidgetView class]]) {
OnScreenWidgetView* widgetView = (OnScreenWidgetView*) view;
if(gotOneWidgetPressed && allFingersTapDownTime <= _tapDownTimeThreshold){ // once we have just 1 button pressed already,& the tapDownTime has not exceeded the threshold, we'll reset pressed flag for the all the widgetViews.
widgetView.pressed = false; //reset the flag for widgetView
continue;
}
if(widgetView.pressed){
gotOneWidgetPressed = true; //got one button pressed
if(allFingersTapDownTime <= _tapDownTimeThreshold) widgetView.pressed = false; // reset the flag for current widgetView if tapDowntime is still within the threshold, if not, leave the flag for mouse scroller gesture in relative touch mode.
}
}
if (allTouchesCount == [touches count]){
_isOnScreenControllerBeingPressed = false; // need to reset this flag anyway, when all fingers are lefting
OnScreenWidgetView.tapGestureShallBeCancelled = false;
}
return gotOneWidgetPressed;
}
@end
+82 -18
View File
@@ -31,6 +31,8 @@ import UIKit
case touchPad
}
@objc static public var tapGestureShallBeCancelled: Bool = false
@objc public var widgetType: WidgetTypeEnum = WidgetTypeEnum.uninitialized
@objc static public var editMode: Bool = false
@@ -61,6 +63,10 @@ import UIKit
@objc public var layoutChanges: [CGPoint] = []
@objc public var mouseButtonAction: MouseButtonAction = .hovering;
//autoTapTimer
@objc public var autoTapInterval: Int = 49;
private var autoTapTimer: SafeTimer?
private let appWindow: UIView
private var vibrationGenerator = UIImpactFeedbackGenerator(style: .light)
@@ -150,6 +156,7 @@ import UIKit
//slide buttons
private var capturedTouches: NSMutableSet
private let noTouch: UITouch = UITouch()
let setLock = NSLock()
//controller touch pad
private var pointerIdPool: Set<UInt32>
@@ -266,7 +273,6 @@ import UIKit
rightIndicator.anchorPoint = CGPoint(x: 0, y: 0.5)
setupView()
}
required init?(coder: NSCoder) {
@@ -274,6 +280,19 @@ import UIKit
}
// ======================================================================================================
@objc public func setupAutoTapTimer() {
if self.widgetType == WidgetTypeEnum.button {
self.autoTapTimer = SafeTimer(interval:0.001 * Double(autoTapInterval)) {
self.handleButtonDown()
DispatchQueue.global(qos: .userInteractive).async {
usleep(25000)
DispatchQueue.main.async {
self.handleButtonUp()
}
}
}
}
}
@objc public func setVibration(style: Int) {
if #available(iOS 13.0, *) {
@@ -980,7 +999,28 @@ import UIKit
}
//==== wholeButtonPress visual effect=============================================
//==== Button actions =============================================
//==== Button widget tap down=============================================
private func handleTapDownOrSlidein() {
if autoTapInterval < 50 {
handleButtonDown()
}
else{
self.autoTapTimer?.restart()
}
}
private func handleFingerUpOrSlideout() {
if autoTapInterval < 50 {
handleButtonUp()
}
else{
self.autoTapTimer?.suspend()
self.handleButtonUp()
}
}
private func handleButtonDown() {
if !OnScreenWidgetView.editMode {self.sendComboButtonsDownEvent(comboStrings: self.comboButtonStrings)}
CATransaction.begin()
@@ -997,7 +1037,7 @@ import UIKit
CATransaction.commit()
}
private func handlebuttonUp() {
private func handleButtonUp() {
if !OnScreenWidgetView.editMode {self.sendComboButtonsUpEvent(comboStrings: self.comboButtonStrings)}
CATransaction.begin()
CATransaction.setDisableActions(true)
@@ -1150,6 +1190,7 @@ import UIKit
override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) {
self.touchBegan = true
self.firstTouchMoved = false
OnScreenWidgetView.tapGestureShallBeCancelled = true
super.touchesBegan(touches, with: event)
// self.isMultipleTouchEnabled = self.touchPadString == "MOUSEPAD" // only enable multi-touch in mousePad mode
self.isMultipleTouchEnabled = self.widgetType == WidgetTypeEnum.button
@@ -1238,8 +1279,10 @@ import UIKit
// this will also deal with button events
if self.widgetType == WidgetTypeEnum.button && !self.comboButtonStrings.isEmpty {
self.handleButtonDown()
self.handleTapDownOrSlidein()
setLock.lock()
self.capturedTouches.union(touches)
setLock.unlock()
//self.handleButtonSliding(touches: touches)
}
@@ -1248,7 +1291,7 @@ import UIKit
let keyboardCmdStrings = CommandManager.shared.extractKeyStringsFromComboCommand(from: self.cmdString)!
CommandManager.shared.sendKeyComboCommand(keyboardCmdStrings: keyboardCmdStrings) // send multi-key command
DispatchQueue.main.asyncAfter(deadline: .now() + 0.03) { // reset shadow color immediately 50ms later
self.handlebuttonUp()
self.handleButtonUp()
}
}
}
@@ -1316,12 +1359,18 @@ import UIKit
}
private func handleButtonSlidingUp(touches: Set<UITouch>) {
private func handleFingerUpAfterSliding(touches: Set<UITouch>) {
for touch in touches {
for subview in self.superview?.subviews ?? [] {
if let widget = subview as? OnScreenWidgetView{
if !widget.capturedTouches.contains(touch) || widget.slideMode == ButtonSlideMode.disabled.rawValue {continue}
widget.handlebuttonUp()
setLock.lock()
let captured = widget.capturedTouches.contains(touch)
setLock.unlock()
if !captured || widget.slideMode == ButtonSlideMode.disabled.rawValue {continue}
widget.handleFingerUpOrSlideout()
setLock.lock()
widget.capturedTouches.remove(touch)
setLock.unlock()
}
}
}
@@ -1335,17 +1384,27 @@ import UIKit
if widget.widgetType != WidgetTypeEnum.button {continue}
let pointInSubview = widget.convert(locationInSuperView, from: self.superview)
if widget.bounds.contains(pointInSubview){
if widget.capturedTouches.contains(touch) || widget.slideMode == ButtonSlideMode.disabled.rawValue {continue}
setLock.lock()
let captured = widget.capturedTouches.contains(touch)
setLock.unlock()
if captured || widget.slideMode == ButtonSlideMode.disabled.rawValue {continue}
setLock.lock()
widget.capturedTouches.add(touch)
widget.handleButtonDown()
setLock.unlock()
widget.handleTapDownOrSlidein()
// print("UIButton: \(widget.buttonLabel) in, \(widget.touchPadString), \(CACurrentMediaTime())")
}
else{
if !widget.capturedTouches.contains(touch) || widget.slideMode == ButtonSlideMode.disabled.rawValue {continue}
setLock.lock()
let captured = widget.capturedTouches.contains(touch)
setLock.unlock()
if !captured || widget.slideMode == ButtonSlideMode.disabled.rawValue {continue}
// print("UIButton: \(widget.buttonLabel) out test, \(widget.touchPadString), \(CACurrentMediaTime())")
if(widget.slideMode == ButtonSlideMode.toggle.rawValue){
widget.handleFingerUpOrSlideout()
setLock.lock()
widget.capturedTouches.remove(touch)
widget.handlebuttonUp()
setLock.unlock()
}
if(widget.slideMode == ButtonSlideMode.slideAndHold.rawValue){
// do nothing here
@@ -1364,7 +1423,7 @@ import UIKit
handleTouchPadMoveEvent(touches, with: event)
}
if !self.buttonString.isEmpty{
if self.widgetType == WidgetTypeEnum.button {
if self.slideMode != ButtonSlideMode.disabled.rawValue {self.handleButtonSliding(touches: touches)}
}
@@ -1373,7 +1432,7 @@ import UIKit
NSLog("touchTapTimeStamp %f", self.touchTapTimeStamp)
if CACurrentMediaTime() - self.touchTapTimeStamp > 0.3 { // temporarily relocate special buttons
self.moveByTouch(touch: touch)
self.handlebuttonUp()
self.handleButtonUp()
}
}
}
@@ -1457,10 +1516,14 @@ import UIKit
}
}
override func touchesCancelled(_ touches: Set<UITouch>, with event: UIEvent?) {
touchesEnded(touches, with: event)
}
override func touchesEnded(_ touches: Set<UITouch>, with event: UIEvent?) {
self.touchBegan = false
super.touchesEnded(touches, with: event)
CATransaction.begin()
CATransaction.setDisableActions(true)
@@ -1560,8 +1623,10 @@ import UIKit
}
if !OnScreenWidgetView.editMode && !self.cmdString.contains("+") && !self.comboButtonStrings.isEmpty { // if the command(keystring contains "+", it's a legacy multi-key command
self.handleButtonSlidingUp(touches: touches)
self.handleFingerUpAfterSliding(touches: touches)
setLock.lock()
self.capturedTouches.minus(touches)
setLock.unlock()
}
if !OnScreenWidgetView.editMode && CommandManager.specialOverlayButtonCmds.contains(self.cmdString){
@@ -1613,8 +1678,7 @@ import UIKit
}
}
self.handlebuttonUp()
self.handleFingerUpOrSlideout()
}
}
+50
View File
@@ -0,0 +1,50 @@
//
// SafeTimer.swift
// VoidLink
//
// Created by True砖家 on 2025/9/9.
// Copyright © 2025 True砖家@Bilibili. All rights reserved.
//
class SafeTimer {
private var timer: DispatchSourceTimer
private(set) var isRunning = false
private var interval: TimeInterval = 0
init(interval: TimeInterval = 1.0, queue: DispatchQueue = .global(), handler: @escaping () -> Void) {
timer = DispatchSource.makeTimerSource(queue: queue)
timer.schedule(deadline: .now(), repeating: interval)
timer.setEventHandler(handler: handler)
self.interval = interval
// 注意:这里不调用 resume,保持 suspended,等 start() 时才运行
}
public func resume() {
guard !isRunning else { return }
timer.resume()
isRunning = true
}
public func suspend() {
guard isRunning else { return }
timer.suspend()
isRunning = false
}
func restart() {
if isRunning {
timer.suspend()
isRunning = false
}
timer.schedule(deadline: .now(), repeating: self.interval) // 重置时间
timer.resume()
isRunning = true
}
deinit {
if !timer.isCancelled {
timer.cancel()
}
}
}
+2
View File
@@ -492,6 +492,7 @@ static const double X1_MOUSE_SPEED_DIVISOR = 2.5;
widgetView.widthFactor = buttonState.widthFactor;
widgetView.heightFactor = buttonState.heightFactor;
widgetView.borderWidth = buttonState.borderWidth;
widgetView.autoTapInterval = buttonState.autoTapInterval;
[widgetView setVibrationWithStyle:buttonState.vibrationStyle];
widgetView.mouseButtonAction = buttonState.mouseButtonAction;
widgetView.sensitivityFactorX = buttonState.sensitivityFactorX;
@@ -507,6 +508,7 @@ static const double X1_MOUSE_SPEED_DIVISOR = 2.5;
[widgetView resizeWidgetView]; // resize must be called after relocation
[widgetView adjustTransparencyWithAlpha:buttonState.backgroundAlpha];
[widgetView adjustBorderWithWidth:buttonState.borderWidth];
[widgetView setupAutoTapTimer];
}
}
}
+111 -13
View File
@@ -703,7 +703,7 @@
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "控件透明度"
"value" : "透明度"
}
},
"zh-Hant" : {
@@ -726,7 +726,7 @@
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "控件透明度: %.2f"
"value" : "透明度: %.2f"
}
},
"zh-Hant" : {
@@ -789,6 +789,52 @@
}
}
},
"Auto tap disabled" : {
"extractionState" : "manual",
"localizations" : {
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "连点已关闭"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "連點已關閉"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"value" : "連點已關閉"
}
}
}
},
"Auto tap: %dms" : {
"extractionState" : "manual",
"localizations" : {
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "自动连点: %dms "
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "自動連點: %dms "
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"value" : "自動連點: %dms "
}
}
}
},
"Back" : {
"extractionState" : "manual",
"localizations" : {
@@ -933,7 +979,7 @@
}
}
},
"Border Width" : {
"Border width" : {
"extractionState" : "manual",
"localizations" : {
"zh-Hans" : {
@@ -956,7 +1002,7 @@
}
}
},
"Border Width: %.2f" : {
"Border width: %.2f" : {
"extractionState" : "manual",
"localizations" : {
"zh-Hans" : {
@@ -2339,7 +2385,7 @@
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "控件高度"
"value" : "高度"
}
},
"zh-Hant" : {
@@ -2362,19 +2408,19 @@
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "控件高度: %.2f"
"value" : "高度: %.2f "
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "高度:%.2f"
"value" : "高度: %.2f "
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"value" : "高度:%.2f"
"value" : "高度: %.2f "
}
}
}
@@ -2471,7 +2517,30 @@
}
}
},
"Indicator Offset: %.0f" : {
"Important Tips" : {
"extractionState" : "manual",
"localizations" : {
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "重要提示"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "重要提示"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"value" : "重要提示"
}
}
}
},
"Indicator offset: %.0f" : {
"extractionState" : "manual",
"localizations" : {
"zh-Hans" : {
@@ -2701,6 +2770,35 @@
}
}
},
"loadOswConfigTip" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "- Tap the drawer icon to duplicate the default profile, since it cannot be modified or overwritten.\n\n- Tap to load configs for each widget.\n\n- To ensure smooth gameplay without interference:\n - Disable All gestures in: Settings → Multitasking & Gestures\n - Disable Settings → Accessibility → Touch → AssistiveTouch\n - Disable Settings → Accessibility → Zoom\n\n- We recommend using new widgets instead of legacy on-screen controls."
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "- 请点击抽屉图标复制一份默认布局,因为默认布局无法修改或覆盖。\n\n- 点击以加载每个控件的配置。\n\n- 为避免游戏过程被干扰,请务必:\n - 设置 → 多任务与手势 → 关闭所有手势\n - 关闭: 设置 → 辅助功能 → 触控 → 辅助触控\n - 关闭: 设置 → 辅助功能 → 缩放\n\n- 建议使用新版屏显控件,而非旧版屏显手柄。"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "- 請點擊抽屜圖示複製一份預設版面,因為預設版面無法修改或覆蓋。\n\n- 點擊以載入每個元件的設定。\n\n- 為避免遊戲過程被干擾,請務必:\n - 設定 → 多工處理與手勢 → 關閉所有手勢\n - 關閉: 設定 → 輔助使用 → 觸控 → 輔助觸控\n - 關閉: 設定 → 輔助使用 → 縮放\n\n- 建議使用新版螢幕控制元件,而非舊版螢幕顯示手把。"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"value" : "- 請點擊抽屜圖示複製一份預設版面,因為預設版面無法修改或覆蓋。\n\n- 點擊以載入每個元件的設定。\n\n- 為避免遊戲過程被干擾,請務必:\n - 設定 → 多工處理與手勢 → 關閉所有手勢\n - 關閉: 設定 → 輔助使用 → 觸控 → 輔助觸控\n - 關閉: 設定 → 輔助使用 → 縮放\n\n- 建議使用新版螢幕控制元件,而非舊版螢幕顯示手把。"
}
}
}
},
"Local Keyboard Toggle Disabled" : {
"extractionState" : "manual",
"localizations" : {
@@ -4788,7 +4886,7 @@
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "控件大小"
"value" : "大小"
}
},
"zh-Hant" : {
@@ -4811,19 +4909,19 @@
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "控件大小: %.2f"
"value" : "大小: %.2f "
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"value" : "大小:%.2f"
"value" : "大小: %.2f "
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"value" : "大小:%.2f"
"value" : "大小: %.2f "
}
}
}
@@ -88,7 +88,8 @@ NS_ASSUME_NONNULL_BEGIN
@property (strong, nonatomic) IBOutlet UISegmentedControl *vibrationStyleSelector;
@property (strong, nonatomic) IBOutlet UIStackView *vibrationStyleStack;
@property (strong, nonatomic) IBOutlet UILabel *loadConfigTipLabel;
@property (strong, nonatomic) IBOutlet UILabel *tipContentLabel;
@property (strong, nonatomic) IBOutlet UILabel *tipTitleLabel;
@property (strong, nonatomic) IBOutlet UIStackView *mouseDownButtonStack;
@property (strong, nonatomic) IBOutlet UISegmentedControl *mouseButtonDownSelector;
@@ -96,6 +97,10 @@ NS_ASSUME_NONNULL_BEGIN
@property (strong, nonatomic) IBOutlet UIStackView *slidableStack;
@property (strong, nonatomic) IBOutlet UISegmentedControl *slidableSelector;
@property (strong, nonatomic) IBOutlet UIStackView *autoTapStack;
@property (strong, nonatomic) IBOutlet UILabel *autoTapLabel;
@property (strong, nonatomic) IBOutlet UISlider *autoTapSlider;
@property (weak, nonatomic) IBOutlet UIStackView *widgetPanelStack;
@@ -116,6 +116,7 @@
widgetView.widthFactor = buttonState.widthFactor;
widgetView.heightFactor = buttonState.heightFactor;
widgetView.borderWidth = buttonState.borderWidth;
widgetView.autoTapInterval = buttonState.autoTapInterval;
[widgetView setVibrationWithStyle:buttonState.vibrationStyle];
widgetView.mouseButtonAction = buttonState.mouseButtonAction;
widgetView.sensitivityFactorX = buttonState.sensitivityFactorX;
@@ -628,6 +629,7 @@
newWidget.widthFactor = widget.widthFactor;
newWidget.heightFactor = widget.heightFactor;
newWidget.borderWidth = widget.borderWidth;
newWidget.autoTapInterval = widget.autoTapInterval;
newWidget.sensitivityFactorX = widget.sensitivityFactorX;
newWidget.sensitivityFactorY = widget.sensitivityFactorY;
newWidget.trackballDecelerationRate = widget.trackballDecelerationRate;
@@ -698,7 +700,8 @@
}
- (void)enableCommonWidgetTools{
self.loadConfigTipLabel.hidden = YES;
self.tipTitleLabel.hidden = YES;
self.tipContentLabel.hidden = YES;
self.widgetSizeStack.hidden = NO;
self.widgetHeightStack.hidden = NO;
self.borderWidthAlphaStack.hidden = NO;
@@ -735,13 +738,12 @@
// receive the selected widgetView obj passed from the notification
[self enableCommonWidgetTools];
OnScreenWidgetView* widgetView = (OnScreenWidgetView* )notification.object;
self->widgetViewSelected = true;
self->controllerLayerSelected = false;
self->selectedWidgetView = widgetView;
[self autoFitLabel:self.currentProfileLabel];
self.currentProfileLabel.textAlignment = NSTextAlignmentLeft;
[self.currentProfileLabel setText:
@@ -752,14 +754,11 @@
self.undoButton.alpha = selectedWidgetView.layoutChanges.count>1 ? 1.0 : 0.3;
[self.layoutOSC updateGuidelinesForOnScreenWidget:self->selectedWidgetView]; // shows guideline immediately when widget is tapped
// setup slider values
[self.widgetSizeSlider setValue: self->selectedWidgetView.deNormalizedWidthFactor];
[self.widgetHeightSlider setValue: self->selectedWidgetView.deNormalizedHeightFactor];
[self.widgetAlphaSlider setValue: self->selectedWidgetView.backgroundAlpha];
[self.widgetBorderWidthSlider setValue:self->selectedWidgetView.borderWidth];
// hide irrelevant stacks
self.autoTapStack.hidden = selectedWidgetView.widgetType != WidgetTypeEnumButton;
self.slidableStack.hidden = selectedWidgetView.widgetType != WidgetTypeEnumButton;
[self.slidableSelector setSelectedSegmentIndex:selectedWidgetView.slideMode];
bool showSensitivityFactorStack = selectedWidgetView.hasSensitivityTweak;
bool showStickIndicatorOffsetStack = selectedWidgetView.hasStickIndicator;
@@ -771,6 +770,9 @@
[self autoFitStack:self.widgetPanelStack];
// setup values
if(showSensitivityFactorStack){
[self.sensitivityXSlider setValue:self->selectedWidgetView.sensitivityFactorX];
[self autoFitLabel:self.sensitivityXLabel];
@@ -785,28 +787,38 @@
selectedWidgetView.touchBeganLocation = CGPointMake(CGRectGetWidth(selectedWidgetView.frame)/2, CGRectGetHeight(selectedWidgetView.frame)/4);
[selectedWidgetView showStickIndicator];// this will create the indicator CAShapeLayers
[self.stickIndicatorOffsetSlider setValue:self->selectedWidgetView.stickIndicatorOffset];
[self stickIndicatorOffsetSliderMoved:self.stickIndicatorOffsetSlider];
[self autoFitLabel:self.stickIndicatorOffsetLabel];
[self.stickIndicatorOffsetLabel setText:[LocalizationHelper localizedStringForKey:@"Indicator Offset: %.0f", self->selectedWidgetView.stickIndicatorOffset]];
[self->selectedWidgetView updateStickIndicator];
/*[self.stickIndicatorOffsetLabel setText:[LocalizationHelper localizedStringForKey:@"Indicator offset: %.0f", self->selectedWidgetView.stickIndicatorOffset]];
[self->selectedWidgetView updateStickIndicator];*/
}
[self.widgetSizeSlider setValue: self->selectedWidgetView.deNormalizedWidthFactor];
[self autoFitLabel:self.widgetSizeLabel];
[self widgetSizeSliderMoved:self.widgetSizeSlider];
[self.widgetSizeLabel setText:[LocalizationHelper localizedStringForKey:@"Size: %.2f", self->selectedWidgetView.deNormalizedWidthFactor]];
[self.widgetHeightSlider setValue: self->selectedWidgetView.deNormalizedHeightFactor];
[self autoFitLabel:self.widgetHeightLabel];
[self.widgetHeightLabel setText:[LocalizationHelper localizedStringForKey:@"Height: %.2f", self->selectedWidgetView.deNormalizedHeightFactor]];
[self widgetHeightSliderMoved:self.widgetHeightSlider];
[self.widgetAlphaSlider setValue: self->selectedWidgetView.backgroundAlpha];
[self autoFitLabel:self.widgetAlphaLabel];
[self.widgetAlphaLabel setText:[LocalizationHelper localizedStringForKey:@"Alpha: %.2f", self->selectedWidgetView.backgroundAlpha]];
[self widgetAlphaSliderMoved:self.widgetAlphaSlider];
[self.widgetBorderWidthSlider setValue:self->selectedWidgetView.borderWidth];
[self autoFitLabel:self.widgetBorderWidthLabel];
[self.widgetBorderWidthLabel setText:[LocalizationHelper localizedStringForKey:@"Border Width: %.2f", self->selectedWidgetView.borderWidth]];
[self widgetBorderWidthSliderMoved:self.widgetBorderWidthSlider];
[self.autoTapSlider setValue:self->selectedWidgetView.autoTapInterval];
[self autoFitLabel:self.autoTapLabel];
[self autoTapSliderMoved:self.autoTapSlider];
[self.decelerationRateSlider setValue:selectedWidgetView.trackballDecelerationRate];
[self autoFitLabel:self.decelerationRateLabel];
[self.decelerationRateLabel setText:[LocalizationHelper localizedStringForKey:@"Deceleration Rate: %.3f ", selectedWidgetView.trackballDecelerationRate]];
[self decelerationRateSliderMoved:self.decelerationRateSlider];
self.mouseButtonDownSelector.selectedSegmentIndex = selectedWidgetView.mouseButtonAction;
[self.slidableSelector setSelectedSegmentIndex:selectedWidgetView.slideMode];
if([self isIPhone]){
self.vibrationStyleStack.hidden =
@@ -820,11 +832,13 @@
- (void)legacyOscLayerTapped: (NSNotification *)notification{
[self enableCommonWidgetTools];
CALayer* controllerLayer = (CALayer* )notification.object;
[self hideStickIndicators];
self->widgetViewSelected = false;
self->selectedWidgetView = nil;
self.autoTapStack.hidden = true; // won't implement auto tap for legacy buttons
self.stickIndicatorOffsetStack.hidden = true;
self.sensitivityXStack.hidden = self.sensitivityYStack.hidden = true;
self.mouseDownButtonStack.hidden = true;
@@ -899,13 +913,22 @@
}
- (void)widgetBorderWidthSliderMoved:(UISlider* )sender{
[self.widgetBorderWidthLabel setText:[LocalizationHelper localizedStringForKey:@"Border Width: %.2f", sender.value]];
[self.widgetBorderWidthLabel setText:[LocalizationHelper localizedStringForKey:@"Border width: %.2f", sender.value]];
if(self->selectedWidgetView != nil && self->widgetViewSelected){
[self->selectedWidgetView adjustBorderWithWidth:sender.value];
}
return;
}
- (void)autoTapSliderMoved:(UISlider* )sender{
[self.autoTapLabel setText:(uint16_t)sender.value < 50 ? [LocalizationHelper localizedStringForKey: @"Auto tap disabled"] : [LocalizationHelper localizedStringForKey: @"Auto tap: %dms", (uint16_t)sender.value]];
if(self->selectedWidgetView != nil && self->widgetViewSelected){
selectedWidgetView.autoTapInterval = (uint16_t)sender.value;
}
return;
}
- (void)mouseDownButtonChanged:(UISegmentedControl* )sender{
if(self->selectedWidgetView != nil && self->widgetViewSelected){
selectedWidgetView.mouseButtonAction = _mouseButtonDownSelector.selectedSegmentIndex;
@@ -964,7 +987,7 @@
- (void)stickIndicatorOffsetSliderMoved:(UISlider* )sender{
[self.stickIndicatorOffsetLabel setText:[LocalizationHelper localizedStringForKey:@"Indicator Offset: %.0f", sender.value]];
[self.stickIndicatorOffsetLabel setText:[LocalizationHelper localizedStringForKey:@"Indicator offset: %.0f", sender.value]];
if(self->selectedWidgetView != nil && self->widgetViewSelected){
self->selectedWidgetView.stickIndicatorOffset = sender.value;
[self->selectedWidgetView updateStickIndicator];
@@ -1006,7 +1029,24 @@
- (void)setupWidgetPanel{
self.widgetPanelStack.hidden = _quickSwitchEnabled;
self.loadConfigTipLabel.hidden = NO;
self.tipTitleLabel.textAlignment = NSTextAlignmentLeft;
self.tipTitleLabel.contentMode = UIViewContentModeTop;
self.tipTitleLabel.lineBreakMode = NSLineBreakByWordWrapping;
self.tipTitleLabel.numberOfLines = 0;
self.tipTitleLabel.font = [UIFont systemFontOfSize:23 weight:UIFontWeightBold];
self.tipTitleLabel.text = [LocalizationHelper localizedStringForKey:@"Important Tips"];
self.tipTitleLabel.hidden = [self isIPhone];
self.tipContentLabel.textAlignment = NSTextAlignmentLeft;
self.tipContentLabel.lineBreakMode = NSLineBreakByWordWrapping;
self.tipContentLabel.contentMode = UIViewContentModeTop;
self.tipContentLabel.numberOfLines = 0;
self.tipContentLabel.accessibilityIdentifier = @"tipContent";
self.tipContentLabel.font = [UIFont systemFontOfSize:[self isIPhone]?15:15];
self.tipContentLabel.text = [LocalizationHelper localizedStringForKey:@"loadOswConfigTip"];
self.tipContentLabel.hidden = NO;
// if([self isIPhone]) [self autoFitLabel:self.tipContentLabel];loadOswConfigTip
self.widgetPanelStack.layoutMargins = UIEdgeInsetsMake(10, 10, 10, 10);
self.widgetPanelStack.layoutMarginsRelativeArrangement = YES;
@@ -1023,7 +1063,7 @@
self.widgetSizeStack.userInteractionEnabled = YES;
for(UIView* view in _widgetPanelStack.subviews){
view.userInteractionEnabled = YES;
if([view isKindOfClass:[UILabel class]]){
if([view isKindOfClass:[UILabel class]] && !view.accessibilityIdentifier){
UILabel* label = (UILabel* )view;
label.font = [UIFont systemFontOfSize:18];
label.textColor = [UIColor whiteColor];
@@ -1035,7 +1075,6 @@
self.widgetSizeStack.hidden = YES;
[self.widgetHeightSlider addTarget:self action:@selector(widgetHeightSliderMoved:) forControlEvents:(UIControlEventValueChanged)];
self.widgetHeightLabel.text = [LocalizationHelper localizedStringForKey:@"Height"];
self.widgetHeightStack.hidden = YES;
@@ -1043,8 +1082,12 @@
self.widgetAlphaLabel.text = [LocalizationHelper localizedStringForKey:@"Alpha"];
[self.widgetBorderWidthSlider addTarget:self action:@selector(widgetBorderWidthSliderMoved:) forControlEvents:(UIControlEventValueChanged)];
self.widgetBorderWidthLabel.text = [LocalizationHelper localizedStringForKey:@"Border Width"];
self.widgetBorderWidthLabel.text = [LocalizationHelper localizedStringForKey:@"Border width"];
self.borderWidthAlphaStack.hidden = YES;
[self.autoTapSlider addTarget:self action:@selector(autoTapSliderMoved:) forControlEvents:(UIControlEventValueChanged)];
self.autoTapLabel.text = [LocalizationHelper localizedStringForKey:@"Autotap"];
self.autoTapStack.hidden = YES;
[self.sensitivityXSlider addTarget:self action:@selector(sensitivityXSliderMoved:) forControlEvents:(UIControlEventValueChanged)];
self.sensitivityXLabel.text = [LocalizationHelper localizedStringForKey:@"SensitivityX"];
@@ -1063,7 +1106,7 @@
// stick indicator offset slider
//self.stickIndicatorOffsetSlider.hidden = YES;
[self.stickIndicatorOffsetSlider addTarget:self action:@selector(stickIndicatorOffsetSliderMoved:) forControlEvents:(UIControlEventValueChanged)];
self.stickIndicatorOffsetLabel.text = [LocalizationHelper localizedStringForKey:@"Indicator Offset"];
self.stickIndicatorOffsetLabel.text = [LocalizationHelper localizedStringForKey:@"Indicator offset"];
self.stickIndicatorOffsetStack.hidden = YES;
NSDictionary *whiteFontAttributes = @{
+52 -28
View File
@@ -823,6 +823,18 @@
}
}
},
"And-W9-9NR.text" : {
"comment" : "Class = \"UILabel\"; text = \"Auto tap: 100ms\"; ObjectID = \"And-W9-9NR\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Auto tap: 100ms"
}
}
}
},
"aup-5k-z6P.text" : {
"comment" : "Class = \"UILabel\"; text = \"Show Local Keyboard Toolbar \"; ObjectID = \"aup-5k-z6P\";",
"extractionState" : "extracted_with_value",
@@ -1034,30 +1046,30 @@
}
},
"c1r-Hf-b7t.text" : {
"comment" : "Class = \"UILabel\"; text = \"Down Button\"; ObjectID = \"c1r-Hf-b7t\";",
"comment" : "Class = \"UILabel\"; text = \"Down button\"; ObjectID = \"c1r-Hf-b7t\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Down Button"
"value" : "Down button"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "鼠标按下"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑鼠按下"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑鼠按下"
}
}
@@ -2804,13 +2816,13 @@
}
},
"NZO-BM-nef.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"NZO-BM-nef\";",
"comment" : "Class = \"UILabel\"; text = \"SensitivityY\"; ObjectID = \"NZO-BM-nef\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "SensitivityY"
}
}
}
@@ -2906,13 +2918,13 @@
}
},
"Pbt-Tw-dnV.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"Pbt-Tw-dnV\";",
"comment" : "Class = \"UILabel\"; text = \"DecelerationRate\"; ObjectID = \"Pbt-Tw-dnV\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "DecelerationRate"
}
}
}
@@ -2948,13 +2960,13 @@
}
},
"Pwa-YK-6Q2.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"Pwa-YK-6Q2\";",
"comment" : "Class = \"UILabel\"; text = \"Alpha\"; ObjectID = \"Pwa-YK-6Q2\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Alpha"
}
}
}
@@ -3050,30 +3062,30 @@
}
},
"qNQ-fB-jhY.text" : {
"comment" : "Class = \"UILabel\"; text = \"Slide Activated\"; ObjectID = \"qNQ-fB-jhY\";",
"comment" : "Class = \"UILabel\"; text = \"Slide activated\"; ObjectID = \"qNQ-fB-jhY\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Slide Activated"
"value" : "Slide activated"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑动触发"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑動觸發"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑動觸發"
}
}
@@ -3260,13 +3272,13 @@
}
},
"r8L-dl-yLZ.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"r8L-dl-yLZ\";",
"comment" : "Class = \"UILabel\"; text = \"BorderWidth\"; ObjectID = \"r8L-dl-yLZ\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "BorderWidth"
}
}
}
@@ -3332,13 +3344,13 @@
}
},
"sbd-0j-KWS.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"sbd-0j-KWS\";",
"comment" : "Class = \"UILabel\"; text = \"Height\"; ObjectID = \"sbd-0j-KWS\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Height"
}
}
}
@@ -3404,13 +3416,25 @@
}
},
"tG7-oX-P9b.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"tG7-oX-P9b\";",
"comment" : "Class = \"UILabel\"; text = \"Stick Indicator\"; ObjectID = \"tG7-oX-P9b\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Stick Indicator"
}
}
}
},
"toF-yb-f3V.text" : {
"comment" : "Class = \"UILabel\"; text = \"Tap any widget to load configuration (per widget)\\n\"; ObjectID = \"toF-yb-f3V\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Tap any widget to load configuration (per widget)\n"
}
}
}
@@ -3446,13 +3470,13 @@
}
},
"vJs-pg-hHe.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"vJs-pg-hHe\";",
"comment" : "Class = \"UILabel\"; text = \"SensitivityX\"; ObjectID = \"vJs-pg-hHe\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "SensitivityX"
}
}
}
@@ -3518,13 +3542,13 @@
}
},
"xfv-K0-1CO.text" : {
"comment" : "Class = \"UILabel\"; text = \"Tap any widget to load configuration (per widget)\"; ObjectID = \"xfv-K0-1CO\";",
"comment" : "Class = \"UILabel\"; text = \"Tap any widget to load configuration (per widget)\\n\"; ObjectID = \"xfv-K0-1CO\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Tap any widget to load configuration (per widget)"
"value" : "Tap any widget to load configuration (per widget)\n"
}
},
"zh-Hans" : {
@@ -3668,13 +3692,13 @@
}
},
"ZuV-4A-0Zb.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"ZuV-4A-0Zb\";",
"comment" : "Class = \"UILabel\"; text = \"Size\"; ObjectID = \"ZuV-4A-0Zb\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Size"
}
}
}
+68 -32
View File
@@ -669,7 +669,7 @@
},
"9Gg-66-UdB.text" : {
"comment" : "Class = \"UILabel\"; text = \"Tap any widget to load configuration (per widget)\"; ObjectID = \"9Gg-66-UdB\";",
"extractionState" : "extracted_with_value",
"extractionState" : "stale",
"localizations" : {
"en" : {
"stringUnit" : {
@@ -1334,13 +1334,13 @@
}
},
"dJh-Ck-ugh.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"dJh-Ck-ugh\";",
"comment" : "Class = \"UILabel\"; text = \"SensitivityX\"; ObjectID = \"dJh-Ck-ugh\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "SensitivityX"
}
}
}
@@ -1466,13 +1466,13 @@
}
},
"eiL-iX-G3Z.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"eiL-iX-G3Z\";",
"comment" : "Class = \"UILabel\"; text = \"BorderWidth\"; ObjectID = \"eiL-iX-G3Z\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "BorderWidth"
}
}
}
@@ -1520,13 +1520,13 @@
}
},
"fcy-zp-LGa.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"fcy-zp-LGa\";",
"comment" : "Class = \"UILabel\"; text = \"Stick Indicator\"; ObjectID = \"fcy-zp-LGa\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Stick Indicator"
}
}
}
@@ -1772,13 +1772,13 @@
}
},
"Idx-O1-5dn.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"Idx-O1-5dn\";",
"comment" : "Class = \"UILabel\"; text = \"Height\"; ObjectID = \"Idx-O1-5dn\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Height"
}
}
}
@@ -1831,6 +1831,30 @@
}
}
},
"IuG-44-1Je.text" : {
"comment" : "Class = \"UILabel\"; text = \"Autotap: 100ms\"; ObjectID = \"IuG-44-1Je\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Autotap: 100ms"
}
}
}
},
"jh9-zs-2EL.text" : {
"comment" : "Class = \"UILabel\"; text = \"Profile:\"; ObjectID = \"jh9-zs-2EL\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Profile:"
}
}
}
},
"jWW-mN-TwW.text" : {
"comment" : "Class = \"UILabel\"; text = \"Gyro Mode\"; ObjectID = \"jWW-mN-TwW\";",
"extractionState" : "extracted_with_value",
@@ -1862,13 +1886,13 @@
}
},
"kva-gQ-CZh.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"kva-gQ-CZh\";",
"comment" : "Class = \"UILabel\"; text = \"Size\"; ObjectID = \"kva-gQ-CZh\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Size"
}
}
}
@@ -2138,30 +2162,30 @@
}
},
"o9I-Gt-YRd.text" : {
"comment" : "Class = \"UILabel\"; text = \"Slide Activated\"; ObjectID = \"o9I-Gt-YRd\";",
"comment" : "Class = \"UILabel\"; text = \"Slide activated\"; ObjectID = \"o9I-Gt-YRd\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Slide Activated"
"value" : "Slide activated"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑动触发"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑動觸發"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑動觸發"
}
}
@@ -2318,30 +2342,30 @@
}
},
"ozU-7C-qKE.text" : {
"comment" : "Class = \"UILabel\"; text = \"Button Down\"; ObjectID = \"ozU-7C-qKE\";",
"comment" : "Class = \"UILabel\"; text = \"Button down\"; ObjectID = \"ozU-7C-qKE\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Button Down"
"value" : "Button down"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "鼠标按下"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑鼠按下"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "滑鼠按下"
}
}
@@ -2612,13 +2636,13 @@
}
},
"qPQ-U2-aSg.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"qPQ-U2-aSg\";",
"comment" : "Class = \"UILabel\"; text = \"Alpha\"; ObjectID = \"qPQ-U2-aSg\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "Alpha"
}
}
}
@@ -2834,13 +2858,13 @@
}
},
"R9C-JW-nkF.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"R9C-JW-nkF\";",
"comment" : "Class = \"UILabel\"; text = \"SensitivityY\"; ObjectID = \"R9C-JW-nkF\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "SensitivityY"
}
}
}
@@ -3254,30 +3278,30 @@
}
},
"u3w-Se-xzH.text" : {
"comment" : "Class = \"UILabel\"; text = \"Vibration Style\"; ObjectID = \"u3w-Se-xzH\";",
"comment" : "Class = \"UILabel\"; text = \"Vibration style\"; ObjectID = \"u3w-Se-xzH\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Vibration Style"
"value" : "Vibration style"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "振动模式"
}
},
"zh-Hant" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "振动模式"
}
},
"zh-HK" : {
"stringUnit" : {
"state" : "translated",
"state" : "needs_review",
"value" : "振动模式"
}
}
@@ -3667,6 +3691,18 @@
}
}
},
"zCC-w1-yXO.text" : {
"comment" : "Class = \"UILabel\"; text = \"Profile:\"; ObjectID = \"zCC-w1-yXO\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "Profile:"
}
}
}
},
"zLl-8w-K8J.segmentTitles[0]" : {
"comment" : "Class = \"UISegmentedControl\"; zLl-8w-K8J.segmentTitles[0] = \"Captured\"; ObjectID = \"zLl-8w-K8J\";",
"extractionState" : "extracted_with_value",
@@ -3758,13 +3794,13 @@
}
},
"znE-Lv-uWV.text" : {
"comment" : "Class = \"UILabel\"; text = \"test\"; ObjectID = \"znE-Lv-uWV\";",
"comment" : "Class = \"UILabel\"; text = \"DecelerationRate\"; ObjectID = \"znE-Lv-uWV\";",
"extractionState" : "extracted_with_value",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "new",
"value" : "test"
"value" : "DecelerationRate"
}
}
}