make on-screen L1/R1 & left & right stick larger by setting option
@@ -500,8 +500,8 @@ ICAgICAgICAgICAgICA
|
||||
<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="Turn on On-Screen Controls Visual Feedback " textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="2Bp-XZ-cCw">
|
||||
<rect key="frame" x="15" y="644" width="456" height="21"/>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Larger Sticks & L1/R1 Buttons" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="2Bp-XZ-cCw">
|
||||
<rect key="frame" x="15" y="644" width="223" height="21"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.93902439019999995" green="0.9625305918" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
@@ -535,6 +535,7 @@ ICAgICAgICAgICAgICA
|
||||
<outlet property="hdrSelector" destination="OA2-SA-bBO" id="uUL-mc-4We"/>
|
||||
<outlet property="keyboardToggleFingerNumLabel" destination="nh6-cn-z23" id="ong-b0-2ST"/>
|
||||
<outlet property="keyboardToggleFingerNumSlider" destination="4wJ-Gd-Dmp" id="fbp-o8-KRA"/>
|
||||
<outlet property="largerStickLR1Selector" destination="sIU-PH-H7V" id="YWg-40-eKd"/>
|
||||
<outlet property="liftStreamViewForKeyboardSelector" destination="hm3-EV-h6d" id="fHG-J1-eQL"/>
|
||||
<outlet property="mousePointerVelocityFactorSlider" destination="Ei2-FJ-9oC" id="1T3-QA-Jua"/>
|
||||
<outlet property="mousePointerVelocityFactorUILabel" destination="oPM-G6-u5O" id="Eco-5u-PRR"/>
|
||||
@@ -542,7 +543,6 @@ ICAgICAgICAgICAgICA
|
||||
<outlet property="onscreenControlSelector" destination="qSU-wh-tqA" id="j8d-fB-Z2c"/>
|
||||
<outlet property="onscreenControllerLabel" destination="LGV-5y-piG" id="GsV-fS-lX9"/>
|
||||
<outlet property="optimizeSettingsSelector" destination="nCO-OT-dV1" id="FB0-Rt-C44"/>
|
||||
<outlet property="oscVisualFeedbackSelector" destination="sIU-PH-H7V" id="YWg-40-eKd"/>
|
||||
<outlet property="pointerVelocityModeDividerSlider" destination="AcZ-2i-GI4" id="dGf-ZU-w3S"/>
|
||||
<outlet property="pointerVelocityModeDividerUILabel" destination="DkI-w6-jku" id="edY-gX-2Cw"/>
|
||||
<outlet property="resolutionDisplayView" destination="9cG-JD-glb" id="TT1-hy-MUC"/>
|
||||
|
||||
@@ -552,6 +552,7 @@ ICAgICAgICAgICAgIA
|
||||
<outlet property="hdrSelector" destination="9xD-GL-9xq" id="5Rf-R7-5TO"/>
|
||||
<outlet property="keyboardToggleFingerNumLabel" destination="PD9-1O-J34" id="EvS-vA-dJD"/>
|
||||
<outlet property="keyboardToggleFingerNumSlider" destination="9rm-7X-TVH" id="SOR-7r-clv"/>
|
||||
<outlet property="largerStickLR1Selector" destination="XbO-CV-orB" id="7vF-xY-n4F"/>
|
||||
<outlet property="liftStreamViewForKeyboardSelector" destination="pQE-vU-Nr7" id="avO-LL-zes"/>
|
||||
<outlet property="mousePointerVelocityFactorSlider" destination="cS3-8R-rEd" id="pcU-fp-Fzg"/>
|
||||
<outlet property="mousePointerVelocityFactorUILabel" destination="ecG-dC-PT1" id="MCr-m1-WHm"/>
|
||||
@@ -559,7 +560,6 @@ ICAgICAgICAgICAgIA
|
||||
<outlet property="onscreenControlSelector" destination="WGf-9d-eAm" id="hob-se-4Sn"/>
|
||||
<outlet property="onscreenControllerLabel" destination="HZT-dd-DuQ" id="xyM-q6-IAK"/>
|
||||
<outlet property="optimizeSettingsSelector" destination="Gob-Lu-b1y" id="9Wl-yp-0Ou"/>
|
||||
<outlet property="oscVisualFeedbackSelector" destination="XbO-CV-orB" id="7vF-xY-n4F"/>
|
||||
<outlet property="pointerVelocityModeDividerSlider" destination="xet-C9-l5y" id="GnQ-xU-e0N"/>
|
||||
<outlet property="pointerVelocityModeDividerUILabel" destination="VlN-ZW-1gm" id="vbe-QK-hZb"/>
|
||||
<outlet property="resolutionDisplayView" destination="Dej-Bj-F6i" id="bi4-N6-snx"/>
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
pointerVelocityModeDivider:(CGFloat)pointerVelocityModeDivider
|
||||
touchPointerVelocityFactor:(CGFloat)touchPointerVelocityFactor
|
||||
mousePointerVelocityFactor:(CGFloat)mousePointerVelocityFactor
|
||||
oscVisualFeedback:(BOOL)oscVisualFeedback
|
||||
largerStickLR1:(BOOL)largerStickLR1
|
||||
liftStreamViewForKeyboard:(BOOL)liftStreamViewForKeyboard
|
||||
showKeyboardToolbar:(BOOL)showKeyboardToolbar
|
||||
optimizeGames:(BOOL)optimizeGames
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
pointerVelocityModeDivider:(CGFloat)pointerVelocityModeDivider
|
||||
touchPointerVelocityFactor:(CGFloat)touchPointerVelocityFactor
|
||||
mousePointerVelocityFactor:(CGFloat)mousePointerVelocityFactor
|
||||
oscVisualFeedback:(BOOL)oscVisualFeedback
|
||||
largerStickLR1:(BOOL)largerStickLR1
|
||||
liftStreamViewForKeyboard:(BOOL)liftStreamViewForKeyboard
|
||||
showKeyboardToolbar:(BOOL)showKeyboardToolbar
|
||||
optimizeGames:(BOOL)optimizeGames
|
||||
@@ -96,7 +96,7 @@
|
||||
settingsToSave.pointerVelocityModeDivider = [NSNumber numberWithFloat:pointerVelocityModeDivider];
|
||||
settingsToSave.touchPointerVelocityFactor = [NSNumber numberWithFloat:touchPointerVelocityFactor];
|
||||
settingsToSave.mousePointerVelocityFactor = [NSNumber numberWithFloat:mousePointerVelocityFactor];
|
||||
settingsToSave.oscVisualFeedback = oscVisualFeedback;
|
||||
settingsToSave.largerStickLR1 = largerStickLR1;
|
||||
settingsToSave.liftStreamViewForKeyboard = liftStreamViewForKeyboard;
|
||||
settingsToSave.showKeyboardToolbar = showKeyboardToolbar;
|
||||
settingsToSave.optimizeGames = optimizeGames;
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
CODEC_PREF_HEVC,
|
||||
CODEC_PREF_AV1,
|
||||
} preferredCodec;
|
||||
@property (nonatomic) BOOL oscVisualFeedback;
|
||||
@property (nonatomic) BOOL largerStickLR1;
|
||||
@property (nonatomic) BOOL useFramePacing;
|
||||
@property (nonatomic) BOOL multiController;
|
||||
@property (nonatomic) BOOL swapABXYButtons;
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
self.multiController = settings.multiController;
|
||||
self.swapABXYButtons = settings.swapABXYButtons;
|
||||
self.onscreenControls = settings.onscreenControls;
|
||||
self.oscVisualFeedback = settings.oscVisualFeedback;
|
||||
self.largerStickLR1 = settings.largerStickLR1;
|
||||
self.btMouseSupport = settings.btMouseSupport;
|
||||
// self.absoluteTouchMode = settings.absoluteTouchMode;
|
||||
self.touchMode = settings.touchMode;
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"scale" : "1x",
|
||||
"filename" : "stick_inner_48x49@1x.png"
|
||||
},
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"scale" : "2x",
|
||||
"filename" : "stick_inner_96x97@2x.png"
|
||||
},
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"scale" : "3x",
|
||||
"filename" : "stick_inner_144x146@3x.png"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
||||
|
After Width: | Height: | Size: 5.8 KiB |
|
After Width: | Height: | Size: 2.6 KiB |
|
After Width: | Height: | Size: 5.4 KiB |
|
Before Width: | Height: | Size: 6.4 KiB After Width: | Height: | Size: 5.8 KiB |
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 5.4 KiB |
@@ -50,6 +50,7 @@
|
||||
- (void) drawButtons {
|
||||
[super setDPadCenter]; // Set custom position for D-Pad here
|
||||
[super setAnalogStickPositions]; // Set custom position for analog sticks here
|
||||
[super drawBumpers];
|
||||
[super drawButtons];
|
||||
|
||||
UIImage* downButtonImage = [UIImage imageNamed:@"DownButton"];
|
||||
|
||||
@@ -75,6 +75,7 @@ typedef NS_ENUM(NSInteger, OnScreenControlsLevel) {
|
||||
- (void) show;
|
||||
- (void) setupComplexControls;
|
||||
- (void) drawButtons;
|
||||
- (void) drawBumpers;
|
||||
- (void) updateControls;
|
||||
- (OnScreenControlsLevel) getLevel;
|
||||
- (void) setDPadCenter;
|
||||
|
||||
@@ -57,7 +57,7 @@ static NSMutableSet* touchAddrsCapturedByOnScreenControls;
|
||||
Controller *_controller;
|
||||
NSMutableArray* _deadTouches;
|
||||
BOOL _swapABXY;
|
||||
BOOL _visualFeedback;
|
||||
BOOL _largerStickLR1;
|
||||
OSCProfilesManager *profilesManager;
|
||||
NSMutableDictionary *_activeCustomOscButtonPositionDict;
|
||||
}
|
||||
@@ -146,8 +146,12 @@ static float L3_Y;
|
||||
_deadTouches = [[NSMutableArray alloc] init];
|
||||
if (streamConfig) {
|
||||
_swapABXY = streamConfig.swapABXYButtons;
|
||||
_visualFeedback = streamConfig.oscVisualFeedback; // turn visual feedback of the OSC buttons on or off
|
||||
}
|
||||
// we have to retrieve largerStickLR1 setting direct from the database, since streamConfig is invalid in LayoutOnScreenControls
|
||||
DataManager* dataMan = [[DataManager alloc] init];
|
||||
Settings* settings = [dataMan retrieveSettings];
|
||||
_largerStickLR1 = settings.largerStickLR1;
|
||||
|
||||
|
||||
_iPad = ([UIDevice currentDevice].userInterfaceIdiom == UIUserInterfaceIdiomPad);
|
||||
_controlArea = CGRectMake(0, 0, _view.frame.size.width, _view.frame.size.height);
|
||||
@@ -595,8 +599,12 @@ static float L3_Y;
|
||||
/**
|
||||
* Loads the selected OSC profile and lays out each button associated with that profile onto the screen
|
||||
*/
|
||||
|
||||
# define LR2_Y_UP_OFFSET 8
|
||||
# define LR1_Y_DOWN_OFFSET 3.5
|
||||
- (void) positionOSCButtons {
|
||||
OSCProfile *oscProfile = [profilesManager getSelectedProfile];
|
||||
bool defaultProfileSelected = [profilesManager getIndexOfSelectedProfile] == 0;
|
||||
|
||||
for (NSData *buttonStateEncoded in oscProfile.buttonStates) {
|
||||
|
||||
@@ -605,17 +613,20 @@ static float L3_Y;
|
||||
for (CALayer *buttonLayer in self.OSCButtonLayers) { // iterate through each button layer on screen and position and hide/unhide each according to the instructions of its associated 'buttonState'
|
||||
|
||||
if ([buttonLayer.name isEqualToString:buttonStateDecoded.name]) {
|
||||
|
||||
if ([buttonLayer.name isEqualToString:@"upButton"] == NO &&
|
||||
[buttonLayer.name isEqualToString:@"rightButton"] == NO &&
|
||||
[buttonLayer.name isEqualToString:@"downButton"] == NO &&
|
||||
[buttonLayer.name isEqualToString:@"leftButton"] == NO &&
|
||||
[buttonLayer.name isEqualToString:@"leftStick"] == NO &&
|
||||
[buttonLayer.name isEqualToString:@"rightStick"] == NO) { // Don't move these buttons since they've already been positioned correctly in the 'drawButtons' and 'drawSticks' methods called before this method is called. The 'buttonStateDecoded' object associated with these buttons contains positions relative to a parent CALayer which only exists on 'LayoutOnScreenControls'. These positions relative to the parent layers would translate incorrectly when placed on the game stream VC's 'view' layer
|
||||
|
||||
buttonLayer.position = buttonStateDecoded.position;
|
||||
}
|
||||
buttonLayer.hidden = buttonStateDecoded.isHidden;
|
||||
|
||||
// adjust default layout for largerStickLR1
|
||||
if( defaultProfileSelected && _largerStickLR1)
|
||||
if([buttonLayer.name isEqualToString:@"l2Button"] || [buttonLayer.name isEqualToString:@"r2Button"]) buttonLayer.position = CGPointMake(buttonLayer.position.x, buttonLayer.position.y - LR2_Y_UP_OFFSET);
|
||||
if([buttonLayer.name isEqualToString:@"l1Button"] || [buttonLayer.name isEqualToString:@"r1Button"]) buttonLayer.position = CGPointMake(buttonLayer.position.x, buttonLayer.position.y + LR1_Y_DOWN_OFFSET);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -636,6 +647,9 @@ static float L3_Y;
|
||||
}
|
||||
|
||||
- (void) drawBumpers {
|
||||
// adjust layout for larger L2 & R2 button settings
|
||||
if(_largerStickLR1) L1_Y = R1_Y = L1_Y + LR1_Y_DOWN_OFFSET;
|
||||
|
||||
// create L1 button
|
||||
UIImage* l1ButtonImage = [UIImage imageNamed:@"L1"];
|
||||
_l1Button.frame = CGRectMake(L1_X - l1ButtonImage.size.width / 2, L1_Y - l1ButtonImage.size.height / 2, l1ButtonImage.size.width, l1ButtonImage.size.height);
|
||||
@@ -646,10 +660,20 @@ static float L3_Y;
|
||||
UIImage* r1ButtonImage = [UIImage imageNamed:@"R1"];
|
||||
_r1Button.frame = CGRectMake(R1_X - r1ButtonImage.size.width / 2, R1_Y - r1ButtonImage.size.height / 2, r1ButtonImage.size.width, r1ButtonImage.size.height);
|
||||
_r1Button.contents = (id) r1ButtonImage.CGImage;
|
||||
|
||||
// make l1 r1 the same size as l2 r2
|
||||
if(_largerStickLR1){
|
||||
UIImage* l2ButtonImage = [UIImage imageNamed:@"L2"];
|
||||
_l1Button.bounds = _r1Button.bounds = CGRectMake(0, 0, l2ButtonImage.size.width, l2ButtonImage.size.height);
|
||||
}
|
||||
|
||||
[_view.layer addSublayer:_r1Button];
|
||||
}
|
||||
|
||||
- (void) drawTriggers {
|
||||
// adjust layout for larger L2 & R2 button settings
|
||||
if(_largerStickLR1) L2_Y = R2_Y = L2_Y - LR2_Y_UP_OFFSET;
|
||||
|
||||
// create L2 button
|
||||
UIImage* l2ButtonImage = [UIImage imageNamed:@"L2"];
|
||||
_l2Button.frame = CGRectMake(L2_X - l2ButtonImage.size.width / 2, L2_Y - l2ButtonImage.size.height / 2, l2ButtonImage.size.width, l2ButtonImage.size.height);
|
||||
@@ -681,13 +705,27 @@ static float L3_Y;
|
||||
_rightStickBackground.contents = (id) rightStickBgImage.CGImage;
|
||||
[_view.layer addSublayer:_rightStickBackground];
|
||||
|
||||
|
||||
|
||||
UIImage* rightStickImage = [UIImage imageNamed:@"StickInner"];
|
||||
_rightStick.frame = CGRectMake(RS_CENTER_X - rightStickImage.size.width / 2, RS_CENTER_Y - rightStickImage.size.height / 2, rightStickImage.size.width, rightStickImage.size.height);
|
||||
|
||||
_rightStick.contents = (id) rightStickImage.CGImage;
|
||||
[_view.layer addSublayer:_rightStick];
|
||||
|
||||
STICK_INNER_SIZE = rightStickImage.size.width;
|
||||
STICK_OUTER_SIZE = rightStickBgImage.size.width;
|
||||
// make stick larger
|
||||
if(_largerStickLR1){
|
||||
STICK_INNER_SIZE = rightStickImage.size.width *1.37;
|
||||
STICK_OUTER_SIZE = rightStickBgImage.size.width *1.17;
|
||||
_rightStick.bounds = _leftStick.bounds = CGRectMake(0, 0, STICK_INNER_SIZE, STICK_INNER_SIZE);
|
||||
_rightStickBackground.bounds = _leftStickBackground.bounds = CGRectMake(0, 0, STICK_OUTER_SIZE, STICK_OUTER_SIZE);
|
||||
}
|
||||
else{
|
||||
STICK_INNER_SIZE = rightStickImage.size.width;
|
||||
STICK_OUTER_SIZE = rightStickBgImage.size.width;
|
||||
_rightStick.bounds = _leftStick.bounds = CGRectMake(0, 0, STICK_INNER_SIZE, STICK_INNER_SIZE);
|
||||
_rightStickBackground.bounds = _leftStickBackground.bounds = CGRectMake(0, 0, STICK_OUTER_SIZE, STICK_OUTER_SIZE);
|
||||
}
|
||||
}
|
||||
|
||||
- (void) drawL3R3 {
|
||||
@@ -861,7 +899,6 @@ static float L3_Y;
|
||||
|
||||
|
||||
- (void)oscButtonTouchDownVisualEffect:(CALayer* )button{
|
||||
if(_visualFeedback){
|
||||
[CATransaction begin];
|
||||
[CATransaction setDisableActions:YES]; // Disable implicit animations
|
||||
|
||||
@@ -883,7 +920,6 @@ static float L3_Y;
|
||||
button.shadowOpacity = 1.0;
|
||||
button.shadowRadius = 0.0; // Adjust the radius to simulate border thickness
|
||||
[CATransaction commit];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -30,13 +30,13 @@
|
||||
<attribute name="framerate" attributeType="Integer 32" defaultValueString="60" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="height" attributeType="Integer 32" defaultValueString="720" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="keyboardToggleFingers" optional="YES" attributeType="Integer 16" defaultValueString="3" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="largerStickLR1" attributeType="Boolean" defaultValueString="YES" usesScalarValueType="YES" syncable="YES"/>
|
||||
<attribute name="liftStreamViewForKeyboard" attributeType="Boolean" defaultValueString="YES" usesScalarValueType="YES" syncable="YES"/>
|
||||
<attribute name="mousePointerVelocityFactor" optional="YES" attributeType="Float" defaultValueString="1" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="multiController" attributeType="Boolean" defaultValueString="YES" usesScalarValueType="YES" syncable="YES"/>
|
||||
<attribute name="onscreenControls" attributeType="Integer 32" defaultValueString="1" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="optimizeGames" attributeType="Boolean" defaultValueString="YES" usesScalarValueType="YES" syncable="YES"/>
|
||||
<attribute name="oscLayoutToolFingers" optional="YES" attributeType="Integer 16" defaultValueString="4" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="oscVisualFeedback" attributeType="Boolean" defaultValueString="YES" usesScalarValueType="YES" syncable="YES"/>
|
||||
<attribute name="playAudioOnPC" attributeType="Boolean" defaultValueString="NO" usesScalarValueType="YES" syncable="YES"/>
|
||||
<attribute name="pointerVelocityModeDivider" optional="YES" attributeType="Float" defaultValueString="0.5" usesScalarValueType="NO" syncable="YES"/>
|
||||
<attribute name="preferredCodec" attributeType="Integer 32" defaultValueString="YES" usesScalarValueType="YES" syncable="YES"/>
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
@property BOOL optimizeGameSettings;
|
||||
@property BOOL playAudioOnPC;
|
||||
@property BOOL swapABXYButtons;
|
||||
@property BOOL oscVisualFeedback;
|
||||
@property BOOL largerStickLR1;
|
||||
@property int audioConfiguration;
|
||||
@property int supportedVideoFormats;
|
||||
@property BOOL multiController;
|
||||
|
||||
@@ -668,7 +668,7 @@ static NSMutableSet* hostList;
|
||||
_streamConfig.playAudioOnPC = streamSettings.playAudioOnPC;
|
||||
_streamConfig.useFramePacing = streamSettings.useFramePacing;
|
||||
_streamConfig.swapABXYButtons = streamSettings.swapABXYButtons;
|
||||
_streamConfig.oscVisualFeedback = streamSettings.oscVisualFeedback; // new streamConfig segment
|
||||
_streamConfig.largerStickLR1 = streamSettings.largerStickLR1; // new streamConfig segment
|
||||
|
||||
// multiController must be set before calling getConnectedGamepadMask
|
||||
_streamConfig.multiController = streamSettings.multiController;
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *touchModeSelector;
|
||||
@property (strong, nonatomic) IBOutlet UILabel *onscreenControllerLabel;
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *onscreenControlSelector;
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *oscVisualFeedbackSelector;
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *largerStickLR1Selector;
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *optimizeSettingsSelector;
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *multiControllerSelector;
|
||||
@property (strong, nonatomic) IBOutlet UISegmentedControl *swapABXYButtonsSelector;
|
||||
|
||||
@@ -441,10 +441,10 @@ BOOL isCustomResolution(CGSize res) {
|
||||
[self.onscreenControlSelector setSelectedSegmentIndex:onscreenControlsLevel];
|
||||
[self.onscreenControlSelector addTarget:self action:@selector(onscreenControlChanged) forControlEvents:UIControlEventValueChanged];
|
||||
[self onscreenControlChanged];
|
||||
[self.oscVisualFeedbackSelector setSelectedSegmentIndex:currentSettings.oscVisualFeedback ? 1 : 0]; // load old setting of oscVisualFeedback
|
||||
[self.largerStickLR1Selector setSelectedSegmentIndex:currentSettings.largerStickLR1 ? 1 : 0]; // load old setting of largerStickLR1
|
||||
|
||||
// [self.touchModeSelector setSelectedSegmentIndex:currentSettings.absoluteTouchMode ? 1 : 0];
|
||||
// this part will enable/disable oscSelector & the visual feedback selector
|
||||
// this part will enable/disable oscSelector & the largerStickLR1 selector
|
||||
[self.touchModeSelector setSelectedSegmentIndex:currentSettings.touchMode.intValue]; //Load old touchMode setting
|
||||
[self.touchModeSelector addTarget:self action:@selector(touchModeChanged) forControlEvents:UIControlEventValueChanged];
|
||||
[self touchModeChanged];
|
||||
@@ -635,7 +635,7 @@ BOOL isCustomResolution(CGSize res) {
|
||||
bool isNativeTouch = [self.touchModeSelector selectedSegmentIndex] == PURE_NATIVE_TOUCH || [self.touchModeSelector selectedSegmentIndex] == REGULAR_NATIVE_TOUCH;
|
||||
|
||||
[self.onscreenControlSelector setEnabled:oscSelectorEnabled];
|
||||
[self.oscVisualFeedbackSelector setEnabled:oscSelectorEnabled]; // this selector stay aligned with oscSelector
|
||||
[self.largerStickLR1Selector setEnabled:oscSelectorEnabled]; // this selector stay aligned with oscSelector
|
||||
|
||||
[self widget:self.pointerVelocityModeDividerSlider setEnabled:isNativeTouch]; // pointer velocity scaling works only in native touch mode.
|
||||
[self widget:self.touchPointerVelocityFactorSlider setEnabled:isNativeTouch]; // pointer velocity scaling works only in native touch mode.
|
||||
@@ -945,7 +945,7 @@ BOOL isCustomResolution(CGSize res) {
|
||||
CGFloat pointerVelocityModeDivider = (CGFloat)(uint8_t)self.pointerVelocityModeDividerSlider.value/100;
|
||||
CGFloat touchPointerVelocityFactor =(CGFloat)(uint16_t)[self map_velocFactorDisplay_fromSliderValue:self.touchPointerVelocityFactorSlider.value]/100;
|
||||
CGFloat mousePointerVelocityFactor =(CGFloat)(uint16_t)self.mousePointerVelocityFactorSlider.value/100;
|
||||
BOOL oscVisualFeedback = [self.oscVisualFeedbackSelector selectedSegmentIndex] == 1;
|
||||
BOOL largerStickLR1 = [self.largerStickLR1Selector selectedSegmentIndex] == 1;
|
||||
BOOL liftStreamViewForKeyboard = [self.liftStreamViewForKeyboardSelector selectedSegmentIndex] == 1;
|
||||
BOOL showKeyboardToolbar = [self.showKeyboardToolbarSelector selectedSegmentIndex] == 1;
|
||||
BOOL optimizeGames = [self.optimizeSettingsSelector selectedSegmentIndex] == 1;
|
||||
@@ -973,7 +973,7 @@ BOOL isCustomResolution(CGSize res) {
|
||||
pointerVelocityModeDivider:pointerVelocityModeDivider
|
||||
touchPointerVelocityFactor:touchPointerVelocityFactor
|
||||
mousePointerVelocityFactor:mousePointerVelocityFactor
|
||||
oscVisualFeedback:oscVisualFeedback
|
||||
largerStickLR1:largerStickLR1
|
||||
liftStreamViewForKeyboard:liftStreamViewForKeyboard
|
||||
showKeyboardToolbar:showKeyboardToolbar
|
||||
optimizeGames:optimizeGames
|
||||
|
||||
@@ -2,31 +2,31 @@
|
||||
"sourceLanguage" : "en",
|
||||
"strings" : {
|
||||
"2Bp-XZ-cCw.text" : {
|
||||
"comment" : "Class = \"UILabel\"; text = \"Turn on On-Screen Controls Visual Feedback \"; ObjectID = \"2Bp-XZ-cCw\";",
|
||||
"comment" : "Class = \"UILabel\"; text = \"Larger Sticks & L1/R1 Buttons\"; ObjectID = \"2Bp-XZ-cCw\";",
|
||||
"extractionState" : "extracted_with_value",
|
||||
"localizations" : {
|
||||
"en" : {
|
||||
"stringUnit" : {
|
||||
"state" : "new",
|
||||
"value" : "Turn on On-Screen Controls Visual Feedback "
|
||||
"value" : "Larger Sticks & L1/R1 Buttons"
|
||||
}
|
||||
},
|
||||
"zh-Hans" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "打开屏显手柄视觉反馈"
|
||||
"value" : "更大的摇杆和L1/R1按键"
|
||||
}
|
||||
},
|
||||
"zh-Hant" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "打开屏显手柄视觉反馈"
|
||||
"value" : "更大的摇杆和L1/R1按键"
|
||||
}
|
||||
},
|
||||
"zh-HK" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "打开屏显手柄视觉反馈"
|
||||
"value" : "更大的摇杆和L1/R1按键"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||