optimization: Avoid enumerating applications multiple times
This commit is contained in:
parent
3c61d560c3
commit
32b4e9d136
1 changed files with 4 additions and 10 deletions
|
@ -576,19 +576,13 @@ namespace Ryujinx.UI.App.Common
|
||||||
{
|
{
|
||||||
AppData = application,
|
AppData = application,
|
||||||
});
|
});
|
||||||
}
|
|
||||||
|
|
||||||
if (applications.Count > 1)
|
numApplicationsFound++;
|
||||||
{
|
numApplicationsLoaded++;
|
||||||
numApplicationsFound += applications.Count - 1;
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
numApplicationsLoaded += applications.Count;
|
numApplicationsFound--;
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
numApplicationsFound--;
|
|
||||||
}
|
|
||||||
|
|
||||||
OnApplicationCountUpdated(new ApplicationCountUpdatedEventArgs
|
OnApplicationCountUpdated(new ApplicationCountUpdatedEventArgs
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue