summaryrefslogtreecommitdiff
path: root/src/lib/elementary
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2016-03-23 12:56:14 -0700
committerCedric BAIL <cedric@osg.samsung.com>2016-03-23 13:24:41 -0700
commitc2a1c49ab2042f559b28e840e54feb8494888e0e (patch)
treec6eb110b7c479499854eede9d0c3ab0a80c9a11a /src/lib/elementary
parent9340855597e7e465435c69b6278650346688da14 (diff)
elementary: move all legacy files to their expected new location.
Diffstat (limited to 'src/lib/elementary')
-rw-r--r--src/lib/elementary/.gitignore13
-rw-r--r--src/lib/elementary/Elementary.h.in279
-rw-r--r--src/lib/elementary/Elementary.hh.in142
-rw-r--r--src/lib/elementary/Elementary_Cursor.h87
-rw-r--r--src/lib/elementary/Makefile.am716
-rw-r--r--src/lib/elementary/elc_combobox.c635
-rw-r--r--src/lib/elementary/elc_combobox.h64
-rw-r--r--src/lib/elementary/elc_combobox_legacy.h11
-rw-r--r--src/lib/elementary/elc_ctxpopup.c1479
-rw-r--r--src/lib/elementary/elc_ctxpopup.h74
-rw-r--r--src/lib/elementary/elc_ctxpopup_eo.h2
-rw-r--r--src/lib/elementary/elc_ctxpopup_legacy.h12
-rw-r--r--src/lib/elementary/elc_fileselector.c2511
-rw-r--r--src/lib/elementary/elc_fileselector.h80
-rw-r--r--src/lib/elementary/elc_fileselector_button.c517
-rw-r--r--src/lib/elementary/elc_fileselector_button.h75
-rw-r--r--src/lib/elementary/elc_fileselector_button_eo.h1
-rw-r--r--src/lib/elementary/elc_fileselector_button_legacy.h13
-rw-r--r--src/lib/elementary/elc_fileselector_common.h3
-rw-r--r--src/lib/elementary/elc_fileselector_entry.c558
-rw-r--r--src/lib/elementary/elc_fileselector_entry.h84
-rw-r--r--src/lib/elementary/elc_fileselector_entry_eo.h1
-rw-r--r--src/lib/elementary/elc_fileselector_entry_legacy.h14
-rw-r--r--src/lib/elementary/elc_fileselector_eo.h11
-rw-r--r--src/lib/elementary/elc_fileselector_legacy.h414
-rw-r--r--src/lib/elementary/elc_hoversel.c971
-rw-r--r--src/lib/elementary/elc_hoversel.h68
-rw-r--r--src/lib/elementary/elc_hoversel_eo.h2
-rw-r--r--src/lib/elementary/elc_hoversel_legacy.h12
-rw-r--r--src/lib/elementary/elc_multibuttonentry.c2064
-rw-r--r--src/lib/elementary/elc_multibuttonentry.h69
-rw-r--r--src/lib/elementary/elc_multibuttonentry_common.h33
-rw-r--r--src/lib/elementary/elc_multibuttonentry_eo.h2
-rw-r--r--src/lib/elementary/elc_multibuttonentry_legacy.h13
-rw-r--r--src/lib/elementary/elc_naviframe.c2007
-rw-r--r--src/lib/elementary/elc_naviframe.h102
-rw-r--r--src/lib/elementary/elc_naviframe_common.h40
-rw-r--r--src/lib/elementary/elc_naviframe_eo.h12
-rw-r--r--src/lib/elementary/elc_naviframe_legacy.h2
-rw-r--r--src/lib/elementary/elc_player.c750
-rw-r--r--src/lib/elementary/elc_popup.c1869
-rw-r--r--src/lib/elementary/elc_popup.h125
-rw-r--r--src/lib/elementary/elc_popup_eo.h11
-rw-r--r--src/lib/elementary/elc_popup_legacy.h11
-rw-r--r--src/lib/elementary/elc_scrolled_entry.c197
-rw-r--r--src/lib/elementary/elementary_js.cc290
-rw-r--r--src/lib/elementary/elm_access.c1453
-rw-r--r--src/lib/elementary/elm_access.eo13
-rw-r--r--src/lib/elementary/elm_access.h275
-rw-r--r--src/lib/elementary/elm_actionslider.c654
-rw-r--r--src/lib/elementary/elm_actionslider.eo82
-rw-r--r--src/lib/elementary/elm_actionslider.h61
-rw-r--r--src/lib/elementary/elm_actionslider_eo.h1
-rw-r--r--src/lib/elementary/elm_actionslider_legacy.h11
-rw-r--r--src/lib/elementary/elm_app.h297
-rw-r--r--src/lib/elementary/elm_app_client.c332
-rw-r--r--src/lib/elementary/elm_app_client.eo64
-rw-r--r--src/lib/elementary/elm_app_client.h3
-rw-r--r--src/lib/elementary/elm_app_client_eo.h11
-rw-r--r--src/lib/elementary/elm_app_client_view.c315
-rw-r--r--src/lib/elementary/elm_app_client_view.eo126
-rw-r--r--src/lib/elementary/elm_app_client_view.h3
-rw-r--r--src/lib/elementary/elm_app_client_view_eo.h3
-rw-r--r--src/lib/elementary/elm_app_common.c56
-rw-r--r--src/lib/elementary/elm_app_common.h9
-rw-r--r--src/lib/elementary/elm_app_server.c453
-rw-r--r--src/lib/elementary/elm_app_server.eo103
-rw-r--r--src/lib/elementary/elm_app_server.h3
-rw-r--r--src/lib/elementary/elm_app_server_eet.c310
-rw-r--r--src/lib/elementary/elm_app_server_eet.h46
-rw-r--r--src/lib/elementary/elm_app_server_eo.h15
-rw-r--r--src/lib/elementary/elm_app_server_view.c388
-rw-r--r--src/lib/elementary/elm_app_server_view.eo107
-rw-r--r--src/lib/elementary/elm_app_server_view.h3
-rw-r--r--src/lib/elementary/elm_app_server_view_eo.h1
-rw-r--r--src/lib/elementary/elm_atspi_app_object.c73
-rw-r--r--src/lib/elementary/elm_atspi_app_object.eo12
-rw-r--r--src/lib/elementary/elm_atspi_app_object.h6
-rw-r--r--src/lib/elementary/elm_atspi_bridge.c4702
-rw-r--r--src/lib/elementary/elm_atspi_bridge.eo22
-rw-r--r--src/lib/elementary/elm_atspi_bridge.h8
-rw-r--r--src/lib/elementary/elm_authors.h172
-rw-r--r--src/lib/elementary/elm_bg.c287
-rw-r--r--src/lib/elementary/elm_bg.eo117
-rw-r--r--src/lib/elementary/elm_bg.h40
-rw-r--r--src/lib/elementary/elm_bg_eo.h1
-rw-r--r--src/lib/elementary/elm_bg_legacy.h94
-rw-r--r--src/lib/elementary/elm_box.c725
-rw-r--r--src/lib/elementary/elm_box.eo298
-rw-r--r--src/lib/elementary/elm_box.h84
-rw-r--r--src/lib/elementary/elm_box_common.h101
-rw-r--r--src/lib/elementary/elm_box_eo.h1
-rw-r--r--src/lib/elementary/elm_box_legacy.h13
-rw-r--r--src/lib/elementary/elm_bubble.c289
-rw-r--r--src/lib/elementary/elm_bubble.eo54
-rw-r--r--src/lib/elementary/elm_bubble.h72
-rw-r--r--src/lib/elementary/elm_bubble_eo.h1
-rw-r--r--src/lib/elementary/elm_bubble_legacy.h13
-rw-r--r--src/lib/elementary/elm_button.c445
-rw-r--r--src/lib/elementary/elm_button.eo102
-rw-r--r--src/lib/elementary/elm_button.h78
-rw-r--r--src/lib/elementary/elm_button_eo.h1
-rw-r--r--src/lib/elementary/elm_button_legacy.h11
-rw-r--r--src/lib/elementary/elm_cache.h31
-rw-r--r--src/lib/elementary/elm_calendar.c1874
-rw-r--r--src/lib/elementary/elm_calendar.eo452
-rw-r--r--src/lib/elementary/elm_calendar.h60
-rw-r--r--src/lib/elementary/elm_calendar_common.h21
-rw-r--r--src/lib/elementary/elm_calendar_eo.h1
-rw-r--r--src/lib/elementary/elm_calendar_legacy.h30
-rw-r--r--src/lib/elementary/elm_check.c460
-rw-r--r--src/lib/elementary/elm_check.eo60
-rw-r--r--src/lib/elementary/elm_check.h70
-rw-r--r--src/lib/elementary/elm_check_eo.h1
-rw-r--r--src/lib/elementary/elm_check_legacy.h11
-rw-r--r--src/lib/elementary/elm_clock.c960
-rw-r--r--src/lib/elementary/elm_clock.eo235
-rw-r--r--src/lib/elementary/elm_clock.h68
-rw-r--r--src/lib/elementary/elm_clock_eo.h1
-rw-r--r--src/lib/elementary/elm_clock_legacy.h14
-rw-r--r--src/lib/elementary/elm_cnp.c5139
-rw-r--r--src/lib/elementary/elm_cnp.h545
-rw-r--r--src/lib/elementary/elm_color_class.c826
-rw-r--r--src/lib/elementary/elm_color_class.h81
-rw-r--r--src/lib/elementary/elm_color_item.eo43
-rw-r--r--src/lib/elementary/elm_colorselector.c2546
-rw-r--r--src/lib/elementary/elm_colorselector.eo127
-rw-r--r--src/lib/elementary/elm_colorselector.h48
-rw-r--r--src/lib/elementary/elm_colorselector_common.h33
-rw-r--r--src/lib/elementary/elm_colorselector_eo.h1
-rw-r--r--src/lib/elementary/elm_colorselector_legacy.h11
-rw-r--r--src/lib/elementary/elm_combobox.eo78
-rw-r--r--src/lib/elementary/elm_config.c4185
-rw-r--r--src/lib/elementary/elm_config.h2109
-rw-r--r--src/lib/elementary/elm_conform.c1020
-rw-r--r--src/lib/elementary/elm_conform.h61
-rw-r--r--src/lib/elementary/elm_conform_eo.h11
-rw-r--r--src/lib/elementary/elm_conform_legacy.h13
-rw-r--r--src/lib/elementary/elm_conformant.eo20
-rw-r--r--src/lib/elementary/elm_container.c13
-rw-r--r--src/lib/elementary/elm_container.eo45
-rw-r--r--src/lib/elementary/elm_container.h6
-rw-r--r--src/lib/elementary/elm_ctxpopup.eo243
-rw-r--r--src/lib/elementary/elm_ctxpopup_item.eo52
-rw-r--r--src/lib/elementary/elm_cursor.h120
-rw-r--r--src/lib/elementary/elm_datetime.c1130
-rw-r--r--src/lib/elementary/elm_datetime.eo305
-rw-r--r--src/lib/elementary/elm_datetime.h208
-rw-r--r--src/lib/elementary/elm_datetime_common.h9
-rw-r--r--src/lib/elementary/elm_datetime_eo.h1
-rw-r--r--src/lib/elementary/elm_datetime_legacy.h15
-rw-r--r--src/lib/elementary/elm_dayselector.c617
-rw-r--r--src/lib/elementary/elm_dayselector.eo164
-rw-r--r--src/lib/elementary/elm_dayselector.h86
-rw-r--r--src/lib/elementary/elm_dayselector_eo.h1
-rw-r--r--src/lib/elementary/elm_dayselector_item.eo7
-rw-r--r--src/lib/elementary/elm_dayselector_legacy.h11
-rw-r--r--src/lib/elementary/elm_dbus_menu.c1034
-rw-r--r--src/lib/elementary/elm_debug.h28
-rw-r--r--src/lib/elementary/elm_deprecated.h1642
-rw-r--r--src/lib/elementary/elm_diskselector.c1832
-rw-r--r--src/lib/elementary/elm_diskselector.eo217
-rw-r--r--src/lib/elementary/elm_diskselector.h78
-rw-r--r--src/lib/elementary/elm_diskselector_common.h8
-rw-r--r--src/lib/elementary/elm_diskselector_eo.h2
-rw-r--r--src/lib/elementary/elm_diskselector_item.eo90
-rw-r--r--src/lib/elementary/elm_diskselector_legacy.h15
-rw-r--r--src/lib/elementary/elm_entry.c5858
-rw-r--r--src/lib/elementary/elm_entry.eo1001
-rw-r--r--src/lib/elementary/elm_entry.h315
-rw-r--r--src/lib/elementary/elm_entry_common.h259
-rw-r--r--src/lib/elementary/elm_entry_eo.h1
-rw-r--r--src/lib/elementary/elm_entry_legacy.h73
-rw-r--r--src/lib/elementary/elm_factory.c342
-rw-r--r--src/lib/elementary/elm_factory.h6
-rw-r--r--src/lib/elementary/elm_fileselector.eo68
-rw-r--r--src/lib/elementary/elm_fileselector_button.eo106
-rw-r--r--src/lib/elementary/elm_fileselector_entry.eo112
-rw-r--r--src/lib/elementary/elm_finger.h45
-rw-r--r--src/lib/elementary/elm_flip.c2069
-rw-r--r--src/lib/elementary/elm_flip.eo250
-rw-r--r--src/lib/elementary/elm_flip.h49
-rw-r--r--src/lib/elementary/elm_flip_eo.h1
-rw-r--r--src/lib/elementary/elm_flip_legacy.h25
-rw-r--r--src/lib/elementary/elm_flipselector.c811
-rw-r--r--src/lib/elementary/elm_flipselector.eo174
-rw-r--r--src/lib/elementary/elm_flipselector.h70
-rw-r--r--src/lib/elementary/elm_flipselector_eo.h2
-rw-r--r--src/lib/elementary/elm_flipselector_item.eo54
-rw-r--r--src/lib/elementary/elm_flipselector_legacy.h15
-rw-r--r--src/lib/elementary/elm_focus.h402
-rw-r--r--src/lib/elementary/elm_focus_item.h61
-rw-r--r--src/lib/elementary/elm_font.c207
-rw-r--r--src/lib/elementary/elm_font.h99
-rw-r--r--src/lib/elementary/elm_frame.c269
-rw-r--r--src/lib/elementary/elm_frame.eo64
-rw-r--r--src/lib/elementary/elm_frame.h59
-rw-r--r--src/lib/elementary/elm_frame_eo.h1
-rw-r--r--src/lib/elementary/elm_frame_legacy.h11
-rw-r--r--src/lib/elementary/elm_gen.h59
-rw-r--r--src/lib/elementary/elm_gen_common.h74
-rw-r--r--src/lib/elementary/elm_general.eot254
-rw-r--r--src/lib/elementary/elm_general.h309
-rw-r--r--src/lib/elementary/elm_gengrid.c5778
-rw-r--r--src/lib/elementary/elm_gengrid.eo592
-rw-r--r--src/lib/elementary/elm_gengrid.h288
-rw-r--r--src/lib/elementary/elm_gengrid_common.h398
-rw-r--r--src/lib/elementary/elm_gengrid_eo.h14
-rw-r--r--src/lib/elementary/elm_gengrid_item.eo228
-rw-r--r--src/lib/elementary/elm_gengrid_legacy.h215
-rw-r--r--src/lib/elementary/elm_gengrid_pan.eo18
-rw-r--r--src/lib/elementary/elm_genlist.c8452
-rw-r--r--src/lib/elementary/elm_genlist.eo598
-rw-r--r--src/lib/elementary/elm_genlist.h428
-rw-r--r--src/lib/elementary/elm_genlist_common.h350
-rw-r--r--src/lib/elementary/elm_genlist_eo.h14
-rw-r--r--src/lib/elementary/elm_genlist_item.eo441
-rw-r--r--src/lib/elementary/elm_genlist_legacy.h35
-rw-r--r--src/lib/elementary/elm_genlist_pan.eo21
-rw-r--r--src/lib/elementary/elm_gesture_layer.c4162
-rw-r--r--src/lib/elementary/elm_gesture_layer.eo160
-rw-r--r--src/lib/elementary/elm_gesture_layer.h79
-rw-r--r--src/lib/elementary/elm_gesture_layer_common.h351
-rw-r--r--src/lib/elementary/elm_gesture_layer_eo.h1
-rw-r--r--src/lib/elementary/elm_gesture_layer_extra_gestures.c241
-rw-r--r--src/lib/elementary/elm_gesture_layer_legacy.h54
-rw-r--r--src/lib/elementary/elm_getting_started.h195
-rw-r--r--src/lib/elementary/elm_glview.c600
-rw-r--r--src/lib/elementary/elm_glview.eo221
-rw-r--r--src/lib/elementary/elm_glview.h38
-rw-r--r--src/lib/elementary/elm_glview_common.h11
-rw-r--r--src/lib/elementary/elm_glview_eo.h1
-rw-r--r--src/lib/elementary/elm_glview_legacy.h92
-rw-r--r--src/lib/elementary/elm_grid.c274
-rw-r--r--src/lib/elementary/elm_grid.eo65
-rw-r--r--src/lib/elementary/elm_grid.h29
-rw-r--r--src/lib/elementary/elm_grid_eo.h11
-rw-r--r--src/lib/elementary/elm_grid_legacy.h37
-rw-r--r--src/lib/elementary/elm_helper.c50
-rw-r--r--src/lib/elementary/elm_helper.h110
-rw-r--r--src/lib/elementary/elm_hover.c851
-rw-r--r--src/lib/elementary/elm_hover.eo85
-rw-r--r--src/lib/elementary/elm_hover.h91
-rw-r--r--src/lib/elementary/elm_hover_eo.h1
-rw-r--r--src/lib/elementary/elm_hover_legacy.h36
-rw-r--r--src/lib/elementary/elm_hoversel.eo111
-rw-r--r--src/lib/elementary/elm_hoversel_item.eo32
-rw-r--r--src/lib/elementary/elm_icon.c954
-rw-r--r--src/lib/elementary/elm_icon.eo114
-rw-r--r--src/lib/elementary/elm_icon.h154
-rw-r--r--src/lib/elementary/elm_icon_eo.h1
-rw-r--r--src/lib/elementary/elm_icon_legacy.h13
-rw-r--r--src/lib/elementary/elm_image.c1665
-rw-r--r--src/lib/elementary/elm_image.eo265
-rw-r--r--src/lib/elementary/elm_image.h53
-rw-r--r--src/lib/elementary/elm_image_eo.h11
-rw-r--r--src/lib/elementary/elm_image_legacy.h323
-rw-r--r--src/lib/elementary/elm_index.c1725
-rw-r--r--src/lib/elementary/elm_index.eo255
-rw-r--r--src/lib/elementary/elm_index.h74
-rw-r--r--src/lib/elementary/elm_index_eo.h12
-rw-r--r--src/lib/elementary/elm_index_item.eo48
-rw-r--r--src/lib/elementary/elm_index_legacy.h15
-rw-r--r--src/lib/elementary/elm_interface_atspi_accessible.c610
-rw-r--r--src/lib/elementary/elm_interface_atspi_accessible.eo436
-rw-r--r--src/lib/elementary/elm_interface_atspi_accessible.h156
-rw-r--r--src/lib/elementary/elm_interface_atspi_action.c23
-rw-r--r--src/lib/elementary/elm_interface_atspi_action.eo76
-rw-r--r--src/lib/elementary/elm_interface_atspi_component.c152
-rw-r--r--src/lib/elementary/elm_interface_atspi_component.eo102
-rw-r--r--src/lib/elementary/elm_interface_atspi_editable_text.c11
-rw-r--r--src/lib/elementary/elm_interface_atspi_editable_text.eo49
-rw-r--r--src/lib/elementary/elm_interface_atspi_image.c55
-rw-r--r--src/lib/elementary/elm_interface_atspi_image.eo43
-rw-r--r--src/lib/elementary/elm_interface_atspi_selection.c11
-rw-r--r--src/lib/elementary/elm_interface_atspi_selection.eo61
-rw-r--r--src/lib/elementary/elm_interface_atspi_text.c20
-rw-r--r--src/lib/elementary/elm_interface_atspi_text.eo225
-rw-r--r--src/lib/elementary/elm_interface_atspi_text.h19
-rw-r--r--src/lib/elementary/elm_interface_atspi_value.c11
-rw-r--r--src/lib/elementary/elm_interface_atspi_value.eo37
-rw-r--r--src/lib/elementary/elm_interface_atspi_widget_action.c143
-rw-r--r--src/lib/elementary/elm_interface_atspi_widget_action.eo24
-rw-r--r--src/lib/elementary/elm_interface_atspi_widget_action.h24
-rw-r--r--src/lib/elementary/elm_interface_atspi_window.c9
-rw-r--r--src/lib/elementary/elm_interface_atspi_window.eo12
-rw-r--r--src/lib/elementary/elm_interface_atspi_window.h56
-rw-r--r--src/lib/elementary/elm_interface_fileselector.c8
-rw-r--r--src/lib/elementary/elm_interface_fileselector.eo180
-rw-r--r--src/lib/elementary/elm_interface_fileselector.h15
-rw-r--r--src/lib/elementary/elm_interface_scrollable.c4552
-rw-r--r--src/lib/elementary/elm_interface_scrollable.eo628
-rw-r--r--src/lib/elementary/elm_interface_scrollable.h241
-rw-r--r--src/lib/elementary/elm_interfaces.h26
-rw-r--r--src/lib/elementary/elm_intro.h.in34
-rw-r--r--src/lib/elementary/elm_inwin.c169
-rw-r--r--src/lib/elementary/elm_inwin.eo31
-rw-r--r--src/lib/elementary/elm_inwin.h55
-rw-r--r--src/lib/elementary/elm_inwin_eo.h1
-rw-r--r--src/lib/elementary/elm_inwin_legacy.h66
-rw-r--r--src/lib/elementary/elm_label.c624
-rw-r--r--src/lib/elementary/elm_label.eo136
-rw-r--r--src/lib/elementary/elm_label.h50
-rw-r--r--src/lib/elementary/elm_label_eo.h11
-rw-r--r--src/lib/elementary/elm_label_legacy.h11
-rw-r--r--src/lib/elementary/elm_layout.c1807
-rw-r--r--src/lib/elementary/elm_layout.eo499
-rw-r--r--src/lib/elementary/elm_layout.h179
-rw-r--r--src/lib/elementary/elm_layout_common.h53
-rw-r--r--src/lib/elementary/elm_layout_eo.h11
-rw-r--r--src/lib/elementary/elm_layout_legacy.h104
-rw-r--r--src/lib/elementary/elm_list.c3285
-rw-r--r--src/lib/elementary/elm_list.eo477
-rw-r--r--src/lib/elementary/elm_list.h108
-rw-r--r--src/lib/elementary/elm_list_eo.h12
-rw-r--r--src/lib/elementary/elm_list_item.eo123
-rw-r--r--src/lib/elementary/elm_list_legacy.h15
-rw-r--r--src/lib/elementary/elm_macros.h16
-rw-r--r--src/lib/elementary/elm_main.c1782
-rw-r--r--src/lib/elementary/elm_map.c5561
-rw-r--r--src/lib/elementary/elm_map.eo647
-rw-r--r--src/lib/elementary/elm_map.h83
-rw-r--r--src/lib/elementary/elm_map_common.h607
-rw-r--r--src/lib/elementary/elm_map_eo.h2
-rw-r--r--src/lib/elementary/elm_map_legacy.h13
-rw-r--r--src/lib/elementary/elm_map_pan.eo30
-rw-r--r--src/lib/elementary/elm_mapbuf.c420
-rw-r--r--src/lib/elementary/elm_mapbuf.eo144
-rw-r--r--src/lib/elementary/elm_mapbuf.h48
-rw-r--r--src/lib/elementary/elm_mapbuf_eo.h11
-rw-r--r--src/lib/elementary/elm_mapbuf_legacy.h14
-rw-r--r--src/lib/elementary/elm_menu.c1410
-rw-r--r--src/lib/elementary/elm_menu.eo89
-rw-r--r--src/lib/elementary/elm_menu.h49
-rw-r--r--src/lib/elementary/elm_menu_eo.h2
-rw-r--r--src/lib/elementary/elm_menu_item.eo92
-rw-r--r--src/lib/elementary/elm_menu_legacy.h34
-rw-r--r--src/lib/elementary/elm_mirroring.h60
-rw-r--r--src/lib/elementary/elm_module.c240
-rw-r--r--src/lib/elementary/elm_multibuttonentry.eo201
-rw-r--r--src/lib/elementary/elm_multibuttonentry_item.eo35
-rw-r--r--src/lib/elementary/elm_naviframe.eo169
-rw-r--r--src/lib/elementary/elm_naviframe_item.eo84
-rw-r--r--src/lib/elementary/elm_need.h110
-rw-r--r--src/lib/elementary/elm_notify.c695
-rw-r--r--src/lib/elementary/elm_notify.eo105
-rw-r--r--src/lib/elementary/elm_notify.h45
-rw-r--r--src/lib/elementary/elm_notify_common.h1
-rw-r--r--src/lib/elementary/elm_notify_eo.h11
-rw-r--r--src/lib/elementary/elm_notify_legacy.h36
-rw-r--r--src/lib/elementary/elm_object.h510
-rw-r--r--src/lib/elementary/elm_object_item.h79
-rw-r--r--src/lib/elementary/elm_pan.eo65
-rw-r--r--src/lib/elementary/elm_panel.c1527
-rw-r--r--src/lib/elementary/elm_panel.eo88
-rw-r--r--src/lib/elementary/elm_panel.h48
-rw-r--r--src/lib/elementary/elm_panel_common.h27
-rw-r--r--src/lib/elementary/elm_panel_eo.h1
-rw-r--r--src/lib/elementary/elm_panel_legacy.h12
-rw-r--r--src/lib/elementary/elm_panes.c541
-rw-r--r--src/lib/elementary/elm_panes.eo147
-rw-r--r--src/lib/elementary/elm_panes.h65
-rw-r--r--src/lib/elementary/elm_panes_eo.h1
-rw-r--r--src/lib/elementary/elm_panes_legacy.h14
-rw-r--r--src/lib/elementary/elm_photo.c420
-rw-r--r--src/lib/elementary/elm_photo.eo69
-rw-r--r--src/lib/elementary/elm_photo.h36
-rw-r--r--src/lib/elementary/elm_photo_eo.h11
-rw-r--r--src/lib/elementary/elm_photo_legacy.h47
-rw-r--r--src/lib/elementary/elm_photocam.c2224
-rw-r--r--src/lib/elementary/elm_photocam.eo213
-rw-r--r--src/lib/elementary/elm_photocam.h91
-rw-r--r--src/lib/elementary/elm_photocam_eo.h2
-rw-r--r--src/lib/elementary/elm_photocam_legacy.h58
-rw-r--r--src/lib/elementary/elm_photocam_pan.eo26
-rw-r--r--src/lib/elementary/elm_player.eo29
-rw-r--r--src/lib/elementary/elm_plug.c192
-rw-r--r--src/lib/elementary/elm_plug.eo42
-rw-r--r--src/lib/elementary/elm_plug.h42
-rw-r--r--src/lib/elementary/elm_plug_eo.h1
-rw-r--r--src/lib/elementary/elm_plug_legacy.h11
-rw-r--r--src/lib/elementary/elm_popup.eo197
-rw-r--r--src/lib/elementary/elm_popup_item.eo15
-rw-r--r--src/lib/elementary/elm_prefs.c1891
-rw-r--r--src/lib/elementary/elm_prefs.eo225
-rw-r--r--src/lib/elementary/elm_prefs.h86
-rw-r--r--src/lib/elementary/elm_prefs_common.h319
-rw-r--r--src/lib/elementary/elm_prefs_data.c1069
-rw-r--r--src/lib/elementary/elm_prefs_data.h298
-rw-r--r--src/lib/elementary/elm_prefs_edd.x326
-rw-r--r--src/lib/elementary/elm_prefs_eo.h11
-rw-r--r--src/lib/elementary/elm_prefs_legacy.h65
-rw-r--r--src/lib/elementary/elm_priv.h611
-rw-r--r--src/lib/elementary/elm_progressbar.c559
-rw-r--r--src/lib/elementary/elm_progressbar.eo174
-rw-r--r--src/lib/elementary/elm_progressbar.h74
-rw-r--r--src/lib/elementary/elm_progressbar_common.h12
-rw-r--r--src/lib/elementary/elm_progressbar_eo.h1
-rw-r--r--src/lib/elementary/elm_progressbar_legacy.h14
-rw-r--r--src/lib/elementary/elm_radio.c409
-rw-r--r--src/lib/elementary/elm_radio.eo92
-rw-r--r--src/lib/elementary/elm_radio.h75
-rw-r--r--src/lib/elementary/elm_radio_eo.h1
-rw-r--r--src/lib/elementary/elm_radio_legacy.h11
-rw-r--r--src/lib/elementary/elm_removed.h6447
-rw-r--r--src/lib/elementary/elm_route.c264
-rw-r--r--src/lib/elementary/elm_route.eo48
-rw-r--r--src/lib/elementary/elm_route.h21
-rw-r--r--src/lib/elementary/elm_route_eo.h1
-rw-r--r--src/lib/elementary/elm_route_legacy.h11
-rw-r--r--src/lib/elementary/elm_scale.h36
-rw-r--r--src/lib/elementary/elm_scroll.h167
-rw-r--r--src/lib/elementary/elm_scroller.c1417
-rw-r--r--src/lib/elementary/elm_scroller.eo136
-rw-r--r--src/lib/elementary/elm_scroller.h76
-rw-r--r--src/lib/elementary/elm_scroller_eo.h11
-rw-r--r--src/lib/elementary/elm_scroller_legacy.h560
-rw-r--r--src/lib/elementary/elm_segment_control.c844
-rw-r--r--src/lib/elementary/elm_segment_control.eo151
-rw-r--r--src/lib/elementary/elm_segment_control.h72
-rw-r--r--src/lib/elementary/elm_segment_control_eo.h2
-rw-r--r--src/lib/elementary/elm_segment_control_item.eo45
-rw-r--r--src/lib/elementary/elm_segment_control_legacy.h15
-rw-r--r--src/lib/elementary/elm_separator.c114
-rw-r--r--src/lib/elementary/elm_separator.eo27
-rw-r--r--src/lib/elementary/elm_separator.h29
-rw-r--r--src/lib/elementary/elm_separator_eo.h1
-rw-r--r--src/lib/elementary/elm_separator_legacy.h12
-rw-r--r--src/lib/elementary/elm_slider.c1304
-rw-r--r--src/lib/elementary/elm_slider.eo295
-rw-r--r--src/lib/elementary/elm_slider.h86
-rw-r--r--src/lib/elementary/elm_slider_common.h12
-rw-r--r--src/lib/elementary/elm_slider_eo.h1
-rw-r--r--src/lib/elementary/elm_slider_legacy.h14
-rw-r--r--src/lib/elementary/elm_slideshow.c737
-rw-r--r--src/lib/elementary/elm_slideshow.eo316
-rw-r--r--src/lib/elementary/elm_slideshow.h85
-rw-r--r--src/lib/elementary/elm_slideshow_common.h36
-rw-r--r--src/lib/elementary/elm_slideshow_eo.h2
-rw-r--r--src/lib/elementary/elm_slideshow_item.eo33
-rw-r--r--src/lib/elementary/elm_slideshow_legacy.h15
-rw-r--r--src/lib/elementary/elm_spinner.c1712
-rw-r--r--src/lib/elementary/elm_spinner.eo248
-rw-r--r--src/lib/elementary/elm_spinner.h68
-rw-r--r--src/lib/elementary/elm_spinner_eo.h1
-rw-r--r--src/lib/elementary/elm_spinner_legacy.h45
-rw-r--r--src/lib/elementary/elm_store.c731
-rw-r--r--src/lib/elementary/elm_store.h407
-rw-r--r--src/lib/elementary/elm_sys_notify.c288
-rw-r--r--src/lib/elementary/elm_sys_notify.eo95
-rw-r--r--src/lib/elementary/elm_sys_notify.h85
-rw-r--r--src/lib/elementary/elm_sys_notify_dbus.c398
-rw-r--r--src/lib/elementary/elm_sys_notify_dbus.eo14
-rw-r--r--src/lib/elementary/elm_sys_notify_interface.c9
-rw-r--r--src/lib/elementary/elm_sys_notify_interface.eo66
-rw-r--r--src/lib/elementary/elm_systray.c518
-rw-r--r--src/lib/elementary/elm_systray.eo124
-rw-r--r--src/lib/elementary/elm_systray.h4
-rw-r--r--src/lib/elementary/elm_systray_common.h6
-rw-r--r--src/lib/elementary/elm_systray_eo.h11
-rw-r--r--src/lib/elementary/elm_systray_watcher.c116
-rw-r--r--src/lib/elementary/elm_systray_watcher.h10
-rw-r--r--src/lib/elementary/elm_table.c417
-rw-r--r--src/lib/elementary/elm_table.eo132
-rw-r--r--src/lib/elementary/elm_table.h40
-rw-r--r--src/lib/elementary/elm_table_eo.h1
-rw-r--r--src/lib/elementary/elm_table_legacy.h45
-rw-r--r--src/lib/elementary/elm_theme.c958
-rw-r--r--src/lib/elementary/elm_theme.h585
-rw-r--r--src/lib/elementary/elm_thumb.c878
-rw-r--r--src/lib/elementary/elm_thumb.eo221
-rw-r--r--src/lib/elementary/elm_thumb.h67
-rw-r--r--src/lib/elementary/elm_thumb_common.h28
-rw-r--r--src/lib/elementary/elm_thumb_eo.h1
-rw-r--r--src/lib/elementary/elm_thumb_legacy.h70
-rw-r--r--src/lib/elementary/elm_toolbar.c4002
-rw-r--r--src/lib/elementary/elm_toolbar.eo402
-rw-r--r--src/lib/elementary/elm_toolbar.h81
-rw-r--r--src/lib/elementary/elm_toolbar_common.h21
-rw-r--r--src/lib/elementary/elm_toolbar_eo.h13
-rw-r--r--src/lib/elementary/elm_toolbar_item.eo323
-rw-r--r--src/lib/elementary/elm_toolbar_legacy.h64
-rw-r--r--src/lib/elementary/elm_tooltip.h247
-rw-r--r--src/lib/elementary/elm_transit.c2571
-rw-r--r--src/lib/elementary/elm_transit.h995
-rw-r--r--src/lib/elementary/elm_url.c152
-rw-r--r--src/lib/elementary/elm_util.c65
-rw-r--r--src/lib/elementary/elm_video.c484
-rw-r--r--src/lib/elementary/elm_video.eo122
-rw-r--r--src/lib/elementary/elm_video.h65
-rw-r--r--src/lib/elementary/elm_video_eo.h2
-rw-r--r--src/lib/elementary/elm_video_legacy.h63
-rw-r--r--src/lib/elementary/elm_view_form.c266
-rw-r--r--src/lib/elementary/elm_view_form.eo32
-rw-r--r--src/lib/elementary/elm_view_form.h10
-rw-r--r--src/lib/elementary/elm_view_list.c429
-rw-r--r--src/lib/elementary/elm_view_list.eo71
-rw-r--r--src/lib/elementary/elm_view_list.h10
-rw-r--r--src/lib/elementary/elm_web.eo544
-rw-r--r--src/lib/elementary/elm_web.h110
-rw-r--r--src/lib/elementary/elm_web2.c227
-rw-r--r--src/lib/elementary/elm_web_common.h283
-rw-r--r--src/lib/elementary/elm_web_eo.h1
-rw-r--r--src/lib/elementary/elm_web_legacy.h50
-rw-r--r--src/lib/elementary/elm_widget.c6003
-rw-r--r--src/lib/elementary/elm_widget.eo871
-rw-r--r--src/lib/elementary/elm_widget.h847
-rw-r--r--src/lib/elementary/elm_widget_actionslider.h66
-rw-r--r--src/lib/elementary/elm_widget_bg.h68
-rw-r--r--src/lib/elementary/elm_widget_box.h97
-rw-r--r--src/lib/elementary/elm_widget_bubble.h62
-rw-r--r--src/lib/elementary/elm_widget_button.h68
-rw-r--r--src/lib/elementary/elm_widget_calendar.h86
-rw-r--r--src/lib/elementary/elm_widget_check.h62
-rw-r--r--src/lib/elementary/elm_widget_clipper.h66
-rw-r--r--src/lib/elementary/elm_widget_clock.h85
-rw-r--r--src/lib/elementary/elm_widget_colorselector.h150
-rw-r--r--src/lib/elementary/elm_widget_combobox.h84
-rw-r--r--src/lib/elementary/elm_widget_conform.h97
-rw-r--r--src/lib/elementary/elm_widget_container.h45
-rw-r--r--src/lib/elementary/elm_widget_ctxpopup.h101
-rw-r--r--src/lib/elementary/elm_widget_datetime.h127
-rw-r--r--src/lib/elementary/elm_widget_dayselector.h78
-rw-r--r--src/lib/elementary/elm_widget_diskselector.h114
-rw-r--r--src/lib/elementary/elm_widget_entry.h180
-rw-r--r--src/lib/elementary/elm_widget_fileselector.h167
-rw-r--r--src/lib/elementary/elm_widget_fileselector_button.h84
-rw-r--r--src/lib/elementary/elm_widget_fileselector_entry.h68
-rw-r--r--src/lib/elementary/elm_widget_flip.h109
-rw-r--r--src/lib/elementary/elm_widget_flipselector.h93
-rw-r--r--src/lib/elementary/elm_widget_frame.h63
-rw-r--r--src/lib/elementary/elm_widget_gengrid.h227
-rw-r--r--src/lib/elementary/elm_widget_genlist.h371
-rw-r--r--src/lib/elementary/elm_widget_glview.h82
-rw-r--r--src/lib/elementary/elm_widget_grid.h31
-rw-r--r--src/lib/elementary/elm_widget_hover.h80
-rw-r--r--src/lib/elementary/elm_widget_hoversel.h102
-rw-r--r--src/lib/elementary/elm_widget_icon.h89
-rw-r--r--src/lib/elementary/elm_widget_image.h120
-rw-r--r--src/lib/elementary/elm_widget_index.h115
-rw-r--r--src/lib/elementary/elm_widget_inwin.h60
-rw-r--r--src/lib/elementary/elm_widget_item.eo539
-rw-r--r--src/lib/elementary/elm_widget_label.h59
-rw-r--r--src/lib/elementary/elm_widget_layout.h79
-rw-r--r--src/lib/elementary/elm_widget_list.h143
-rw-r--r--src/lib/elementary/elm_widget_map.h534
-rw-r--r--src/lib/elementary/elm_widget_mapbuf.h74
-rw-r--r--src/lib/elementary/elm_widget_menu.h107
-rw-r--r--src/lib/elementary/elm_widget_multibuttonentry.h153
-rw-r--r--src/lib/elementary/elm_widget_naviframe.h136
-rw-r--r--src/lib/elementary/elm_widget_notify.h70
-rw-r--r--src/lib/elementary/elm_widget_panel.h79
-rw-r--r--src/lib/elementary/elm_widget_panes.h77
-rw-r--r--src/lib/elementary/elm_widget_photo.h76
-rw-r--r--src/lib/elementary/elm_widget_photocam.h172
-rw-r--r--src/lib/elementary/elm_widget_player.h79
-rw-r--r--src/lib/elementary/elm_widget_plug.h51
-rw-r--r--src/lib/elementary/elm_widget_popup.h118
-rw-r--r--src/lib/elementary/elm_widget_prefs.h131
-rw-r--r--src/lib/elementary/elm_widget_progressbar.h82
-rw-r--r--src/lib/elementary/elm_widget_radio.h73
-rw-r--r--src/lib/elementary/elm_widget_route.h84
-rw-r--r--src/lib/elementary/elm_widget_scroller.h71
-rw-r--r--src/lib/elementary/elm_widget_segment_control.h88
-rw-r--r--src/lib/elementary/elm_widget_separator.h61
-rw-r--r--src/lib/elementary/elm_widget_slider.h89
-rw-r--r--src/lib/elementary/elm_widget_slideshow.h103
-rw-r--r--src/lib/elementary/elm_widget_spinner.h90
-rw-r--r--src/lib/elementary/elm_widget_table.h31
-rw-r--r--src/lib/elementary/elm_widget_thumb.h99
-rw-r--r--src/lib/elementary/elm_widget_toolbar.h137
-rw-r--r--src/lib/elementary/elm_widget_video.h65
-rw-r--r--src/lib/elementary/elm_widget_web.h66
-rw-r--r--src/lib/elementary/elm_win.c5773
-rw-r--r--src/lib/elementary/elm_win.eo1316
-rw-r--r--src/lib/elementary/elm_win.h116
-rw-r--r--src/lib/elementary/elm_win_common.h76
-rw-r--r--src/lib/elementary/elm_win_eo.h11
-rw-r--r--src/lib/elementary/elm_win_legacy.h246
-rw-r--r--src/lib/elementary/elm_win_standard.c36
-rw-r--r--src/lib/elementary/elm_win_standard.eo7
-rw-r--r--src/lib/elementary/elm_win_standard.h3
-rw-r--r--src/lib/elementary/els_box.c500
-rw-r--r--src/lib/elementary/els_box.h1
-rw-r--r--src/lib/elementary/els_cursor.c714
-rw-r--r--src/lib/elementary/els_tooltip.c1066
-rw-r--r--src/lib/elementary/elu_ews_wm.c532
587 files changed, 204681 insertions, 0 deletions
diff --git a/src/lib/elementary/.gitignore b/src/lib/elementary/.gitignore
new file mode 100644
index 0000000..0015d39
--- /dev/null
+++ b/src/lib/elementary/.gitignore
@@ -0,0 +1,13 @@
1/Elementary.h
2/Elementary.hh
3/elm_intro.h
4/*.eo.c
5/*.eo.h
6/*.eo.legacy.h
7/*.eo.hh
8/*.eo.impl.hh
9/*.eot.h
10/eldbus_elementary_colorclass.c
11/eldbus_elementary_colorclass.h
12/eldbus_utils.h
13
diff --git a/src/lib/elementary/Elementary.h.in b/src/lib/elementary/Elementary.h.in
new file mode 100644
index 0000000..b8fe89a
--- /dev/null
+++ b/src/lib/elementary/Elementary.h.in
@@ -0,0 +1,279 @@
1/* This is the prmary Elementary header file that includes all other useful
2 * headers.
3 *
4 * Elementary is distributed under the LGPLv2 license. Please see the COPYING
5 * file that was distributed with this source.
6 */
7#ifndef ELEMENTARY_H
8#define ELEMENTARY_H
9
10#define ELM_ELDBUS
11#define ELM_EFREET
12#define ELM_ETHUMB
13
14@ELM_UNIX_DEF@ ELM_UNIX
15@ELM_WIN32_DEF@ ELM_WIN32
16@ELM_EMAP_DEF@ ELM_EMAP
17@ELM_DEBUG_DEF@ ELM_DEBUG
18@ELM_ALLOCA_H_DEF@ ELM_ALLOCA_H
19@ELM_LIBINTL_H_DEF@ ELM_LIBINTL_H
20@ELM_DIRENT_H_DEF@ ELM_DIRENT_H
21
22#ifdef EFL_BETA_API_SUPPORT
23@ELM_ELOCATION_DEF@ ELM_ELOCATION
24#endif
25
26/* Standard headers for standard system calls etc. */
27#include <stdio.h>
28#include <stdlib.h>
29#include <unistd.h>
30#include <string.h>
31#include <sys/types.h>
32#include <sys/stat.h>
33#include <sys/time.h>
34#include <sys/param.h>
35#include <math.h>
36#include <fnmatch.h>
37#include <limits.h>
38#include <ctype.h>
39#include <time.h>
40#ifdef ELM_DIRENT_H
41#include <dirent.h>
42#endif
43#include <pwd.h>
44#include <errno.h>
45
46#ifdef ELM_UNIX
47#include <locale.h>
48#ifdef ELM_LIBINTL_H
49#include <libintl.h>
50#endif
51#include <signal.h>
52#include <grp.h>
53#include <glob.h>
54#endif
55
56#ifdef ELM_ALLOCA_H
57#include <alloca.h>
58#endif
59
60#ifdef ELM_WIN32
61#include <malloc.h>
62#ifndef alloca
63#define alloca _alloca
64#endif
65#endif
66
67/* EFL headers */
68#include "Efl_Config.h"
69
70#include <Eina.h>
71#include <Eet.h>
72#include <Evas.h>
73#include <Evas_GL.h>
74#include <Ecore.h>
75#include <Ecore_Evas.h>
76#include <Ecore_File.h>
77#include <Ecore_Input.h>
78#include <Ecore_IMF.h>
79#include <Ecore_Con.h>
80#include <Edje.h>
81#include <Eldbus.h>
82#include <Efreet.h>
83#include <Efreet_Mime.h>
84#include <Efreet_Trash.h>
85#include <Ethumb_Client.h>
86
87#ifdef ELM_ELOCATION
88#include <Elocation.h>
89#endif
90
91#ifdef ELM_EMAP
92#include <EMap.h>
93#endif
94
95#ifdef EAPI
96# undef EAPI
97#endif
98
99#ifdef _WIN32
100# ifdef ELEMENTARY_BUILD
101# ifdef DLL_EXPORT
102# define EAPI __declspec(dllexport)
103# else
104# define EAPI
105# endif /* ! DLL_EXPORT */
106# else
107# define EAPI __declspec(dllimport)
108# endif /* ! EFL_EVAS_BUILD */
109#else
110# ifdef __GNUC__
111# if __GNUC__ >= 4
112# define EAPI __attribute__ ((visibility("default")))
113# else
114# define EAPI
115# endif
116# else
117# define EAPI
118# endif
119#endif /* ! _WIN32 */
120
121#ifdef _WIN32
122# define EAPI_MAIN
123#else
124# define EAPI_MAIN EAPI
125#endif
126
127/* allow usage from c++ */
128#ifdef __cplusplus
129extern "C"
130{
131#endif
132
133/* docs */
134#include <elm_intro.h>
135#include <elm_getting_started.h>
136#include <elm_authors.h>
137
138#define ELM_VERSION_MAJOR @ELM_VERSION_MAJOR@
139#define ELM_VERSION_MINOR @ELM_VERSION_MINOR@
140
141typedef struct _Elm_Version
142{
143 int major;
144 int minor;
145 int micro;
146 int revision;
147} Elm_Version;
148
149EAPI extern Elm_Version *elm_version;
150
151/* include these first for general used definitions */
152#include <elm_gen.h>
153#include <elm_general.h>
154#include <elm_config.h>
155#include <elm_focus.h>
156#include <elm_tooltip.h>
157#include <elm_object_item.h>
158#include <elm_focus_item.h>
159
160#include <elm_prefs_data.h>
161#include <elm_prefs.h>
162#include <elm_systray.h>
163#include <elm_sys_notify.h>
164
165/* special widgets - types used elsewhere */
166#include <elm_access.h>
167#include <elm_icon.h>
168#include <elm_scroller.h>
169#include <elm_entry.h>
170#include <elm_list.h>
171
172/* Interfaces */
173#include <elm_interfaces.h>
174
175/* other includes */
176#include <elc_ctxpopup.h>
177#include <elc_combobox.h>
178#include <elm_dayselector.h>
179#include <elc_fileselector_button.h>
180#include <elc_fileselector_entry.h>
181#include <elc_fileselector.h>
182#include <elc_hoversel.h>
183#include <elc_multibuttonentry.h>
184#include <elc_naviframe.h>
185#include <elc_popup.h>
186#include <elm_actionslider.h>
187#include <elm_app_common.h>
188#include <elm_app_server.h>
189#include <elm_app_server_view.h>
190#include <elm_app_client.h>
191#include <elm_app_client_view.h>
192#include <elm_app.h>
193#include <elm_atspi_app_object.h>
194#include <elm_atspi_bridge.h>
195#include <elm_bg.h>
196#include <elm_box.h>
197
198#include <elm_bubble.h>
199#include <elm_button.h>
200#include <elm_cache.h>
201#include <elm_calendar.h>
202#include <elm_check.h>
203#include <elm_clock.h>
204#include <elm_cnp.h>
205#include <elm_colorselector.h>
206#include <elm_color_class.h>
207#include <elm_conform.h>
208#include <elm_container.h>
209#include <elm_cursor.h>
210#include <elm_datetime.h>
211#include <elm_debug.h>
212#include <elm_diskselector.h>
213
214//#include <elm_factory.h>
215#include <elm_finger.h>
216#include <elm_flip.h>
217#include <elm_flipselector.h>
218#include <elm_font.h>
219#include <elm_frame.h>
220#include <elm_gengrid.h>
221#include <elm_genlist.h>
222#include <elm_gesture_layer.h>
223#include <elm_glview.h>
224#include <elm_grid.h>
225
226#include <elm_hover.h>
227#include <elm_image.h>
228#include <elm_index.h>
229#include <elm_inwin.h>
230#include <elm_label.h>
231#include <elm_layout.h>
232#include <elm_macros.h>
233#include <elm_map.h>
234#include <elm_mapbuf.h>
235#include <elm_menu.h>
236#include <elm_mirroring.h>
237#include <elm_need.h>
238#include <elm_notify.h>
239#include <elm_object.h>
240
241#include <elm_panel.h>
242#include <elm_panes.h>
243#include <elm_photocam.h>
244#include <elm_photo.h>
245#include <elm_plug.h>
246#include <elm_progressbar.h>
247#include <elm_radio.h>
248#include <elm_route.h>
249#include <elm_scale.h>
250#include <elm_scroll.h>
251#include <elm_segment_control.h>
252
253#include <elm_separator.h>
254#include <elm_slider.h>
255#include <elm_slideshow.h>
256#include <elm_spinner.h>
257#include <elm_store.h>
258#include <elm_table.h>
259#include <elm_theme.h>
260#include <elm_thumb.h>
261#include <elm_toolbar.h>
262#include <elm_transit.h>
263#include <elm_video.h>
264#include <elm_view_list.h>
265#include <elm_view_form.h>
266#include <elm_web.h>
267#include <elm_win.h>
268#include <elm_win_standard.h>
269
270/* include deprecated calls last of all */
271#include <elm_deprecated.h>
272
273#include <elm_helper.h>
274
275#ifdef __cplusplus
276}
277#endif
278
279#endif
diff --git a/src/lib/elementary/Elementary.hh.in b/src/lib/elementary/Elementary.hh.in
new file mode 100644
index 0000000..51f3127
--- /dev/null
+++ b/src/lib/elementary/Elementary.hh.in
@@ -0,0 +1,142 @@
1/* This is the prmary Elementary header file that includes all other useful
2 * headers.
3 *
4 * Elementary is distributed under the LGPLv2 license. Please see the COPYING
5 * file that was distributed with this source.
6 */
7#ifndef ELEMENTARY_CXX_HH
8#define ELEMENTARY_CXX_HH
9
10#if defined(ELEMENTARY_H) || defined(ELM_WIDGET_H)
11#error Do not include Elm C API headers before including Elementary.hh
12#endif
13
14#define EFL_BETA_API_SUPPORT 1
15#define EFL_EO_API_SUPPORT 1
16#define ELM_INTERNAL_API_ARGESFSDFEFC
17#define ELM_WIDGET_ITEM_PROTECTED
18
19extern "C" {
20
21#include "Elementary.h"
22
23#include "elm_widget.h"
24
25}
26
27#ifdef EFL_BETA_API_SUPPORT
28@ELM_ELOCATION_DEF@ ELM_ELOCATION
29#include <elm_widget_item.eo.hh>
30#include <elm_access.eo.hh>
31#include <elm_actionslider.eo.hh>
32#include <elm_atspi_bridge.eo.hh>
33#include <elm_app_client.eo.hh>
34#include <elm_app_client_view.eo.hh>
35#include <elm_app_server.eo.hh>
36#include <elm_app_server_view.eo.hh>
37#include <elm_atspi_app_object.eo.hh>
38#include <elm_bg.eo.hh>
39#include <elm_box.eo.hh>
40#include <elm_bubble.eo.hh>
41#include <elm_button.eo.hh>
42#include <elm_calendar.eo.hh>
43#include <elm_check.eo.hh>
44#include <elm_clock.eo.hh>
45#include <elm_colorselector.eo.hh>
46#include <elm_conformant.eo.hh>
47#include <elm_container.eo.hh>
48#include <elm_ctxpopup.eo.hh>
49#include <elm_datetime.eo.hh>
50#include <elm_dayselector.eo.hh>
51#include <elm_diskselector.eo.hh>
52#include <elm_entry.eo.hh>
53#include <elm_fileselector.eo.hh>
54#include <elm_fileselector_button.eo.hh>
55#include <elm_fileselector_entry.eo.hh>
56#include <elm_flip.eo.hh>
57#include <elm_flipselector.eo.hh>
58#include <elm_frame.eo.hh>
59#include <elm_gengrid.eo.hh>
60#include <elm_gengrid_pan.eo.hh>
61#include <elm_genlist.eo.hh>
62#include <elm_genlist_pan.eo.hh>
63#include <elm_gesture_layer.eo.hh>
64#include <elm_glview.eo.hh>
65#include <elm_grid.eo.hh>
66#include <elm_hover.eo.hh>
67#include <elm_hoversel.eo.hh>
68#include <elm_icon.eo.hh>
69#include <elm_image.eo.hh>
70#include <elm_index.eo.hh>
71#include <elm_interface_atspi_accessible.eo.hh>
72#include <elm_interface_atspi_action.eo.hh>
73#include <elm_interface_atspi_component.eo.hh>
74#include <elm_interface_atspi_editable_text.eo.hh>
75#include <elm_interface_atspi_image.eo.hh>
76#include <elm_interface_atspi_selection.eo.hh>
77#include <elm_interface_atspi_text.eo.hh>
78#include <elm_interface_atspi_value.eo.hh>
79#include <elm_interface_atspi_widget_action.eo.hh>
80#include <elm_interface_atspi_window.eo.hh>
81#include <elm_interface_fileselector.eo.hh>
82#include <elm_interface_scrollable.eo.hh>
83#include <elm_inwin.eo.hh>
84#include <elm_label.eo.hh>
85#include <elm_layout.eo.hh>
86#include <elm_list.eo.hh>
87#include <elm_map.eo.hh>
88#include <elm_map_pan.eo.hh>
89#include <elm_mapbuf.eo.hh>
90#include <elm_menu.eo.hh>
91#include <elm_multibuttonentry.eo.hh>
92#include <elm_naviframe.eo.hh>
93#include <elm_notify.eo.hh>
94#include <elm_pan.eo.hh>
95#include <elm_panel.eo.hh>
96#include <elm_panes.eo.hh>
97#include <elm_photo.eo.hh>
98#include <elm_photocam.eo.hh>
99#include <elm_photocam_pan.eo.hh>
100#include <elm_player.eo.hh>
101#include <elm_plug.eo.hh>
102#include <elm_popup.eo.hh>
103#include <elm_prefs.eo.hh>
104#include <elm_progressbar.eo.hh>
105#include <elm_radio.eo.hh>
106#include <elm_route.eo.hh>
107#include <elm_scroller.eo.hh>
108#include <elm_segment_control.eo.hh>
109#include <elm_separator.eo.hh>
110#include <elm_slider.eo.hh>
111#include <elm_slideshow.eo.hh>
112#include <elm_spinner.eo.hh>
113#include <elm_systray.eo.hh>
114#include <elm_table.eo.hh>
115#include <elm_thumb.eo.hh>
116#include <elm_toolbar.eo.hh>
117#include <elm_video.eo.hh>
118#include <elm_view_list.eo.hh>
119#include <elm_view_form.eo.hh>
120#include <elm_web.eo.hh>
121#include <elm_widget.eo.hh>
122#include <elm_win.eo.hh>
123#include <elm_win_standard.eo.hh>
124#include <elm_color_item.eo.hh>
125#include <elm_dayselector_item.eo.hh>
126#include <elm_hoversel_item.eo.hh>
127#include <elm_segment_control_item.eo.hh>
128#include <elm_slideshow_item.eo.hh>
129#include <elm_flipselector_item.eo.hh>
130#include <elm_menu_item.eo.hh>
131#include <elm_ctxpopup_item.eo.hh>
132#include <elm_index_item.eo.hh>
133#include <elm_multibuttonentry_item.eo.hh>
134#include <elm_naviframe_item.eo.hh>
135#include <elm_genlist_item.eo.hh>
136#include <elm_gengrid_item.eo.hh>
137#include <elm_list_item.eo.hh>
138#include <elm_toolbar_item.eo.hh>
139#include <elm_diskselector_item.eo.hh>
140#include <elm_popup_item.eo.hh>
141#endif
142#endif
diff --git a/src/lib/elementary/Elementary_Cursor.h b/src/lib/elementary/Elementary_Cursor.h
new file mode 100644
index 0000000..f77154b
--- /dev/null
+++ b/src/lib/elementary/Elementary_Cursor.h
@@ -0,0 +1,87 @@
1#ifndef _ELM_CURSOR_H
2#define _ELM_CURSOR_H
3
4/**
5 * @file
6 * @brief Defines the various cursor types for the X Windows system.
7 */
8
9#define ELM_CURSOR_X "x"
10#define ELM_CURSOR_ARROW "arrow"
11#define ELM_CURSOR_BASED_ARROW_DOWN "based_arrow_down"
12#define ELM_CURSOR_BASED_ARROW_UP "based_arrow_up"
13#define ELM_CURSOR_BOAT "boat"
14#define ELM_CURSOR_BOGOSITY "bogosity"
15#define ELM_CURSOR_BOTTOM_LEFT_CORNER "bottom_left_corner"
16#define ELM_CURSOR_BOTTOM_RIGHT_CORNER "bottom_right_corner"
17#define ELM_CURSOR_BOTTOM_SIDE "bottom_side"
18#define ELM_CURSOR_BOTTOM_TEE "bottom_tee"
19#define ELM_CURSOR_BOX_SPIRAL "box_spiral"
20#define ELM_CURSOR_CENTER_PTR "center_ptr"
21#define ELM_CURSOR_CIRCLE "circle"
22#define ELM_CURSOR_CLOCK "clock"
23#define ELM_CURSOR_COFFEE_MUG "coffee_mug"
24#define ELM_CURSOR_CROSS "cross"
25#define ELM_CURSOR_CROSS_REVERSE "cross_reverse"
26#define ELM_CURSOR_CROSSHAIR "crosshair"
27#define ELM_CURSOR_DIAMOND_CROSS "diamond_cross"
28#define ELM_CURSOR_DOT "dot"
29#define ELM_CURSOR_DOT_BOX_MASK "dot_box_mask"
30#define ELM_CURSOR_DOUBLE_ARROW "double_arrow"
31#define ELM_CURSOR_DRAFT_LARGE "draft_large"
32#define ELM_CURSOR_DRAFT_SMALL "draft_small"
33#define ELM_CURSOR_DRAPED_BOX "draped_box"
34#define ELM_CURSOR_EXCHANGE "exchange"
35#define ELM_CURSOR_FLEUR "fleur"
36#define ELM_CURSOR_GOBBLER "gobbler"
37#define ELM_CURSOR_GUMBY "gumby"
38#define ELM_CURSOR_HAND1 "hand1"
39#define ELM_CURSOR_HAND2 "hand2"
40#define ELM_CURSOR_HEART "heart"
41#define ELM_CURSOR_ICON "icon"
42#define ELM_CURSOR_IRON_CROSS "iron_cross"
43#define ELM_CURSOR_LEFT_PTR "left_ptr"
44#define ELM_CURSOR_LEFT_SIDE "left_side"
45#define ELM_CURSOR_LEFT_TEE "left_tee"
46#define ELM_CURSOR_LEFTBUTTON "leftbutton"
47#define ELM_CURSOR_LL_ANGLE "ll_angle"
48#define ELM_CURSOR_LR_ANGLE "lr_angle"
49#define ELM_CURSOR_MAN "man"
50#define ELM_CURSOR_MIDDLEBUTTON "middlebutton"
51#define ELM_CURSOR_MOUSE "mouse"
52#define ELM_CURSOR_PENCIL "pencil"
53#define ELM_CURSOR_PIRATE "pirate"
54#define ELM_CURSOR_PLUS "plus"
55#define ELM_CURSOR_QUESTION_ARROW "question_arrow"
56#define ELM_CURSOR_RIGHT_PTR "right_ptr"
57#define ELM_CURSOR_RIGHT_SIDE "right_side"
58#define ELM_CURSOR_RIGHT_TEE "right_tee"
59#define ELM_CURSOR_RIGHTBUTTON "rightbutton"
60#define ELM_CURSOR_RTL_LOGO "rtl_logo"
61#define ELM_CURSOR_SAILBOAT "sailboat"
62#define ELM_CURSOR_SB_DOWN_ARROW "sb_down_arrow"
63#define ELM_CURSOR_SB_H_DOUBLE_ARROW "sb_h_double_arrow"
64#define ELM_CURSOR_SB_LEFT_ARROW "sb_left_arrow"
65#define ELM_CURSOR_SB_RIGHT_ARROW "sb_right_arrow"
66#define ELM_CURSOR_SB_UP_ARROW "sb_up_arrow"
67#define ELM_CURSOR_SB_V_DOUBLE_ARROW "sb_v_double_arrow"
68#define ELM_CURSOR_SHUTTLE "shuttle"
69#define ELM_CURSOR_SIZING "sizing"
70#define ELM_CURSOR_SPIDER "spider"
71#define ELM_CURSOR_SPRAYCAN "spraycan"
72#define ELM_CURSOR_STAR "star"
73#define ELM_CURSOR_TARGET "target"
74#define ELM_CURSOR_TCROSS "tcross"
75#define ELM_CURSOR_TOP_LEFT_ARROW "top_left_arrow"
76#define ELM_CURSOR_TOP_LEFT_CORNER "top_left_corner"
77#define ELM_CURSOR_TOP_RIGHT_CORNER "top_right_corner"
78#define ELM_CURSOR_TOP_SIDE "top_side"
79#define ELM_CURSOR_TOP_TEE "top_tee"
80#define ELM_CURSOR_TREK "trek"
81#define ELM_CURSOR_UL_ANGLE "ul_angle"
82#define ELM_CURSOR_UMBRELLA "umbrella"
83#define ELM_CURSOR_UR_ANGLE "ur_angle"
84#define ELM_CURSOR_WATCH "watch"
85#define ELM_CURSOR_XTERM "xterm"
86
87#endif // ifndef _ELM_CURSOR_H
diff --git a/src/lib/elementary/Makefile.am b/src/lib/elementary/Makefile.am
new file mode 100644
index 0000000..7ea2597
--- /dev/null
+++ b/src/lib/elementary/Makefile.am
@@ -0,0 +1,716 @@
1AUTOMAKE_OPTIONS = 1.4 foreign
2MAINTAINERCLEANFILES = Makefile.in
3
4CLEANFILES=
5
6EOLIAN_FLAGS = @DEPS_EOLIAN_FLAGS@ \
7 -I$(top_srcdir)/src/lib
8
9include $(top_srcdir)/Makefile_Eolian_Helper.am
10include $(top_srcdir)/Makefile_Eolian_Cxx_Helper.am
11include $(top_srcdir)/Makefile_Eolian_Js_Helper.am
12
13AM_CPPFLAGS = \
14-DELM_INTERNAL_API_ARGESFSDFEFC=1 \
15-DMODULES_PATH=\"$(pkglibdir)/modules\" \
16-I. \
17-I$(top_builddir) \
18-I$(top_srcdir) \
19-I$(top_srcdir)/src/imported \
20-I$(top_srcdir)/src/lib \
21-I$(top_builddir)/src/lib \
22-DPACKAGE_DATA_DIR=\"$(pkgdatadir)\" \
23-DLOCALE_DIR=\"$(localedir)\" \
24-DPACKAGE_LIB_DIR=\"$(libdir)\" \
25-DICON_DIR=\"$(datadir)/icons\" \
26-DELM_TOP_BUILD_DIR=\"$(top_builddir)\" \
27-DELEMENTARY_BUILD \
28@ELEMENTARY_CFLAGS@
29
30lib_LTLIBRARIES = libelementary.la
31
32includes_HEADERS = \
33Elementary.h \
34Elementary_Cursor.h
35includesdir = $(includedir)/elementary-@VMAJ@
36
37includesunstable_HEADERS = \
38elm_gen_common.h \
39elm_atspi_bridge.h \
40elm_interface_atspi_accessible.h \
41elm_interface_atspi_text.h \
42elm_interface_atspi_widget_action.h \
43elm_interface_atspi_window.h \
44elm_interface_fileselector.h \
45elm_interface_scrollable.h \
46elm_interfaces.h \
47elm_widget.h \
48elm_widget_actionslider.h \
49elm_widget_bg.h \
50elm_widget_box.h \
51elm_widget_bubble.h \
52elm_widget_button.h \
53elm_widget_calendar.h \
54elm_widget_check.h \
55elm_widget_clock.h \
56elm_widget_colorselector.h \
57elm_widget_conform.h \
58elm_widget_container.h \
59elm_widget_combobox.h \
60elm_widget_ctxpopup.h \
61elm_widget_datetime.h \
62elm_widget_dayselector.h \
63elm_widget_diskselector.h \
64elm_widget_entry.h \
65elm_widget_fileselector.h \
66elm_widget_fileselector_button.h \
67elm_widget_fileselector_entry.h \
68elm_widget_flip.h \
69elm_widget_flipselector.h \
70elm_widget_frame.h \
71elm_widget_gengrid.h \
72elm_widget_genlist.h \
73elm_widget_glview.h \
74elm_widget_grid.h \
75elm_widget_hover.h \
76elm_widget_hoversel.h \
77elm_widget_icon.h \
78elm_widget_image.h \
79elm_widget_index.h \
80elm_widget_inwin.h \
81elm_widget_label.h \
82elm_widget_layout.h \
83elm_widget_list.h \
84elm_widget_map.h \
85elm_widget_mapbuf.h \
86elm_widget_menu.h \
87elm_widget_multibuttonentry.h \
88elm_widget_naviframe.h \
89elm_widget_notify.h \
90elm_widget_panel.h \
91elm_widget_panes.h \
92elm_widget_photo.h \
93elm_widget_photocam.h \
94elm_widget_player.h \
95elm_widget_plug.h \
96elm_widget_popup.h \
97elm_widget_prefs.h \
98elm_widget_progressbar.h \
99elm_widget_radio.h \
100elm_widget_route.h \
101elm_widget_scroller.h \
102elm_widget_segment_control.h \
103elm_widget_separator.h \
104elm_widget_slider.h \
105elm_widget_slideshow.h \
106elm_widget_spinner.h \
107elm_widget_table.h \
108elm_widget_thumb.h \
109elm_widget_toolbar.h \
110elm_widget_video.h \
111elm_widget_web.h
112includesunstabledir = $(includedir)/elementary-@VMAJ@
113
114includesub_HEADERS = \
115elc_ctxpopup.h \
116elc_ctxpopup_eo.h \
117elc_ctxpopup_legacy.h \
118elc_combobox.h \
119elc_combobox_legacy.h \
120elc_fileselector.h \
121elc_fileselector_eo.h \
122elc_fileselector_legacy.h \
123elc_fileselector_common.h \
124elc_fileselector_button.h \
125elc_fileselector_button_eo.h \
126elc_fileselector_button_legacy.h \
127elc_fileselector_entry.h \
128elc_fileselector_entry_eo.h \
129elc_fileselector_entry_legacy.h \
130elc_hoversel.h \
131elc_hoversel_eo.h \
132elc_hoversel_legacy.h \
133elc_multibuttonentry.h \
134elc_multibuttonentry_eo.h \
135elc_multibuttonentry_legacy.h \
136elc_multibuttonentry_common.h \
137elc_naviframe.h \
138elc_naviframe_eo.h \
139elc_naviframe_legacy.h \
140elc_naviframe_common.h \
141elc_popup.h \
142elc_popup_eo.h \
143elc_popup_legacy.h \
144elm_access.h \
145elm_actionslider.h \
146elm_actionslider_eo.h \
147elm_actionslider_legacy.h \
148elm_app_common.h \
149elm_app_server_eo.h \
150elm_app_server_view_eo.h \
151elm_app_server_view.h \
152elm_app_server_eet.h \
153elm_app_server.h \
154elm_app_client_eo.h \
155elm_app_client.h \
156elm_app_client_view_eo.h \
157elm_app_client_view.h \
158elm_app.h \
159elm_atspi_app_object.h \
160elm_authors.h \
161elm_bg.h \
162elm_bg_eo.h \
163elm_bg_legacy.h \
164elm_box.h \
165elm_box_eo.h \
166elm_box_legacy.h \
167elm_box_common.h \
168elm_bubble.h \
169elm_bubble_eo.h \
170elm_bubble_legacy.h \
171elm_button.h \
172elm_button_eo.h \
173elm_button_legacy.h \
174elm_cache.h \
175elm_calendar.h \
176elm_calendar_eo.h \
177elm_calendar_legacy.h \
178elm_calendar_common.h \
179elm_check.h \
180elm_check_eo.h \
181elm_check_legacy.h \
182elm_clock.h \
183elm_clock_eo.h \
184elm_clock_legacy.h \
185elm_cnp.h \
186elm_colorselector.h \
187elm_colorselector_eo.h \
188elm_colorselector_legacy.h \
189elm_colorselector_common.h \
190elm_color_class.h \
191elm_config.h \
192elm_conform.h \
193elm_conform_eo.h \
194elm_conform_legacy.h \
195elm_container.h \
196elm_cursor.h \
197elm_datetime.h \
198elm_datetime_common.h \
199elm_datetime_eo.h \
200elm_datetime_legacy.h \
201elm_dayselector.h \
202elm_dayselector_eo.h \
203elm_dayselector_legacy.h \
204elm_debug.h \
205elm_deprecated.h \
206elm_diskselector.h \
207elm_diskselector_common.h \
208elm_diskselector_eo.h \
209elm_diskselector_legacy.h \
210elm_entry.h \
211elm_entry_common.h \
212elm_entry_eo.h \
213elm_entry_legacy.h \
214elm_finger.h \
215elm_flip.h \
216elm_flip_eo.h \
217elm_flip_legacy.h \
218elm_flipselector.h \
219elm_flipselector_eo.h \
220elm_flipselector_legacy.h \
221elm_focus.h \
222elm_focus_item.h \
223elm_font.h \
224elm_frame.h \
225elm_frame_eo.h \
226elm_frame_legacy.h \
227elm_gen.h \
228elm_general.h \
229elm_gengrid.h \
230elm_gengrid_common.h \
231elm_gengrid_eo.h \
232elm_gengrid_legacy.h \
233elm_genlist.h \
234elm_genlist_common.h \
235elm_genlist_eo.h \
236elm_genlist_legacy.h \
237elm_gesture_layer.h \
238elm_gesture_layer_common.h \
239elm_gesture_layer_eo.h \
240elm_gesture_layer_legacy.h \
241elm_getting_started.h \
242elm_glview.h \
243elm_glview_common.h \
244elm_glview_eo.h \
245elm_glview_legacy.h \
246elm_grid.h \
247elm_grid_eo.h \
248elm_grid_legacy.h \
249elm_hover.h \
250elm_hover_eo.h \
251elm_hover_legacy.h \
252elm_icon.h \
253elm_icon_eo.h \
254elm_icon_legacy.h \
255elm_image.h \
256elm_image_eo.h \
257elm_image_legacy.h \
258elm_index.h \
259elm_index_eo.h \
260elm_index_legacy.h \
261elm_intro.h \
262elm_inwin.h \
263elm_inwin_eo.h \
264elm_inwin_legacy.h \
265elm_label.h \
266elm_label_eo.h \
267elm_label_legacy.h \
268elm_layout.h \
269elm_layout_common.h \
270elm_layout_eo.h \
271elm_layout_legacy.h \
272elm_list.h \
273elm_list_eo.h \
274elm_list_legacy.h \
275elm_macros.h \
276elm_map.h \
277elm_map_common.h \
278elm_map_eo.h \
279elm_map_legacy.h \
280elm_mapbuf.h \
281elm_mapbuf_eo.h \
282elm_mapbuf_legacy.h \
283elm_menu.h \
284elm_menu_eo.h \
285elm_menu_legacy.h \
286elm_mirroring.h \
287elm_need.h \
288elm_notify.h \
289elm_notify_common.h \
290elm_notify_eo.h \
291elm_notify_legacy.h \
292elm_object.h \
293elm_object_item.h \
294elm_panel.h \
295elm_panel_common.h \
296elm_panel_eo.h \
297elm_panel_legacy.h \
298elm_panes.h \
299elm_panes_eo.h \
300elm_panes_legacy.h \
301elm_photo.h \
302elm_photo_eo.h \
303elm_photo_legacy.h \
304elm_photocam.h \
305elm_photocam_eo.h \
306elm_photocam_legacy.h \
307elm_plug.h \
308elm_plug_eo.h \
309elm_plug_legacy.h \
310elm_prefs.h \
311elm_prefs_common.h \
312elm_prefs_eo.h \
313elm_prefs_legacy.h \
314elm_prefs_data.h \
315elm_progressbar.h \
316elm_progressbar_common.h \
317elm_progressbar_eo.h \
318elm_progressbar_legacy.h \
319elm_radio.h \
320elm_radio_eo.h \
321elm_radio_legacy.h \
322elm_route.h \
323elm_route_eo.h \
324elm_route_legacy.h \
325elm_scale.h \
326elm_scroll.h \
327elm_scroller.h \
328elm_scroller_eo.h \
329elm_scroller_legacy.h \
330elm_segment_control.h \
331elm_segment_control_eo.h \
332elm_segment_control_legacy.h \
333elm_separator.h \
334elm_separator_eo.h \
335elm_separator_legacy.h \
336elm_slider.h \
337elm_slider_common.h \
338elm_slider_eo.h \
339elm_slider_legacy.h \
340elm_slideshow.h \
341elm_slideshow_common.h \
342elm_slideshow_eo.h \
343elm_slideshow_legacy.h \
344elm_spinner.h \
345elm_spinner_eo.h \
346elm_spinner_legacy.h \
347elm_store.h \
348elm_systray.h \
349elm_systray_eo.h \
350elm_systray_common.h \
351elm_systray_watcher.h \
352elm_sys_notify.h \
353elm_sys_notify.eo.h \
354elm_sys_notify_dbus.eo.h \
355elm_table.h \
356elm_table_eo.h \
357elm_table_legacy.h \
358elm_theme.h \
359elm_thumb.h \
360elm_thumb_common.h \
361elm_thumb_eo.h \
362elm_thumb_legacy.h \
363elm_toolbar.h \
364elm_toolbar_common.h \
365elm_toolbar_eo.h \
366elm_toolbar_legacy.h \
367elm_tooltip.h \
368elm_transit.h \
369elm_video.h \
370elm_video_eo.h \
371elm_video_legacy.h \
372elm_view_list.h \
373elm_view_form.h \
374elm_web.h \
375elm_web_common.h \
376elm_web_eo.h \
377elm_web_legacy.h \
378elm_win.h \
379elm_win_common.h \
380elm_win_eo.h \
381elm_win_legacy.h \
382elm_win_standard.h \
383elm_win_standard.eo.h \
384elm_helper.h
385includesubdir = $(includedir)/elementary-@VMAJ@/
386
387libelementary_la_SOURCES = \
388elm_priv.h \
389els_box.h \
390elc_ctxpopup.c \
391elc_fileselector.c \
392elc_fileselector_button.c \
393elc_fileselector_entry.c \
394elc_hoversel.c \
395elc_multibuttonentry.c \
396elc_naviframe.c \
397elc_player.c \
398elc_popup.c \
399elc_scrolled_entry.c \
400elm_access.c \
401elm_actionslider.c \
402elm_app_common.c \
403elm_app_server_eet.c \
404elm_app_server.c \
405elm_app_server_view.c \
406elm_app_client.c \
407elm_app_client_view.c \
408elm_atspi_app_object.c \
409elm_atspi_bridge.c \
410elm_bg.c \
411elm_box.c \
412elm_bubble.c \
413elm_button.c \
414elm_calendar.c \
415elm_check.c \
416elm_clock.c \
417elm_cnp.c \
418elm_colorselector.c \
419elm_color_class.c \
420elc_combobox.c \
421elm_config.c \
422elm_conform.c \
423elm_container.c \
424elm_datetime.c \
425elm_dayselector.c \
426elm_dbus_menu.c \
427elm_diskselector.c \
428elm_entry.c \
429elm_flip.c \
430elm_flipselector.c \
431elm_font.c \
432elm_frame.c \
433elm_gengrid.c \
434elm_genlist.c \
435elm_gesture_layer.c \
436elm_gesture_layer_extra_gestures.c \
437elm_glview.c \
438elm_grid.c \
439elm_hover.c \
440elm_icon.c \
441elm_image.c \
442elm_index.c \
443elm_interface_atspi_accessible.c \
444elm_interface_atspi_action.c \
445elm_interface_atspi_component.c \
446elm_interface_atspi_editable_text.c \
447elm_interface_atspi_image.c \
448elm_interface_atspi_selection.c \
449elm_interface_atspi_text.c \
450elm_interface_atspi_value.c \
451elm_interface_atspi_widget_action.c \
452elm_interface_atspi_window.c \
453elm_interface_fileselector.c \
454elm_interface_scrollable.c \
455elm_inwin.c \
456elm_label.c \
457elm_layout.c \
458elm_list.c \
459elm_main.c \
460elm_map.c \
461elm_mapbuf.c \
462elm_menu.c \
463elm_module.c \
464elm_notify.c \
465elm_panel.c \
466elm_panes.c \
467elm_photo.c \
468elm_photocam.c \
469elm_plug.c \
470elm_prefs.c \
471elm_prefs_data.c \
472elm_prefs_edd.x \
473elm_progressbar.c \
474elm_radio.c \
475elm_route.c \
476elm_scroller.c \
477elm_segment_control.c \
478elm_separator.c \
479elm_slider.c \
480elm_slideshow.c \
481elm_spinner.c \
482elm_store.c \
483elm_systray.c \
484elm_systray_watcher.c \
485elm_sys_notify_interface.c \
486elm_sys_notify.c \
487elm_sys_notify_dbus.c \
488elm_table.c \
489elm_theme.c \
490elm_thumb.c \
491elm_toolbar.c \
492elm_transit.c \
493elm_util.c \
494elm_url.c \
495elm_video.c \
496elm_view_list.c \
497elm_view_form.c \
498elm_web2.c \
499elm_widget.c \
500elm_win.c \
501elm_win_standard.c \
502elm_helper.c \
503els_box.c \
504els_cursor.c \
505els_tooltip.c \
506elu_ews_wm.c
507
508libelementary_la_CFLAGS = @ELEMENTARY_CFLAGS@
509libelementary_la_LIBADD = \
510@ELEMENTARY_LIBS@ \
511@LTLIBINTL@
512
513libelementary_la_LDFLAGS = @EFL_LTLIBRARY_FLAGS@
514
515EXTRA_DIST = \
516elm_factory.h \
517elm_factory.c \
518elm_intro.h.in
519
520elm_eolian_files = \
521elm_access.eo \
522elm_actionslider.eo \
523elm_atspi_bridge.eo \
524elm_app_client.eo \
525elm_app_client_view.eo \
526elm_app_server.eo \
527elm_app_server_view.eo \
528elm_atspi_app_object.eo \
529elm_bg.eo \
530elm_box.eo \
531elm_bubble.eo \
532elm_button.eo \
533elm_calendar.eo \
534elm_check.eo \
535elm_clock.eo \
536elm_colorselector.eo \
537elm_combobox.eo \
538elm_conformant.eo \
539elm_container.eo \
540elm_ctxpopup.eo \
541elm_datetime.eo \
542elm_dayselector.eo \
543elm_diskselector.eo \
544elm_entry.eo \
545elm_fileselector.eo \
546elm_fileselector_button.eo \
547elm_fileselector_entry.eo \
548elm_flip.eo \
549elm_flipselector.eo \
550elm_frame.eo \
551elm_gengrid.eo \
552elm_gengrid_pan.eo \
553elm_genlist.eo \
554elm_genlist_pan.eo \
555elm_gesture_layer.eo \
556elm_glview.eo \
557elm_grid.eo \
558elm_hover.eo \
559elm_hoversel.eo \
560elm_icon.eo \
561elm_image.eo \
562elm_index.eo \
563elm_interface_atspi_accessible.eo \
564elm_interface_atspi_action.eo \
565elm_interface_atspi_component.eo \
566elm_interface_atspi_editable_text.eo \
567elm_interface_atspi_image.eo \
568elm_interface_atspi_selection.eo \
569elm_interface_atspi_text.eo \
570elm_interface_atspi_value.eo \
571elm_interface_atspi_widget_action.eo \
572elm_interface_atspi_window.eo \
573elm_interface_fileselector.eo \
574elm_interface_scrollable.eo \
575elm_inwin.eo \
576elm_label.eo \
577elm_layout.eo \
578elm_list.eo \
579elm_map.eo \
580elm_map_pan.eo \
581elm_mapbuf.eo \
582elm_menu.eo \
583elm_multibuttonentry.eo \
584elm_naviframe.eo \
585elm_notify.eo \
586elm_pan.eo \
587elm_panel.eo \
588elm_panes.eo \
589elm_photo.eo \
590elm_photocam.eo \
591elm_photocam_pan.eo \
592elm_player.eo \
593elm_plug.eo \
594elm_popup.eo \
595elm_prefs.eo \
596elm_progressbar.eo \
597elm_radio.eo \
598elm_route.eo \
599elm_scroller.eo \
600elm_segment_control.eo \
601elm_separator.eo \
602elm_slider.eo \
603elm_slideshow.eo \
604elm_spinner.eo \
605elm_sys_notify_interface.eo \
606elm_sys_notify.eo \
607elm_sys_notify_dbus.eo \
608elm_systray.eo \
609elm_table.eo \
610elm_thumb.eo \
611elm_toolbar.eo \
612elm_video.eo \
613elm_view_list.eo \
614elm_view_form.eo \
615elm_web.eo \
616elm_widget.eo \
617elm_win.eo \
618elm_win_standard.eo \
619elm_widget_item.eo \
620elm_color_item.eo \
621elm_dayselector_item.eo \
622elm_hoversel_item.eo \
623elm_segment_control_item.eo \
624elm_slideshow_item.eo \
625elm_flipselector_item.eo \
626elm_menu_item.eo \
627elm_ctxpopup_item.eo \
628elm_index_item.eo \
629elm_multibuttonentry_item.eo \
630elm_naviframe_item.eo \
631elm_genlist_item.eo \
632elm_gengrid_item.eo \
633elm_list_item.eo \
634elm_toolbar_item.eo \
635elm_diskselector_item.eo \
636elm_popup_item.eo
637
638elm_eolian_type_files = \
639elm_general.eot
640
641elm_eolian_c = $(elm_eolian_files:%.eo=%.eo.c)
642elm_eolian_h = $(elm_eolian_files:%.eo=%.eo.h)
643elm_eolian_legacy_h = $(elm_eolian_files:%.eo=%.eo.legacy.h)
644elm_eolian_hh = $(elm_eolian_files:%.eo=%.eo.hh)
645elm_eolian_impl_hh = $(elm_eolian_files:%.eo=%.eo.impl.hh)
646
647elm_eolian_eot_h = $(elm_eolian_type_files:%.eot=%.eot.h)
648
649elm_eolian_js_cc = $(elm_eolian_files:%.eo=%.eo.js.cc)
650
651BUILT_SOURCES = \
652 $(elm_eolian_c) \
653 $(elm_eolian_h) \
654 $(elm_eolian_eot_h) \
655 $(elm_eolian_legacy_h)
656
657elementaryeolianfilesdir = $(datadir)/eolian/include/elementary-@VMAJ@
658elementaryeolianfiles_DATA = $(elm_eolian_files) $(elm_eolian_type_files)
659EXTRA_DIST += ${elementaryeolianfiles_DATA}
660
661nodist_includesunstable_HEADERS = $(elm_eolian_h) $(elm_eolian_legacy_h) $(elm_eolian_eot_h)
662CLEANFILES += $(nodist_includesunstable_HEADERS)
663
664EXTRA_DIST += ${elementaryeolianfiles_DATA}
665
666includecxxbindingsdir = $(includedir)/elementary-cxx-@VMAJ@
667
668if HAVE_CXX11
669nodist_includecxxbindings_HEADERS = Elementary.hh $(elm_eolian_hh) $(elm_eolian_impl_hh)
670CLEANFILES += $(nodist_includecxxbindings_HEADERS)
671EXTRA_DIST += Elementary.hh.in
672endif
673
674if HAVE_JS
675CLEANFILES += $(elm_eolian_js_cc)
676
677lib_LTLIBRARIES += libelementary_js.la
678
679AM_V_CP = $(am__v_CP_@AM_V@)
680am__v_CP_ = $(am__v_CP_@AM_DEFAULT_V@)
681am__v_CP_0 = @echo " CP " $@;
682CP = cp
683
684if HAVE_NODEJS
685elm.node: libelementary_js.la
686 $(AM_V_CP)$(CP) $(abs_top_builddir)/src/lib/.libs/libelementary_js.so $(abs_top_builddir)/src/lib/elm.node
687
688elmnodedir = $(libdir)/node_modules
689elmnode_DATA = elm.node
690
691CLEANFILES += ${elmnodedir_DATA}
692EXTRA_DIST += ${elmnodedir_DATA}
693
694BUILT_SOURCES += ${elmnodedir_DATA}
695endif
696
697AM_CXXFLAGS = @ELEMENTARY_CFLAGS@ @ELEMENTARY_JS_CFLAGS@
698
699elm_js_object_files = $(elm_eolian_files:%.eo=%.eo.js.l$(OBJEXT))
700elm_js_object_files: $(elm_eolian_js_cc)
701
702libelementary_js_la_SOURCES = elementary_js.cc
703nodist_EXTRA_libelementary_js_la_SOURCES = $(elm_eolian_js_cc)
704
705libelementary_js_la_CXXFLAGS = @ELEMENTARY_CFLAGS@ @ELEMENTARY_JS_CFLAGS@
706libelementary_js_la_LIBADD = \
707@ELEMENTARY_LIBS@ \
708@ELEMENTARY_JS_LIBS@ \
709libelementary.la \
710@LTLIBINTL@ \
711$(elm_js_object_files)
712
713libelementary_js_la_LDFLAGS = @EFL_LTLIBRARY_FLAGS@
714
715endif
716
diff --git a/src/lib/elementary/elc_combobox.c b/src/lib/elementary/elc_combobox.c
new file mode 100644
index 0000000..65e8205
--- /dev/null
+++ b/src/lib/elementary/elc_combobox.c
@@ -0,0 +1,635 @@
1#ifdef HAVE_CONFIG_H
2# include "elementary_config.h"
3#endif
4
5#define EO_BASE_BETA
6#define ELM_INTERFACE_ATSPI_ACCESSIBLE_PROTECTED
7#define ELM_INTERFACE_ATSPI_WIDGET_ACTION_PROTECTED
8
9#include <Elementary.h>
10#include "elm_priv.h"
11#include "elm_widget_combobox.h"
12
13#define MY_CLASS ELM_COMBOBOX_CLASS
14
15#define MY_CLASS_NAME "Elm_Combobox"
16#define MY_CLASS_NAME_LEGACY "elm_combobox"
17
18static const char SIG_DISMISSED[] = "dismissed";
19static const char SIG_EXPANDED[] = "expanded";
20static const char SIG_ITEM_SELECTED[] = "item,selected";
21static const char SIG_ITEM_PRESSED[] = "item,pressed";
22static const char SIG_FILTER_DONE[] = "filter,done";
23
24static const Evas_Smart_Cb_Description _smart_callbacks[] = {
25 {SIG_DISMISSED, ""},
26 {SIG_EXPANDED, ""},
27 {SIG_ITEM_SELECTED, ""},
28 {SIG_ITEM_PRESSED, ""},
29 {SIG_FILTER_DONE, ""},
30 {"clicked", ""}, /**< handled by parent button class */
31 {SIG_WIDGET_LANG_CHANGED, ""}, /**< handled by elm_widget */
32 {SIG_WIDGET_ACCESS_CHANGED, ""}, /**< handled by elm_widget */
33 {NULL, NULL}
34};
35
36static Eina_Bool _key_action_move(Evas_Object *obj, const char *params);
37static Eina_Bool _key_action_activate(Evas_Object *obj, const char *params);
38
39static const Elm_Action key_actions[] = {
40 {"activate", _key_action_activate},
41 {"move", _key_action_move},
42 {NULL, NULL}
43};
44
45EOLIAN static Eina_Bool
46_elm_combobox_elm_widget_translate(Eo *obj EINA_UNUSED, Elm_Combobox_Data *sd)
47{
48 elm_obj_widget_translate(eo_super(obj, MY_CLASS));
49 elm_obj_widget_translate(sd->genlist);
50 elm_obj_widget_translate(sd->entry);
51
52 if (sd->hover)
53 elm_obj_widget_translate(sd->hover);
54
55 return EINA_TRUE;
56}
57
58EOLIAN static Eina_Bool
59_elm_combobox_elm_widget_theme_apply(Eo *obj, Elm_Combobox_Data *sd)
60{
61 const char *style;
62 Eina_Bool int_ret = EINA_FALSE;
63 Eina_Bool mirrored;
64 char buf[128];
65
66 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, EINA_FALSE);
67
68 style = eina_stringshare_add(elm_widget_style_get(obj));
69
70 snprintf(buf, sizeof(buf), "combobox_vertical/%s", style);
71
72 /* combobox's style has no extra bit for orientation but could have... */
73 eina_stringshare_replace(&(wd->style), buf);
74
75 int_ret = elm_obj_widget_theme_apply(eo_super(obj, MY_CLASS));
76 if (!int_ret) return EINA_FALSE;
77
78 eina_stringshare_replace(&(wd->style), style);
79
80 mirrored = elm_widget_mirrored_get(obj);
81
82 if (sd->hover)
83 elm_widget_mirrored_set(sd->hover, mirrored);
84
85 elm_widget_mirrored_set(sd->genlist, mirrored);
86 elm_widget_mirrored_set(sd->entry, mirrored);
87 eina_stringshare_del(style);
88
89 elm_combobox_hover_end(obj);
90
91 return EINA_TRUE;
92}
93
94static Eina_Bool
95_on_hover_clicked(void *data, const Eo_Event *event)
96{
97 const char *dismissstr;
98
99 dismissstr = elm_layout_data_get(event->obj, "dismiss");
100
101 if (!dismissstr || strcmp(dismissstr, "on"))
102 elm_combobox_hover_end(data); // for backward compatibility
103
104 return EINA_TRUE;
105}
106
107static void
108_hover_end_finished(void *data,
109 Evas_Object *obj EINA_UNUSED,
110 const char *emission EINA_UNUSED,
111 const char *source EINA_UNUSED)
112{
113 const char *dismissstr;
114 ELM_COMBOBOX_DATA_GET(data, sd);
115 dismissstr = elm_layout_data_get(sd->hover, "dismiss");
116 if (dismissstr && !strcmp(dismissstr, "on"))
117 {
118 sd->expanded = EINA_FALSE;
119 evas_object_hide(sd->hover);
120 eo_event_callback_call(data, ELM_COMBOBOX_EVENT_DISMISSED, NULL);
121 }
122}
123
124static void
125count_items_genlist(void *data)
126{
127 ELM_COMBOBOX_DATA_GET(data, sd);
128 Eina_Iterator *filter_iter;
129 int count = 0;
130 Elm_Object_Item *item;
131
132 filter_iter = elm_genlist_filter_iterator_new(sd->genlist);
133 if (!filter_iter) return;
134 EINA_ITERATOR_FOREACH(filter_iter, item)
135 if (item) count++;
136 sd->count = count;
137 eina_iterator_free(filter_iter);
138}
139
140static void
141_table_resize(void *data)
142{
143 ELM_COMBOBOX_DATA_GET(data, sd);
144 if (sd->count > 0)
145 {
146 int hover_parent_w, hover_parent_h, obj_h, obj_w, obj_y, win_y_offset;
147 int current_height, h;
148 sd->item = elm_genlist_first_item_get(sd->genlist);
149 //FIXME:- the height of item is zero, sometimes.
150 evas_object_geometry_get(elm_object_item_track(sd->item), NULL, NULL,
151 NULL, &h);
152 if (h) sd->item_height = h;
153 evas_object_geometry_get(elm_object_part_content_get(data, "elm.swallow.content"),
154 NULL, NULL, &obj_w, NULL);
155 evas_object_geometry_get(data, NULL, &obj_y, NULL, &obj_h);
156 evas_object_geometry_get(sd->hover_parent, NULL, NULL, &hover_parent_w,
157 &hover_parent_h);
158 current_height = sd->item_height * sd->count;
159 sd->best_location = elm_hover_best_content_location_get(sd->hover,
160 ELM_HOVER_AXIS_VERTICAL);
161 if (sd->best_location && !strcmp(sd->best_location , "bottom"))
162 win_y_offset = hover_parent_h - obj_y - obj_h;
163 else win_y_offset = obj_y;
164
165 if (current_height < win_y_offset)
166 evas_object_size_hint_min_set(sd->spacer, obj_w * elm_config_scale_get(),
167 current_height + (2 * elm_config_scale_get()));
168 else evas_object_size_hint_min_set(sd->spacer, obj_w * elm_config_scale_get(),
169 win_y_offset * elm_config_scale_get());
170 }
171}
172
173static void
174_activate(Evas_Object *obj)
175{
176 ELM_COMBOBOX_DATA_GET(obj, sd);
177 if (elm_widget_disabled_get(obj)) return;
178
179 if (sd->expanded)
180 {
181 elm_combobox_hover_end(obj);
182 return;
183 }
184
185 sd->expanded = EINA_TRUE;
186
187 if (sd->count <= 0) return;
188
189 _table_resize(obj);
190 elm_object_part_content_set(sd->hover, sd->best_location, sd->tbl);
191 evas_object_show(sd->genlist);
192 elm_genlist_item_selected_set(sd->item, EINA_TRUE);
193 evas_object_show(sd->hover);
194 eo_event_callback_call(obj, ELM_COMBOBOX_EVENT_EXPANDED, NULL);
195}
196
197static void
198_on_item_selected(void *data , Evas_Object *obj EINA_UNUSED, void *event)
199{
200 ELM_COMBOBOX_DATA_GET(data, sd);
201
202 if (!sd->multiple_selection) elm_object_focus_set(sd->entry, EINA_TRUE);
203 else
204 {
205 elm_genlist_item_bring_in(sd->item, ELM_GENLIST_ITEM_SCROLLTO_TOP);
206 elm_object_focus_set(sd->mbe, EINA_TRUE);
207 }
208 eo_event_callback_call(data, ELM_COMBOBOX_EVENT_ITEM_SELECTED, event);
209}
210
211static void
212_on_item_pressed(void *data , Evas_Object *obj EINA_UNUSED, void *event)
213{
214 eo_event_callback_call(data, ELM_COMBOBOX_EVENT_ITEM_PRESSED, event);
215}
216
217static Eina_Bool
218_gl_filter_finished_cb(void *data, const Eo_Event *event)
219{
220 char buf[1024];
221 ELM_COMBOBOX_DATA_GET(data, sd);
222
223 count_items_genlist(data);
224
225 if (sd->first_filter)
226 {
227 sd->first_filter = EINA_FALSE;
228 return EINA_TRUE;
229 }
230
231 eo_event_callback_call(data, ELM_COMBOBOX_EVENT_FILTER_DONE, event->event_info);
232
233 if (sd->count > 0)
234 {
235 if (!sd->expanded) _activate(data);
236 else _table_resize(data);
237 elm_genlist_item_selected_set(sd->item, EINA_TRUE);
238 }
239 else
240 {
241 sd->expanded = EINA_FALSE;
242 elm_layout_signal_emit(sd->hover, "elm,action,hide,no_animate", "elm");
243 snprintf(buf, sizeof(buf), "elm,action,slot,%s,hide", sd->best_location);
244 elm_layout_signal_emit(sd->hover, buf, "elm");
245 edje_object_message_signal_process(elm_layout_edje_get(sd->hover));
246 }
247
248 return EINA_TRUE;
249}
250
251static Eina_Bool
252_on_aborted(void *data, const Eo_Event *event EINA_UNUSED)
253{
254 ELM_COMBOBOX_DATA_GET(data, sd);
255 if (sd->expanded) elm_combobox_hover_end(data);
256 return EINA_TRUE;
257}
258
259static Eina_Bool
260_on_changed(void *data, const Eo_Event *event EINA_UNUSED)
261{
262 eo_event_callback_call(data, ELM_ENTRY_EVENT_CHANGED, NULL);
263 return EINA_TRUE;
264}
265
266static Eina_Bool
267_on_clicked(void *data, const Eo_Event *event EINA_UNUSED)
268{
269 elm_combobox_hover_begin(data);
270 return EINA_TRUE;
271}
272
273EOLIAN static void
274_elm_combobox_evas_object_smart_add(Eo *obj, Elm_Combobox_Data *sd EINA_UNUSED)
275{
276 evas_obj_smart_add(eo_super(obj, MY_CLASS));
277 elm_widget_sub_object_parent_add(obj);
278
279 elm_widget_mirrored_automatic_set(obj, EINA_FALSE);
280
281 eo_event_callback_add(obj, EVAS_CLICKABLE_INTERFACE_EVENT_CLICKED, _on_clicked, obj);
282
283 //What are you doing here?
284 elm_obj_widget_theme_apply(obj);
285}
286
287EOLIAN static void
288_elm_combobox_evas_object_smart_del(Eo *obj, Elm_Combobox_Data *sd)
289{
290 sd->hover_parent = NULL;
291 evas_obj_smart_del(eo_super(obj, MY_CLASS));
292}
293
294EOLIAN static void
295_elm_combobox_evas_object_smart_show(Eo *obj, Elm_Combobox_Data *sd)
296{
297 evas_obj_smart_show(eo_super(obj, MY_CLASS));
298 if (sd->expanded) evas_object_show(sd->hover);
299}
300
301EOLIAN static void
302_elm_combobox_evas_object_smart_hide(Eo *obj, Elm_Combobox_Data *sd)
303{
304 evas_obj_smart_hide(eo_super(obj, MY_CLASS));
305 if (sd->hover) evas_object_hide(sd->hover);
306}
307
308EOLIAN static Eina_Bool
309_elm_combobox_elm_button_admits_autorepeat_get(Eo *obj EINA_UNUSED,
310 Elm_Combobox_Data *sd EINA_UNUSED)
311{
312 return EINA_FALSE;
313}
314
315EOLIAN static Eina_Bool
316_elm_combobox_multiple_selection_get(Eo *obj EINA_UNUSED, Elm_Combobox_Data *pd)
317{
318 return pd->multiple_selection;
319}
320
321static Eina_Bool
322_mbe_clicked_cb(void *data EINA_UNUSED, const Eo_Event *event)
323{
324 //Unset the multibuttonentry to contracted mode of single line
325 elm_multibuttonentry_expanded_set(event->obj, EINA_TRUE);
326 return EINA_TRUE;
327}
328
329static Eina_Bool
330_mbe_focused_cb(void *data EINA_UNUSED, const Eo_Event *event EINA_UNUSED)
331{
332 return EINA_TRUE;
333}
334
335static Eina_Bool
336_mbe_unfocused_cb(void *data EINA_UNUSED, const Eo_Event *event)
337{
338 //Set the multibuttonentry to contracted mode of single line
339 elm_multibuttonentry_expanded_set(event->obj, EINA_FALSE);
340 return EINA_TRUE;
341}
342
343static Eina_Bool
344_mbe_item_added(void *data, const Eo_Event *event EINA_UNUSED)
345{
346 ELM_COMBOBOX_DATA_GET(data, sd);
347 elm_genlist_filter_set(sd->genlist, NULL);
348 return EINA_TRUE;
349}
350
351EO_CALLBACKS_ARRAY_DEFINE(mbe_callbacks,
352 { EVAS_CLICKABLE_INTERFACE_EVENT_CLICKED, _mbe_clicked_cb },
353 { ELM_WIDGET_EVENT_FOCUSED, _mbe_focused_cb },
354 { ELM_WIDGET_EVENT_UNFOCUSED, _mbe_unfocused_cb },
355 { ELM_MULTIBUTTONENTRY_EVENT_ITEM_ADDED , _mbe_item_added });
356
357EO_CALLBACKS_ARRAY_DEFINE(entry_callbacks,
358 { ELM_ENTRY_EVENT_CHANGED_USER, _on_changed },
359 { ELM_ENTRY_EVENT_ABORTED, _on_aborted });
360
361EOLIAN static void
362_elm_combobox_multiple_selection_set(Eo *obj, Elm_Combobox_Data *pd,
363 Eina_Bool enabled)
364{
365 Evas_Object* scr;
366
367 pd->multiple_selection = enabled;
368
369 if (enabled)
370 {
371 // This is multibuttonentry object that will take over the MBE call
372 pd->mbe = eo_add(ELM_MULTIBUTTONENTRY_CLASS, obj);
373 evas_object_size_hint_weight_set(pd->mbe, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
374 evas_object_size_hint_align_set(pd->mbe, EVAS_HINT_FILL, EVAS_HINT_FILL);
375 eo_event_callback_array_add(elm_multibuttonentry_entry_get(pd->mbe), entry_callbacks(), obj);
376 eo_event_callback_array_add(pd->mbe, mbe_callbacks(), obj);
377
378 pd->entry = elm_object_part_content_unset(obj, "elm.swallow.content");
379 elm_object_text_set(pd->mbe, elm_object_part_text_get(pd->entry, NULL));
380 elm_object_part_text_set(pd->mbe, "guide", elm_object_part_text_get(pd->entry,
381 "guide"));
382 evas_object_hide(pd->entry);
383 eo_composite_attach(obj, pd->mbe);
384
385 scr = elm_scroller_add(obj);
386 elm_scroller_bounce_set(scr, EINA_FALSE, EINA_TRUE);
387 elm_scroller_policy_set(scr, ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_AUTO);
388 evas_object_size_hint_weight_set(scr, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
389 evas_object_size_hint_align_set(scr, EVAS_HINT_FILL, EVAS_HINT_FILL);
390 evas_object_show(scr);
391 elm_object_content_set(scr, pd->mbe);
392 elm_object_part_content_set(obj, "elm.swallow.content", scr);
393 elm_widget_can_focus_set(pd->genlist, EINA_FALSE);
394 }
395 else
396 {
397 scr = elm_object_part_content_unset(obj, "elm.swallow.content");
398 elm_object_part_content_set(obj, "elm.swallow.content", pd->entry);
399 elm_object_text_set(pd->entry, elm_object_part_text_get(pd->mbe, NULL));
400 elm_object_part_text_set(pd->entry, "guide",
401 elm_object_part_text_get(pd->mbe, "guide"));
402 elm_widget_can_focus_set(pd->genlist, EINA_TRUE);
403 elm_genlist_item_bring_in(pd->item, ELM_GENLIST_ITEM_SCROLLTO_NONE);
404 evas_object_hide(scr);
405 }
406}
407
408EAPI Evas_Object *
409elm_combobox_add(Evas_Object *parent)
410{
411 EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
412 Evas_Object *obj = eo_add(MY_CLASS, parent);
413 return obj;
414}
415
416EOLIAN static Eo *
417_elm_combobox_eo_base_constructor(Eo *obj, Elm_Combobox_Data *sd)
418{
419 Evas_Object *gl;
420 Evas_Object *entry;
421 char buf[128];
422
423 obj = eo_constructor(eo_super(obj, MY_CLASS));
424
425 sd->first_filter = EINA_TRUE;
426
427 evas_obj_type_set(obj, MY_CLASS_NAME_LEGACY);
428 evas_obj_smart_callbacks_descriptions_set(obj, _smart_callbacks);
429 elm_interface_atspi_accessible_role_set(obj, ELM_ATSPI_ROLE_GLASS_PANE);
430
431 //hover-parent
432 sd->hover_parent = elm_object_parent_widget_get(obj);
433
434 //hover
435 sd->hover = eo_add(ELM_HOVER_CLASS, sd->hover_parent);
436 elm_widget_mirrored_automatic_set(sd->hover, EINA_FALSE);
437 elm_hover_target_set(sd->hover, obj);
438 snprintf(buf, sizeof(buf), "combobox_vertical/%s",
439 elm_widget_style_get(obj));
440 elm_object_style_set(sd->hover, buf);
441
442 eo_event_callback_add
443 (sd->hover, EVAS_CLICKABLE_INTERFACE_EVENT_CLICKED, _on_hover_clicked, obj);
444 elm_layout_signal_callback_add
445 (sd->hover, "elm,action,hide,finished", "elm", _hover_end_finished, obj);
446
447 //table
448 sd->tbl = elm_table_add(obj);
449 evas_object_size_hint_weight_set(sd->tbl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
450 evas_object_size_hint_align_set(sd->tbl, EVAS_HINT_FILL, EVAS_HINT_FILL);
451
452 //spacer
453 sd->spacer = evas_object_rectangle_add(evas_object_evas_get(sd->hover_parent));
454 evas_object_size_hint_weight_set(sd->spacer, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
455 evas_object_size_hint_align_set(sd->spacer, EVAS_HINT_FILL, EVAS_HINT_FILL);
456 evas_object_color_set(sd->spacer, 0, 0, 0, 0);
457 elm_table_pack(sd->tbl, sd->spacer, 0, 0, 1, 1);
458
459 // This is the genlist object that will take over the genlist call
460 sd->genlist = gl = eo_add(ELM_GENLIST_CLASS, obj);
461 elm_genlist_filter_set(gl, NULL);
462 elm_widget_mirrored_automatic_set(gl, EINA_FALSE);
463 elm_widget_mirrored_set(gl, elm_widget_mirrored_get(obj));
464 evas_object_size_hint_weight_set(gl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
465 evas_object_size_hint_align_set(gl, EVAS_HINT_FILL, EVAS_HINT_FILL);
466 evas_object_smart_callback_add(gl, "selected", _on_item_selected, obj);
467 evas_object_smart_callback_add(gl, "pressed", _on_item_pressed, obj);
468 eo_event_callback_add(gl, ELM_GENLIST_EVENT_FILTER_DONE, _gl_filter_finished_cb, obj);
469 elm_genlist_homogeneous_set(gl, EINA_TRUE);
470 elm_genlist_mode_set(gl, ELM_LIST_COMPRESS);
471 elm_table_pack(sd->tbl, gl, 0, 0, 1, 1);
472
473 // This is the entry object that will take over the entry call
474 sd->entry = entry = eo_add(ELM_ENTRY_CLASS, obj);
475 elm_widget_mirrored_automatic_set(entry, EINA_FALSE);
476 elm_widget_mirrored_set(entry, elm_widget_mirrored_get(obj));
477 elm_scroller_policy_set(entry, ELM_SCROLLER_POLICY_OFF,
478 ELM_SCROLLER_POLICY_OFF);
479 elm_entry_scrollable_set(entry, EINA_TRUE);
480 elm_entry_single_line_set(entry, EINA_TRUE);
481 eo_event_callback_array_add(entry, entry_callbacks(), obj);
482 evas_object_show(entry);
483
484 eo_composite_attach(obj, gl);
485 eo_composite_attach(obj, entry);
486
487 elm_object_part_content_set(obj, "elm.swallow.content", entry);
488 return obj;
489}
490
491EOLIAN static void
492_elm_combobox_hover_begin(Eo *obj, Elm_Combobox_Data *sd)
493{
494 if (!sd->hover) return;
495
496 if (sd->multiple_selection)
497 elm_object_focus_set(sd->mbe, EINA_TRUE);
498 else elm_object_focus_set(sd->entry, EINA_TRUE);
499
500 _activate(obj);
501}
502
503EOLIAN static void
504_elm_combobox_hover_end(Eo *obj, Elm_Combobox_Data *sd)
505{
506 const char *dismissstr;
507 if (!sd->hover) return;
508 dismissstr = elm_layout_data_get(sd->hover, "dismiss");
509
510 if (dismissstr && !strcmp(dismissstr, "on"))
511 elm_hover_dismiss(sd->hover);
512 else
513 {
514 sd->expanded = EINA_FALSE;
515 evas_object_hide(sd->hover);
516 eo_event_callback_call(obj, ELM_COMBOBOX_EVENT_DISMISSED, NULL);
517 } // for backward compatibility
518}
519
520EOLIAN static Eina_Bool
521_elm_combobox_expanded_get(Eo *obj EINA_UNUSED, Elm_Combobox_Data *sd)
522{
523 return sd->expanded;
524}
525
526static Eina_Bool
527_key_action_move(Evas_Object *obj, const char *params)
528{
529 ELM_COMBOBOX_DATA_GET(obj, sd);
530 Elm_Object_Item *it = NULL;
531 const char *dir = params;
532 if (!sd->hover) return EINA_FALSE;
533
534 if (!strcmp(dir, "up"))
535 {
536 it = sd->item;
537 it = elm_genlist_item_prev_get(it);
538 if (!it) sd->item = elm_genlist_last_item_get(sd->genlist);
539 else sd->item = it;
540 elm_genlist_item_selected_set(sd->item, EINA_TRUE);
541 }
542 else if (!strcmp(dir, "down"))
543 {
544 it = sd->item;
545 it = elm_genlist_item_next_get(it);
546 if (!it) sd->item = elm_genlist_first_item_get(sd->genlist);
547 else sd->item = it;
548 elm_genlist_item_selected_set(sd->item, EINA_TRUE);
549 }
550 else return EINA_FALSE;
551 return EINA_TRUE;
552}
553
554static Eina_Bool
555_key_action_activate(Evas_Object *obj, const char *params EINA_UNUSED)
556{
557 ELM_COMBOBOX_DATA_GET(obj, sd);
558 if (!sd->expanded)
559 elm_combobox_hover_begin(obj);
560 else
561 {
562 eo_event_callback_call(sd->genlist, EVAS_CLICKABLE_INTERFACE_EVENT_PRESSED, sd->item);
563 elm_entry_cursor_end_set(sd->entry);
564 }
565 return EINA_TRUE;
566}
567
568EOLIAN static Eina_Bool
569_elm_combobox_elm_widget_event(Eo *obj, Elm_Combobox_Data *sd,
570 Evas_Object *src EINA_UNUSED,
571 Evas_Callback_Type type, void *event_info)
572{
573 Evas_Event_Key_Down *ev = event_info;
574 if (!sd || !sd->hover) return EINA_FALSE;
575 if (type != EVAS_CALLBACK_KEY_DOWN) return EINA_FALSE;
576 if (ev->event_flags & EVAS_EVENT_FLAG_ON_HOLD) return EINA_FALSE;
577 if (!_elm_config_key_binding_call(obj, MY_CLASS_NAME, ev, key_actions))
578 return EINA_FALSE;
579
580 ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD;
581 return EINA_TRUE;
582}
583
584static void
585_elm_combobox_class_constructor(Eo_Class *klass)
586{
587 evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
588}
589
590EOLIAN const Elm_Atspi_Action *
591_elm_combobox_elm_interface_atspi_widget_action_elm_actions_get(Eo *obj EINA_UNUSED,
592 Elm_Combobox_Data *pd
593 EINA_UNUSED)
594{
595 static Elm_Atspi_Action atspi_actions[] = {
596 {"activate", "activate", "return", _key_action_activate},
597 {"move,up", "move", "up", _key_action_move},
598 {"move,down", "move", "down", _key_action_move},
599 {NULL, NULL, NULL, NULL}
600 };
601 return &atspi_actions[0];
602}
603
604EOLIAN void
605_elm_combobox_elm_genlist_filter_set(Eo *obj EINA_UNUSED, Elm_Combobox_Data *pd, void *key)
606{
607 pd->first_filter = EINA_FALSE;
608
609 elm_obj_genlist_filter_set(pd->genlist, key);
610}
611
612EOLIAN void
613_elm_combobox_elm_widget_part_text_set(Eo *obj EINA_UNUSED, Elm_Combobox_Data *pd,
614 const char * part, const char *label)
615{
616 if (pd->multiple_selection) elm_object_part_text_set(pd->mbe, part, label);
617 else elm_object_part_text_set(pd->entry, part, label);
618}
619
620EOLIAN const char *
621_elm_combobox_elm_widget_part_text_get(Eo *obj EINA_UNUSED, Elm_Combobox_Data *pd,
622 const char * part)
623{
624 if (pd->multiple_selection) return elm_object_part_text_get(pd->mbe, part);
625 return elm_object_part_text_get(pd->entry, part);
626}
627
628EOLIAN static void
629_elm_combobox_evas_object_smart_resize(Eo *obj, Elm_Combobox_Data *pd,
630 Evas_Coord w, Evas_Coord h)
631{
632 evas_obj_smart_resize(eo_super(obj, MY_CLASS), w, h);
633 if (pd->count > 0) _table_resize(obj);
634}
635#include "elm_combobox.eo.c"
diff --git a/src/lib/elementary/elc_combobox.h b/src/lib/elementary/elc_combobox.h
new file mode 100644
index 0000000..006280b
--- /dev/null
+++ b/src/lib/elementary/elc_combobox.h
@@ -0,0 +1,64 @@
1/**
2 * @defgroup Elm_Combobox Combobox
3 * @ingroup Elementary
4 *
5 * @image html combobox_inheritance_tree.png
6 * @image latex combobox_inheritance_tree.eps
7 *
8 * @image html img/widget/combobox/preview-00.png
9 * @image latex img/widget/combobox/preview-00.eps
10 *
11 * A combobox is a button displaying an entry that pops up a list of items
12 * (automatically choosing the direction to display). It is a convenience
13 * widget to avoid the need to do all the piecing together yourself. It is
14 * intended for manipulating a large number of items in the combobox menu.
15 *
16 * This widget inherits from the @ref Button, @ref Genlist and @ref Entry
17 * one, so that all the functions acting on it also work for combobox objects.
18 *
19 * This widget emits the following signals, besides the ones sent from
20 * @ref Button:
21 * - @c "clicked" - the user clicked the combobox button and popped up
22 * the sel
23 * - @c "selected" - an item in the combobox list is selected. event_info
24 * is the selected item
25 * - @c "dismissed" - the hover is dismissed
26 * - @c "expanded" - This is called on clicking combobox and elm_combobox_hover_begin().
27 * - @c "language,changed" - the program's language changed.
28 * - @c "item,pressed" - When the combobox item is pressed.
29 * - @c "filter,done" - When the combobox completes the filter process.
30 *
31 * Default content parts of the combobox widget that you can use are the
32 * the same that you use with the @ref Button
33 *
34 * Default text parts of the combobox widget that you can use are the
35 * the same that you use with the @ref Entry
36 *
37 * Supported elm_object common APIs.
38 * @li @ref elm_object_disabled_set
39 * @li @ref elm_object_disabled_get
40 * @li @ref elm_object_part_text_set
41 * @li @ref elm_object_part_text_get
42 * @li @ref elm_object_part_content_set
43 * @li @ref elm_object_part_content_unset
44 *
45 * Supported elm_object_item common APIs.
46 * @li elm_object_item_del
47 * @li elm_object_item_part_text_get
48 * @li elm_object_item_signal_emit - this works only when the item is created.
49 * @li elm_object_item_style_set - this works only when the item is created.
50 * @li elm_object_item_style_get - this works only when the item is created.
51 *
52 * See @ref tutorial_combobox for an example.
53 * @{
54 */
55
56#ifdef EFL_EO_API_SUPPORT
57#include "elm_combobox.eo.h"
58#endif
59#ifndef EFL_NOLEGACY_API_SUPPORT
60#include "elc_combobox_legacy.h"
61#endif
62/**
63 * @}
64 */
diff --git a/src/lib/elementary/elc_combobox_legacy.h b/src/lib/elementary/elc_combobox_legacy.h
new file mode 100644
index 0000000..21e888f
--- /dev/null
+++ b/src/lib/elementary/elc_combobox_legacy.h
@@ -0,0 +1,11 @@
1/**
2 * @brief Add a new Combobox object
3 *
4 * @param parent The parent object
5 * @return The new object or NULL if it cannot be created
6 *
7 * @ingroup Elm_Combobox
8 */
9EAPI Evas_Object *elm_combobox_add(Evas_Object *parent);
10
11#include "elm_combobox.eo.legacy.h"
diff --git a/src/lib/elementary/elc_ctxpopup.c b/src/lib/elementary/elc_ctxpopup.c
new file mode 100644
index 0000000..89bbefa
--- /dev/null
+++ b/src/lib/elementary/elc_ctxpopup.c
@@ -0,0 +1,1479 @@
1#ifdef HAVE_CONFIG_H
2# include "elementary_config.h"
3#endif
4
5#define ELM_INTERFACE_ATSPI_ACCESSIBLE_PROTECTED
6#define ELM_INTERFACE_ATSPI_WIDGET_ACTION_PROTECTED
7
8#define ELM_WIDGET_ITEM_PROTECTED
9#include <Elementary.h>
10
11#include "elm_priv.h"
12#include "elm_widget_ctxpopup.h"
13
14#define MY_CLASS ELM_CTXPOPUP_CLASS
15
16#define MY_CLASS_NAME "Elm_Ctxpopup"
17#define MY_CLASS_NAME_LEGACY "elm_ctxpopup"
18
19EAPI const char ELM_CTXPOPUP_SMART_NAME[] = "elm_ctxpopup";
20
21#define ELM_PRIV_CTXPOPUP_SIGNALS(cmd) \
22 cmd(SIG_DISMISSED, "dismissed", "") \
23 cmd(SIG_GEOMETRY_UPDATE, "geometry,update", "") \
24
25
26ELM_PRIV_CTXPOPUP_SIGNALS(ELM_PRIV_STATIC_VARIABLE_DECLARE);
27
28static const Evas_Smart_Cb_Description _smart_callbacks[] = {
29 ELM_PRIV_CTXPOPUP_SIGNALS(ELM_PRIV_SMART_CALLBACKS_DESC)
30 {SIG_WIDGET_LANG_CHANGED, ""}, /**< handled by elm_widget */
31 {SIG_WIDGET_ACCESS_CHANGED, ""}, /**< handled by elm_widget */
32 {SIG_LAYOUT_FOCUSED, ""}, /**< handled by elm_layout */
33 {SIG_LAYOUT_UNFOCUSED, ""}, /**< handled by elm_layout */
34 {NULL, NULL}
35};
36#undef ELM_PRIV_CTXPOPUP_SIGNALS
37
38static Eina_Bool _key_action_move(Evas_Object *obj, const char *params);
39static Eina_Bool _key_action_escape(Evas_Object *obj, const char *params);
40
41static const Elm_Action key_actions[] = {
42 {"move", _key_action_move},
43 {"escape", _key_action_escape},
44 {NULL, NULL}
45};
46
47EOLIAN static Eina_Bool
48_elm_ctxpopup_elm_widget_translate(Eo *obj, Elm_Ctxpopup_Data *sd)
49{
50 Eina_List *l;
51 Elm_Object_Item *it;
52
53 if (sd->auto_hide) evas_object_hide(obj);
54
55 EINA_LIST_FOREACH(sd->items, l, it)
56 elm_wdg_item_translate(it);
57
58 elm_obj_widget_translate(eo_super(obj, MY_CLASS));
59
60 return EINA_TRUE;
61}
62
63EOLIAN static Eina_Bool
64_elm_ctxpopup_elm_widget_focus_next_manager_is(Eo *obj EINA_UNUSED, Elm_Ctxpopup_Data *_pd EINA_UNUSED)
65{
66 return EINA_TRUE;
67}
68
69EOLIAN static Eina_Bool
70_elm_ctxpopup_elm_widget_focus_direction_manager_is(Eo *obj EINA_UNUSED, Elm_Ctxpopup_Data *_pd EINA_UNUSED)
71{
72 return EINA_TRUE;
73}
74
75EOLIAN static Eina_Bool
76_elm_ctxpopup_elm_widget_focus_next(Eo *obj EINA_UNUSED, Elm_Ctxpopup_Data *sd, Elm_Focus_Direction dir, Evas_Object **next, Elm_Object_Item **next_item)
77{
78 if (!sd)
79 return EINA_FALSE;
80
81 if (!elm_widget_focus_next_get(sd->box, dir, next, next_item))
82 {
83 elm_widget_focused_object_clear(sd->box);
84 elm_widget_focus_next_get(sd->box, dir, next, next_item);
85 }
86
87 return EINA_TRUE;
88}
89
90EOLIAN static Eina_Bool
91_elm_ctxpopup_elm_widget_focus_direction(Eo *obj EINA_UNUSED, Elm_Ctxpopup_Data *sd, const Evas_Object *base, double degree, Evas_Object **direction, Elm_Object_Item **direction_item, double *weight)
92{
93 Eina_Bool int_ret;
94
95 Eina_List *l = NULL;
96 void *(*list_data_get)(const Eina_List *list);
97
98 if (!sd)
99 return EINA_FALSE;
100
101 list_data_get = eina_list_data_get;
102
103 l = eina_list_append(l, sd->box);
104
105 int_ret = elm_widget_focus_list_direction_get
106 (obj, base, l, list_data_get, degree, direction, direction_item, weight);
107 eina_list_free(l);
108
109 return int_ret;
110}
111
112static Eina_Bool
113_key_action_move(Evas_Object *obj, const char *params)
114{
115 ELM_CTXPOPUP_DATA_GET(obj, sd);
116 const char *dir = params;
117
118 if (!sd->box) return EINA_FALSE;
119
120 _elm_widget_focus_auto_show(obj);
121 if (!strcmp(dir, "previous"))
122 elm_widget_focus_cycle(sd->box, ELM_FOCUS_PREVIOUS);
123 else if (!strcmp(dir, "next"))
124 elm_widget_focus_cycle(sd->box, ELM_FOCUS_NEXT);
125 else if (!strcmp(dir, "left"))
126 elm_widget_focus_cycle(sd->box, ELM_FOCUS_LEFT);
127 else if (!strcmp(dir, "right"))
128 elm_widget_focus_cycle(sd->box, ELM_FOCUS_RIGHT);
129 else if (!strcmp(dir, "up"))
130 elm_widget_focus_cycle(sd->box, ELM_FOCUS_UP);
131 else if (!strcmp(dir, "down"))
132 elm_widget_focus_cycle(sd->box, ELM_FOCUS_DOWN);
133 else return EINA_FALSE;
134
135 return EINA_TRUE;
136}
137
138static Eina_Bool
139_key_action_escape(Evas_Object *obj, const char *params EINA_UNUSED)
140{
141 elm_ctxpopup_dismiss(obj);
142 return EINA_TRUE;
143}
144
145EOLIAN static Eina_Bool
146_elm_ctxpopup_elm_widget_event(Eo *obj, Elm_Ctxpopup_Data *sd EINA_UNUSED, Evas_Object *src, Evas_Callback_Type type, void *event_info)
147{
148 Evas_Event_Key_Down *ev = event_info;
149 (void)src;
150
151 if (type != EVAS_CALLBACK_KEY_DOWN) return EINA_FALSE;
152 if (ev->event_flags & EVAS_EVENT_FLAG_ON_HOLD) return EINA_FALSE;
153
154 if (!_elm_config_key_binding_call(obj, MY_CLASS_NAME, ev, key_actions))
155 return EINA_FALSE;
156
157 ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD;
158 return EINA_TRUE;
159}
160
161static void
162_x_pos_adjust(Evas_Coord_Point *pos,
163 Evas_Coord_Point *base_size,
164 Evas_Coord_Rectangle *hover_area)
165{
166 pos->x -= (base_size->x / 2);
167
168 if (pos->x < hover_area->x)
169 pos->x = hover_area->x;
170 else if ((pos->x + base_size->x) > (hover_area->x + hover_area->w))
171 pos->x = (hover_area->x + hover_area->w) - base_size->x;
172
173 if (base_size->x > hover_area->w)
174 base_size->x -= (base_size->x - hover_area->w);
175
176 if (pos->x < hover_area->x)
177 pos->x = hover_area->x;
178}
179
180static void
181_y_pos_adjust(Evas_Coord_Point *pos,
182 Evas_Coord_Point *base_size,
183 Evas_Coord_Rectangle *hover_area)
184{
185 pos->y -= (base_size->y / 2);
186
187 if (pos->y < hover_area->y)
188 pos->y = hover_area->y;
189 else if ((pos->y + base_size->y) > (hover_area->y + hover_area->h))
190 pos->y = hover_area->y + hover_area->h - base_size->y;
191
192 if (base_size->y > hover_area->h)
193 base_size->y -= (base_size->y - hover_area->h);
194
195 if (pos->y < hover_area->y)
196 pos->y = hover_area->y;
197}
198
199static Elm_Ctxpopup_Direction
200_base_geometry_calc(Evas_Object *obj,
201 Evas_Coord_Rectangle *rect)
202{
203 Elm_Ctxpopup_Direction dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
204 Evas_Coord_Rectangle hover_area;
205 Evas_Coord_Point pos = {0, 0};
206 Evas_Coord_Point arrow_size;
207 Evas_Coord_Point base_size;
208 Evas_Coord_Point max_size;
209 Evas_Coord_Point min_size;
210 Evas_Coord_Point temp;
211 int idx;
212
213 ELM_CTXPOPUP_DATA_GET(obj, sd);
214 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, ELM_CTXPOPUP_DIRECTION_DOWN);
215
216 if (!rect || !sd->parent) return ELM_CTXPOPUP_DIRECTION_DOWN;
217
218 edje_object_part_geometry_get(sd->arrow, "base", NULL, NULL,
219 &arrow_size.x, &arrow_size.y);
220 evas_object_resize(sd->arrow, arrow_size.x, arrow_size.y);
221
222 //Initialize Area Rectangle.
223 evas_object_geometry_get
224 (sd->parent, &hover_area.x, &hover_area.y, &hover_area.w,
225 &hover_area.h);
226 if (sd->parent && eo_isa(sd->parent, ELM_WIN_CLASS))
227 hover_area.x = hover_area.y = 0;
228
229 evas_object_geometry_get(obj, &pos.x, &pos.y, NULL, NULL);
230
231 //recalc the edje
232 edje_object_size_min_calc
233 (wd->resize_obj, &base_size.x, &base_size.y);
234 evas_object_smart_calculate(wd->resize_obj);
235
236 //Limit to Max Size
237 evas_object_size_hint_max_get(obj, &max_size.x, &max_size.y);
238
239 if ((max_size.y > 0) && (base_size.y > max_size.y))
240 base_size.y = max_size.y;
241
242 if ((max_size.x > 0) && (base_size.x > max_size.x))
243 base_size.x = max_size.x;
244 //Limit to Min Size
245 evas_object_size_hint_min_get(obj, &min_size.x, &min_size.y);
246
247 if ((min_size.y > 0) && (base_size.y < min_size.y))
248 base_size.y = min_size.y;
249
250 if ((min_size.x > 0) && (base_size.x < min_size.x))
251 base_size.x = min_size.x;
252
253 //Check available directions. If there is one, it adjusts ctxpopup's position
254 // and size.
255 for (idx = 0; idx < 4; idx++)
256 {
257 switch (sd->dir_priority[idx])
258 {
259 case ELM_CTXPOPUP_DIRECTION_UP:
260 temp.y = (pos.y - base_size.y);
261 if ((temp.y - arrow_size.y) < hover_area.y)
262 continue;
263
264 _x_pos_adjust(&pos, &base_size, &hover_area);
265 pos.y -= base_size.y;
266 dir = ELM_CTXPOPUP_DIRECTION_UP;
267 break;
268
269 case ELM_CTXPOPUP_DIRECTION_LEFT:
270 temp.x = (pos.x - base_size.x);
271 if ((temp.x - arrow_size.x) < hover_area.x)
272 continue;
273
274 _y_pos_adjust(&pos, &base_size, &hover_area);
275 pos.x -= base_size.x;
276 dir = ELM_CTXPOPUP_DIRECTION_LEFT;
277 break;
278
279 case ELM_CTXPOPUP_DIRECTION_RIGHT:
280 temp.x = (pos.x + base_size.x);
281 if ((temp.x + arrow_size.x) >
282 (hover_area.x + hover_area.w))
283 continue;
284
285 _y_pos_adjust(&pos, &base_size, &hover_area);
286 dir = ELM_CTXPOPUP_DIRECTION_RIGHT;
287 break;
288
289 case ELM_CTXPOPUP_DIRECTION_DOWN:
290 temp.y = (pos.y + base_size.y);
291 if ((temp.y + arrow_size.y) >
292 (hover_area.y + hover_area.h))
293 continue;
294
295 _x_pos_adjust(&pos, &base_size, &hover_area);
296 dir = ELM_CTXPOPUP_DIRECTION_DOWN;
297 break;
298
299 default:
300 continue;
301 }
302 break;
303 }
304
305 //In this case, all directions are invalid because of lack of space.
306 if (idx == 4)
307 {
308 Evas_Coord length[2];
309
310 if (!sd->horizontal)
311 {
312 length[0] = pos.y - hover_area.y;
313 length[1] = (hover_area.y + hover_area.h) - pos.y;
314
315 // ELM_CTXPOPUP_DIRECTION_UP
316 if (length[0] > length[1])
317 {
318 _x_pos_adjust(&pos, &base_size, &hover_area);
319 pos.y -= base_size.y;
320 dir = ELM_CTXPOPUP_DIRECTION_UP;
321 if (pos.y < (hover_area.y + arrow_size.y))
322 {
323 base_size.y -= ((hover_area.y + arrow_size.y) - pos.y);
324 pos.y = hover_area.y + arrow_size.y;
325 }
326 }
327 //ELM_CTXPOPUP_DIRECTION_DOWN
328 else
329 {
330 _x_pos_adjust(&pos, &base_size, &hover_area);
331 dir = ELM_CTXPOPUP_DIRECTION_DOWN;
332 if ((pos.y + arrow_size.y + base_size.y) >
333 (hover_area.y + hover_area.h))
334 base_size.y -=
335 ((pos.y + arrow_size.y + base_size.y) -
336 (hover_area.y + hover_area.h));
337 }
338 }
339 else
340 {
341 length[0] = pos.x - hover_area.x;
342 length[1] = (hover_area.x + hover_area.w) - pos.x;
343
344 //ELM_CTXPOPUP_DIRECTION_LEFT
345 if (length[0] > length[1])
346 {
347 _y_pos_adjust(&pos, &base_size, &hover_area);
348 pos.x -= base_size.x;
349 dir = ELM_CTXPOPUP_DIRECTION_LEFT;
350 if (pos.x < (hover_area.x + arrow_size.x))
351 {
352 base_size.x -= ((hover_area.x + arrow_size.x) - pos.x);
353 pos.x = hover_area.x + arrow_size.x;
354 }
355 }
356 //ELM_CTXPOPUP_DIRECTION_RIGHT
357 else
358 {
359 _y_pos_adjust(&pos, &base_size, &hover_area);
360 dir = ELM_CTXPOPUP_DIRECTION_RIGHT;
361 if (pos.x + (arrow_size.x + base_size.x) >
362 hover_area.x + hover_area.w)
363 base_size.x -=
364 ((pos.x + arrow_size.x + base_size.x) -
365 (hover_area.x + hover_area.w));
366 }
367 }
368 }
369
370 //Final position and size.
371 rect->x = pos.x;
372 rect->y = pos.y;
373 rect->w = base_size.x;
374 rect->h = base_size.y;
375
376 return dir;
377}
378
379static void
380_arrow_update(Evas_Object *obj,
381 Elm_Ctxpopup_Direction dir,
382 Evas_Coord_Rectangle base_size)
383{
384 Evas_Coord_Rectangle arrow_size;
385 Evas_Coord x, y;
386 double drag;
387
388 ELM_CTXPOPUP_DATA_GET(obj, sd);
389 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
390
391 evas_object_geometry_get(obj, &x, &y, NULL, NULL);
392 evas_object_geometry_get
393 (sd->arrow, NULL, NULL, &arrow_size.w, &arrow_size.h);
394
395 /* arrow is not being kept as sub-object on purpose, here. the
396 * design of the widget does not help with the contrary */
397
398 switch (dir)
399 {
400 case ELM_CTXPOPUP_DIRECTION_RIGHT:
401 edje_object_signal_emit(sd->arrow, "elm,state,left", "elm");
402 if (!edje_object_part_swallow(wd->resize_obj,
403 (elm_widget_mirrored_get(obj) ? "elm.swallow.arrow_right" :
404 "elm.swallow.arrow_left"), sd->arrow))
405 {
406 evas_object_hide(sd->arrow);
407 break;
408 }
409
410 if (base_size.h > 0)
411 {
412 if (y < ((arrow_size.h * 0.5) + base_size.y))
413 y = 0;
414 else if (y > base_size.y + base_size.h - (arrow_size.h * 0.5))
415 y = base_size.h - arrow_size.h;
416 else
417 y = y - base_size.y - (arrow_size.h * 0.5);
418 drag = (double)(y) / (double)(base_size.h - arrow_size.h);
419 edje_object_part_drag_value_set
420 (wd->resize_obj,
421 (elm_widget_mirrored_get(obj) ? "elm.swallow.arrow_right" :
422 "elm.swallow.arrow_left"), 1, drag);
423 }
424 break;
425
426 case ELM_CTXPOPUP_DIRECTION_LEFT:
427 edje_object_signal_emit(sd->arrow, "elm,state,right", "elm");
428 if (!edje_object_part_swallow(wd->resize_obj,
429 (elm_widget_mirrored_get(obj) ? "elm.swallow.arrow_left" :
430 "elm.swallow.arrow_right"), sd->arrow))
431 {
432 evas_object_hide(sd->arrow);
433 break;
434 }
435
436 if (base_size.h > 0)
437 {
438 if (y < ((arrow_size.h * 0.5) + base_size.y))
439 y = 0;
440 else if (y > (base_size.y + base_size.h - (arrow_size.h * 0.5)))
441 y = base_size.h - arrow_size.h;
442 else
443 y = y - base_size.y - (arrow_size.h * 0.5);
444 drag = (double)(y) / (double)(base_size.h - arrow_size.h);
445 edje_object_part_drag_value_set
446 (wd->resize_obj,
447 (elm_widget_mirrored_get(obj) ? "elm.swallow.arrow_left" :
448 "elm.swallow.arrow_right"), 0, drag);
449 }
450 break;
451
452 case ELM_CTXPOPUP_DIRECTION_DOWN:
453 edje_object_signal_emit(sd->arrow, "elm,state,top", "elm");
454 if (!edje_object_part_swallow(wd->resize_obj, "elm.swallow.arrow_up", sd->arrow))
455 {
456 evas_object_hide(sd->arrow);
457 break;
458 }
459
460 if (base_size.w > 0)
461 {
462 if (x < ((arrow_size.w * 0.5) + base_size.x))
463 x = 0;
464 else if (x > (base_size.x + base_size.w - (arrow_size.w * 0.5)))
465 x = base_size.w - arrow_size.w;
466 else
467 x = x - base_size.x - (arrow_size.w * 0.5);
468 drag = (double)(x) / (double)(base_size.w - arrow_size.w);
469 edje_object_part_drag_value_set
470 (wd->resize_obj, "elm.swallow.arrow_up", drag,
471 1);
472 }
473 break;
474
475 case ELM_CTXPOPUP_DIRECTION_UP:
476 edje_object_signal_emit(sd->arrow, "elm,state,bottom", "elm");
477 if (!edje_object_part_swallow(wd->resize_obj, "elm.swallow.arrow_down", sd->arrow))
478 {
479 evas_object_hide(sd->arrow);
480 break;
481 }
482
483 if (base_size.w > 0)
484 {
485 if (x < ((arrow_size.w * 0.5) + base_size.x))
486 x = 0;
487 else if (x > (base_size.x + base_size.w - (arrow_size.w * 0.5)))
488 x = base_size.w - arrow_size.w;
489 else x = x - base_size.x - (arrow_size.w * 0.5);
490 drag = (double)(x) / (double)(base_size.w - arrow_size.w);
491 edje_object_part_drag_value_set
492 (wd->resize_obj, "elm.swallow.arrow_down",
493 drag, 0);
494 }
495 break;
496
497 default:
498 break;
499 }
500
501 //should be here for getting accurate geometry value
502 evas_object_smart_calculate(wd->resize_obj);
503}
504
505static void
506_show_signals_emit(Evas_Object *obj,
507 Elm_Ctxpopup_Direction dir)
508{
509 ELM_CTXPOPUP_DATA_GET(obj, sd);
510
511 if (!sd->visible) return;
512 if ((sd->list) && (!sd->list_visible)) return;
513 if (sd->emitted) return;
514
515 sd->emitted = EINA_TRUE;
516 switch (dir)
517 {
518 case ELM_CTXPOPUP_DIRECTION_UP:
519 elm_layout_signal_emit(obj, "elm,state,show,up", "elm");
520 break;
521
522 case ELM_CTXPOPUP_DIRECTION_LEFT:
523 elm_layout_signal_emit(obj,
524 (elm_widget_mirrored_get(obj) ? "elm,state,show,right" :
525 "elm,state,show,left"), "elm");
526 break;
527
528 case ELM_CTXPOPUP_DIRECTION_RIGHT:
529 elm_layout_signal_emit(obj,
530 (elm_widget_mirrored_get(obj) ? "elm,state,show,left" :
531 "elm,state,show,right"), "elm");
532 break;
533
534 case ELM_CTXPOPUP_DIRECTION_DOWN:
535 elm_layout_signal_emit(obj, "elm,state,show,down", "elm");
536 break;
537
538 default:
539 break;
540 }
541
542 edje_object_signal_emit(sd->bg, "elm,state,show", "elm");
543 elm_layout_signal_emit(obj, "elm,state,show", "elm");
544}
545
546static void
547_hide_signals_emit(Evas_Object *obj,
548 Elm_Ctxpopup_Direction dir)
549{
550 ELM_CTXPOPUP_DATA_GET(obj, sd);
551
552 if (!sd->visible) return;
553
554 switch (dir)
555 {
556 case ELM_CTXPOPUP_DIRECTION_UP:
557 elm_layout_signal_emit(obj, "elm,state,hide,up", "elm");
558 break;
559
560 case ELM_CTXPOPUP_DIRECTION_LEFT:
561 elm_layout_signal_emit(obj,
562 (elm_widget_mirrored_get(obj) ? "elm,state,hide,right" :
563 "elm,state,hide,left"), "elm");
564 break;
565
566 case ELM_CTXPOPUP_DIRECTION_RIGHT:
567 elm_layout_signal_emit(obj,
568 (elm_widget_mirrored_get(obj) ? "elm,state,hide,left" :
569 "elm,state,hide,right"), "elm");
570 break;
571
572 case ELM_CTXPOPUP_DIRECTION_DOWN:
573 elm_layout_signal_emit(obj, "elm,state,hide,down", "elm");
574 break;
575
576 default:
577 break;
578 }
579 edje_object_signal_emit(sd->bg, "elm,state,hide", "elm");
580 elm_layout_signal_emit(obj, "elm,state,hide", "elm");
581}
582
583static void
584_base_shift_by_arrow(Evas_Object *arrow,
585 Elm_Ctxpopup_Direction dir,
586 Evas_Coord_Rectangle *rect)
587{
588 Evas_Coord arrow_w, arrow_h;
589
590 evas_object_geometry_get(arrow, NULL, NULL, &arrow_w, &arrow_h);
591 switch (dir)
592 {
593 case ELM_CTXPOPUP_DIRECTION_RIGHT:
594 rect->x += arrow_w;
595 break;
596
597 case ELM_CTXPOPUP_DIRECTION_LEFT:
598 rect->x -= arrow_w;
599 break;
600
601 case ELM_CTXPOPUP_DIRECTION_DOWN:
602 rect->y += arrow_h;
603 break;
604
605 case ELM_CTXPOPUP_DIRECTION_UP:
606 rect->y -= arrow_h;
607 break;
608
609 default:
610 break;
611 }
612}
613
614EOLIAN static Eina_Bool
615_elm_ctxpopup_elm_layout_sub_object_add_enable(Eo *obj EINA_UNUSED, Elm_Ctxpopup_Data *_pd EINA_UNUSED)
616{
617 return EINA_FALSE;
618}
619
620EOLIAN static Eina_Bool
621_elm_ctxpopup_elm_widget_sub_object_add(Eo *obj, Elm_Ctxpopup_Data *_pd EINA_UNUSED, Evas_Object *sobj)
622{
623 Eina_Bool int_ret = EINA_FALSE;
624
625 int_ret = elm_obj_widget_sub_object_add(eo_super(obj, MY_CLASS), sobj);
626
627 return int_ret;
628}
629
630EOLIAN static void
631_elm_ctxpopup_elm_layout_sizing_eval(Eo *obj, Elm_Ctxpopup_Data *sd)
632{
633 Evas_Coord_Rectangle rect = { 0, 0, 1, 1 };
634 Evas_Coord_Point list_size = { 0, 0 }, parent_size = {0, 0};
635
636 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
637
638 if (!sd->arrow) return; /* simple way to flag "under deletion" */
639 if (!sd->parent) return; /* do not calculate sizes unless parent is set */
640
641 //Base
642 sd->dir = _base_geometry_calc(obj, &rect);
643
644 _arrow_update(obj, sd->dir, rect);
645
646 _base_shift_by_arrow(sd->arrow, sd->dir, &rect);
647
648 if ((sd->list) && (sd->list_visible))
649 {
650 evas_object_geometry_get(sd->list, 0, 0, &list_size.x, &list_size.y);
651 if ((list_size.x >= rect.w) || (list_size.y >= rect.h))
652 {
653 elm_list_mode_set(sd->list, ELM_LIST_COMPRESS);
654 evas_object_size_hint_min_set(obj, list_size.x, list_size.y);
655 }
656 /*
657 Decrease height of main object initiate recalc of size (sizing_eval).
658 At each iteration of calculating size height of the object
659 will be closer to the height of the list.
660 */
661 if (list_size.y < rect.h) rect.h--;
662 }
663 else if (sd->content)
664 {
665 evas_object_geometry_get(sd->content, 0, 0, &list_size.x, &list_size.y);
666 if ((list_size.x >= rect.w) || (list_size.y >= rect.h))
667 evas_object_size_hint_min_set(obj, list_size.x, list_size.y);
668 }
669
670 evas_object_geometry_get(sd->parent, NULL, NULL, &parent_size.x, &parent_size.y);
671 evas_object_resize(sd->bg, parent_size.x, parent_size.y);
672
673 evas_object_move(wd->resize_obj, rect.x, rect.y);
674 evas_object_resize(wd->resize_obj, rect.w, rect.h);
675
676 _show_signals_emit(obj, sd->dir);
677
678 eo_event_callback_call(obj, ELM_CTXPOPUP_EVENT_GEOMETRY_UPDATE, &rect);
679}
680
681static void
682_on_parent_del(void *data,
683 Evas *e EINA_UNUSED,
684 Evas_Object *obj EINA_UNUSED,
685 void *event_info EINA_UNUSED)
686{
687 evas_object_del(data);
688}
689
690static void
691_on_parent_move(void *data,
692 Evas *e EINA_UNUSED,
693 Evas_Object *obj EINA_UNUSED,
694 void *event_info EINA_UNUSED)
695{
696 ELM_CTXPOPUP_DATA_GET(data, sd);
697
698 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
699
700 if (sd->visible) elm_layout_sizing_eval(data);
701}
702
703static void
704_on_parent_resize(void *data,
705 Evas *e EINA_UNUSED,
706 Evas_Object *obj EINA_UNUSED,
707 void *event_info EINA_UNUSED)
708{
709 ELM_CTXPOPUP_DATA_GET(data, sd);
710
711 if (sd->auto_hide)
712 {
713 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
714
715 evas_object_hide(data);
716 eo_event_callback_call(data, ELM_CTXPOPUP_EVENT_DISMISSED, NULL);
717 }
718 else
719 {
720 if (sd->visible)
721 elm_layout_sizing_eval(data);
722 }
723}
724
725static void
726_parent_detach(Evas_Object *obj)
727{
728 ELM_CTXPOPUP_DATA_GET(obj, sd);
729
730 if (!sd->parent) return;
731
732 evas_object_event_callback_del_full
733 (sd->parent, EVAS_CALLBACK_DEL, _on_parent_del, obj);
734 evas_object_event_callback_del_full
735 (sd->parent, EVAS_CALLBACK_MOVE, _on_parent_move, obj);
736 evas_object_event_callback_del_full
737 (sd->parent, EVAS_CALLBACK_RESIZE, _on_parent_resize, obj);
738}
739
740static void
741_on_content_resized(void *data,
742 Evas *e EINA_UNUSED,
743 Evas_Object *obj EINA_UNUSED,
744 void *event_info EINA_UNUSED)
745{
746 ELM_CTXPOPUP_DATA_GET(data, sd);
747
748 elm_box_recalculate(sd->box);
749 elm_layout_sizing_eval(data);
750}
751
752//FIXME: lost the content size when theme hook is called.
753EOLIAN static Eina_Bool
754_elm_ctxpopup_elm_widget_theme_apply(Eo *obj, Elm_Ctxpopup_Data *sd)
755{
756 Eina_Bool int_ret = EINA_FALSE;
757
758 int_ret = elm_obj_widget_theme_apply(eo_super(obj, MY_CLASS));
759 if (!int_ret) return EINA_FALSE;
760
761 elm_widget_theme_object_set
762 (obj, sd->bg, "ctxpopup", "bg", elm_widget_style_get(obj));
763 elm_widget_theme_object_set
764 (obj, sd->arrow, "ctxpopup", "arrow", elm_widget_style_get(obj));
765
766 if (sd->list)
767 {
768 if (!strncmp(elm_object_style_get(obj), "default", strlen("default")))
769 elm_object_style_set(sd->list, "ctxpopup");
770 else
771 elm_object_style_set(sd->list, elm_object_style_get(obj));
772 }
773
774 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
775
776 if (sd->visible) elm_layout_sizing_eval(obj);
777
778 return EINA_TRUE;
779}
780
781/* kind of a big and tricky override here: an internal box will hold
782 * the actual content. content aliases won't be of much help here */
783EOLIAN static Eina_Bool
784_elm_ctxpopup_elm_container_content_set(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part, Evas_Object *content)
785{
786 Eina_Bool int_ret = EINA_TRUE;
787
788 if ((part) && (strcmp(part, "default")))
789 {
790 int_ret = elm_obj_container_content_set(eo_super(obj, MY_CLASS), part, content);
791 return int_ret;
792 }
793
794 if (!content) return EINA_FALSE;
795
796 if (content == sd->content) return EINA_TRUE;
797
798 evas_object_del(sd->content);
799 if (sd->content == sd->list) sd->list = NULL;
800
801 evas_object_size_hint_weight_set
802 (content, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
803 evas_object_size_hint_fill_set
804 (content, EVAS_HINT_FILL, EVAS_HINT_FILL);
805
806 elm_box_pack_end(sd->box, content);
807 evas_object_show(content);
808
809 sd->content = content;
810 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
811
812 if (sd->visible) elm_layout_sizing_eval(obj);
813
814 return EINA_TRUE;
815}
816
817EOLIAN static Evas_Object*
818_elm_ctxpopup_elm_container_content_get(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part)
819{
820
821 if ((part) && (strcmp(part, "default")))
822 {
823 Evas_Object *ret = NULL;
824 ret = elm_obj_container_content_get(eo_super(obj, MY_CLASS), part);
825 return ret;
826 }
827
828 return sd->content;
829}
830
831EOLIAN static Evas_Object*
832_elm_ctxpopup_elm_container_content_unset(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part)
833{
834 Evas_Object *content = NULL;
835
836 if ((part) && (strcmp(part, "default")))
837 {
838 content = elm_obj_container_content_unset(eo_super(obj, MY_CLASS), part);
839 return content;
840 }
841
842 content = sd->content;
843 if (!content) return content;
844
845 elm_box_unpack(sd->box, content);
846 sd->content = NULL;
847 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
848
849 if (sd->visible) elm_layout_sizing_eval(obj);
850
851 return content;
852}
853
854EOLIAN static void
855_elm_ctxpopup_item_elm_widget_item_part_text_set(Eo *eo_ctxpopup_it EINA_UNUSED,
856 Elm_Ctxpopup_Item_Data *ctxpopup_it,
857 const char *part,
858 const char *label)
859{
860 if ((part) && (strcmp(part, "default"))) return;
861
862 ELM_CTXPOPUP_DATA_GET(WIDGET(ctxpopup_it), sd);
863
864 elm_object_item_part_text_set(ctxpopup_it->list_item, "default", label);
865 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
866
867 if (sd->visible) elm_layout_sizing_eval(WIDGET(ctxpopup_it));
868}
869
870EOLIAN static const char *
871_elm_ctxpopup_item_elm_widget_item_part_text_get(Eo *eo_ctxpopup_it EINA_UNUSED,
872 Elm_Ctxpopup_Item_Data *ctxpopup_it,
873 const char *part)
874{
875 if (part && strcmp(part, "default")) return NULL;
876
877 return elm_object_item_part_text_get(ctxpopup_it->list_item, "default");
878}
879
880EOLIAN static void
881_elm_ctxpopup_item_elm_widget_item_part_content_set(Eo *eo_ctxpopup_it EINA_UNUSED,
882 Elm_Ctxpopup_Item_Data *ctxpopup_it,
883 const char *part,
884 Evas_Object *content)
885{
886 if ((part) && (strcmp(part, "icon"))
887 && (strcmp(part, "start"))
888 && (strcmp(part, "end"))) return;
889
890 ELM_CTXPOPUP_DATA_GET(WIDGET(ctxpopup_it), sd);
891
892 if ((part) && (!strcmp(part, "end")))
893 elm_object_item_part_content_set(ctxpopup_it->list_item, "end", content);
894 else
895 elm_object_item_part_content_set
896 (ctxpopup_it->list_item, "start", content);
897
898 sd->dir = ELM_CTXPOPUP_DIRECTION_UNKNOWN;
899
900 if (sd->visible) elm_layout_sizing_eval(WIDGET(ctxpopup_it));
901}
902
903EOLIAN static Evas_Object *
904_elm_ctxpopup_item_elm_widget_item_part_content_get(Eo *eo_ctxpopup_it EINA_UNUSED,
905 Elm_Ctxpopup_Item_Data *ctxpopup_it,
906 const char *part)
907{
908 if (part && strcmp(part, "icon") && strcmp(part, "start")
909 && strcmp(part, "end")) return NULL;
910
911 if (part && !strcmp(part, "end"))