Commit Graph

54994 Commits

Author SHA1 Message Date
Carsten Haitzler 10ea932262 elm init - fix init seq and quicklaunch as we shut down x before evas
... and others. this leads to crashes if x ops are busy in a thread or
engine evas thread shutdown happens to call engine calls that then do
x calls... should apply in general to wl too. fixes some segv's on
shutdown given the new gl thread patches.

@fix
2017-08-23 17:25:43 +09:00
Jean-Philippe Andre 87aa053e58 elm_test: Remove calls to fill+expand (EO)
Wherever the EO API is used, i.e. efl_add() is used to create evas
objects, we can skip the calls to set fill/expand.

This new set of defaults indeed saves ~60 loc in the tests (out of 115
objects created). I found only 3 cases where the align had to be set
manually (to the old default of 0.5).

See 1a1b8bc451
And e8b7f5f255

Ref T5301
2017-08-23 15:57:49 +09:00
Jean-Philippe Andre e8b7f5f255 evas: Set default align to FILL for EO objects
See also 1a1b8bc451
2017-08-23 15:24:37 +09:00
Jean-Philippe Andre 29bacf5988 gfx: Remove size hint request (EO)
This hint is simply not supported by any container.
Add the EO API back if the containers support it.

Ref T5487
2017-08-23 15:24:37 +09:00
Jean-Philippe Andre 20e6c2e908 js: Fix javascript generator's compilation
javascript bindings are broken, because of function pointers but it
seems something else as well (Eina_Slice?).
2017-08-23 15:24:37 +09:00
Jean-Philippe Andre eb5d9a07ec ecore: Fix shadow warning (with nodejs enabled) 2017-08-23 15:24:37 +09:00
Jean-Philippe Andre cec45f616a js: Fix some js examples usage of orient API
This was not tested. How to test js?
2017-08-23 15:24:37 +09:00
Jean-Philippe Andre db4950ba2f efl: Remove Efl.Orientation horiz & vert (EO)
They are now replaced by Efl.Ui.Dir

NOTE: The name Efl.Ui.Dir is not satisfactory. Maybe we should use
Direction_Type or Direction_Value?

Ref T5870
2017-08-23 15:24:37 +09:00
Jean-Philippe Andre d28510a37b test: Fix EO API usage (direction) 2017-08-23 15:24:37 +09:00
JinYong Park 948d20ab54 test_check: fix build warning
Summary:  In state_changed_cb2 callback function, obj is used. so it should not be EINA_UNUSED

Reviewers: Jaehyun_Cho, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5122
2017-08-23 13:52:25 +09:00
JinYong Park 6f87330fe2 layout: call size calculating after text_set(NULL)
Summary:
When text set NULL, size is not changed even text is removed.
So, fix that case logic

1. send text,hidden signal
2. remove text
3. call sizing eval to resize layout

Test Plan:
1. run elementary_test -to check
2. change value last check object
3. compare before and after

Reviewers: Jaehyun_Cho, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5086
2017-08-23 13:29:14 +09:00
Jean-Philippe Andre 06ec847a7c widget: Use EO function pointer for on_show_region
This is as much a test of the EO function pointer as it is a clean up of
this widget API.
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 509ed86cdf widget: Remove unused legacy function name
Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 5cfd698894 win: Remove types socket and fake from EO
Fake: This should never have had the fake_canvas_set API. It already can
not work after efl_finalize. And Ecore_Evas isn't part of EO API so it
doesn't make sense at this point to try to expose the fake window as
part of EO API.

Socket: This is the only type of window that implements socket_listen.
So we can just move this function to a new subclass.

NOTE: Socket & plug are currently broken, even in 1.20 (at least for me)!

Ref T5322
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre e9dffa723d win: Add Efl.Ui.Win_Inlined and remove parent2
Inlined windows are the only use case for parent2. We might as well want
to create a separate subclass for those special windows.

Ref T5322
Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 964fafe429 widget: Remove parents_bounce from EO
It's specific to scroller and can be implemented there. Moved.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 6a08d4c519 widget: Remove inexisting property parent_widget
We also have widget_parent.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 3137c2c01e widget: Clean up doc for focus & focus_allow
I'm not sure about the name for focus_allow:
 - can_focus
 - focusable
 - focus_allow
 - ???

