[ci skip] chore: Fix usage of var

This commit is contained in:
GreemDev
2025-10-20 02:41:45 -05:00
parent f46577af58
commit 5b3b907fd2
18 changed files with 83 additions and 82 deletions

View File

@@ -35,7 +35,7 @@ namespace Ryujinx.Ava.UI.ViewModels
SortApply();
}
var filtered = _visibleEntries;
IEnumerable<LdnGameModel> filtered = _visibleEntries;
if (OnlyShowForOwnedGames)
filtered = filtered.Where(x => _ownedGameTitleIds.ContainsIgnoreCase(x.Title.Id));

View File

@@ -348,7 +348,7 @@ namespace Ryujinx.Ava.UI.ViewModels
{
if (ts.HasValue)
{
var formattedPlayTime = ValueFormatUtils.FormatTimeSpan(ts.Value);
string formattedPlayTime = ValueFormatUtils.FormatTimeSpan(ts.Value);
LocaleManager.Associate(LocaleKeys.GameListLabelTotalTimePlayed, formattedPlayTime);
ShowTotalTimePlayed = formattedPlayTime != string.Empty;
return;
@@ -827,10 +827,10 @@ namespace Ryujinx.Ava.UI.ViewModels
private void RefreshGrid()
{
var appsList = Applications.ToObservableChangeSet()
IObservableList<ApplicationData> appsList = Applications.ToObservableChangeSet()
.Filter(Filter)
.Sort(GetComparer())
.Bind(out var apps)
.Bind(out ReadOnlyObservableCollection<ApplicationData> apps)
.AsObservableList();
AppsObservableList = apps;

View File

@@ -447,9 +447,9 @@ namespace Ryujinx.Ava.UI.ViewModels
_virtualFileSystem = virtualFileSystem;
_contentManager = contentManager;
if (gameIconData != null && gameIconData.Length > 0)
if (gameIconData is { Length: > 0 })
{
using var ms = new MemoryStream(gameIconData);
using MemoryStream ms = new(gameIconData);
_gameIcon = new Bitmap(ms);
}