|
|
|
|
@ -149,42 +149,42 @@ void MainWindow::localization() {
|
|
|
|
|
time_t now = time(0);
|
|
|
|
|
tm *ltm = localtime(&now);
|
|
|
|
|
unsigned int year= 1900+ ltm->tm_year;
|
|
|
|
|
string str_authors = string(_("Copyright © UBSoft LLC, 2022 - ")) + to_string(year);
|
|
|
|
|
string str_authors = string(gettext("Copyright © UBSoft LLC, 2022 - ")) + to_string(year);
|
|
|
|
|
aboutWindows->set_copyright(str_authors);
|
|
|
|
|
aboutWindows->set_website(_("https://wiki.ublinux.com"));
|
|
|
|
|
btnSynopsis->set_label(_("Help"));
|
|
|
|
|
btnAbout->set_label(_("About"));
|
|
|
|
|
aboutWindows->set_comments(_("ublexec"));
|
|
|
|
|
aboutWindows->set_website_label(_("Project Home Page"));
|
|
|
|
|
aboutWindows->set_version(_(version_application.c_str()));
|
|
|
|
|
lblHeaderName->set_text(_("ublexec"));
|
|
|
|
|
this->set_title(_("ublexec"));
|
|
|
|
|
btnStart->set_label(_("Run"));
|
|
|
|
|
wndChooseFileWallpaper->set_title(_("Please select File"));
|
|
|
|
|
dialogStartMenu->set_title(_("Selecting Programs"));
|
|
|
|
|
lblInfoHead->set_text(_("Run applications as another user\nwith the specified priority"));
|
|
|
|
|
lblinfoCmd->set_text(_("Command Line"));
|
|
|
|
|
lblInfoTime->set_text(_("Team:"));
|
|
|
|
|
labInfoExecutTerm->set_text(_("Run in the terminal emulator"));
|
|
|
|
|
lblInfoUser->set_text(_("User"));
|
|
|
|
|
lblInfoUserOther->set_text(_("Run as another user:"));
|
|
|
|
|
lblInfoUserName->set_text(_("User Name:"));
|
|
|
|
|
lblInfoNooPriority->set_text(_("Priority"));
|
|
|
|
|
lblInfoExec->set_text(_("Change startup priority"));
|
|
|
|
|
lblInfoPriority->set_text(_("Priority:"));
|
|
|
|
|
lblMessageError->set_text(_("Select an executable file or program"));
|
|
|
|
|
lblGraphics->set_text(_("Graphics"));
|
|
|
|
|
lblTools->set_text(_("Tools"));
|
|
|
|
|
lblInternet->set_text(_("Internet"));
|
|
|
|
|
lblMultimedia->set_text(_("Multimedia"));
|
|
|
|
|
lblSettings->set_text(_("Settings"));
|
|
|
|
|
lblEducation->set_text(_("Education"));
|
|
|
|
|
lblOffice->set_text(_("Office"));
|
|
|
|
|
lblOther->set_text(_("Other"));
|
|
|
|
|
lblDevelopment->set_text(_("Development"));
|
|
|
|
|
lblSystem->set_text(_("System"));
|
|
|
|
|
btnListApp->set_tooltip_text(_("Application Overview"));
|
|
|
|
|
btnFilemaneg->set_tooltip_text(_("File Overview"));
|
|
|
|
|
aboutWindows->set_website(gettext("https://wiki.ublinux.com"));
|
|
|
|
|
btnSynopsis->set_label(gettext("Help"));
|
|
|
|
|
btnAbout->set_label(gettext("About"));
|
|
|
|
|
aboutWindows->set_comments(gettext("ublexec"));
|
|
|
|
|
aboutWindows->set_website_label(gettext("Project Home Page"));
|
|
|
|
|
aboutWindows->set_version(gettext(version_application.c_str()));
|
|
|
|
|
lblHeaderName->set_text(gettext("ublexec"));
|
|
|
|
|
this->set_title(gettext("ublexec"));
|
|
|
|
|
btnStart->set_label(gettext("Run"));
|
|
|
|
|
wndChooseFileWallpaper->set_title(gettext("Please select File"));
|
|
|
|
|
dialogStartMenu->set_title(gettext("Selecting Programs"));
|
|
|
|
|
lblInfoHead->set_text(gettext("Run applications as another user\nwith the specified priority"));
|
|
|
|
|
lblinfoCmd->set_text(gettext("Command Line"));
|
|
|
|
|
lblInfoTime->set_text(gettext("Team:"));
|
|
|
|
|
labInfoExecutTerm->set_text(gettext("Run in the terminal emulator"));
|
|
|
|
|
lblInfoUser->set_text(gettext("User"));
|
|
|
|
|
lblInfoUserOther->set_text(gettext("Run as another user:"));
|
|
|
|
|
lblInfoUserName->set_text(gettext("User Name:"));
|
|
|
|
|
lblInfoNooPriority->set_text(gettext("Priority"));
|
|
|
|
|
lblInfoExec->set_text(gettext("Change startup priority"));
|
|
|
|
|
lblInfoPriority->set_text(gettext("Priority:"));
|
|
|
|
|
lblMessageError->set_text(gettext("Select an executable file or program"));
|
|
|
|
|
lblGraphics->set_text(gettext("Graphics"));
|
|
|
|
|
lblTools->set_text(gettext("Tools"));
|
|
|
|
|
lblInternet->set_text(gettext("Internet"));
|
|
|
|
|
lblMultimedia->set_text(gettext("Multimedia"));
|
|
|
|
|
lblSettings->set_text(gettext("Settings"));
|
|
|
|
|
lblEducation->set_text(gettext("Education"));
|
|
|
|
|
lblOffice->set_text(gettext("Office"));
|
|
|
|
|
lblOther->set_text(gettext("Other"));
|
|
|
|
|
lblDevelopment->set_text(gettext("Development"));
|
|
|
|
|
lblSystem->set_text(gettext("System"));
|
|
|
|
|
btnListApp->set_tooltip_text(gettext("Application Overview"));
|
|
|
|
|
btnFilemaneg->set_tooltip_text(gettext("File Overview"));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void MainWindow::event() {
|
|
|
|
|
@ -232,32 +232,32 @@ void MainWindow::sudo_nice(){
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(-20, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("-20 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("-20 (High)"));
|
|
|
|
|
}
|
|
|
|
|
else if (rbSudo->get_active() && response.find("wheel") != string::npos){
|
|
|
|
|
spinPriority->set_range(-20, 19);
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(-20, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("-20 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("-20 (High)"));
|
|
|
|
|
}
|
|
|
|
|
else if (rbSu->get_active()){
|
|
|
|
|
spinPriority->set_range(0, 19);
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(0, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("0 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("0 (High)"));
|
|
|
|
|
}
|
|
|
|
|
else if (rbPkexec->get_active()){
|
|
|
|
|
spinPriority->set_range(0, 19);
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(0, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("0 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("0 (High)"));
|
|
|
|
|
}
|
|
|
|
|
this->denamic_cmd();
|
|
|
|
|
}
|
|
|
|
|
@ -271,16 +271,16 @@ void MainWindow::changed_user() {
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(-20, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("-20 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("-20 (High)"));
|
|
|
|
|
}
|
|
|
|
|
else{
|
|
|
|
|
spinPriority->set_range(0, 19);
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(0, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("0 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("0 (High)"));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -310,7 +310,7 @@ bool MainWindow::focus_in_txt_cmd(GdkEventFocus* event) {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void MainWindow::synopsis_show() {
|
|
|
|
|
string cmd = "xdg-open " + string(_("https://wiki.ublinux.com/ru/Программное_обеспечение/Программы_и_утилиты/Все/")) + app_name + " &";
|
|
|
|
|
string cmd = "xdg-open " + string(gettext("https://wiki.ublinux.com/ru/Программное_обеспечение/Программы_и_утилиты/Все/")) + app_name + " &";
|
|
|
|
|
system(cmd.c_str());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -409,8 +409,8 @@ void MainWindow::settings() {
|
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
|
scalePriority->set_range(0, 19);
|
|
|
|
|
scalePriority->set_value(0);
|
|
|
|
|
lblTimeEpriorityLow->set_text(_("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(_("0 (High)"));
|
|
|
|
|
lblTimeEpriorityLow->set_text(gettext("19 (Low)"));
|
|
|
|
|
lblTime4EpriorityHigh->set_text(gettext("0 (High)"));
|
|
|
|
|
scalePriority->set_inverted(true);
|
|
|
|
|
this->pars_dir_bin();
|
|
|
|
|
this->pars_dir_terminal();
|
|
|
|
|
|