SVN revision: 48191devs/princeamd/enlightenment-0.17-elive
parent
c622928863
commit
26127d523f
31 changed files with 4 additions and 2499 deletions
@ -1,7 +0,0 @@ |
||||
.deps |
||||
.libs |
||||
Makefile |
||||
Makefile.in |
||||
*.lo |
||||
module.la |
||||
module.desktop |
@ -1,31 +0,0 @@ |
||||
MAINTAINERCLEANFILES = Makefile.in
|
||||
MODULE = conf_exebuf
|
||||
|
||||
# data files for the module
|
||||
filesdir = $(libdir)/enlightenment/modules/$(MODULE)
|
||||
files_DATA = \
|
||||
e-module-$(MODULE).edj module.desktop |
||||
|
||||
EXTRA_DIST = $(files_DATA)
|
||||
|
||||
# the module .so file
|
||||
INCLUDES = -I. \
|
||||
-I$(top_srcdir) \
|
||||
-I$(top_srcdir)/src/modules/$(MODULE) \
|
||||
-I$(top_srcdir)/src/bin \
|
||||
-I$(top_srcdir)/src/lib \
|
||||
-I$(top_srcdir)/src/modules \
|
||||
@e_cflags@
|
||||
pkgdir = $(libdir)/enlightenment/modules/$(MODULE)/$(MODULE_ARCH)
|
||||
pkg_LTLIBRARIES = module.la
|
||||
module_la_SOURCES = e_mod_main.c \
|
||||
e_mod_main.h \
|
||||
e_int_config_exebuf.c \
|
||||
e_int_config_exebuf.h
|
||||
|
||||
module_la_LIBADD = @e_libs@ @dlopen_libs@
|
||||
module_la_LDFLAGS = -module -avoid-version
|
||||
module_la_DEPENDENCIES = $(top_builddir)/config.h
|
||||
|
||||
uninstall: |
||||
rm -rf $(DESTDIR)$(libdir)/enlightenment/modules/$(MODULE)
|
Binary file not shown.
@ -1,293 +0,0 @@ |
||||
#include "e.h" |
||||
|
||||
/* local function prototypes */ |
||||
static void *_create_data(E_Config_Dialog *cfd __UNUSED__); |
||||
static void _fill_data(E_Config_Dialog_Data *cfdata); |
||||
static void _free_data(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata); |
||||
static int _basic_apply(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata); |
||||
static Evas_Object *_basic_create(E_Config_Dialog *cfd __UNUSED__, Evas *evas, E_Config_Dialog_Data *cfdata); |
||||
static int _basic_check_changed(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata); |
||||
static int _adv_apply(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata); |
||||
static Evas_Object *_adv_create(E_Config_Dialog *cfd __UNUSED__, Evas *evas, E_Config_Dialog_Data *cfdata); |
||||
static int _adv_check_changed(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata); |
||||
static void _cb_animate_changed(void *data, Evas_Object *obj __UNUSED__); |
||||
|
||||
struct _E_Config_Dialog_Data |
||||
{ |
||||
/* Basic */ |
||||
int max_exe_list, max_eap_list, max_hist_list; |
||||
int scroll_animate; |
||||
/* Advanced */ |
||||
double scroll_speed, pos_align_x, pos_align_y; |
||||
double pos_size_w, pos_size_h; |
||||
int pos_min_w, pos_min_h, pos_max_w, pos_max_h; |
||||
char *term_cmd; |
||||
struct |
||||
{ |
||||
Evas_Object *scroll_speed_lbl, *scroll_speed_slider; |
||||
} gui; |
||||
}; |
||||
|
||||
E_Config_Dialog * |
||||
e_int_config_exebuf(E_Container *con, const char *params __UNUSED__) |
||||
{ |
||||
E_Config_Dialog *cfd; |
||||
E_Config_Dialog_View *v; |
||||
|
||||
if (e_config_dialog_find("E", "advanced/run_command")) return NULL; |
||||
|
||||
v = E_NEW(E_Config_Dialog_View, 1); |
||||
v->create_cfdata = _create_data; |
||||
v->free_cfdata = _free_data; |
||||
v->basic.create_widgets = _basic_create; |
||||
v->basic.apply_cfdata = _basic_apply; |
||||
v->basic.check_changed = _basic_check_changed; |
||||
v->advanced.create_widgets = _adv_create; |
||||
v->advanced.apply_cfdata = _adv_apply; |
||||
v->advanced.check_changed = _adv_check_changed; |
||||
|
||||
cfd = e_config_dialog_new(con, _("Run Command Settings"), "E", |
||||
"advanced/run_command", "system-run", 0, v, NULL); |
||||
return cfd; |
||||
} |
||||
|
||||
/* local function prototypes */ |
||||
static void * |
||||
_create_data(E_Config_Dialog *cfd __UNUSED__) |
||||
{ |
||||
E_Config_Dialog_Data *cfdata; |
||||
|
||||
cfdata = E_NEW(E_Config_Dialog_Data, 1); |
||||
_fill_data(cfdata); |
||||
return cfdata; |
||||
} |
||||
|
||||
static void |
||||
_fill_data(E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
cfdata->max_exe_list = e_config->exebuf_max_exe_list; |
||||
cfdata->max_eap_list = e_config->exebuf_max_eap_list; |
||||
cfdata->max_hist_list = e_config->exebuf_max_hist_list; |
||||
cfdata->scroll_animate = e_config->exebuf_scroll_animate; |
||||
cfdata->scroll_speed = e_config->exebuf_scroll_speed; |
||||
cfdata->pos_align_x = e_config->exebuf_pos_align_x; |
||||
cfdata->pos_align_y = e_config->exebuf_pos_align_y; |
||||
cfdata->pos_size_w = e_config->exebuf_pos_size_w; |
||||
cfdata->pos_size_h = e_config->exebuf_pos_size_h; |
||||
cfdata->pos_min_w = e_config->exebuf_pos_min_w; |
||||
cfdata->pos_min_h = e_config->exebuf_pos_min_h; |
||||
cfdata->pos_max_w = e_config->exebuf_pos_max_w; |
||||
cfdata->pos_max_h = e_config->exebuf_pos_max_h; |
||||
if (e_config->exebuf_term_cmd) |
||||
cfdata->term_cmd = strdup(e_config->exebuf_term_cmd); |
||||
} |
||||
|
||||
static void |
||||
_free_data(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
E_FREE(cfdata->term_cmd); |
||||
E_FREE(cfdata); |
||||
} |
||||
|
||||
static int |
||||
_basic_apply(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
e_config->exebuf_max_exe_list = cfdata->max_exe_list; |
||||
e_config->exebuf_max_eap_list = cfdata->max_eap_list; |
||||
e_config->exebuf_max_hist_list = cfdata->max_hist_list; |
||||
e_config->exebuf_scroll_animate = cfdata->scroll_animate; |
||||
e_config_save_queue(); |
||||
return 1; |
||||
} |
||||
|
||||
static Evas_Object * |
||||
_basic_create(E_Config_Dialog *cfd __UNUSED__, Evas *evas, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
Evas_Object *o, *of, *ow; |
||||
|
||||
o = e_widget_list_add(evas, 0, 0); |
||||
|
||||
of = e_widget_framelist_add(evas, _("General"), 0); |
||||
ow = e_widget_label_add(evas, _("Maximum Apps to List")); |
||||
e_widget_framelist_object_append(of, ow); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 50, 5, 0, NULL, |
||||
&(cfdata->max_eap_list), 100); |
||||
e_widget_framelist_object_append(of, ow); |
||||
ow = e_widget_label_add(evas, _("Maximum Exes to List")); |
||||
e_widget_framelist_object_append(of, ow); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 50, 5, 0, NULL, |
||||
&(cfdata->max_exe_list), 100); |
||||
e_widget_framelist_object_append(of, ow); |
||||
ow = e_widget_label_add(evas, _("Maximum History to List")); |
||||
e_widget_framelist_object_append(of, ow); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 200, 5, 0, NULL, |
||||
&(cfdata->max_hist_list), 100); |
||||
e_widget_framelist_object_append(of, ow); |
||||
e_widget_list_object_append(o, of, 1, 0, 0.5); |
||||
|
||||
of = e_widget_framelist_add(evas, _("Animations"), 0); |
||||
ow = e_widget_check_add(evas, _("Animate"), &(cfdata->scroll_animate)); |
||||
e_widget_framelist_object_append(of, ow); |
||||
e_widget_list_object_append(o, of, 1, 0, 0.5); |
||||
|
||||
return o; |
||||
} |
||||
|
||||
static int |
||||
_basic_check_changed(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
#define CHK_CHG(_e_config, _cfdata) \ |
||||
if (e_config->exebuf_##_e_config != cfdata->_cfdata) return 1; |
||||
|
||||
CHK_CHG(max_exe_list, max_exe_list); |
||||
CHK_CHG(max_eap_list, max_eap_list); |
||||
CHK_CHG(max_hist_list, max_hist_list); |
||||
CHK_CHG(scroll_animate, scroll_animate); |
||||
|
||||
#undef CHK_CHG |
||||
|
||||
return 0; |
||||
} |
||||
|
||||
static int |
||||
_adv_apply(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
e_config->exebuf_max_exe_list = cfdata->max_exe_list; |
||||
e_config->exebuf_max_eap_list = cfdata->max_eap_list; |
||||
e_config->exebuf_max_hist_list = cfdata->max_hist_list; |
||||
e_config->exebuf_scroll_animate = cfdata->scroll_animate; |
||||
e_config->exebuf_scroll_speed = cfdata->scroll_speed; |
||||
e_config->exebuf_pos_align_x = cfdata->pos_align_x; |
||||
e_config->exebuf_pos_align_y = cfdata->pos_align_y; |
||||
e_config->exebuf_pos_min_w = cfdata->pos_min_w; |
||||
e_config->exebuf_pos_min_h = cfdata->pos_min_h; |
||||
e_config->exebuf_pos_max_w = cfdata->pos_max_w; |
||||
e_config->exebuf_pos_max_h = cfdata->pos_max_h; |
||||
eina_stringshare_replace(&e_config->exebuf_term_cmd, cfdata->term_cmd); |
||||
e_config_save_queue(); |
||||
return 1; |
||||
} |
||||
|
||||
static Evas_Object * |
||||
_adv_create(E_Config_Dialog *cfd __UNUSED__, Evas *evas, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
Evas_Object *otb, *ol, *ow; |
||||
|
||||
otb = e_widget_toolbook_add(evas, (48 * e_scale), (48 * e_scale)); |
||||
|
||||
/* General Page */ |
||||
ol = e_widget_list_add(evas, 0, 0); |
||||
ow = e_widget_label_add(evas, _("Maximum Apps to List")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 50, 5, 0, NULL, |
||||
&(cfdata->max_eap_list), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Maximum Exes to List")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 50, 5, 0, NULL, |
||||
&(cfdata->max_exe_list), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Maximum History to List")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 200, 5, 0, NULL, |
||||
&(cfdata->max_hist_list), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
e_widget_toolbook_page_append(otb, NULL, _("General"), ol, 1, 0, 1, 0, |
||||
0.5, 0.0); |
||||
|
||||
/* Scroll Page */ |
||||
ol = e_widget_list_add(evas, 0, 0); |
||||
ow = e_widget_check_add(evas, _("Animate"), &(cfdata->scroll_animate)); |
||||
e_widget_on_change_hook_set(ow, _cb_animate_changed, cfdata); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Speed")); |
||||
cfdata->gui.scroll_speed_lbl = ow; |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.2f"), 0.0, 1.0, 0.01, 0, |
||||
&(cfdata->scroll_speed), NULL, 100); |
||||
cfdata->gui.scroll_speed_slider = ow; |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
e_widget_toolbook_page_append(otb, NULL, _("Animations"), ol, 1, 0, 1, 0, |
||||
0.5, 0.0); |
||||
|
||||
/* Size Page */ |
||||
ol = e_widget_list_add(evas, 0, 0); |
||||
ow = e_widget_label_add(evas, _("Minimum Width")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%4.0f"), 0, 4000, 50, 0, |
||||
NULL, &(cfdata->pos_min_w), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Minimum Height")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%4.0f"), 0, 4000, 50, 0, |
||||
NULL, &(cfdata->pos_min_h), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Maximum Width")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%4.0f"), 0, 4000, 50, 0, |
||||
NULL, &(cfdata->pos_max_w), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Maximum Height")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%4.0f"), 0, 4000, 50, 0, |
||||
NULL, &(cfdata->pos_max_h), 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("X-Axis Alignment")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.2f"), 0.0, 1.0, 0.01, 0, |
||||
&(cfdata->pos_align_x), NULL, 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_label_add(evas, _("Y-Axis Alignment")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_slider_add(evas, 1, 0, _("%1.2f"), 0.0, 1.0, 0.01, 0, |
||||
&(cfdata->pos_align_y), NULL, 100); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
e_widget_toolbook_page_append(otb, NULL, _("Geometry"), ol, 1, 0, 1, 0, |
||||
0.5, 0.0); |
||||
|
||||
/* Terminal Page */ |
||||
ol = e_widget_list_add(evas, 0, 0); |
||||
ow = e_widget_label_add(evas, _("Command (CTRL+RETURN to utilize)")); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
ow = e_widget_entry_add(evas, &(cfdata->term_cmd), NULL, NULL, NULL); |
||||
e_widget_list_object_append(ol, ow, 1, 0, 0.5); |
||||
e_widget_toolbook_page_append(otb, NULL, _("Terminal"), ol, 1, 0, 1, 0, |
||||
0.5, 0.0); |
||||
|
||||
e_widget_toolbook_page_show(otb, 0); |
||||
return otb; |
||||
} |
||||
|
||||
static int |
||||
_adv_check_changed(E_Config_Dialog *cfd __UNUSED__, E_Config_Dialog_Data *cfdata) |
||||
{ |
||||
#define CHK_CHG(_e_config, _cfdata) \ |
||||
if (e_config->exebuf_##_e_config != cfdata->_cfdata) return 1; |
||||
|
||||
CHK_CHG(max_exe_list, max_exe_list); |
||||
CHK_CHG(max_eap_list, max_eap_list); |
||||
CHK_CHG(max_hist_list, max_hist_list); |
||||
CHK_CHG(scroll_animate, scroll_animate); |
||||
CHK_CHG(scroll_speed, scroll_speed); |
||||
CHK_CHG(pos_align_x, pos_align_x); |
||||
CHK_CHG(pos_align_y, pos_align_y); |
||||
CHK_CHG(pos_min_w, pos_min_w); |
||||
CHK_CHG(pos_min_h, pos_min_h); |
||||
CHK_CHG(pos_max_w, pos_max_w); |
||||
CHK_CHG(pos_max_h, pos_max_h); |
||||
|
||||
if (strcmp(e_config->exebuf_term_cmd, cfdata->term_cmd)) return 1; |
||||
#undef CHK_CHG |
||||
|
||||
return 0; |
||||
} |
||||
|
||||
static void |
||||
_cb_animate_changed(void *data, Evas_Object *obj __UNUSED__) |
||||
{ |
||||
E_Config_Dialog_Data *cfdata; |
||||
|
||||
if (!(cfdata = data)) return; |
||||
e_widget_disabled_set(cfdata->gui.scroll_speed_lbl, !cfdata->scroll_animate); |
||||
e_widget_disabled_set(cfdata->gui.scroll_speed_slider, !cfdata->scroll_animate); |
||||
} |
@ -1,9 +0,0 @@ |
||||
#ifdef E_TYPEDEFS |
||||
#else |
||||
#ifndef E_INT_CONFIG_EXEBUF_H |
||||
#define E_INT_CONFIG_EXEBUF_H |
||||
|
||||
E_Config_Dialog *e_int_config_exebuf(E_Container *con, const char *params __UNUSED__); |
||||
|
||||
#endif |
||||
#endif |
@ -1,42 +0,0 @@ |
||||
/*
|
||||
* vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2 |
||||
*/ |
||||
#include "e.h" |
||||
#include "e_mod_main.h" |
||||
|
||||
/* actual module specifics */ |
||||
static E_Module *conf_module = NULL; |
||||
|
||||
/* module setup */ |
||||
EAPI E_Module_Api e_modapi = |
||||
{ |
||||
E_MODULE_API_VERSION, |
||||
"Settings - Run Command" |
||||
}; |
||||
|
||||
EAPI void * |
||||
e_modapi_init(E_Module *m) |
||||
{ |
||||
e_configure_registry_category_add("advanced", 80, _("Advanced"), NULL, "preferences-advanced"); |
||||
e_configure_registry_item_add("advanced/run_command", 40, _("Run Command"), NULL, "system-run", e_int_config_exebuf); |
||||
conf_module = m; |
||||
e_module_delayed_set(m, 1); |
||||
return m; |
||||
} |
||||
|
||||
EAPI int |
||||
e_modapi_shutdown(E_Module *m) |
||||
{ |
||||
E_Config_Dialog *cfd; |
||||
while ((cfd = e_config_dialog_get("E", "advanced/run_command"))) e_object_del(E_OBJECT(cfd)); |
||||
e_configure_registry_item_del("advanced/run_command"); |
||||
e_configure_registry_category_del("advanced"); |
||||
conf_module = NULL; |
||||
return 1; |
||||
} |
||||
|
||||
EAPI int |
||||
e_modapi_save(E_Module *m) |
||||
{ |
||||
return 1; |
||||
} |
@ -1,19 +0,0 @@ |
||||
/*
|
||||
* vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2 |
||||
*/ |
||||
#ifndef E_MOD_MAIN_H |
||||
#define E_MOD_MAIN_H |
||||
|
||||
#define E_TYPEDEFS 1 |
||||
#include "e_int_config_exebuf.h" |
||||
|
||||
#undef E_TYPEDEFS |
||||
#include "e_int_config_exebuf.h" |
||||
|
||||
EAPI extern E_Module_Api e_modapi; |
||||
|
||||
EAPI void *e_modapi_init (E_Module *m); |
||||
EAPI int e_modapi_shutdown (E_Module *m); |
||||
EAPI int e_modapi_save (E_Module *m); |
||||
|
||||
#endif |
@ -1,32 +0,0 @@ |
||||
[Desktop Entry] |
||||
Type=Link |
||||
Name=Settings - Run Command |
||||
Name[cs]=Nastavení - dialog Spustit |
||||
Name[de]= |
||||
Name[eo]=Agordo - Lanĉi komandon |
||||
Name[es]=Configuración - Ejecutar comando |
||||
Name[fr]=Configuration - Ligne de commande |
||||
Name[hu]=Beállítások - Parancs futtatása |
||||
Name[it]=Configurazione - Lanciacomandi |
||||
Name[ja]= |
||||
Name[pt]= |
||||
Name[pt_BR]= |
||||
Name[tr]=Ayarlar - Komut Çalıştır |
||||
Name[zh_CN]= |
||||
Name[zh_TW]= |
||||
Icon=e-module-conf_exebuf |
||||
Comment=Used to configure the settings of the run command GUI. |
||||
Comment[cs]=Použit pro nastavení voleb dialogu Spustit. |
||||
Comment[de]= |
||||
Comment[eo]=Agordi la parametrojn de la uzulinterfaco por la lanĉo de komandoj. |
||||
Comment[es]=Usado para configurar las opciones de la GUI para ejecutar un comando. |
||||
Comment[fr]=Permet de configurer l'interface de l'exécution de commande. |
||||
Comment[hu]=Itt beállíthadot a "Parancs futtatása" ablak tulajdonságait. |
||||
Comment[it]=Usato per configurare le impostazioni della GUI per l'esecuzione di comandi. |
||||
Comment[ja]= |
||||
Comment[pt]= |
||||
Comment[pt_BR]= |
||||
Comment[tr]=Komut çalıştırma arayüzünün ayarlarını yapılandırır. |
||||
Comment[zh_CN]= |
||||
Comment[zh_TW]= |
||||
X-Enlightenment-ModuleType=config |
@ -1,7 +0,0 @@ |
||||
.deps |
||||
.libs |
||||
Makefile |
||||
Makefile.in |
||||
*.lo |
||||
module.la |
||||
module.desktop |
@ -1,31 +0,0 @@ |
||||
MAINTAINERCLEANFILES = Makefile.in
|
||||
MODULE = exebuf
|
||||
|
||||
# data files for the module
|
||||
filesdir = $(libdir)/enlightenment/modules/$(MODULE)
|
||||
files_DATA = \
|
||||
e-module-$(MODULE).edj module.desktop |
||||
|
||||
EXTRA_DIST = $(files_DATA)
|
||||
|
||||
# the module .so file
|
||||
INCLUDES = -I. \
|
||||
-I$(top_srcdir) \
|
||||
-I$(top_srcdir)/src/modules/$(MODULE) \
|
||||
-I$(top_srcdir)/src/bin \
|
||||
-I$(top_srcdir)/src/lib \
|
||||
-I$(top_srcdir)/src/modules \
|
||||
@e_cflags@
|
||||
pkgdir = $(libdir)/enlightenment/modules/$(MODULE)/$(MODULE_ARCH)
|
||||
pkg_LTLIBRARIES = module.la
|
||||
module_la_SOURCES = e_mod_main.c \
|
||||
e_mod_main.h \
|
||||
e_exebuf.c \
|
||||
e_exebuf.h
|
||||
|
||||
module_la_LIBADD = @e_libs@ @dlopen_libs@
|
||||
module_la_LDFLAGS = -module -avoid-version
|
||||
module_la_DEPENDENCIES = $(top_builddir)/config.h
|
||||
|
||||
uninstall: |
||||
rm -rf $(DESTDIR)$(libdir)/enlightenment/modules/$(MODULE)
|
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@ -1,17 +0,0 @@ |
||||
/*
|
||||
* vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2 |
||||
*/ |
||||
#ifdef E_TYPEDEFS |
||||
|
||||
#else |
||||
#ifndef E_EXEBUF_H |
||||
#define E_EXEBUF_H |
||||
|
||||
int e_exebuf_init(void); |
||||
int e_exebuf_shutdown(void); |
||||
|
||||
int e_exebuf_show(E_Zone *zone); |
||||
void e_exebuf_hide(void); |
||||
|
||||
#endif |
||||
#endif |
@ -1,118 +0,0 @@ |
||||
/*
|
||||
* vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2 |
||||
*/ |
||||
#include "e.h" |
||||
#include "e_mod_main.h" |
||||
|
||||
/* actual module specifics */ |
||||
static void _e_mod_action_exebuf_cb(E_Object *obj, const char *params); |
||||
static int _e_mod_run_defer_cb(void *data); |
||||
static void _e_mod_run_cb(void *data, E_Menu *m, E_Menu_Item *mi); |
||||
static void _e_mod_menu_add(void *data, E_Menu *m); |
||||
|
||||
static E_Module *conf_module = NULL; |
||||
static E_Action *act = NULL; |
||||
static E_Int_Menu_Augmentation *maug = NULL; |
||||
|
||||
/* module setup */ |
||||
EAPI E_Module_Api e_modapi = |
||||
{ |
||||
E_MODULE_API_VERSION, |
||||
"Exebuf" |
||||
}; |
||||
|
||||
EAPI void * |
||||
e_modapi_init(E_Module *m) |
||||
{ |
||||
conf_module = m; |
||||
e_exebuf_init(); |
||||
/* add module supplied action */ |
||||
act = e_action_add("exebuf"); |
||||
if (act) |
||||
{ |
||||
act->func.go = _e_mod_action_exebuf_cb; |
||||
e_action_predef_name_set(_("Launch"), _("Run Command Dialog"), "exebuf", |
||||
NULL, NULL, 0); |
||||
} |
||||
maug = e_int_menus_menu_augmentation_add_sorted |
||||
("main/1", _("Run Command"), _e_mod_menu_add, NULL, NULL, NULL); |
||||
e_module_delayed_set(m, 1); |
||||
return m; |
||||
} |
||||
|
||||
EAPI int |
||||
e_modapi_shutdown(E_Module *m) |
||||
{ |
||||
/* remove module-supplied menu additions */ |
||||
if (maug) |
||||
{ |
||||
e_int_menus_menu_augmentation_del("main/1", maug); |
||||
maug = NULL; |
||||
} |
||||
/* remove module-supplied action */ |
||||
if (act) |
||||
{ |
||||
e_action_predef_name_del(_("Launch"), _("Run Command Dialog")); |
||||
e_action_del("exebuf"); |
||||
act = NULL; |
||||
} |
||||
e_exebuf_shutdown(); |
||||
conf_module = NULL; |
||||
return 1; |
||||
} |
||||
|
||||
EAPI int |
||||
e_modapi_save(E_Module *m) |
||||
{ |
||||
return 1; |
||||
} |
||||
|
||||
/* action callback */ |
||||
static void |
||||
_e_mod_action_exebuf_cb(E_Object *obj, const char *params) |
||||
{ |
||||
E_Zone *zone = NULL; |
||||
|
||||
if (obj) |
||||
{ |
||||
if (obj->type == E_MANAGER_TYPE) |
||||
zone = e_util_zone_current_get((E_Manager *)obj); |
||||
else if (obj->type == E_CONTAINER_TYPE) |
||||
zone = e_util_zone_current_get(((E_Container *)obj)->manager); |
||||
else if (obj->type == E_ZONE_TYPE) |
||||
zone = e_util_zone_current_get(((E_Zone *)obj)->container->manager); |
||||
else |
||||
zone = e_util_zone_current_get(e_manager_current_get()); |
||||
} |
||||
if (!zone) zone = e_util_zone_current_get(e_manager_current_get()); |
||||
if (zone) e_exebuf_show(zone); |
||||
} |
||||
|
||||
/* menu item callback(s) */ |
||||
static int |
||||
_e_mod_run_defer_cb(void *data) |
||||
{ |
||||
E_Zone *zone; |
||||
|
||||
zone = data; |
||||
if (zone) e_exebuf_show(zone); |
||||
return 0; |
||||
} |
||||
|
||||
static void
|
||||
_e_mod_run_cb(void *data, E_Menu *m, E_Menu_Item *mi) |
||||
{ |
||||
ecore_idle_enterer_add(_e_mod_run_defer_cb, m->zone); |
||||
} |
||||
|
||||
/* menu item add hook */ |
||||
static void |
||||
_e_mod_menu_add(void *data, E_Menu *m) |
||||
{ |
||||
E_Menu_Item *mi; |
||||
|
||||
mi = e_menu_item_new(m); |
||||
e_menu_item_label_set(mi, _("Run Command")); |
||||
e_util_menu_item_theme_icon_set(mi, "system-run"); |
||||
e_menu_item_callback_set(mi, _e_mod_run_cb, NULL); |
||||
} |
@ -1,19 +0,0 @@ |
||||
/*
|
||||
* vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2 |
||||
*/ |
||||
#ifndef E_MOD_MAIN_H |
||||
#define E_MOD_MAIN_H |
||||
|
||||
#define E_TYPEDEFS 1 |
||||
#include "e_exebuf.h" |
||||
|
||||
#undef E_TYPEDEFS |
||||
#include "e_exebuf.h" |
||||
|
||||
EAPI extern E_Module_Api e_modapi; |
||||
|
||||
EAPI void *e_modapi_init (E_Module *m); |
||||
EAPI int e_modapi_shutdown (E_Module *m); |
||||
EAPI int e_modapi_save (E_Module *m); |
||||
|
||||
#endif |
@ -1,32 +0,0 @@ |
||||
[Desktop Entry] |
||||
Type=Link |
||||
Name=Run Command |
||||
Name[cs]=Dialog Spustit |
||||
Name[de]= |
||||
Name[eo]=Lanĉi komandojn |
||||
Name[es]=Ejecutar comando |
||||
Name[fr]=Ligne de commande |
||||
Name[hu]=Parancs futtatása |
||||
Name[it]=Lanciacomandi |
||||
Name[ja]= |
||||
Name[pt]= |
||||
Name[pt_BR]= |
||||
Name[tr]=Komut Çalıştır |
||||
Name[zh_CN]= |
||||
Name[zh_TW]= |
||||
Icon=e-module-exebuf |
||||
Comment=The run command module provides an application launcher dialog. |
||||
Comment[cs]=Poskytuje dialog pro spuštění aplikací. |
||||
Comment[de]= |
||||
Comment[eo]=La modulo de lanĉo de komandoj provizas dialogon de lanĉilo de aplikaĵoj. |
||||
Comment[es]=El módulo de ejecutar comandos provee un diálogo para ejecutar aplicaciones. |
||||
Comment[fr]=Fournit une fenêtre de commande pour lancer des applications. |
||||
Comment[hu]=A parancs futtató modul egy alkalmazásindítót biztosít a számunkra. |
||||
Comment[it]=Questo modulo fornisce una finestra di dialogo per l'esecuzione di comandi. |
||||
Comment[ja]= |
||||
Comment[pt]= |
||||
Comment[pt_BR]= |
||||
Comment[tr]=Komut çalıştır modülü program çalıştırma penceresi açar. |
||||
Comment[zh_CN]= |
||||
Comment[zh_TW]= |
||||
X-Enlightenment-ModuleType=system |
Loading…
Reference in new issue