Also, it looks like focus should just be the evas object function
overridden.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre ef4cbfc9ff widget: Clean up orientation_mode_disabled
Only doc.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 560f7c0f3e config: Update default key bindings (class names)
See also the previous commit.
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre b588cefbae config: Automatically fix some key bindings
This changes the name used in the config file, without changing the
system config files yet. This restores key bindings for:
 - Win
 - Image
 - Video
 - Photocam

See also the previous commit.
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 031ae12c2f elm: Rename some EO widget class names
It was discussed a while ago that Zoomable was a poor name in some
languages, like python.

This changes, in Efl.Ui, to use underscores:
 - Image.Zoomable
 - Grid.Static
 - Box.Flow
 - Box.Stack
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre c4ac589455 widget: Remove all legacy event stuff in propagate
The EO API is now clean! Yay!

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 66d241eadf elm: Process all input events with EO
This removes all uses of type & event_info in the method widget_event.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre acdef50276 photocam: Fix key zoom in/out
Zoom +/- doesn't work well as this is a multiplication factor.

Test scenario:
 - elementary_test -to Photocam

Then click on the image, and press + or - on the keyboard.

@fix
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 20a5968c12 elm: Use a macro to handle key bindings
This factorizes the code and makes most widgets handle key down events
in the same way:
 - check that the object is not disabled, event is not on hold
 - figure out the key binding based on the class name
 - mark event as on hold

The class name is usually MY_CLASS_NAME but in some cases it was
MY_CLASS_NAME_LEGACY which may be different from the EO class name (eg.
elm_win vs. Efl.Ui.Win). In that case the key bindings are broken.

This breaks key bindings for the following widgets:
 - Win (focus)
 - Image ("clicked")
 - Video (move, play)

This fixes key bindings for the following widgets:
 - Nstate

Some widgets remain broken:
 - Photocam / Efl.Ui.Image.Zoomable

A patch will be applied to restore the key bindings for the above
breaks.
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 069747b9de widget: Add eo event info inside widget_event
This is an internal function that should probably become an overridable
protected method, as it's required for proper event handling in widgets.
Next step: use eo_event_info in the widgets implementations. Then remove
legacy event struct.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre e8826062eb eo: Define Efl.Event in EO
This can be used in the widgets propagation mechanism later. I don't see
any really good reason to not define this struct in EO anyway.

Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 47070c7d14 widget: Remove import edje_types from EO
Ref T5363
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 1a1b8bc451 evas: Set weight to "expand" by default
This is a semi experimental patch to set the default weight
of objects to (1, 1), i.e. EXPAND. This seems like a more
sensible default value than no weight. Some objects may not
need the expand weight, but this seems to be the minority,
not the majority.

Ref T5301
2017-08-23 11:16:45 +09:00
Stephen 'Okra' Houston fa1842370b Netstatus: Use arrows for up and down net traffic indicators. 2017-08-22 20:44:53 -05:00
Felipe Magno de Almeida a7649a7897 eolian-cxx: Add workaround for function pointer types 2017-08-22 22:40:13 -03:00
Daniel Zaoui 2f53bdfe60 Move efl interfaces from evas to efl directory
You may need to remove your installed directory to avoid conflicts
2017-08-22 09:53:24 +03:00
Woochan Lee d1631d8a86 elm_spinner: Support min,max filter for float format case.
Summary: The previous min, max filter doesn't support float format case.

Test Plan: elementary_test -> spinner.

Reviewers: jpeg, cedric, woohyun, myoungwoon

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5016
2017-08-22 14:42:27 +09:00
Woochan Lee 4656f98e22 efl_ui_clock: Parses the format recursively.
Summary:
Some of locale formats convert as extension format.
For example,
             uk_UA d_t_fmt is "%a, %d-%b-%Y %X %z".
             The %X will convert as %T.
             The %T format has to convert one more time to convert as %H:%M:%S.

ref : https://lh.2xlibre.net/locale/uk_UA/

We need to parse the format recursively to support that kind of case.

@fix

Test Plan:
Change the locale as uk_UA.
Run elementary_test -> datetime
See the time field is not appear.

