chore: update strings

This commit is contained in:
aclist 2026-05-13 18:00:35 +09:00
parent cf913eff1b
commit c5a0050004
5 changed files with 17 additions and 17 deletions

View File

@ -7,3 +7,5 @@ errors = "Errors"
mods = "Mods"
total_mods = "Total mods: "
all_updated = "All mods updated."
"If you recently installed {build} or moved it to a different drive, "
"restart Steam to allow these changes to synchronize, then try again."

View File

@ -2,6 +2,7 @@ from typing import Callable, Self, TYPE_CHECKING
from dzgui.util.clip import copy_clipboard
from dzgui.util.format import pluralize
from dzgui.strings import buttons
from dzgui.util.strings import (
alert_button_tooltip,
atomic_buttons,
@ -169,8 +170,8 @@ class SteamTextButton(SteamConnectButton):
class SteamWorkshopButton(SteamTextButton):
def __init__(self) -> None:
super().__init__(label="Steam Workshop")
self.set_tooltip_text("connect to workshop")
super().__init__(label=buttons.workshop)
self.set_tooltip_text(buttons.workshop_tooltip)
class AddButton(IconTextButton):

View File

@ -45,10 +45,6 @@ class ServerDialog(GenericDialog):
self.content = self.get_content_area()
self.content.pack_start(self.scrollable_tree, EXPAND, FILL, 0)
# TODO:
# def pack(self, widget: Gtk.Widget) -> None:
# self.content.pack_start(widget, EXPAND, FILL, NO_PADDING)
def _on_keypress(self, view: Gtk.TreeView, event: Gdk.EventKey) -> bool:
# NOTE: ESC normally unfocuses treeview instead of destroying dialog
if event.keyval == Gdk.KEY_Escape:

View File

@ -20,8 +20,9 @@ from dzgui.const.constants import (
)
from dzgui.const.endpoints import STEAM_API_SETUP, BM_API_SETUP
from dzgui.const.enum import Preferences, ServerTab
from dzgui.strings import errors
from dzgui.strings import errors, options
from dzgui.util import strings, css, open_links
from dzgui.views.components.buttons import SteamWorkshopButton
from dzgui.views.components.labels import LeftLabel
from dzgui.views.components.eventbox import InfoEventBox
from dzgui.views.components.buttons import WebButton
@ -144,19 +145,14 @@ class Options(Gtk.Box):
# NOTE: sensitivity state is updated after config file is loaded
self.force_button.set_sensitive(False)
eb = InfoEventBox(strings.options.dl_eventbox, controller)
# eb2 = InfoEventBox(strings.options.force_eventbox, controller)
from dzgui.views.components.buttons import SteamWorkshopButton
eb = InfoEventBox(options.workshop_eventbox, controller)
workshop_button = SteamWorkshopButton() # label=strings.self_workshop)
workshop_button.connect(
"clicked", lambda _: self.controller.open_user_workshop(self.uid)
)
mod_rows = [
[LeftLabel("Steam Workshop"), workshop_button, eb],
# [LeftLabel(strings.options.install_mode), self.mod_install_toggle, eb],
# [LeftLabel(strings.options.force_update), self.force_button, eb2],
[LeftLabel(options.workshop_label), workshop_button, eb],
]
self.dayz_version_label = Gtk.Label(label=strings.null)

View File

@ -225,14 +225,19 @@ class PreConnectionAssistant(Gtk.ScrolledWindow):
warnings: list[str] = []
errors: list[str] = []
resync_msg = (
f"If you recently installed {prereqs.build} or moved it to a different drive,\n"
"restart Steam to allow these changes to synchronize, then try again."
)
"""Errors"""
if prereqs.binary_missing:
errors.append(
f"Remote server is running the build '{prereqs.build}', but it is not installed."
f"Remote server is running the build '{prereqs.build}', but it is not installed.\n{resync_msg}"
)
elif prereqs.local_version != prereqs.remote_version:
errors.append(
f"Local client version '{prereqs.local_version}' does not match remote version '{prereqs.remote_version}'."
f"Local client version '{prereqs.local_version}' does not match remote version '{prereqs.remote_version}'.\n{resync_msg}"
)
if prereqs.required_space > prereqs.available_space:
required_pretty = number(prereqs.required_space)
@ -307,7 +312,7 @@ class PreConnectionAssistant(Gtk.ScrolledWindow):
self.mod_count.set_text(f"{prefix}{str(total_mods)}.{suffix}")
self._process_warnings(prereqs)
if self.tree.is_visible:
if self.tree.is_visible():
self.tree.grab_focus()
else:
self.grab_focus()