summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvi Levin <avi.levin@samsung.com>2015-05-10 11:50:37 +0300
committerAvi Levin <avi.levin@samsung.com>2015-06-29 17:03:33 +0300
commitad3aa2204e1840f26ebc8a7d934e8fb3fe39b91e (patch)
treeb0dd4fbcb968527f34c0a29258b3f235f831a829
parent047311c850b7054462d70ea915ad0eb028d575c3 (diff)
elm_scroller: porting evas smart callbacks to eo
-rw-r--r--src/lib/elm_scroller.c46
-rw-r--r--src/lib/elm_scroller.eo15
2 files changed, 41 insertions, 20 deletions
diff --git a/src/lib/elm_scroller.c b/src/lib/elm_scroller.c
index 07ec4266b..98f103b4c 100644
--- a/src/lib/elm_scroller.c
+++ b/src/lib/elm_scroller.c
@@ -491,140 +491,146 @@ static void
491_edge_left_cb(Evas_Object *obj, 491_edge_left_cb(Evas_Object *obj,
492 void *data EINA_UNUSED) 492 void *data EINA_UNUSED)
493{ 493{
494 evas_object_smart_callback_call(obj, SIG_EDGE_LEFT, NULL); 494 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_EDGE_LEFT, NULL));
495} 495}
496 496
497static void 497static void
498_edge_right_cb(Evas_Object *obj, 498_edge_right_cb(Evas_Object *obj,
499 void *data EINA_UNUSED) 499 void *data EINA_UNUSED)
500{ 500{
501 evas_object_smart_callback_call(obj, SIG_EDGE_RIGHT, NULL); 501 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_EDGE_RIGHT, NULL));
502} 502}
503 503
504static void 504static void
505_edge_top_cb(Evas_Object *obj, 505_edge_top_cb(Evas_Object *obj,
506 void *data EINA_UNUSED) 506 void *data EINA_UNUSED)
507{ 507{
508 evas_object_smart_callback_call(obj, SIG_EDGE_TOP, NULL); 508 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_EDGE_TOP, NULL));
509} 509}
510 510
511static void 511static void
512_edge_bottom_cb(Evas_Object *obj, 512_edge_bottom_cb(Evas_Object *obj,
513 void *data EINA_UNUSED) 513 void *data EINA_UNUSED)
514{ 514{
515 evas_object_smart_callback_call(obj, SIG_EDGE_BOTTOM, NULL); 515 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_EDGE_BOTTOM, NULL));
516} 516}
517 517
518static void 518static void
519_scroll_cb(Evas_Object *obj, 519_scroll_cb(Evas_Object *obj,
520 void *data EINA_UNUSED) 520 void *data EINA_UNUSED)
521{ 521{
522 evas_object_smart_callback_call(obj, SIG_SCROLL, NULL); 522 eo_do(obj, eo_event_callback_call
523 (EVAS_SCROLLABLE_INTERFACE_EVENT_SCROLL, NULL));
523} 524}
524 525
525static void 526static void
526_scroll_left_cb(Evas_Object *obj, 527_scroll_left_cb(Evas_Object *obj,
527 void *data EINA_UNUSED) 528 void *data EINA_UNUSED)
528{ 529{
529 evas_object_smart_callback_call(obj, SIG_SCROLL_LEFT, NULL); 530 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_SCROLL_LEFT, NULL));
530} 531}
531 532
532static void 533static void
533_scroll_right_cb(Evas_Object *obj, 534_scroll_right_cb(Evas_Object *obj,
534 void *data EINA_UNUSED) 535 void *data EINA_UNUSED)
535{ 536{
536 evas_object_smart_callback_call(obj, SIG_SCROLL_RIGHT, NULL); 537 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_SCROLL_RIGHT, NULL));
537} 538}
538 539
539static void 540static void
540_scroll_up_cb(Evas_Object *obj, 541_scroll_up_cb(Evas_Object *obj,
541 void *data EINA_UNUSED) 542 void *data EINA_UNUSED)
542{ 543{
543 evas_object_smart_callback_call(obj, SIG_SCROLL_UP, NULL); 544 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_SCROLL_UP, NULL));
544} 545}
545 546
546static void 547static void
547_scroll_down_cb(Evas_Object *obj, 548_scroll_down_cb(Evas_Object *obj,
548 void *data EINA_UNUSED) 549 void *data EINA_UNUSED)
549{ 550{
550 evas_object_smart_callback_call(obj, SIG_SCROLL_DOWN, NULL); 551 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_SCROLL_DOWN, NULL));
551} 552}
552 553
553static void 554static void
554_scroll_anim_start_cb(Evas_Object *obj, 555_scroll_anim_start_cb(Evas_Object *obj,
555 void *data EINA_UNUSED) 556 void *data EINA_UNUSED)
556{ 557{
557 evas_object_smart_callback_call(obj, SIG_SCROLL_ANIM_START, NULL); 558 eo_do(obj, eo_event_callback_call
559 (EVAS_SCROLLABLE_INTERFACE_EVENT_SCROLL_ANIM_START, NULL));
558} 560}
559 561
560static void 562static void
561_scroll_anim_stop_cb(Evas_Object *obj, 563_scroll_anim_stop_cb(Evas_Object *obj,
562 void *data EINA_UNUSED) 564 void *data EINA_UNUSED)
563{ 565{
564 evas_object_smart_callback_call(obj, SIG_SCROLL_ANIM_STOP, NULL); 566 eo_do(obj, eo_event_callback_call
567 (EVAS_SCROLLABLE_INTERFACE_EVENT_SCROLL_ANIM_STOP, NULL));
565} 568}
566 569
567static void 570static void
568_scroll_drag_start_cb(Evas_Object *obj, 571_scroll_drag_start_cb(Evas_Object *obj,
569 void *data EINA_UNUSED) 572 void *data EINA_UNUSED)
570{ 573{
571 evas_object_smart_callback_call(obj, SIG_SCROLL_DRAG_START, NULL); 574 eo_do(obj, eo_event_callback_call
575 (EVAS_SCROLLABLE_INTERFACE_EVENT_SCROLL_DRAG_START, NULL));
572} 576}
573 577
574static void 578static void
575_scroll_drag_stop_cb(Evas_Object *obj, 579_scroll_drag_stop_cb(Evas_Object *obj,
576 void *data EINA_UNUSED) 580 void *data EINA_UNUSED)
577{ 581{
578 evas_object_smart_callback_call(obj, SIG_SCROLL_DRAG_STOP, NULL); 582 eo_do(obj, eo_event_callback_call
583 (EVAS_SCROLLABLE_INTERFACE_EVENT_SCROLL_DRAG_STOP, NULL));
579} 584}
580 585
581static void 586static void
582_vbar_drag_cb(Evas_Object *obj, 587_vbar_drag_cb(Evas_Object *obj,
583 void *data EINA_UNUSED) 588 void *data EINA_UNUSED)
584{ 589{
585 evas_object_smart_callback_call(obj, SIG_VBAR_DRAG, NULL); 590 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_VBAR_DRAG, NULL));
586} 591}
587 592
588static void 593static void
589_vbar_press_cb(Evas_Object *obj, 594_vbar_press_cb(Evas_Object *obj,
590 void *data EINA_UNUSED) 595 void *data EINA_UNUSED)
591{ 596{
592 evas_object_smart_callback_call(obj, SIG_VBAR_PRESS, NULL); 597 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_VBAR_PRESS, NULL));
593} 598}
594 599
595static void 600static void
596_vbar_unpress_cb(Evas_Object *obj, 601_vbar_unpress_cb(Evas_Object *obj,
597 void *data EINA_UNUSED) 602 void *data EINA_UNUSED)
598{ 603{
599 evas_object_smart_callback_call(obj, SIG_VBAR_UNPRESS, NULL); 604 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_VBAR_UNPRESS, NULL));
600} 605}
601 606
602static void 607static void
603_hbar_drag_cb(Evas_Object *obj, 608_hbar_drag_cb(Evas_Object *obj,
604 void *data EINA_UNUSED) 609 void *data EINA_UNUSED)
605{ 610{
606 evas_object_smart_callback_call(obj, SIG_HBAR_DRAG, NULL); 611 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_HBAR_DRAG, NULL));
607} 612}
608 613
609static void 614static void
610_hbar_press_cb(Evas_Object *obj, 615_hbar_press_cb(Evas_Object *obj,
611 void *data EINA_UNUSED) 616 void *data EINA_UNUSED)
612{ 617{
613 evas_object_smart_callback_call(obj, SIG_HBAR_PRESS, NULL); 618 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_HBAR_PRESS, NULL));
614} 619}
615 620
616static void 621static void
617_hbar_unpress_cb(Evas_Object *obj, 622_hbar_unpress_cb(Evas_Object *obj,
618 void *data EINA_UNUSED) 623 void *data EINA_UNUSED)
619{ 624{
620 evas_object_smart_callback_call(obj, SIG_HBAR_UNPRESS, NULL); 625 eo_do(obj, eo_event_callback_call(ELM_SCROLLER_EVENT_HBAR_UNPRESS, NULL));
621} 626}
622 627
623static void 628static void
624_page_change_cb(Evas_Object *obj, 629_page_change_cb(Evas_Object *obj,
625 void *data EINA_UNUSED) 630 void *data EINA_UNUSED)
626{ 631{
627 evas_object_smart_callback_call(obj, SIG_SCROLL_PAGE_CHANGE, NULL); 632 eo_do(obj, eo_event_callback_call
633 (ELM_SCROLLER_EVENT_SCROLL_PAGE_CHANGED, NULL));
628} 634}
629 635
630static void 636static void
diff --git a/src/lib/elm_scroller.eo b/src/lib/elm_scroller.eo
index d4441deb5..0b7854f0d 100644
--- a/src/lib/elm_scroller.eo
+++ b/src/lib/elm_scroller.eo
@@ -134,6 +134,21 @@ class Elm.Scroller (Elm.Layout, Elm_Interface_Scrollable,
134 events { 134 events {
135 focused; 135 focused;
136 unfocused; 136 unfocused;
137 scroll,page,changed;
138 hbar,unpress;
139 hbar,press;
140 hbar,drag;
141 vbar,unpress;
142 vbar,press;
143 vbar,drag;
144 scroll,left;
145 scroll,right;
146 scroll,up;
147 scroll,down;
148 edge,left;
149 edge,right;
150 edge,top;
151 edge,bottom;
137 } 152 }
138 153
139} 154}