Merge pull request 'Wiki link fix' (#185) from YanTheKaller/ubl-settings-datetime:master into master

Reviewed-on: #185
pull/189/head
Dmitry Razumov 5 months ago
commit 52fd35f709

@ -69,6 +69,14 @@ msgstr ""
msgid "Synchronize via NTP" msgid "Synchronize via NTP"
msgstr "" msgstr ""
#: source/ubl-strings.h:16
msgid "The selected date and time are set"
msgstr ""
#: source/ubl-strings.h:16
msgid "The selected date and time are set"
msgstr ""
#: source/ubl-strings.h:17 #: source/ubl-strings.h:17
msgid "Default" msgid "Default"
msgstr "" msgstr ""
@ -152,3 +160,11 @@ msgstr ""
#: source/ubl-strings.h:40 #: source/ubl-strings.h:40
msgid "MM-DD-YYYY" msgid "MM-DD-YYYY"
msgstr "" msgstr ""
#: source/ubl-strings.h:16
msgid "Set the selected date and time"
msgstr ""
#: source/ubl-strings.h:16
msgid "Set the selected date and time in the BIOS"
msgstr ""

@ -69,6 +69,14 @@ msgstr "Синхронизировать аппаратное время:"
msgid "Synchronize via NTP" msgid "Synchronize via NTP"
msgstr "Синхронизировать через NTP" msgstr "Синхронизировать через NTP"
#: source/ubl-strings.h:16
msgid "The selected date and time are set"
msgstr "Установлена выбранная дата и время"
#: source/ubl-strings.h:16
msgid "The selected date and time are set in the BIOS"
msgstr "Установлена выбранная дата и время в BIOS"
#: source/ubl-strings.h:17 #: source/ubl-strings.h:17
msgid "Default" msgid "Default"
msgstr "По умолчанию" msgstr "По умолчанию"
@ -157,6 +165,14 @@ msgstr "ДД/ММ/ГГГГ"
msgid "MM-DD-YYYY" msgid "MM-DD-YYYY"
msgstr "ММ-ДД-ГГГГ" msgstr "ММ-ДД-ГГГГ"
#: source/ubl-strings.h:16
msgid "Set the selected date and time"
msgstr "Установить выбранную дату и время"
#: source/ubl-strings.h:16
msgid "Set the selected date and time in the BIOS"
msgstr "Установить выбранную дату и время в BIOS"
msgid "Stopped" msgid "Stopped"
msgstr "Остановлен" msgstr "Остановлен"

@ -369,9 +369,7 @@ void on_date_format_changed(GtkWidget *, main_window *widgets){
} }
gboolean on_operation_success(void*){ gboolean on_operation_success(void*){
textdomain(template_ui_LocaleName); yon_ubl_status_box_render(SYNC_SUCCESS_LABEL,BACKGROUND_IMAGE_SUCCESS_TYPE);
yon_ubl_status_box_render(SUCCESS_LABEL,BACKGROUND_IMAGE_SUCCESS_TYPE);
textdomain(LocaleName);
return G_SOURCE_REMOVE; return G_SOURCE_REMOVE;
} }
@ -491,9 +489,16 @@ void on_ntp_sync(GtkWidget *, main_window *widgets){
} }
} }
gboolean on_hardware_operation_success(void*){
yon_ubl_status_box_render(SYNC_HARDWARE_SUCCESS_LABEL,BACKGROUND_IMAGE_SUCCESS_TYPE);
return G_SOURCE_REMOVE;
}
void *yon_sync_hardware_thread_start(void*){ void *yon_sync_hardware_thread_start(void*){
if (system(hardware_datetime_sync_command)){ if (system(hardware_datetime_sync_command)){
gdk_threads_add_idle((GSourceFunc)on_sync_error,NULL); g_idle_add((GSourceFunc)on_sync_error,NULL);
} else {
g_idle_add((GSourceFunc)on_hardware_operation_success,NULL);
} }
pthread_exit(NULL); pthread_exit(NULL);
} }

