patches from people (see mail list) and stuff.

SVN revision: 27174
This commit is contained in:
Carsten Haitzler 2006-11-19 08:58:05 +00:00
parent addf4cffa5
commit 815e1699c7
16 changed files with 2169 additions and 1967 deletions

9
TODO
View File

@ -62,6 +62,10 @@ Some of the things (in very short form) that need to be done to E17...
CLEANUPS
-------------------------------------------------------------------------------
* make e internal windows (config panel, dialogs, config windows etc.) use
special border styles by default
* accidental DND removals of icons from ibar - make it harder by not removing
if you do not drag it far enough away (put the icon back where it was).
* e app editor needs to be able to let users select what mime types that app
can handle :)
* applications config dialog is good - but "complex". people ask simple
@ -107,6 +111,11 @@ Some of the things (in very short form) that need to be done to E17...
"NICE TO HAVE" FEATURES
-------------------------------------------------------------------------------
* insets in shelf needs to rottate with shelf
* maybe look at improving config panel layout - list is getting VERY long
* a way for modules to add config panel items
* a way for external apps to register config panel items (and be executed)
* option for svg icon render resolution size
* for startup - apps that say "wait for me befofe running the next app" have
a timeout so if they never complete - complain and continue anyway.
* enlightenment_remote cmd's for logout, hibernate, reboot, suspend.

View File

@ -147,7 +147,7 @@ AC_SUBST(cf_libs)
#ALL_LINGUAS="bg de eo es fi fr ja pl pt ru zh_CN hu sl it cs da sk sv nb nl zh_TW ko"
#ALL_LINGUAS="bg de eo es fi fr ja pt ru zh_CN hu sl it cs da sk sv nb nl zh_TW"
# a lot of .po's are broken
ALL_LINGUAS="bg ja ru hu sl it"
ALL_LINGUAS="bg ja ru hu sl it fr"
AC_SUBST(ALL_LINGUAS)
AM_GNU_GETTEXT([external])

3813
po/fr.po

File diff suppressed because it is too large Load Diff

View File

