Commit Graph

936 Commits

Author SHA1 Message Date
Kai Huuhko 708f02bccc Evas.SmartObject: Add more docs to move_children_relative() 2015-03-31 12:15:41 +03:00
Kai Huuhko aee5433cdc Fix method/prop highlight color with Sphinx 1.3 2015-03-25 07:15:20 +02:00
Kai Huuhko a119c3ccdb Tests: Fix custom smart event callbacks' tests
Custom events always get event_info since commit
fcc93216f9
2015-03-25 05:53:38 +02:00
Kai Huuhko 9f4eab83b7 Elm.Naviframe: Fix item_pop_cb call 2015-03-24 14:48:05 +02:00
Kai Huuhko 61b53f2477 Elm.Toolbar: Add missing event_info to events 2015-03-24 09:06:49 +02:00
Kai Huuhko 73b54938c6 Elm.Naviframe: Add item_pop_cb, missing event_info for events 2015-03-24 09:05:40 +02:00
Kai Huuhko aaaa3a1438 Evas.Rect: Use inline and nogil to optimize the intersection helper 2015-03-24 05:05:28 +02:00
Kai Huuhko fcc93216f9 Evas.SmartObject: Fix smart callbacks with NULL event_info
If the event has a conversion func assigned but event_info is NULL
we should pass None instead of dropping the parameter. This behavior
is now the same as before the callback rework.
2015-03-23 19:15:25 +02:00
Kai Huuhko 8a0dccbf22 Evas: Optimize Smart methods
The methods are now checked on __init__. If a method is not initially
defined the calls to it will be skipped entirely. The methods can be
rebound later in runtime by initially providing an empty (pass) method.
2015-03-21 10:38:24 +02:00
Kai Huuhko 1940b51f15 Evas.SmartObject: Use calloc to allocate the array 2015-03-21 10:37:47 +02:00
Kai Huuhko 149f7d1278 setup.py: Fix Cython specific options
**SPANK SPANK SPANK!!**  Dave has been naughty.

build_ext must be imported from Cython in order for options like
 --cython-dbg to be understood by the setup script.
2015-03-21 10:08:25 +02:00
Kai Huuhko 0266db28bd Eo: Add the property 'parent' 2015-03-21 10:06:45 +02:00
Kai Huuhko c547f72374 Ecore-X: Fix copy & paste error in last commit 2015-03-13 20:36:05 +02:00
Kai Huuhko 0a9ccfca74 Ecore-X: Add cursor_free, deprecate screensaver_supend 2015-03-13 20:13:31 +02:00
Kai Huuhko 6036567b41 Ecore-X: Add cursor_shape_get() 2015-03-13 19:48:15 +02:00
Kai Huuhko 4ccea0f35d Evas.SmartObject: Add smart callback introspection 2015-03-13 19:22:01 +02:00
Kai Huuhko ea2d5bd689 Evas.SmartObject: Optimize Smart calls 2015-03-13 13:10:22 +02:00
Kai Huuhko 3120e56250 Evas.SmartObject: Go back to the old cb system
Turns out the C calls are awfully slow.

Dave, good work with the tests!
2015-03-13 02:40:39 +02:00
Davide Andreoli 807f0417db Some tests for SmartObject callbacks 2015-03-12 22:02:07 +01:00
Kai Huuhko ccc88f6650 Elementary.Object: Use Evas.Object._set_obj() 2015-03-12 21:17:25 +02:00
Kai Huuhko 4b9a44d2fc Evas.Object: Add more documentation for size hints from C headers 2015-03-12 19:39:29 +02:00
Kai Huuhko dd5b35ef8f Evas.Object: Re-order the methods into sections, cosmetic 2015-03-12 18:52:08 +02:00
Kai Huuhko 6fa1b78256 Evas.SmartObject: Keep reference to Smart in the SO object
Smart gets freed automatically when no SO or user has references to it.
2015-03-12 18:22:46 +02:00
Kai Huuhko 270ac10e09 Evas.SmartObject: Optimize python cb call 2015-03-12 16:19:35 +02:00
Kai Huuhko 179404e279 Evas.SmartObject: Change SmartCb spec into a custom object
This allows faster C access to the values, avoids casting the conv_func
pointer to an integer and back.
2015-03-12 14:27:36 +02:00
Kai Huuhko 8b594d4bd8 Evas.SmartObject: Improve Smart cb handling
Calling custom callbacks with event_info was broken, fixed.