@ -16,7 +16,7 @@
#endif #endif
#include "ubl-strings.h" #include "ubl-strings.h"
#define WIKI_LINK "https://wiki.ublinux.com/Software/Programs_and_utilities/All/ubl-settings-datetime" #define WIKI_LINK "https://wiki.ublinux.ru/software/programs_and_utilities/all/ubl-settings-datetime"
#define _(String) gettext(String) #define _(String) gettext(String)
@ -113,6 +113,7 @@ void on_region_changed(GtkComboBox *self, main_window *widgets);
void yon_interface_update(main_window *widgets); void yon_interface_update(main_window *widgets);
gboolean on_sync_error(void*); gboolean on_sync_error(void*);
gboolean on_hardware_operation_success(void*);
void *yon_sync_hardware_thread_start(void*); void *yon_sync_hardware_thread_start(void*);
void *yon_sync_thread_start(void*); void *yon_sync_thread_start(void*);

@ -14,6 +14,8 @@
#define SYNC_HARDWARE_BUTTON_LABEL _("Synchronize hardware time") #define SYNC_HARDWARE_BUTTON_LABEL _("Synchronize hardware time")
#define SYNC_HARDWARE_LABEL _("Synchronize hardware time:") #define SYNC_HARDWARE_LABEL _("Synchronize hardware time:")
#define SYNC_NTP_LABEL _("Synchronize via NTP") #define SYNC_NTP_LABEL _("Synchronize via NTP")
#define SYNC_SUCCESS_LABEL _("The selected date and time are set")
#define SYNC_HARDWARE_SUCCESS_LABEL _("The selected date and time are set in the BIOS")
#define DEFAULT_LABEL _("Default") #define DEFAULT_LABEL _("Default")
#define STOPPED_LABEL _("Do not configure") #define STOPPED_LABEL _("Do not configure")
#define DISABLED_LABEL _("Stop") #define DISABLED_LABEL _("Stop")
@ -37,4 +39,7 @@
#define DMY_FORMAT_LABEL _("DD.MM.YYYY") #define DMY_FORMAT_LABEL _("DD.MM.YYYY")
#define DMY_MINUS_FORMAT_LABEL _("DD-MM-YYYY") #define DMY_MINUS_FORMAT_LABEL _("DD-MM-YYYY")
#define DMY_SLASH_FORMAT_LABEL _("DD/MM/YYYY") #define DMY_SLASH_FORMAT_LABEL _("DD/MM/YYYY")
#define MDY_FORMAT_LABEL _("MM-DD-YYYY") #define MDY_FORMAT_LABEL _("MM-DD-YYYY")
#define SYNC_TOOLTIP_LABEL _("Set the selected date and time")
#define SYNC_HARDWARE_TOOLTIP_LABEL _("Set the selected date and time in the BIOS")

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- Generated with glade 3.38.2 --> <!-- Generated with glade 3.40.0 -->
<interface domain="ubl-settings-datetime"> <interface domain="ubl-settings-datetime">
<requires lib="gtk+" version="3.24"/> <requires lib="gtk+" version="3.24"/>
<!-- interface-css-provider-path ubl-settings-datetime.css --> <!-- interface-css-provider-path ubl-settings-datetime.css -->
@ -185,6 +185,7 @@ format</property>
<property name="visible">True</property> <property name="visible">True</property>
<property name="can-focus">True</property> <property name="can-focus">True</property>
<property name="receives-default">True</property> <property name="receives-default">True</property>
<property name="tooltip-text" translatable="yes">Set the selected date and time</property>
<property name="image">image1</property> <property name="image">image1</property>
</object> </object>
<packing> <packing>
@ -199,6 +200,7 @@ format</property>
<property name="visible">True</property> <property name="visible">True</property>
<property name="can-focus">True</property> <property name="can-focus">True</property>
<property name="receives-default">True</property> <property name="receives-default">True</property>
<property name="tooltip-text" translatable="yes">Set the selected date and time in the BIOS</property>
</object> </object>
<packing> <packing>
<property name="expand">True</property> <property name="expand">True</property>

Loading…
Cancel
Save