@ -56,41 +56,41 @@ _fill_data(E_App_Autopsy *app, E_Config_Dialog_Data *cfdata)
if ((app->del.exited) && (!cfdata->exit))
{
snprintf(buf, sizeof(buf),
_("An exit code of %i was returned from %s"), app->del.exit_code, app->app->exe);
_("An exit code of %i was returned from %s."), app->del.exit_code, app->app->exe);
cfdata->exit = strdup(buf);
}
if ((app->del.signalled) && (!cfdata->signal))
{
if (app->del.exit_signal == SIGINT)
snprintf(buf, sizeof(buf),
_("%s was interrupted by an Interrupt Signal"), app->app->exe);
_("%s was interrupted by an Interrupt Signal."), app->app->exe);
else if (app->del.exit_signal == SIGQUIT)
snprintf(buf, sizeof(buf), _("%s was interrupted by a Quit Signal"),
snprintf(buf, sizeof(buf), _("%s was interrupted by a Quit Signal."),
app->app->exe);
else if (app->del.exit_signal == SIGABRT)
snprintf(buf, sizeof(buf),
_("%s was interrupted by an Abort Signal"), app->app->exe);
_("%s was interrupted by an Abort Signal."), app->app->exe);
else if (app->del.exit_signal == SIGFPE)
snprintf(buf, sizeof(buf),
_("%s was interrupted by a Floating Point Error"), app->app->exe);
_("%s was interrupted by a Floating Point Error."), app->app->exe);
else if (app->del.exit_signal == SIGKILL)
snprintf(buf, sizeof(buf),
_("%s was interrupted by an Uninterruptable Kill Signal"), app->app->exe);
_("%s was interrupted by an Uninterruptable Kill Signal."), app->app->exe);
else if (app->del.exit_signal == SIGSEGV)
snprintf(buf, sizeof(buf),
_("%s was interrupted by a Segmentation Fault"), app->app->exe);
_("%s was interrupted by a Segmentation Fault."), app->app->exe);
else if (app->del.exit_signal == SIGPIPE)
snprintf(buf, sizeof(buf),
_("%s was interrupted by a Broken Pipe"), app->app->exe);
_("%s was interrupted by a Broken Pipe."), app->app->exe);
else if (app->del.exit_signal == SIGTERM)
snprintf(buf, sizeof(buf),
_("%s was interrupted by a Termination Singal"), app->app->exe);
_("%s was interrupted by a Termination Signal."), app->app->exe);
else if (app->del.exit_signal == SIGBUS)
snprintf(buf, sizeof(buf),
_("%s was interrupted by a Bus Error"), app->app->exe);
_("%s was interrupted by a Bus Error."), app->app->exe);
else
snprintf(buf, sizeof(buf),
_("%s was interrupted by the signal number %i"),
_("%s was interrupted by the signal number %i."),
app->app->exe, app->del.exit_signal);
cfdata->signal = strdup(buf);
/* FIXME: Add sigchld_info stuff

View File

@ -333,60 +333,60 @@ _e_fdo_menu_to_order_find_category(char *category)
{
if (strstr(token, "Development") != NULL)
{
cat = "Programming";
cat = _("Programming");
}
else if (strstr(token, "Game") != NULL)
{
cat = "Games";
cat = _("Games");
}
else if ((strstr(token, "AudioVideo") != NULL) ||
(strstr(token, "Sound") != NULL) || (strstr(token, "Video") != NULL) || (strstr(token, "Multimedia") != NULL))
{
cat = "Multimedia";
cat = _("Multimedia");
}
else if (strstr(token, "Net") != NULL)
{
cat = "Internet";
cat = _("Internet");
}
else if (strstr(token, "Education") != NULL)
{
cat = "Edutainment";
cat = _("Edutainment");
}
else if (strstr(token, "Amusement") != NULL)
{
cat = "Toys";
cat = _("Toys");
}
else if (strstr(token, "System") != NULL)
{
cat = "System";
cat = _("System");
}
else if ((strstr(token, "Shells") != NULL) || (strstr(token, "Utility") != NULL) || (strstr(token, "Tools") != NULL))
{
cat = "Utilities";
cat = _("Utilities");
}
else if ((strstr(token, "Viewers") != NULL) || (strstr(token, "Editors") != NULL) || (strstr(token, "Text") != NULL))
{
cat = "Editors";
cat = _("Editors");
}
else if (strstr(token, "Graphics") != NULL)
{
cat = "Graphics";
cat = _("Graphics");
}
else if ((strstr(token, "WindowManagers") != NULL) || (strstr(token, "Core") != NULL))
{
cat = "Core";
cat = _("Core");
}
else if ((strstr(token, "Settings") != NULL) || (strstr(token, "Accessibility") != NULL))
{
cat = "Settings";
cat = _("Settings");
}
else if (strstr(token, "Office") != NULL)
{
cat = "Office";
cat = _("Office");
}
else
{
cat = "Core";
cat = _("Core");
}
}
token = strtok(NULL, ":");
@ -397,7 +397,7 @@ _e_fdo_menu_to_order_find_category(char *category)
}
}
if (!cat)
cat = "Core";
cat = _("Core");
return strdup(cat);
}

View File

@ -413,6 +413,7 @@ e_fm2_path_set(Evas_Object *obj, const char *dev, const char *path)
_e_fm2_queue_free(obj);
_e_fm2_regions_free(obj);
_e_fm2_icons_free(obj);
edje_object_part_text_set(sd->overlay, "e.text.busy_label", "");
_e_fm2_scan_start(obj);
evas_object_smart_callback_call(obj, "dir_changed", NULL);
@ -4923,8 +4924,9 @@ _e_fm2_file_delete(void *data, E_Menu *m, E_Menu_Item *mi)
{
snprintf(text, sizeof(text),
_("Are you sure you want to delete<br>"
"the selected files in:<br>"
"the %d selected files in:<br>"
"<hilight>%s</hilight> ?"),
evas_list_count(sel),
ic->sd->realpath);
}
if (sel) evas_list_free(sel);

View File

@ -108,7 +108,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o = e_widget_list_add(evas, 0, 0);
of = e_widget_framelist_add(evas, _("General Settings"), 0);
ob = e_widget_label_add(evas, _("Maximum Number of Matched Eaps to List"));
ob = e_widget_label_add(evas, _("Maximum Number of Matched Apps to List"));
e_widget_framelist_object_append(of, ob);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 50, 5, 0, NULL, &(cfdata->max_eap_list), 200);
e_widget_framelist_object_append(of, ob);
@ -164,7 +164,7 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
ot = e_widget_table_add(evas, 0);
of = e_widget_framelist_add(evas, _("General Settings"), 0);
ob = e_widget_label_add(evas, _("Maximum Number of Matched Eaps to List"));
ob = e_widget_label_add(evas, _("Maximum Number of Matched Apps to List"));
e_widget_framelist_object_append(of, ob);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f"), 10, 50, 5, 0, NULL, &(cfdata->max_eap_list), 200);
e_widget_framelist_object_append(of, ob);

View File

@ -319,7 +319,7 @@ const E_Intl_Pair region_predefined_pairs[ ] = {
{ "CD", N_("Congo")},
{ "CK", N_("Cook Islands")},
{ "CR", N_("Costa Rica")},
{ "CI", N_("Cote D'ivoire")},
{ "CI", N_("Cote d'Ivoire")},
{ "HR", N_("Croatia")},
{ "CU", N_("Cuba")},
{ "CY", N_("Cyprus")},
@ -357,11 +357,11 @@ const E_Intl_Pair region_predefined_pairs[ ] = {
{ "GT", N_("Guatemala")},
{ "GG", N_("Guernsey")},
{ "GN", N_("Guinea")},
{ "GW", N_("Guinea-bissau")},
{ "GW", N_("Guinea-Bissau")},
{ "GY", N_("Guyana")},
{ "HT", N_("Haiti")},
{ "HM", N_("Heard Island and Mcdonald Islands")},
{ "VA", N_("Holy See (vatican City State)")},
{ "VA", N_("Holy See (Vatican City State)")},
{ "HN", N_("Honduras")},
{ "HK", N_("Hong Kong")},
{ "HU", N_("Hungary")},
@ -481,7 +481,7 @@ const E_Intl_Pair region_predefined_pairs[ ] = {
{ "TJ", N_("Tajikistan")},
{ "TZ", N_("Tanzania")},
{ "TH", N_("Thailand")},
{ "TL", N_("Timor-leste")},
{ "TL", N_("Timor-Leste")},
{ "TG", N_("Togo")},
{ "TK", N_("Tokelau")},
{ "TO", N_("Tonga")},

View File

@ -125,8 +125,8 @@ _ilist_fill(E_Config_Dialog_Data *cfdata)
if (!es) continue;
label = es->name;
if (!label) label = "shelf";
snprintf(buf, sizeof(buf), "%s #%i", label, es->id);
if (!label) label = _("Shelf #");
snprintf(buf, sizeof(buf), "%s %i", label, es->id);
ob = edje_object_add(evas);
switch(es->cfg->orient)

View File

@ -547,7 +547,7 @@ _import_cb_ok(void *data, void *data2)
e_util_dialog_show(_("Wallpaper Import Error"),
_("Enlightenment was unable to "
"import the wallpaper<br>due to a "
"copy error"));
"copy error."));
return;
}
else

View File

@ -1213,8 +1213,8 @@ _e_int_menus_shelves_pre_cb(void *data, E_Menu *m)
if (s->cfg->container != con->num) continue;
name = s->name;
if (!name) name = "shelf";
snprintf(buf, sizeof(buf), "%s #%i", name, s->id);
if (!name) name = _("Shelf #");
snprintf(buf, sizeof(buf), "%s %i", name, s->id);
mi = e_menu_item_new(m);
e_menu_item_label_set(mi, buf);

View File

@ -350,7 +350,7 @@ _e_sys_current_action(void)
{
case E_SYS_LOGOUT:
e_dialog_text_set(dia,
_("Enlightenment is busy logging out<br>"
_("Enlightenment is busy logging out.<br>"
"You cannot perform other system actions<br>"
"once a logout has begun.")
);

View File

@ -118,15 +118,15 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
rg = e_widget_radio_group_new(&(cfdata->eap_label));
cfdata->radio_name = e_widget_radio_add(evas, _("Display Eap Name"), 0, rg);
cfdata->radio_name = e_widget_radio_add(evas, _("Display App Name"), 0, rg);
e_widget_framelist_object_append(of, cfdata->radio_name);
if (!cfdata->show_label) e_widget_disabled_set(cfdata->radio_name, 1);
cfdata->radio_comment = e_widget_radio_add(evas, _("Display Eap Comment"), 1, rg);
cfdata->radio_comment = e_widget_radio_add(evas, _("Display App Comment"), 1, rg);
e_widget_framelist_object_append(of, cfdata->radio_comment);
if (!cfdata->show_label) e_widget_disabled_set(cfdata->radio_comment, 1);
cfdata->radio_generic = e_widget_radio_add(evas, _("Display Eap Generic"), 2, rg);
cfdata->radio_generic = e_widget_radio_add(evas, _("Display App Generic"), 2, rg);
e_widget_framelist_object_append(of, cfdata->radio_generic);
if (!cfdata->show_label) e_widget_disabled_set(cfdata->radio_generic, 1);
@ -157,8 +157,8 @@ _cb_add(void *data, void *data2)
E_Config_Dialog_Data *cfdata;
cfdata = data;
e_entry_dialog_show(_("Create new ibar source"), "enlightenment/e",
_("Enter a name for this new source"), "", NULL, NULL,
e_entry_dialog_show(_("Create new IBar source"), "enlightenment/e",
_("Enter a name for this new source:"), "", NULL, NULL,
_cb_entry_ok, NULL, cfdata);
}

View File

@ -1,11 +1,37 @@
#include "e.h"
#include "e_mod_main.h"
typedef enum _Pager_Grab_Button Pager_Grab_Button;
enum _Pager_Grab_Button
{
GRAB_BUTTON_DRAG,
GRAB_BUTTON_NOPLACE
};
struct _E_Config_Dialog_Data
{
int show_popup;
double popup_speed;
int drag_resist;
unsigned char btn_drag;
unsigned char btn_noplace;
int flip_desk;
struct
{
Ecore_X_Window bind_win;
E_Dialog *dia;
Evas_List *handlers;
unsigned char *button1;
unsigned char *button2;
} grab;
struct
{
Evas_Object *o_btn1;
Evas_Object *o_btn2;
} gui;
};
/* Protos */
@ -15,6 +41,11 @@ static Evas_Object *_basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Co
static int _basic_apply_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata);
static Evas_Object *_advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cfdata);
static int _advanced_apply_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata);
static void _advanced_update_button_label(E_Config_Dialog_Data *cfdata);
static void _grab_wnd_show(void *data1, void *data2);
static void _grab_wnd_hide(E_Config_Dialog_Data *cfdata);
static int _grab_mouse_down_cb(void *data, int type, void *event);
static int _grab_key_down_cb(void *data, int type, void *event);
void
_config_pager_module(Config_Item *ci)
@ -47,6 +78,9 @@ _fill_data(Config_Item *ci, E_Config_Dialog_Data *cfdata)
cfdata->show_popup = pager_config->popup;
cfdata->popup_speed = pager_config->popup_speed;
cfdata->drag_resist = pager_config->drag_resist;
cfdata->btn_drag = pager_config->btn_drag;
cfdata->btn_noplace = pager_config->btn_noplace;
cfdata->flip_desk = pager_config->flip_desk;
}
static void *
@ -111,6 +145,25 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o, of, 1, 1, 0.5);
of = e_widget_frametable_add(evas, _("Buttons Settings"), 0);
ob = e_widget_label_add(evas, _("Drag and select button"));
e_widget_frametable_object_append(of, ob, 1, 1, 1, 1, 1, 1, 1, 1);
ob = e_widget_label_add(evas, _("Drag no place button"));
e_widget_frametable_object_append(of, ob, 1, 2, 1, 1, 1, 1, 1, 1);
ob = e_widget_button_add(evas, _("Click to set"), NULL, _grab_wnd_show, (void *)GRAB_BUTTON_DRAG, cfdata);
e_widget_frametable_object_append(of, ob, 2, 1, 1, 1, 1, 1, 0, 0);
cfdata->gui.o_btn1 = ob;
ob = e_widget_button_add(evas, _("Click to set"), NULL, _grab_wnd_show, (void *)GRAB_BUTTON_NOPLACE, cfdata);
e_widget_frametable_object_append(of, ob, 2, 2, 1, 1, 1, 1, 0, 0);
cfdata->gui.o_btn2 = ob;
_advanced_update_button_label(cfdata);
e_widget_list_object_append(o, of, 1, 1, 0.5);
of = e_widget_framelist_add(evas, _("Wheel callback"), 0);
ob = e_widget_check_add(evas, _("Flip desktop on mouse wheel"), &(cfdata->flip_desk));
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o, of, 1, 1, 0.5);
return o;
}
@ -120,7 +173,135 @@ _advanced_apply_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata)
pager_config->popup = cfdata->show_popup;
pager_config->popup_speed = cfdata->popup_speed;
pager_config->drag_resist = cfdata->drag_resist;
pager_config->btn_drag = cfdata->btn_drag;
pager_config->btn_noplace = cfdata->btn_noplace;
pager_config->flip_desk = cfdata->flip_desk;
_pager_cb_config_updated();
e_config_save_queue();
return 1;
}
static void
_advanced_update_button_label(E_Config_Dialog_Data *cfdata)
{
char label[256] = "";
if (cfdata->btn_drag)
snprintf(label, sizeof(label), _("Button %i"), cfdata->btn_drag);
else
snprintf(label, sizeof(label), _("Click to set"));
e_widget_button_label_set(cfdata->gui.o_btn1, label);
if (cfdata->btn_noplace)
snprintf(label, sizeof(label), _("Button %i"), cfdata->btn_noplace);
else
snprintf(label, sizeof(label), _("Click to set"));
e_widget_button_label_set(cfdata->gui.o_btn2, label);
}
static void
_grab_wnd_show(void *data1, void *data2)
{
E_Manager *man;
E_Config_Dialog_Data *cfdata;
man = e_manager_current_get();
cfdata = data2;
if ((Pager_Grab_Button)data1 == GRAB_BUTTON_DRAG)
{
cfdata->grab.button1 = &(cfdata->btn_drag);
cfdata->grab.button2 = &(cfdata->btn_noplace);
}
else
{
cfdata->grab.button1 = &(cfdata->btn_noplace);
cfdata->grab.button2 = &(cfdata->btn_drag);
}
cfdata->grab.dia = e_dialog_new(e_container_current_get(man), "Pager", "_pager_button_grab_dialog");
if (!cfdata->grab.dia) return;
e_dialog_title_set(cfdata->grab.dia, _("Pager Button Grab"));
e_dialog_icon_set(cfdata->grab.dia, "enlightenment/mouse_clean", 48);
e_dialog_text_set(cfdata->grab.dia, _("Please press a mouse button<br>"
"Press <hilight>Escape</hilight> to abort.<br>"
"Or <hilight>Del</hilight> to reset the button."));
e_win_centered_set(cfdata->grab.dia->win, 1);
e_win_borderless_set(cfdata->grab.dia->win, 1);
cfdata->grab.bind_win = ecore_x_window_input_new(man->root, 0, 0, 1, 1);
ecore_x_window_show(cfdata->grab.bind_win);
e_grabinput_get(cfdata->grab.bind_win, 0, cfdata->grab.bind_win);
cfdata->grab.handlers = evas_list_append(cfdata->grab.handlers,
ecore_event_handler_add(ECORE_X_EVENT_KEY_DOWN,
_grab_key_down_cb, cfdata));
cfdata->grab.handlers = evas_list_append(cfdata->grab.handlers,
ecore_event_handler_add(ECORE_X_EVENT_MOUSE_BUTTON_DOWN,
_grab_mouse_down_cb, cfdata));
e_dialog_show(cfdata->grab.dia);
}
static void
_grab_wnd_hide(E_Config_Dialog_Data *cfdata)
{
while (cfdata->grab.handlers)
{
ecore_event_handler_del(cfdata->grab.handlers->data);
cfdata->grab.handlers = evas_list_remove_list(cfdata->grab.handlers, cfdata->grab.handlers);
}
cfdata->grab.handlers = NULL;
e_grabinput_release(cfdata->grab.bind_win, cfdata->grab.bind_win);
ecore_x_window_del(cfdata->grab.bind_win);
cfdata->grab.bind_win = 0;
e_object_del(E_OBJECT(cfdata->grab.dia));
cfdata->grab.dia = NULL;
_advanced_update_button_label(cfdata);
}
static int
_grab_mouse_down_cb(void *data, int type, void *event)
{
E_Config_Dialog_Data *cfdata;
Ecore_X_Event_Mouse_Button_Down *ev;
ev = event;
cfdata = data;
if (ev->button != 3)
{
if (ev->button == *(cfdata->grab.button2))
{
*(cfdata->grab.button2) = *(cfdata->grab.button1);
*(cfdata->grab.button1) = ev->button;
}
else
{
*(cfdata->grab.button1) = ev->button;
}
}
_grab_wnd_hide(cfdata);
return 1;
}
static int
_grab_key_down_cb(void *data, int type, void *event)
{
E_Config_Dialog_Data *cfdata;
Ecore_X_Event_Key_Down *ev = event;
cfdata = data;
if (ev->win != cfdata->grab.bind_win) return 1;
if (!strcmp(ev->keyname, "Escape")) _grab_wnd_hide(cfdata);
if (!strcmp(ev->keyname, "Delete"))
{
*(cfdata->grab.button1) = 0;
_grab_wnd_hide(cfdata);
}
return 1;
}

