Ack's requested changes

This commit is contained in:
Xpl0itR 2020-02-28 21:48:22 +00:00
parent 1fe5b1a260
commit 2266126e20
4 changed files with 16 additions and 74 deletions

View file

@ -327,11 +327,9 @@ namespace Ryujinx.Ui
StatusUpdatedEvent?.Invoke(this, new StatusUpdatedEventArgs
{
VSyncEnabled = _device.EnableDeviceVsync,
HostFpsStatus = $"Host FPS: {_device.Statistics.GetSystemFrameRate():0.0}",
GameFpsStatus = $"Game FPS: {_device.Statistics.GetGameFrameRate():0.0}",
HostFrameTimeStatus = $"Host Frame Time: {_device.Statistics.GetSystemFrameTime():00.00}ms",
GameFrameTimeStatus = $"Game Frame Time: {_device.Statistics.GetGameFrameTime():00.00}ms"
VSyncEnabled = _device.EnableDeviceVsync,
HostStatus = $"Host: {_device.Statistics.GetSystemFrameRate():00.00}FPS - {_device.Statistics.GetSystemFrameTime():00.00}ms",
GameStatus = $"Game: {_device.Statistics.GetGameFrameRate():00.00}FPS - { _device.Statistics.GetGameFrameTime():00.00}ms"
});
_device.System.SignalVsync();

View file

@ -56,8 +56,7 @@ namespace Ryujinx.Ui
[GUI] CheckMenuItem _favToggle;
[GUI] MenuItem _firmwareInstallFile;
[GUI] MenuItem _firmwareInstallDirectory;
[GUI] Label _hostFpsStatus;
[GUI] Label _hostFrameTimeStatus;
[GUI] Label _hostStatus;
[GUI] MenuItem _openDebugger;
[GUI] CheckMenuItem _iconToggle;
[GUI] CheckMenuItem _appToggle;
@ -68,8 +67,7 @@ namespace Ryujinx.Ui
[GUI] CheckMenuItem _fileExtToggle;
[GUI] CheckMenuItem _fileSizeToggle;
[GUI] CheckMenuItem _pathToggle;
[GUI] Label _gameFpsStatus;
[GUI] Label _gameFrameTimeStatus;
[GUI] Label _gameStatus;
[GUI] TreeView _gameTable;
[GUI] ScrolledWindow _gameTableWindow;
[GUI] TreeSelection _gameTableSelection;
@ -605,21 +603,19 @@ namespace Ryujinx.Ui
{
Application.Invoke(delegate
{
_vSyncStatus.Text = args.VSyncEnabled ? "VSync On" : "VSync Off";
_hostFpsStatus.Text = args.HostFpsStatus;
_gameFpsStatus.Text = args.GameFpsStatus;
_hostFrameTimeStatus.Text = args.HostFrameTimeStatus;
_gameFrameTimeStatus.Text = args.GameFrameTimeStatus;
_vSyncStatus.Text = "VSync";
_hostStatus.Text = args.HostStatus;
_gameStatus.Text = args.GameStatus;
if (args.VSyncEnabled)
{
_vSyncStatus.Attributes = new Pango.AttrList();
_vSyncStatus.Attributes.Insert(new Pango.AttrForeground(0, ushort.MaxValue, 0));
_vSyncStatus.Attributes.Insert(new Pango.AttrForeground(11822, 60138, 51657));
}
else
{
_vSyncStatus.Attributes = new Pango.AttrList();
_vSyncStatus.Attributes.Insert(new Pango.AttrForeground(ushort.MaxValue, 0, 0));
_vSyncStatus.Attributes.Insert(new Pango.AttrForeground(ushort.MaxValue, 17733, 21588));
}
});
}

View file

@ -496,7 +496,7 @@
</packing>
</child>
<child>
<object class="GtkLabel" id="_hostFpsStatus">
<object class="GtkLabel" id="_hostStatus">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
@ -521,57 +521,7 @@
</packing>
</child>
<child>
<object class="GtkLabel" id="_hostFrameTimeStatus">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
<property name="margin_left">5</property>
<property name="margin_right">5</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">4</property>
</packing>
</child>
<child>
<object class="GtkSeparator">
<property name="visible">True</property>
<property name="can_focus">False</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">5</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="_gameFpsStatus">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
<property name="margin_left">5</property>
<property name="margin_right">5</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">6</property>
</packing>
</child>
<child>
<object class="GtkSeparator">
<property name="visible">True</property>
<property name="can_focus">False</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">7</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="_gameFrameTimeStatus">
<object class="GtkLabel" id="_gameStatus">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
@ -580,7 +530,7 @@
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">8</property>
<property name="position">4</property>
</packing>
</child>
</object>

View file

@ -4,10 +4,8 @@ namespace Ryujinx.Ui
{
public class StatusUpdatedEventArgs : EventArgs
{
public bool VSyncEnabled { get; set; }
public string HostFpsStatus { get; set; }
public string GameFpsStatus { get; set; }
public string HostFrameTimeStatus { get; set; }
public string GameFrameTimeStatus { get; set; }
public bool VSyncEnabled { get; set; }
public string HostStatus { get; set; }
public string GameStatus { get; set; }
}
}