|
|
|
@ -339,7 +339,9 @@ void MainWindow::event() {
|
|
|
|
bool MainWindow::focus_ntp(GdkEventFocus* event) {
|
|
|
|
bool MainWindow::focus_ntp(GdkEventFocus* event) {
|
|
|
|
if (event!=NULL){
|
|
|
|
if (event!=NULL){
|
|
|
|
}
|
|
|
|
}
|
|
|
|
this->focus_ntp_text();
|
|
|
|
if (flag_ntp_edit == false) {
|
|
|
|
|
|
|
|
this->focus_ntp_text();
|
|
|
|
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@ -995,12 +997,13 @@ void MainWindow::save_Dhcp(string &cmd_default, string &cmd_dhcp, string &remove
|
|
|
|
wrapper_system(cmd_dhcp, "&");
|
|
|
|
wrapper_system(cmd_dhcp, "&");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (activ_index == 2) {
|
|
|
|
else if (activ_index == 2) {
|
|
|
|
|
|
|
|
if (flag_ntp_edit == false) {
|
|
|
|
if (this->focus_ntp_text()){
|
|
|
|
if (this->focus_ntp_text()){
|
|
|
|
string str_ntp = txtNtpServer->get_text();
|
|
|
|
string str_ntp = txtNtpServer->get_text();
|
|
|
|
string cmd = cmd_set_ntp + str_ntp + "\"";
|
|
|
|
string cmd = cmd_set_ntp + str_ntp + "\"";
|
|
|
|
this->write_config(str_ntp, "dhcp");
|
|
|
|
this->write_config(str_ntp, "dhcp");
|
|
|
|
wrapper_system(cmd, "&");
|
|
|
|
wrapper_system(cmd, "&");
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|