ui: fix stratum server enable/disable button text, update translations
This commit is contained in:
parent
152798629e
commit
f5d213bb4c
3 changed files with 5 additions and 7 deletions
|
@ -102,8 +102,6 @@ network_metrics:
|
|||
difficulty_window: 'Difficulty window %{size}'
|
||||
network_mining:
|
||||
loading: Mining will be available after the synchronization
|
||||
enable_server: Enable server
|
||||
disable_server: Disable server
|
||||
info: 'Mining server is enabled, you can change its settings by selecting %{settings} at the bottom of the screen. Data is updating when devices are connected.'
|
||||
restart_server_required: Server restart is required to apply changes.
|
||||
rewards_wallet: Wallet for rewards
|
||||
|
|
|
@ -102,8 +102,6 @@ network_metrics:
|
|||
difficulty_window: 'Окно сложности %{size}'
|
||||
network_mining:
|
||||
loading: Майнинг будет доступен после синхронизации
|
||||
enable_server: Включить сервер
|
||||
disable_server: Выключить сервер
|
||||
info: 'Сервер майнинга запущен, вы можете изменить его настройки, выбрав %{settings} внизу экрана. Данные обновляются, когда устройства подключены.'
|
||||
restart_server_required: Для применения изменений потребуется перезапуск Stratum сервера.
|
||||
rewards_wallet: Кошелёк для наград
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
use egui::{Id, RichText, TextStyle, Widget};
|
||||
|
||||
use crate::gui::Colors;
|
||||
use crate::gui::icons::{BARBELL, HARD_DRIVES, PLUG, TIMER};
|
||||
use crate::gui::icons::{BARBELL, HARD_DRIVES, PLUG, POWER, TIMER};
|
||||
use crate::gui::platform::PlatformCallbacks;
|
||||
use crate::gui::views::{Modal, View};
|
||||
use crate::gui::views::network::settings::NetworkSettings;
|
||||
|
@ -111,13 +111,15 @@ impl StratumSetup {
|
|||
});
|
||||
} else if Node::get_stratum_stats().is_running {
|
||||
ui.add_space(6.0);
|
||||
View::button(ui, t!("network_mining.disable_server"), Colors::GOLD, || {
|
||||
let disable_text = format!("{} {}", POWER, t!("network_settings.disable"));
|
||||
View::button(ui, disable_text, Colors::GOLD, || {
|
||||
Node::stop_stratum();
|
||||
});
|
||||
ui.add_space(6.0);
|
||||
} else {
|
||||
ui.add_space(6.0);
|
||||
View::button(ui, t!("network_mining.enable_server"), Colors::GOLD, || {
|
||||
let enable_text = format!("{} {}", POWER, t!("network_settings.enable"));
|
||||
View::button(ui, enable_text, Colors::GOLD, || {
|
||||
Node::start_stratum();
|
||||
});
|
||||
ui.add_space(6.0);
|
||||
|
|
Loading…
Reference in a new issue