mirror of
https://github.com/aclist/dztui.git
synced 2026-11-22 09:29:31 +01:00
chore: abstract dialog strings
This commit is contained in:
1 parent
4c59ba85d7
commit
ee18b9c513
5 files changed
+8
-9
No files matched your search
@@ -1,3 +1,6 @@
|
||||
default_header = "DZGUI - Dialog"
|
||||
error = "ERROR"
|
||||
|
||||
waiting_for_launch = "Waiting for DayZ to launch"
|
||||
waiting_for_mods = "Queueing up mods (step 1/2)"
|
||||
waiting_for_directories = "Steam is staging mods (step 2/2)"
|
||||
|
||||
@@ -382,9 +382,6 @@ server_labels = ServerLabels(
|
||||
)
|
||||
|
||||
|
||||
dialog_error = "ERROR"
|
||||
|
||||
|
||||
atomic_buttons = AtomicButton(
|
||||
refresh="Refresh",
|
||||
refresh_tooltip="Refresh server data",
|
||||
|
||||
@@ -13,7 +13,6 @@ from dzgui.init.update import check_updates
|
||||
from dzgui.managers.threading import call_on_thread, StoredFunc, ThreadingManager
|
||||
from dzgui.strings import preboot, dialogs
|
||||
from dzgui.util.format import format_exception
|
||||
from dzgui.util.strings import dialog_header
|
||||
from dzgui.util.symlink import rebuild_symlinks
|
||||
from dzgui.views.components.buttons import ClipboardButton
|
||||
from dzgui.views.mixins.colorscheme import ColorAwareApp
|
||||
@@ -36,7 +35,7 @@ class Success(Enum):
|
||||
class BootDialog(ColorAwareApp, Gtk.Dialog): # type: ignore
|
||||
def __init__(self, parent: "BootWindow", xdg: "Xdg", version: str) -> None:
|
||||
super().__init__(
|
||||
title=dialog_header,
|
||||
title=dialogs.default_header,
|
||||
transient_for=parent,
|
||||
modal=True,
|
||||
)
|
||||
|
||||
@@ -2,7 +2,7 @@ import textwrap
|
||||
import sys
|
||||
|
||||
from typing import Self
|
||||
from dzgui.util.strings import dialog_error, dialog_header
|
||||
from dzgui.strings import dialogs
|
||||
from dzgui.views.mixins.colorscheme import ColorAwareApp
|
||||
|
||||
import gi
|
||||
@@ -14,8 +14,8 @@ from gi.repository import Gtk
|
||||
class AbortDialog(ColorAwareApp, Gtk.MessageDialog): # type: ignore
|
||||
def __init__(self, string: str, buttons: Gtk.ButtonsType) -> None:
|
||||
super().__init__(
|
||||
title=dialog_header,
|
||||
text=dialog_error,
|
||||
title=dialogs.default_header,
|
||||
text=dialogs.error,
|
||||
transient_for=None,
|
||||
buttons=buttons,
|
||||
)
|
||||
|
||||
@@ -28,7 +28,7 @@ class GenericDialog(Gtk.MessageDialog):
|
||||
buttons=buttons,
|
||||
text=text,
|
||||
secondary_text=secondary,
|
||||
title=strings.dialog_header,
|
||||
title=dialogs.default_header,
|
||||
modal=True,
|
||||
)
|
||||
|
||||
|
||||
Reference in new issue
Block a user