Reviewers: jpeg, cedric

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5021
2017-08-22 14:17:41 +09:00
Jean-Philippe Andre b433592b03 edje: Fix warning message
efl_version is a top-level value

@fix
2017-08-22 11:50:31 +09:00
Jean-Philippe Andre 76d4c965c4 evas: Add safety checks to avoid crash
Without more information or clear reproduction scenario (this crash
doesn't happen for me), this is probably the best we can do.

Fixes T5532
2017-08-22 11:50:31 +09:00
Jean-Philippe Andre ba36214a47 evas: Fix experimental code related to visibility
This is to pretend the object is visible when it's been added with
efl_add but evas hasn't started rendering yet (it's in the queue).

This code is not enabled (yet?) although I think it could very well be
(I don't observe the same bugs as I did the first time I tried this
patch).
2017-08-22 09:44:07 +09:00
Mike Blumenkrantz 906908341e theme: fix dialog sizing when no buttons are present
ensure that the content is used for min sizing and not the icon

@fix
2017-08-21 10:16:56 -04:00
Jean-Philippe Andre 85d04a74d4 elm_box: Fix support of aspect hints
Test scenario: ephoto without a recent patch (47fe2b9ab03c151b0f4).
Before any further explanation, ephoto was definitely misusing the
aspect API here. A label most definitely shouldn't be sized based on an
aspect ratio, that's just crazy (you really want to make it as tall as
it's wide?)

If a box has an aspected item, it needs to run its min calc loop twice:
 1. Once to determine the "true" min size in the direction of the box
    (ie.  in X in case of a horizontal box), and
 2. Once more in order to apply the aspect ratio to aspected items and
    augment the perpendicular min size (ie. Y for horizontal).

After that, it can go and layout the items based on the available size.

As we may guess from the above description (1) determines min W and
(2) determines min H (in horizontal mode).

BUT, there were two problems:
 - The wrong item min size was used inside the 2nd loop (the code was
   not symmetrical between horizontal and vertical modes). These are the
   changes in _smart_extents_non_homogeneous_calc.
 - The box min length was based on the actual size of aspected items,
   rather than their min size. This goes against the observation. These
   are the changes in _smart_extents_calculate.

Ref T5888

@fix
2017-08-21 18:35:31 +09:00
Jean-Philippe Andre 7270a98d8c popup: Avoid error messages on NULL
Those were spotted in ephoto (with no config, first run).
2017-08-21 16:30:21 +09:00
Carsten Haitzler 6226e88b6e evas - fix build dependencies that cause failed builds
missing dev on ecore_wl2 so fix...
2017-08-21 16:04:43 +09:00
Jean-Philippe Andre 9da7e98dcf evas gl: Improve GL_ERRORS (internal debug code) 2017-08-21 13:53:30 +09:00
Jean-Philippe Andre d44cbb618a glview: Fix ALWAYS render policy
@fix
2017-08-21 13:53:29 +09:00
Jean-Philippe Andre d3f2696838 eina: Add EINA_UNUSED in eina_pass_through_from
Fixes a warning
2017-08-21 13:53:28 +09:00
Amitesh Singh e2724b300d elm segment control: delete event cbs on obj delete.
@fix
2017-08-19 16:32:59 +09:00
Derek Foreman 8c917daa06 wayland: Tick like a boss
Instead of the clever but awful manual_render_set hack, actually do ticks
based on frame callbacks.

Fix T5850
2017-08-18 14:27:32 -05:00
Derek Foreman 913e216ea3 ecore_wl2: Send configure complete when windows don't need configure
The intent of the "configure complete" event is to indicate that the
window is configured and ready to receive buffers.

For "windows" like mouse cursors, that's immediate - let them know.
2017-08-18 14:27:32 -05:00
Derek Foreman 9df39b5616 ecore_wl2: Refactor out code to send window configure complete event 2017-08-18 14:27:32 -05:00
Derek Foreman f95f17ae37 wayland_egl: Call ecore_wl2_window_buffer_attach
This lets ecore_wl2 know that there's a buffer attached - even if we don't
know what it is because it's hidden by gl.
2017-08-18 14:27:32 -05:00