|
|
|
|
@ -836,7 +836,7 @@ void MainWindow::get_config(){
|
|
|
|
|
this->update_calendar();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
array<string, 2> MainWindow::split_region_zone(string read_reg_zon_cfg){
|
|
|
|
|
array<string, 2> MainWindow::split_region_zone(string &read_reg_zon_cfg){
|
|
|
|
|
array<string, 2> arr;
|
|
|
|
|
if (read_reg_zon_cfg.find("/")!=std::string::npos){
|
|
|
|
|
string str_filling_reg = read_reg_zon_cfg.substr(0,read_reg_zon_cfg.find("/"));
|
|
|
|
|
@ -845,6 +845,10 @@ array<string, 2> MainWindow::split_region_zone(string read_reg_zon_cfg){
|
|
|
|
|
arr[0] = str_filling_reg;
|
|
|
|
|
arr[1] = str_filling_zon;
|
|
|
|
|
}
|
|
|
|
|
else if (read_reg_zon_cfg.length()!=0){
|
|
|
|
|
arr[0] = read_reg_zon_cfg;
|
|
|
|
|
arr[1] = "";
|
|
|
|
|
}
|
|
|
|
|
else{
|
|
|
|
|
arr[0] = "";
|
|
|
|
|
arr[1] = "";
|
|
|
|
|
@ -940,11 +944,13 @@ void MainWindow::append_region_zone(string region, string zone, Gtk::ComboBoxTex
|
|
|
|
|
if (region==""){
|
|
|
|
|
tmpCbZone->append(" ");
|
|
|
|
|
tmpCbZone->set_active(0);
|
|
|
|
|
tmpCbReg->set_active(-1);
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (time_reg_map_local.find(region) == time_reg_map_local.end()){
|
|
|
|
|
tmpCbZone->append(" ");
|
|
|
|
|
tmpCbZone->set_active(0);
|
|
|
|
|
tmpCbReg->set_active(-1);
|
|
|
|
|
}
|
|
|
|
|
else{
|
|
|
|
|
for (string &_str_zone : time_reg_map_local.at(region)){
|
|
|
|
|
@ -959,6 +965,7 @@ void MainWindow::append_region_zone(string region, string zone, Gtk::ComboBoxTex
|
|
|
|
|
}
|
|
|
|
|
if (region=="Etc" && zone==""){
|
|
|
|
|
warning_info-=1;
|
|
|
|
|
tmpCbZone->set_active(index);
|
|
|
|
|
}
|
|
|
|
|
else if (region=="" && zone==""){
|
|
|
|
|
warning_info+=1;
|
|
|
|
|
@ -991,6 +998,7 @@ string MainWindow::call(string cmd){
|
|
|
|
|
void MainWindow::append_zone(){
|
|
|
|
|
cbZone->remove_all();
|
|
|
|
|
int index = cbRegion->get_active_row_number();
|
|
|
|
|
if (index!=-1){
|
|
|
|
|
string str_region = array_region[index];
|
|
|
|
|
string zone_mixing="";
|
|
|
|
|
string path_dir="";
|
|
|
|
|
@ -1000,6 +1008,7 @@ void MainWindow::append_zone(){
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
cbZone->set_active(0);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void MainWindow::update_time_date(){
|
|
|
|
|
|