mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-22 17:29:18 +01:00
Change check for remapping execution. Take some Gyro mode settings into account
This commit is contained in:
parent
fc679bf807
commit
24f030aba5
@ -1319,8 +1319,7 @@ namespace DS4Windows
|
|||||||
|
|
||||||
if (!recordingMacro && (useTempProfile[ind] ||
|
if (!recordingMacro && (useTempProfile[ind] ||
|
||||||
containsCustomAction(ind) || containsCustomExtras(ind) ||
|
containsCustomAction(ind) || containsCustomExtras(ind) ||
|
||||||
getProfileActionCount(ind) > 0 ||
|
getProfileActionCount(ind) > 0))
|
||||||
GetSASteeringWheelEmulationAxis(ind) >= SASteeringWheelEmulationAxisType.VJoy1X))
|
|
||||||
{
|
{
|
||||||
Mapping.MapCustom(ind, cState, MappedState[ind], ExposedState[ind], touchPad[ind], this);
|
Mapping.MapCustom(ind, cState, MappedState[ind], ExposedState[ind], touchPad[ind], this);
|
||||||
cState = MappedState[ind];
|
cState = MappedState[ind];
|
||||||
|
@ -1690,8 +1690,16 @@ namespace DS4Windows
|
|||||||
|
|
||||||
public static void cacheProfileCustomsFlags(int device)
|
public static void cacheProfileCustomsFlags(int device)
|
||||||
{
|
{
|
||||||
m_Config.containsCustomAction[device] = HasCustomActions(device);
|
bool customAct = false;
|
||||||
|
m_Config.containsCustomAction[device] = customAct = HasCustomActions(device);
|
||||||
m_Config.containsCustomExtras[device] = HasCustomExtras(device);
|
m_Config.containsCustomExtras[device] = HasCustomExtras(device);
|
||||||
|
|
||||||
|
if (!customAct)
|
||||||
|
{
|
||||||
|
customAct = m_Config.gyroOutMode[device] == GyroOutMode.MouseJoystick;
|
||||||
|
customAct = customAct || m_Config.sASteeringWheelEmulationAxis[device] >= SASteeringWheelEmulationAxisType.VJoy1X;
|
||||||
|
m_Config.containsCustomAction[device] = customAct;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void CacheExtraProfileInfo(int device)
|
public static void CacheExtraProfileInfo(int device)
|
||||||
|
@ -651,9 +651,13 @@ namespace DS4WinWPF.DS4Forms.ViewModels
|
|||||||
default: break;
|
default: break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GyroOutMode current = Global.GyroOutputMode[device];
|
||||||
|
if (temp == current) return;
|
||||||
Global.GyroOutputMode[device] = temp;
|
Global.GyroOutputMode[device] = temp;
|
||||||
|
GyroOutModeIndexChanged?.Invoke(this, EventArgs.Empty);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public event EventHandler GyroOutModeIndexChanged;
|
||||||
|
|
||||||
public OutContType ContType
|
public OutContType ContType
|
||||||
{
|
{
|
||||||
@ -665,6 +669,7 @@ namespace DS4WinWPF.DS4Forms.ViewModels
|
|||||||
get => (int)Global.SASteeringWheelEmulationAxis[device];
|
get => (int)Global.SASteeringWheelEmulationAxis[device];
|
||||||
set => Global.SASteeringWheelEmulationAxis[device] = (SASteeringWheelEmulationAxisType)value;
|
set => Global.SASteeringWheelEmulationAxis[device] = (SASteeringWheelEmulationAxisType)value;
|
||||||
}
|
}
|
||||||
|
public event EventHandler SASteeringWheelEmulationAxisIndexChanged;
|
||||||
|
|
||||||
private int[] saSteeringRangeValues =
|
private int[] saSteeringRangeValues =
|
||||||
new int[9] { 90, 180, 270, 360, 450, 720, 900, 1080, 1440 };
|
new int[9] { 90, 180, 270, 360, 450, 720, 900, 1080, 1440 };
|
||||||
@ -1561,6 +1566,14 @@ namespace DS4WinWPF.DS4Forms.ViewModels
|
|||||||
{
|
{
|
||||||
DS4WinLightVisibleChanged?.Invoke(this, EventArgs.Empty);
|
DS4WinLightVisibleChanged?.Invoke(this, EventArgs.Empty);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
GyroOutModeIndexChanged += CalcProfileFlags;
|
||||||
|
SASteeringWheelEmulationAxisIndexChanged += CalcProfileFlags;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void CalcProfileFlags(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
Global.cacheProfileCustomsFlags(device);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ProfileSettingsViewModel_MainColorChanged(object sender, EventArgs e)
|
private void ProfileSettingsViewModel_MainColorChanged(object sender, EventArgs e)
|
||||||
|
Loading…
Reference in New Issue
Block a user