diff options
author | Ac_K <Acoustik666@gmail.com> | 2021-01-08 09:14:13 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-08 09:14:13 +0100 |
commit | a9cb31e75fe269519f6be71ae83627ee21d1bc1f (patch) | |
tree | d078b6adea185e6bab72bdb79db37b061ca3bcdf /Ryujinx/Ui/Applet/ErrorAppletDialog.cs | |
parent | 72e94bb089a0f2fef862acee1960dd05083a735b (diff) |
gui: Refactoring Part 1 (#1859)
* gui: Refactoring Part 1
* Fix ProfileDialog.glade path
* Fix Application.Quit assert
* Fix TitleUpdateWindow parent
* Fix TitleUpdate selected item
* Remove extra line in TitleUpdateWindow
* Fix empty assign of Enum.TryParse
* Add Patrons list in the About Window
* update about error messages
Diffstat (limited to 'Ryujinx/Ui/Applet/ErrorAppletDialog.cs')
-rw-r--r-- | Ryujinx/Ui/Applet/ErrorAppletDialog.cs | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Ryujinx/Ui/Applet/ErrorAppletDialog.cs b/Ryujinx/Ui/Applet/ErrorAppletDialog.cs new file mode 100644 index 00000000..a51d5324 --- /dev/null +++ b/Ryujinx/Ui/Applet/ErrorAppletDialog.cs @@ -0,0 +1,27 @@ +using Gtk; + +namespace Ryujinx.Ui.Applet +{ + internal class ErrorAppletDialog : MessageDialog + { + public ErrorAppletDialog(Window parentWindow, DialogFlags dialogFlags, MessageType messageType, string[] buttons) : base(parentWindow, dialogFlags, messageType, ButtonsType.None, null) + { + int responseId = 0; + + if (buttons != null) + { + foreach (string buttonText in buttons) + { + AddButton(buttonText, responseId); + responseId++; + } + } + else + { + AddButton("OK", 0); + } + + ShowAll(); + } + } +}
\ No newline at end of file |