|
|
|
@ -46,7 +46,6 @@ MainWindow::MainWindow(Glib::RefPtr<Gtk::Builder> const& builder) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void MainWindow::get_builder() {
|
|
|
|
void MainWindow::get_builder() {
|
|
|
|
|
|
|
|
|
|
|
|
builder->get_widget("imgHeadBackground", imgHeadBackground);
|
|
|
|
builder->get_widget("imgHeadBackground", imgHeadBackground);
|
|
|
|
builder->get_widget("overHead", overHead);
|
|
|
|
builder->get_widget("overHead", overHead);
|
|
|
|
builder->get_widget("btnFilemaneg", btnFilemaneg);
|
|
|
|
builder->get_widget("btnFilemaneg", btnFilemaneg);
|
|
|
|
@ -143,6 +142,10 @@ void MainWindow::add_CSS() {
|
|
|
|
Glib::RefPtr<Gtk::StyleContext> context_lbl_head = lblInfoHead->get_style_context();
|
|
|
|
Glib::RefPtr<Gtk::StyleContext> context_lbl_head = lblInfoHead->get_style_context();
|
|
|
|
Glib::RefPtr<Gtk::StyleContext> boxAbout_css = boxAbout->get_style_context();
|
|
|
|
Glib::RefPtr<Gtk::StyleContext> boxAbout_css = boxAbout->get_style_context();
|
|
|
|
imgHeadBackground->set(path_img_head_background);
|
|
|
|
imgHeadBackground->set(path_img_head_background);
|
|
|
|
|
|
|
|
for (auto &view: array_icon){
|
|
|
|
|
|
|
|
Glib::RefPtr<Gtk::StyleContext> view_css = view->get_style_context();
|
|
|
|
|
|
|
|
view_css->add_class("view_app");
|
|
|
|
|
|
|
|
}
|
|
|
|
context_lbl_head->add_class("textHead");
|
|
|
|
context_lbl_head->add_class("textHead");
|
|
|
|
if (socket_ext_id_I == 0){
|
|
|
|
if (socket_ext_id_I == 0){
|
|
|
|
boxAbout_css->add_class("bkim_no_plug");
|
|
|
|
boxAbout_css->add_class("bkim_no_plug");
|
|
|
|
@ -297,6 +300,9 @@ void MainWindow::delete_cmd(const int &x, const int &y) {
|
|
|
|
chbTerminal->set_active(false);
|
|
|
|
chbTerminal->set_active(false);
|
|
|
|
chbAnotherUser->set_active(false);
|
|
|
|
chbAnotherUser->set_active(false);
|
|
|
|
cbxExecuteEpriority->set_active(false);
|
|
|
|
cbxExecuteEpriority->set_active(false);
|
|
|
|
|
|
|
|
name_app = "";
|
|
|
|
|
|
|
|
path_file = "";
|
|
|
|
|
|
|
|
user_cmd = "";
|
|
|
|
txtCmd->set_text("");
|
|
|
|
txtCmd->set_text("");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
@ -306,10 +312,10 @@ bool MainWindow::focus_in_txt_cmd(GdkEventFocus* event) {
|
|
|
|
if (user_cmd.length() != 0) {
|
|
|
|
if (user_cmd.length() != 0) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (name_app.length() != 0) {
|
|
|
|
else if (name_app.length() != 0) {
|
|
|
|
name_app = "";
|
|
|
|
//name_app = "";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (path_file.length() != 0) {
|
|
|
|
else if (path_file.length() != 0) {
|
|
|
|
path_file = "";
|
|
|
|
//path_file = "";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else{
|
|
|
|
else{
|
|
|
|
user_cmd = txtCmd->get_text();
|
|
|
|
user_cmd = txtCmd->get_text();
|
|
|
|
@ -324,7 +330,6 @@ void MainWindow::synopsis_show() {
|
|
|
|
string response_user = getlogin();
|
|
|
|
string response_user = getlogin();
|
|
|
|
cmd = "su -l " + response_user + " -c \" DISPLAY=$DISPLAY " + cmd + " \"";
|
|
|
|
cmd = "su -l " + response_user + " -c \" DISPLAY=$DISPLAY " + cmd + " \"";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
cout << cmd << endl;
|
|
|
|
|
|
|
|
index_error = system(cmd.c_str());
|
|
|
|
index_error = system(cmd.c_str());
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@ -425,6 +430,7 @@ void MainWindow::settings() {
|
|
|
|
this->get_builder();
|
|
|
|
this->get_builder();
|
|
|
|
this->event();
|
|
|
|
this->event();
|
|
|
|
this->localization();
|
|
|
|
this->localization();
|
|
|
|
|
|
|
|
this->set_icon_array();
|
|
|
|
this->add_CSS();
|
|
|
|
this->add_CSS();
|
|
|
|
spinPriority->set_range(0, 19);
|
|
|
|
spinPriority->set_range(0, 19);
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
spinPriority->set_increments(1.0, -1.0);
|
|
|
|
@ -704,7 +710,7 @@ void MainWindow::denamic_cmd() {
|
|
|
|
path_file = "";
|
|
|
|
path_file = "";
|
|
|
|
name_app = "";
|
|
|
|
name_app = "";
|
|
|
|
user_cmd = "";
|
|
|
|
user_cmd = "";
|
|
|
|
txtCmd->set_text(user_cmd);
|
|
|
|
txtCmd->set_text(user_cmd);
|
|
|
|
messageError->set_title(gettext("Attention"));
|
|
|
|
messageError->set_title(gettext("Attention"));
|
|
|
|
messageError->show();
|
|
|
|
messageError->show();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|