summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--TODO2
-rw-r--r--src/bin/sel.c28
2 files changed, 20 insertions, 10 deletions
diff --git a/TODO b/TODO
index 6975c45..1de040a 100644
--- a/TODO
+++ b/TODO
@@ -3,7 +3,7 @@ make it a first-class terminal:
3 3
4[ ] splits need to size only by steps in font size (elm feature) 4[ ] splits need to size only by steps in font size (elm feature)
5[ ] split handles need to become invisible (elm theme) 5[ ] split handles need to become invisible (elm theme)
6[ ] new term/split/cose buttons need proper icons 6[ ] new term/split/close buttons need proper icons
7[ ] better info in tyls -m 7[ ] better info in tyls -m
8[ ] tyls -b needs doing 8[ ] tyls -b needs doing
9[ ] blink and blink2 attributes need to be supported 9[ ] blink and blink2 attributes need to be supported
diff --git a/src/bin/sel.c b/src/bin/sel.c
index 2bd80c7..9912629 100644
--- a/src/bin/sel.c
+++ b/src/bin/sel.c
@@ -357,12 +357,25 @@ _media_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void
357} 357}
358 358
359static void 359static void
360_entry_termio_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *info __UNUSED__)
361{
362 Entry *en = data;
363 if (en->termio) evas_object_event_callback_add
364 (en->termio, EVAS_CALLBACK_DEL, _entry_termio_del_cb, en);
365 en->termio = NULL;
366}
367
368static void
360_entry_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *info __UNUSED__) 369_entry_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *info __UNUSED__)
361{ 370{
362 Entry *en = data; 371 Entry *en = data;
372 if (en->obj) evas_object_event_callback_del_full
373 (en->obj, EVAS_CALLBACK_DEL, _entry_del_cb, en);
363 en->obj = NULL; 374 en->obj = NULL;
364 if (en->termio) 375 if (en->termio)
365 { 376 {
377 evas_object_event_callback_del_full(en->termio, EVAS_CALLBACK_DEL,
378 _entry_termio_del_cb, en);
366 evas_object_smart_callback_del_full(en->termio, "title,change", 379 evas_object_smart_callback_del_full(en->termio, "title,change",
367 _title_cb, en); 380 _title_cb, en);
368 evas_object_smart_callback_del_full(en->termio, "icon,change", 381 evas_object_smart_callback_del_full(en->termio, "icon,change",
@@ -374,13 +387,6 @@ _entry_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void
374} 387}
375 388
376static void 389static void
377_entry_termio_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *info __UNUSED__)
378{
379 Entry *en = data;
380 en->termio = NULL;
381}
382
383static void
384_smart_add(Evas_Object *obj) 390_smart_add(Evas_Object *obj)
385{ 391{
386 Sel *sd; 392 Sel *sd;
@@ -412,6 +418,8 @@ _smart_del(Evas_Object *obj)
412 { 418 {
413 if (en->termio) 419 if (en->termio)
414 { 420 {
421 evas_object_event_callback_del_full(en->termio, EVAS_CALLBACK_DEL,
422 _entry_termio_del_cb, en);
415 evas_object_smart_callback_del_full(en->termio, "title,change", 423 evas_object_smart_callback_del_full(en->termio, "title,change",
416 _title_cb, en); 424 _title_cb, en);
417 evas_object_smart_callback_del_full(en->termio, "icon,change", 425 evas_object_smart_callback_del_full(en->termio, "icon,change",
@@ -419,6 +427,8 @@ _smart_del(Evas_Object *obj)
419 evas_object_smart_callback_del_full(en->termio, "bell", 427 evas_object_smart_callback_del_full(en->termio, "bell",
420 _bell_cb, en); 428 _bell_cb, en);
421 } 429 }
430 if (en->obj) evas_object_event_callback_del_full
431 (en->obj, EVAS_CALLBACK_DEL, _entry_del_cb, en);
422 if (en->obj) evas_object_del(en->obj); 432 if (en->obj) evas_object_del(en->obj);
423 if (en->media) evas_object_del(en->media); 433 if (en->media) evas_object_del(en->media);
424 evas_object_del(en->bg); 434 evas_object_del(en->bg);
@@ -616,7 +626,7 @@ sel_entry_selected_set(Evas_Object *obj, Evas_Object *entry, Eina_Bool keep_befo
616 } 626 }
617 if (!keep_before) en->selected_before = EINA_FALSE; 627 if (!keep_before) en->selected_before = EINA_FALSE;
618 } 628 }
619 _transit(obj, 0.3); 629 _transit(obj, 0.5);
620} 630}
621 631
622void 632void
@@ -625,7 +635,7 @@ sel_zoom(Evas_Object *obj, double zoom)
625 Sel *sd = evas_object_smart_data_get(obj); 635 Sel *sd = evas_object_smart_data_get(obj);
626 if (!sd) return; 636 if (!sd) return;
627 sd->zoom1 = zoom; 637 sd->zoom1 = zoom;
628 _transit(obj, 0.3); 638 _transit(obj, 0.5);
629} 639}
630 640
631void 641void