mirror of
https://github.com/GreemDev/Ryujinx.git
synced 2025-01-09 20:32:00 +00:00
misc: some cleanups and fix compile warnings
This commit is contained in:
parent
391f57bdd2
commit
88d11d3d8d
4 changed files with 13 additions and 11 deletions
|
@ -52,7 +52,7 @@ namespace Ryujinx.Headless
|
||||||
// Make process DPI aware for proper window sizing on high-res screens.
|
// Make process DPI aware for proper window sizing on high-res screens.
|
||||||
ForceDpiAware.Windows();
|
ForceDpiAware.Windows();
|
||||||
|
|
||||||
Console.Title = $"Ryujinx Console {Program.Version} (Headless)";
|
Console.Title = $"HeadlessRyujinx Console {Program.Version}";
|
||||||
|
|
||||||
if (OperatingSystem.IsMacOS() || OperatingSystem.IsLinux())
|
if (OperatingSystem.IsMacOS() || OperatingSystem.IsLinux())
|
||||||
{
|
{
|
||||||
|
|
|
@ -171,13 +171,11 @@ namespace Ryujinx.Headless
|
||||||
{ PlayerIndex.Player8, (nameof(InputId8), nameof(InputProfile8Name)) }
|
{ PlayerIndex.Player8, (nameof(InputId8), nameof(InputProfile8Name)) }
|
||||||
};
|
};
|
||||||
|
|
||||||
foreach ((PlayerIndex playerIndex, (string id, string profile)) in indicesToProperties)
|
foreach ((PlayerIndex playerIndex, _) in indicesToProperties
|
||||||
|
.Where(it => NeedsOverride(it.Value.InputId) && NeedsOverride(it.Value.InputProfileName)))
|
||||||
{
|
{
|
||||||
if (NeedsOverride(id) && NeedsOverride(profile))
|
configurationState.Hid.InputConfig.Value.FindFirst(x => x.PlayerIndex == playerIndex)
|
||||||
{
|
.IfPresent(ic => InheritedInputConfigs[playerIndex] = ic);
|
||||||
configurationState.Hid.InputConfig.Value.FindFirst(x => x.PlayerIndex == playerIndex)
|
|
||||||
.IfPresent(ic => InheritedInputConfigs[playerIndex] = ic);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -107,8 +107,8 @@ namespace Ryujinx.Ava.UI.ViewModels
|
||||||
// some reason. so we save the items here and add them back after
|
// some reason. so we save the items here and add them back after
|
||||||
var items = SelectedDownloadableContents.ToArray();
|
var items = SelectedDownloadableContents.ToArray();
|
||||||
|
|
||||||
_views.Clear();
|
Views.Clear();
|
||||||
_views.AddRange(view);
|
Views.AddRange(view);
|
||||||
|
|
||||||
foreach (DownloadableContentModel item in items)
|
foreach (DownloadableContentModel item in items)
|
||||||
{
|
{
|
||||||
|
|
|
@ -182,7 +182,11 @@ namespace Ryujinx.Ava.UI.ViewModels
|
||||||
Applications.ToObservableChangeSet()
|
Applications.ToObservableChangeSet()
|
||||||
.Filter(Filter)
|
.Filter(Filter)
|
||||||
.Sort(GetComparer())
|
.Sort(GetComparer())
|
||||||
|
.OnItemAdded(_ => OnPropertyChanged(nameof(AppsObservableList)))
|
||||||
|
.OnItemRemoved(_ => OnPropertyChanged(nameof(AppsObservableList)))
|
||||||
|
#pragma warning disable MVVMTK0034 // Event to update is fired below
|
||||||
.Bind(out _appsObservableList)
|
.Bind(out _appsObservableList)
|
||||||
|
#pragma warning restore MVVMTK0034
|
||||||
.AsObservableList();
|
.AsObservableList();
|
||||||
|
|
||||||
_rendererWaitEvent = new AutoResetEvent(false);
|
_rendererWaitEvent = new AutoResetEvent(false);
|
||||||
|
@ -192,8 +196,8 @@ namespace Ryujinx.Ava.UI.ViewModels
|
||||||
LoadConfigurableHotKeys();
|
LoadConfigurableHotKeys();
|
||||||
|
|
||||||
Volume = ConfigurationState.Instance.System.AudioVolume;
|
Volume = ConfigurationState.Instance.System.AudioVolume;
|
||||||
|
CustomVSyncInterval = ConfigurationState.Instance.Graphics.CustomVSyncInterval.Value;
|
||||||
}
|
}
|
||||||
CustomVSyncInterval = ConfigurationState.Instance.Graphics.CustomVSyncInterval.Value;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Initialize(
|
public void Initialize(
|
||||||
|
|
Loading…
Reference in a new issue