summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/bin/win.c38
1 files changed, 15 insertions, 23 deletions
diff --git a/src/bin/win.c b/src/bin/win.c
index 22c837e..5e48258 100644
--- a/src/bin/win.c
+++ b/src/bin/win.c
@@ -264,17 +264,6 @@ _cb_win_focus_in(void *data, Evas_Object *obj EINA_UNUSED, void *event EINA_UNUS
264 edje_object_signal_emit(term->base, "focus,in", "terminology"); 264 edje_object_signal_emit(term->base, "focus,in", "terminology");
265 if (!wn->cmdbox_up) 265 if (!wn->cmdbox_up)
266 elm_object_focus_set(term->termio, EINA_TRUE); 266 elm_object_focus_set(term->termio, EINA_TRUE);
267 /* TODO */
268#if 0
269 sp = _split_find(wn->win, term->term, NULL);
270 if (sp->sel)
271 {
272 if (!wn->cmdbox_up) elm_object_focus_set(sp->sel, EINA_TRUE);
273 }
274 else
275 {
276 }
277#endif
278} 267}
279 268
280static void 269static void
@@ -844,6 +833,13 @@ static void
844_win_focus(Term_Container *tc, Term_Container *child EINA_UNUSED) 833_win_focus(Term_Container *tc, Term_Container *child EINA_UNUSED)
845{ 834{
846 DBG("focus"); 835 DBG("focus");
836 Win *wn;
837 assert (tc->type == TERM_CONTAINER_TYPE_WIN);
838
839 wn = (Win*) tc;
840
841 if (!wn->focused) elm_win_urgent_set(wn->win, EINA_FALSE);
842 wn->focused = EINA_TRUE;
847 /* TODO: go down? */ 843 /* TODO: go down? */
848} 844}
849 845
@@ -1329,6 +1325,7 @@ _split_focus(Term_Container *tc, Term_Container *relative)
1329 else 1325 else
1330 { 1326 {
1331 split->last_focus = relative; 1327 split->last_focus = relative;
1328 tc->parent->focus(tc->parent, tc);
1332 } 1329 }
1333} 1330}
1334 1331
@@ -2384,7 +2381,9 @@ _tabs_focus(Term_Container *tc, Term_Container *relative)
2384 assert(l); 2381 assert(l);
2385 2382
2386 tab_item = l->data; 2383 tab_item = l->data;
2387 elm_toolbar_item_selected_set(tab_item->elm_item, EINA_FALSE); 2384 elm_toolbar_item_selected_set(tabs->current->elm_item, EINA_FALSE);
2385 elm_toolbar_item_selected_set(tab_item->elm_item, EINA_TRUE);
2386 tc->parent->focus(tc->parent, tc);
2388 } 2387 }
2389} 2388}
2390 2389
@@ -2419,7 +2418,7 @@ _tabs_new(Term_Container *child, Term_Container *parent)
2419 Term_Container *tc; 2418 Term_Container *tc;
2420 Tabs *tabs; 2419 Tabs *tabs;
2421 Evas_Object *o; 2420 Evas_Object *o;
2422 Elm_Object_Item *tb_item, *sep; 2421 Elm_Object_Item *sep;
2423 2422
2424 tabs = calloc(1, sizeof(Tabs)); 2423 tabs = calloc(1, sizeof(Tabs));
2425 if (!tabs) 2424 if (!tabs)
@@ -2575,22 +2574,15 @@ _term_focus(Term *term)
2575 elm_object_focus_set(term->termio, EINA_TRUE); 2574 elm_object_focus_set(term->termio, EINA_TRUE);
2576 2575
2577 tc = term->container; 2576 tc = term->container;
2577
2578 tc->focus(tc, tc);
2579
2578 title = termio_title_get(term->termio); 2580 title = termio_title_get(term->termio);
2579 if (title) 2581 if (title)
2580 tc->set_title(tc, tc, title); 2582 tc->set_title(tc, tc, title);
2581 2583
2582 if (term->missed_bell) 2584 if (term->missed_bell)
2583 term->missed_bell = EINA_FALSE; 2585 term->missed_bell = EINA_FALSE;
2584
2585
2586
2587 /* TODO: tabs ? */
2588/* TODO: why ? */
2589#if 0
2590 Split *sp = NULL;
2591 sp = _split_find(term->wn->win, term->term, NULL);
2592 if (sp) _split_tabcount_update(sp, term);
2593#endif
2594} 2586}
2595 2587
2596void term_prev(Term *term) 2588void term_prev(Term *term)