static void _e_mod_config_schedule_start_working_cb(void *data, void *data2) { E_Config_Schedule_Data *csd; E_Config_Dialog_Data *cfdata; if(!(csd = data)) return; if(!(cfdata = data2)) return; if(e_widget_disabled_get(csd->obstop) == EINA_TRUE) { e_widget_disabled_set(csd->obbreak, EINA_TRUE); e_widget_disabled_set(csd->obwork, EINA_TRUE); if(csd->lock == EINA_FALSE) { csd->lock = EINA_TRUE; } if(productivity_conf->secs_to_break) productivity_conf->secs_to_break = 0; } _e_mod_config_schedule_lock_update(csd); e_mod_config_schedule_save_config(cfdata); e_mod_config_worktools_save(cfdata); productivity_conf->init = E_MOD_PROD_INIT_START; ecore_timer_freeze(productivity_conf->wm); e_mod_config_window_manager_v2(productivity_conf->cwl); ecore_timer_thaw(productivity_conf->wm); e_config_save(); }
static void _e_wid_disable_hook(Evas_Object *obj) { E_Widget_Data *wd; wd = e_widget_data_get(obj); if (e_widget_disabled_get(obj)) edje_object_signal_emit(wd->o_check, "e,state,disabled", "e"); else edje_object_signal_emit(wd->o_check, "e,state,enabled", "e"); }
static void _e_wid_disable_hook(Evas_Object *obj) { E_Widget_Data *wd; if (!(obj) || (!(wd = e_widget_data_get(obj)))) return; if (e_widget_disabled_get(obj)) e_entry_disable(wd->o_entry); else e_entry_enable(wd->o_entry); }
static void _e_mod_config_schedule_lock_update(E_Config_Schedule_Data *csd) { if(csd->lock == EINA_TRUE) { e_widget_disabled_set(csd->obstop, EINA_FALSE); e_widget_disabled_set(csd->obbreak, EINA_TRUE); e_widget_disabled_set(csd->obwork, EINA_TRUE); e_widget_disabled_set(csd->oburgent, EINA_TRUE); if(e_widget_disabled_get(csd->obstart) == EINA_FALSE) e_widget_disabled_set(csd->obstart, EINA_TRUE); } else if (csd->lock == EINA_FALSE) { e_widget_disabled_set(csd->obstop, EINA_TRUE); e_widget_disabled_set(csd->obbreak, EINA_FALSE); e_widget_disabled_set(csd->obwork, EINA_FALSE); e_widget_disabled_set(csd->oburgent, EINA_FALSE); if(e_widget_disabled_get(csd->obstart) == EINA_TRUE) e_widget_disabled_set(csd->obstart, EINA_FALSE); } }
static void _e_wid_do(Evas_Object *obj) { E_Widget_Data *wd; if (e_widget_disabled_get(obj)) return; wd = e_widget_data_get(obj); if (wd->valptr) { if (*(wd->valptr) == 0) { *(wd->valptr) = 1; edje_object_signal_emit(wd->o_check, "e,state,checked", "e"); } else { *(wd->valptr) = 0; edje_object_signal_emit(wd->o_check, "e,state,unchecked", "e"); } } evas_object_smart_callback_call(obj, "changed", NULL); e_widget_change(obj); }