A check was added for event_info pointer, a warning will emit
when it's non-NULL and we don't have a conv function set.

Small optimizations.
2015-03-12 02:00:04 +02:00
Kai Huuhko 247eb9e452 Evas.SmartObject: Revert SmartCb add/del mechanism partially
We need to keep a better track of the spec references so they
don't get mixed up when user adds and deletes the callbacks.
2015-03-11 22:13:00 +02:00
Kai Huuhko a407e11298 Evas: Change SmartCb event_info conversions into C functions 2015-03-11 15:37:06 +02:00
Kai Huuhko d36b61e97e Evas.SmartObject: Keep refs in a list
Using Py_INCREF/DECREF in add/del we could have dangling references when
the object is deleted without user calling callback_del.
2015-03-11 11:36:50 +02:00
Kai Huuhko 7fad9e3ff4 Evas.SmartObject: Simplify callback handler code
This should do the same as the previous approach, except heaps and tons
faster. No more dicts and lists to go through.
2015-03-11 04:13:08 +02:00
Kai Huuhko c4786f997e Evas.SmartObject: changed smart event callback add/del methods to cdef 2015-03-11 02:12:36 +02:00
Kai Huuhko 4ab927809e Move smart callback handling from elm Object to evas SO and inherit 2015-03-10 22:53:16 +02:00
Kai Huuhko a11fadc82d Evas.SmartObject: Handle object deletion in a saner way
Evas free event gets called last, we free resources there so that the
SO callbacks can call with a valid object reference.
2015-03-10 00:04:28 +02:00
Kai Huuhko d416425f51 Evas.SmartObject: Trivial changes
Removed cruft, upgraded cls == NULL log message level to ERR,
added formatter to SO example logging.
2015-03-09 21:01:55 +02:00
Kai Huuhko fbc22d850d Make Evas.SO iterator a generic Eo iterator and move to efl.eo 2015-03-09 19:36:42 +02:00
Kai Huuhko 16f04ee2ec Evas.SmartObject: Move documentation to right places 2015-03-09 17:40:34 +02:00
Kai Huuhko 9dbff82aac Evas: Copy SO methods member_add/del to Object.smart_member_add/del 2015-03-09 13:11:15 +02:00
Kai Huuhko 3dd81c4f60 Evas.SmartObject: Switch to using C implementation of ClippedSO 2015-03-08 23:48:21 +02:00
Kai Huuhko 9e86901b0d Evas.SmartObject: Add unicode/py3k safety to callback methods 2015-03-08 23:47:07 +02:00
Kai Huuhko c61e4912e7 Evas.SmartObject: Allow callback calls even when obj is NULL 2015-03-08 20:06:32 +02:00
Kai Huuhko 204aecc746 Evas.SmartObject: Use the correct function when deleting data 2015-03-08 20:04:50 +02:00
Kai Huuhko f3a5b44151 Evas.SmartObject: Add smart_get, commented out parent getter
Need to test if we can use Eo parent_get to do the same thing.
2015-03-08 19:35:47 +02:00
Kai Huuhko c1e51903fe Evas.SmartObject: Fix crash when Smart is re-used 2015-03-08 19:20:58 +02:00
Kai Huuhko 3d7b940631 Evas: Remove now redundant SmartObject metaclass 2015-03-08 18:18:01 +02:00
Kai Huuhko db5663773e Evas.SmartObject: Fix issues in the new API implementation 2015-03-08 18:15:26 +02:00
Kai Huuhko 3c710bb4b4 Evas.SmartObject: Change tests and examples in accordance to new API 2015-03-08 18:07:57 +02:00
Kai Huuhko 4af81e96a7 Evas.SmartObject: rewrite because of changes in Cython 0.21.1
Unfortunately it was impossible to keep api compatibility.

Compiles but didn't test it yet, need to rewrite the tests and
examples too.
2015-03-07 21:38:08 +02:00
Kai Huuhko d3357619f7 Evas: Bring back SmartObject
Possible TODO: support per-child delete cb like in C
2015-03-05 21:07:38 +02:00
Kai Huuhko ded0c5fd06 Elementary: Documentation fixes 2015-03-05 14:19:48 +02:00
Kai Huuhko 2dcc34230e Documentation: Switch syntax highlighting (pygments) style to monokai
It suits our dark background coloring better.
2015-03-04 11:21:59 +02:00