View File

@ -99,6 +99,7 @@ static void _pager_cb_obj_moveresize(void *data, Evas *e, Evas_Object *obj, void
static void _button_cb_mouse_down(void *data, Evas *e, Evas_Object *obj, void *event_info);
static void _menu_cb_post(void *data, E_Menu *m);
static void _pager_inst_cb_menu_configure(void *data, E_Menu *m, E_Menu_Item *mi);
static void _pager_inst_cb_menu_virtual_desktops_dialog(void *data, E_Menu *m, E_Menu_Item *mi);
static void _pager_instance_drop_zone_recalc(Instance *inst);
static int _pager_cb_event_border_resize(void *data, int type, void *event);
static int _pager_cb_event_border_move(void *data, int type, void *event);
@ -629,6 +630,11 @@ _button_cb_mouse_down(void *data, Evas *e, Evas_Object *obj, void *event_info)
e_util_menu_item_edje_icon_set(mi, "enlightenment/configuration");
e_menu_item_callback_set(mi, _pager_inst_cb_menu_configure, NULL);
mi = e_menu_item_new(mn);
e_menu_item_label_set(mi, _("Virtual Desktops Configuration"));
e_util_menu_item_edje_icon_set(mi, "enlightenment/desktops");
e_menu_item_callback_set(mi, _pager_inst_cb_menu_virtual_desktops_dialog, inst);
e_gadcon_client_util_menu_items_append(inst->gcc, mn, 0);
e_gadcon_canvas_zone_geometry_get(inst->gcc->gadcon,
@ -661,6 +667,13 @@ _pager_inst_cb_menu_configure(void *data, E_Menu *m, E_Menu_Item *mi)
_config_pager_module(NULL);
}
static void _pager_inst_cb_menu_virtual_desktops_dialog(void *data, E_Menu *m, E_Menu_Item *mi)
{
Instance *inst;
inst = data;
e_int_config_desks(inst->gcc->gadcon->zone->container);
}
static void
_pager_instance_drop_zone_recalc(Instance *inst)
{
@ -1319,8 +1332,8 @@ _pager_window_cb_mouse_down(void *data, Evas *e, Evas_Object *obj, void *event_i
pw = data;
if (!pw) return;
if (pw->border->lock_user_location) return;
/* FIXME: make this configurable */
if ((ev->button == 1) || (ev->button == 2))
if ((ev->button == pager_config->btn_drag) ||
(ev->button == pager_config->btn_noplace))
{
Evas_Coord ox, oy;
@ -1333,7 +1346,8 @@ _pager_window_cb_mouse_down(void *data, Evas *e, Evas_Object *obj, void *event_i
pw->drag.start = 1;
pw->drag.no_place = 0;
pw->drag.button = ev->button;
if (ev->button == 2) pw->drag.no_place = 1;
if (ev->button == pager_config->btn_noplace)
pw->drag.no_place = 1;
}
}
@ -1346,8 +1360,8 @@ _pager_window_cb_mouse_up(void *data, Evas *e, Evas_Object *obj, void *event_inf
ev = event_info;
pw = data;
if (!pw) return;
/* FIXME: make this configurable as above */
if ((ev->button == 1) || (ev->button == 2))
if ((ev->button == pager_config->btn_drag) ||
(ev->button ==pager_config->btn_noplace))
{
if (!pw->drag.from_pager)
{
@ -1712,7 +1726,7 @@ _pager_desk_cb_mouse_wheel(void *data, Evas *e, Evas_Object *obj, void *event_in
ev = event_info;
pd = data;
e_zone_desk_linear_flip_by(pd->desk->zone, ev->z);
if (pager_config->flip_desk) e_zone_desk_linear_flip_by(pd->desk->zone, ev->z);
}
static int
@ -1747,6 +1761,9 @@ e_modapi_init(E_Module *m)
E_CONFIG_VAL(D, T, drag_resist, UINT);
E_CONFIG_VAL(D, T, scale, UCHAR);
E_CONFIG_VAL(D, T, resize, UCHAR);
E_CONFIG_VAL(D, T, btn_drag, UCHAR);
E_CONFIG_VAL(D, T, btn_noplace, UCHAR);
E_CONFIG_VAL(D, T, flip_desk, UINT);
pager_config = e_config_domain_load("module.pager", conf_edd);
@ -1758,12 +1775,18 @@ e_modapi_init(E_Module *m)
pager_config->drag_resist = 3;
pager_config->scale = 1;
pager_config->resize = PAGER_RESIZE_BOTH;
pager_config->btn_drag = 1;
pager_config->btn_noplace = 2;
pager_config->flip_desk = 0;
}
E_CONFIG_LIMIT(pager_config->popup_speed, 0.1, 10.0);
E_CONFIG_LIMIT(pager_config->popup, 0, 1);
E_CONFIG_LIMIT(pager_config->drag_resist, 0, 50);
E_CONFIG_LIMIT(pager_config->scale, 0, 1);
E_CONFIG_LIMIT(pager_config->resize, PAGER_RESIZE_HORZ, PAGER_RESIZE_BOTH);
E_CONFIG_LIMIT(pager_config->flip_desk, 0, 1);
E_CONFIG_LIMIT(pager_config->scale, 0, 1);
E_CONFIG_LIMIT(pager_config->btn_drag, 1, 32);
E_CONFIG_LIMIT(pager_config->btn_noplace, 1, 32);
pager_config->handlers = evas_list_append
(pager_config->handlers, ecore_event_handler_add

View File

@ -33,6 +33,10 @@ struct _Config
Evas_List *instances;
E_Menu *menu;
Evas_List *handlers;
unsigned char btn_drag;
unsigned char btn_noplace;
unsigned int flip_desk;
};
struct _Config_Item