pull/3/head
Igor Belitskiy 2 years ago
parent 28c581fde6
commit 4acb8c8bba

@ -1,5 +1,5 @@
#ifndef SAVE_H
#define SAVE_H
#ifndef MY_PROCESS_H
#define MY_PROCESS_H
#include "util.h"
namespace My_Process {

@ -30,10 +30,6 @@ void MainWindow::settings() {
this->lacalization();
this->add_CSS();
btnBoxAboutDialog->set_visible(false);
Gtk::Widget *boxWidget;
builder->get_widget("boxColor", boxWidget);
HeadOverlay->add_overlay(*boxWidget);
ubl_make_plugs(boxSave, boxButton, socket_ext_id_I, socket_trd_id_I);
this->entry_generalGroupsEnableCheck();
this->entry_generalUsersEnableCheck();
map_device = obj_device.get_map_part_devices("/dev/");
@ -43,9 +39,9 @@ void MainWindow::settings() {
this->entry_combo_box_temp(generalDeviceCombo,lblFstypeGeneralSettings);
this->entry_combo_box_temp(groupsDeviceCombo, lblFstypeGroups);
this->entry_combo_box_temp(usersDeviceCombo, lblFstypeUsers);
this->init_tree_view();
this->init_spin_all();
if (geteuid() == 0) {
this->init_tree_view();
this->load_system_cfg();
this->load_global_cfg();
this->event();
@ -58,6 +54,10 @@ void MainWindow::settings() {
info_status_app("boxInfoMessError");
lblWarning->set_text(_("The program must be run as root"));
}
Gtk::Widget *boxWidget;
builder->get_widget("boxColor", boxWidget);
HeadOverlay->add_overlay(*boxWidget);
ubl_make_plugs(boxSave, boxButton, socket_ext_id_I, socket_trd_id_I);
}
void MainWindow::init_spin_all() {
@ -144,7 +144,7 @@ void MainWindow::lacalization() {
generalTabLabel->set_text(_("General settings"));
GroupsTabLabel->set_text(_("Groups"));
headerAboutTopic->set_label(_(app_name.c_str()));
headerTopic->set_label(_(app_name.c_str()));
headerTopic->set_label(_("ubl-settings-quotas"));
UsersTabLabel->set_text(_("Users"));
generalDeviceLabel->set_text(_("Device:"));
generalFileSystemLabel->set_text(_("File system:"));
@ -226,11 +226,10 @@ void MainWindow::lacalization() {
btnSaveLocalGlob->set_label(_("Save to global and local configuration"));
btnSaveGlob->set_label(_("Save to global configuration"));
btnSaveLocal->set_label(_("Save to local configuration"));
lblHeadFiltersWindow->set_label(_("Filters"));
}
void MainWindow::view_add_columns(Gtk::TreeView &treeView) {
// TODO:
// Не готово
treeView.append_column(_("Name"), m_columns.name);
treeView.append_column_editable(_("Quotas"), m_columns.quotas);
treeView.append_column(_("Size"), m_columns.size);

@ -20,11 +20,8 @@ extern const string app_name;
extern const string path_locale;
extern const string path_css;
extern const string path_img_head_background;
extern string version_application;
class MainWindow : public Gtk::ApplicationWindow {
public:
class ModelColumns : public Gtk::TreeModel::ColumnRecord {
@ -185,9 +182,6 @@ class MainWindow : public Gtk::ApplicationWindow {
Gtk::SpinButton *generalUsersFilesHoursSpin;
Gtk::SpinButton *generalUsersSizeMinuteSpin;
Gtk::SpinButton *generalUsersFilesMinutesSpin;
public:
Lib_save::Save obj_save = Lib_save::Save();
Lib_Load::Load obj_load = Lib_Load::Load();
@ -200,7 +194,6 @@ class MainWindow : public Gtk::ApplicationWindow {
vector<string> vec_param_names;
map_str_device map_device;
string str_cmd_error;
public:
MainWindow(BaseObjectType* obj, Glib::RefPtr<Gtk::Builder> const& builder);
MainWindow(Glib::RefPtr<Gtk::Builder> const& builder);

@ -12,4 +12,4 @@ Icon=com.ublinux.ubl-settings-quotas
Terminal=false
X-XfcePluggable=true
X-UBLPluggable=true
Categories=XFCE;GTK;Settings;DesktopSettings;X-XFCE-SettingsDialog;X-XFCE-SystemSettings;
Categories=XFCE;GTK;Settings;DesktopSettings;X-XFCE-SettingsDialog;X-XFCE-SystemSettings;X-UBL-SettingsManager;X-UBL-SystemSettings;

@ -725,8 +725,8 @@ msgstr "ubl-settings-quotas версия: "
msgid "weeks"
msgstr "недели"
#~ msgid "ubl-settings-quotas"
#~ msgstr "Квоты"
msgid "ubl-settings-quotas"
msgstr "Квоты"
#~ msgid "Severe limitation (size)"
#~ msgstr "Жесткое ограничение (объём)"

Loading…
Cancel
Save