tabs: improve behavior by making possible to navigate between them by using mouse wheel.
More theme work is needed, but first step for T449.
This commit is contained in:
parent
d4445b87f9
commit
5f15fae4e7
|
@ -498,6 +498,14 @@ collections {
|
|||
signal: "mouse,clicked,1"; source: "tabcount_ev";
|
||||
action: SIGNAL_EMIT "tabcount,go" "terminology";
|
||||
}
|
||||
program {
|
||||
signal: "mouse,wheel,0,-1"; source: "tabcount_ev";
|
||||
action: SIGNAL_EMIT "tabcount,prev" "terminology";
|
||||
}
|
||||
program {
|
||||
signal: "mouse,wheel,0,1"; source: "tabcount_ev";
|
||||
action: SIGNAL_EMIT "tabcount,next" "terminology";
|
||||
}
|
||||
program {
|
||||
signal: "tabcount,off"; source: "terminology";
|
||||
action: STATE_SET "default" 0.0;
|
||||
|
|
|
@ -1999,6 +1999,18 @@ main_term_free(Term *term)
|
|||
free(term);
|
||||
}
|
||||
|
||||
static void
|
||||
_cb_tabcount_prev(void *data, Evas_Object *obj EINA_UNUSED, const char *sig EINA_UNUSED, const char *src EINA_UNUSED)
|
||||
{
|
||||
_cb_prev(data, NULL, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
_cb_tabcount_next(void *data, Evas_Object *obj EINA_UNUSED, const char *sig EINA_UNUSED, const char *src EINA_UNUSED)
|
||||
{
|
||||
_cb_next(data, NULL, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
main_term_bg_config(Term *term)
|
||||
{
|
||||
|
@ -2018,6 +2030,10 @@ main_term_bg_config(Term *term)
|
|||
_cb_popmedia_done, term);
|
||||
edje_object_signal_callback_add(term->bg, "tabcount,go", "terminology",
|
||||
_cb_tabcount_go, term);
|
||||
edje_object_signal_callback_add(term->bg, "tabcount,prev", "terminology",
|
||||
_cb_tabcount_prev, term);
|
||||
edje_object_signal_callback_add(term->bg, "tabcount,next", "terminology",
|
||||
_cb_tabcount_next, term);
|
||||
edje_object_part_swallow(term->base, "terminology.content", term->term);
|
||||
edje_object_part_swallow(term->bg, "terminology.content", term->base);
|
||||
if (term->popmedia)
|
||||
|
@ -2165,6 +2181,10 @@ main_term_new(Win *wn, Config *config, const char *cmd,
|
|||
_cb_popmedia_done, term);
|
||||
edje_object_signal_callback_add(term->bg, "tabcount,go", "terminology",
|
||||
_cb_tabcount_go, term);
|
||||
edje_object_signal_callback_add(term->bg, "tabcount,prev", "terminology",
|
||||
_cb_tabcount_prev, term);
|
||||
edje_object_signal_callback_add(term->bg, "tabcount,next", "terminology",
|
||||
_cb_tabcount_next, term);
|
||||
|
||||
evas_object_size_hint_weight_set(o, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
|
||||
evas_object_size_hint_fill_set(o, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
||||
|
|
Loading…
Reference in New Issue