[EGIT] [apps/epour] master 02/03: Improve torrent data save location entry in torrent add dialog

2015-04-21 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/apps/epour.git/commit/?id=055a4e86a1ed1c8fdcb5c0eb9bf63bc602000ecb

commit 055a4e86a1ed1c8fdcb5c0eb9bf63bc602000ecb
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 22 05:06:46 2015 +0300

Improve torrent data save location entry in torrent add dialog

Use fs.path instead of fs.selected for getting the path, allows user to
enter the path in the entry widget
---
 epour/gui/TorrentSelector.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/epour/gui/TorrentSelector.py b/epour/gui/TorrentSelector.py
index 6472c0f..92176e6 100644
--- a/epour/gui/TorrentSelector.py
+++ b/epour/gui/TorrentSelector.py
@@ -129,7 +129,7 @@ class TorrentSelector(StandardWindow):
 e.show()
 
 def fs_cb(fs, key):
-self.add_dict[key] = fs.selected
+self.add_dict[key] = fs.path
 
 save_path = FsEntry(
 opt_box, size_hint_align=FILL_HORIZ, text=Save path,

-- 




[EGIT] [apps/epour] master 01/03: Use more xdg icon names

2015-04-21 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/apps/epour.git/commit/?id=59b7544370e4c7cf2531a511ab2c5f0eb470f72e

commit 59b7544370e4c7cf2531a511ab2c5f0eb470f72e
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 22 05:05:55 2015 +0300

Use more xdg icon names
---
 epour/gui/__init__.py | 14 ++
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/epour/gui/__init__.py b/epour/gui/__init__.py
index 98ddcc1..87a131e 100644
--- a/epour/gui/__init__.py
+++ b/epour/gui/__init__.py
@@ -408,9 +408,9 @@ class SessionStatus(Table):
 self.uploads_l.text = t
 self.listen_l.text = str(self.session.is_listening())
 if self.session.is_paused():
-icon = player_pause
+icon = media-playback-pause
 else:
-icon = player_play
+icon = media-playback-play
 try:
 self.ses_pause_ic.standard = icon
 except Exception as e:
@@ -482,12 +482,18 @@ class TorrentClass(GenlistItemClass):
 try:
 ic.standard = up
 except Exception:
-pass
+try:
+ic.standard = arrow-up
+except Exception:
+pass
 else:
 try:
 ic.standard = down
 except Exception:
-pass
+try:
+ic.standard = arrow-down
+except Exception:
+pass
 except RuntimeError:
 log.debug(Setting torrent ic failed)
 ic.tooltip_text_set(self.state_str[s.state])

-- 




[EGIT] [bindings/python/python-efl] master 01/02: Documentation: Sphinx 1.3 compatibility fixes

2015-04-22 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=c3b9a5b18f4db8373b925ee3f07c0c9bc0e80ed4

commit c3b9a5b18f4db8373b925ee3f07c0c9bc0e80ed4
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 22 13:06:07 2015 +0300

Documentation: Sphinx 1.3 compatibility fixes
---
 doc/themes/efldoc/static/efl.css | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/doc/themes/efldoc/static/efl.css b/doc/themes/efldoc/static/efl.css
index 369fb22..229104b 100644
--- a/doc/themes/efldoc/static/efl.css
+++ b/doc/themes/efldoc/static/efl.css
@@ -322,7 +322,7 @@ cite, code, tt {
 letter-spacing: -0.02em;
 }
 
-tt {
+code, tt {
 background-color: rgb(51,51,51); /*#f2f2f2*/
 border: 1px solid rgb(32,32,32); /*#ddd*/
 border-radius: 2px;
@@ -351,12 +351,12 @@ hr {
 margin: 2em;
 }
 
-a tt {
+a tt, a code{
 border: 0;
 color: rgb(200,200,170);
 }
 
-a tt:hover {
+a tt:hover, a code:hover{
 color: rgb(230,230,200);
 }
 

-- 




[EGIT] [bindings/python/python-efl] master 02/02: Documentation: Prettify warning/note boxes, class headers

2015-04-22 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=8f68e52eccb2706e0e8ab39199cd72a4f8f22b0e

commit 8f68e52eccb2706e0e8ab39199cd72a4f8f22b0e
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 22 14:16:50 2015 +0300

Documentation: Prettify warning/note boxes, class headers

Sphinx 1.3 includes class constructor's signature in the class header;
reduced font size slightly to accommodate this change.
---
 doc/themes/efldoc/static/efl.css | 14 +-
 1 file changed, 9 insertions(+), 5 deletions(-)

diff --git a/doc/themes/efldoc/static/efl.css b/doc/themes/efldoc/static/efl.css
index 229104b..68d6dd3 100644
--- a/doc/themes/efldoc/static/efl.css
+++ b/doc/themes/efldoc/static/efl.css
@@ -325,7 +325,7 @@ cite, code, tt {
 code, tt {
 background-color: rgb(51,51,51); /*#f2f2f2*/
 border: 1px solid rgb(32,32,32); /*#ddd*/
-border-radius: 2px;
+border-radius: 3px;
 color: white; /*#333*/
 padding: 1px;
 }
@@ -406,8 +406,8 @@ table td, table th {
 div.admonition, div.warning {
 font-size: 0.9em;
 margin: 1em 0 1em 0;
-border: 1px solid rgb(32,32,32); /*#86989B*/
-border-radius: 2px;
+border: 1px dashed rgb(32,32,32); /*#86989B*/
+border-radius: 12px;
 background-color: rgb(51,51,51); /*#f7f7f7*/
 padding: 0;
 }
@@ -429,7 +429,7 @@ div.warning p.admonition-title {
 }
 
 div.warning {
-border: 1px solid rgb(101,16,16); /*#94*/
+border-color: rgb(101,16,16); /*#94*/
 background-color: rgb(101,51,51); /*#FFCCCF*/
 }
 
@@ -506,11 +506,15 @@ dl.class {
 }
 
 dl.class  dt {
-font-size: 20px;
+font-size: 1.2em;
 background-color: #333;
 padding: 2px;
 }
 
+dl.class  dt em {
+font-size: 0.8em;
+}
+
 dl.class dt{
 border-bottom: 1px solid #333;
 }

-- 




[EGIT] [bindings/python/python-efl] master 01/02: Elm.Systray: Fix compile warning

2015-04-19 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=6532ef85f6ef2118b0fcf59edbf7417ed17aceed

commit 6532ef85f6ef2118b0fcf59edbf7417ed17aceed
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Fri Apr 17 20:29:35 2015 +0300

Elm.Systray: Fix compile warning
---
 efl/elementary/systray.pyx | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/efl/elementary/systray.pyx b/efl/elementary/systray.pyx
index be57906..7368e9e 100644
--- a/efl/elementary/systray.pyx
+++ b/efl/elementary/systray.pyx
@@ -190,17 +190,17 @@ cdef class Systray(Eo):
 eo_do(self.obj, elm_obj_systray_menu_set(value.obj))
 
 def __get__(self):
-cdef cEo *value = NULL
+cdef const cEo *value = NULL
 eo_do_ret(self.obj, value, elm_obj_systray_menu_get())
-return object_from_instance(value)
+return object_from_instance(cEo *value)
 
 def menu_set(self, Eo value):
 eo_do(self.obj, elm_obj_systray_menu_set(value.obj))
 
 def menu_get(self):
-cdef cEo *value = NULL
+cdef const cEo *value = NULL
 eo_do_ret(self.obj, value, elm_obj_systray_menu_get())
-return object_from_instance(value)
+return object_from_instance(cEo *value)
 
 property att_icon_name:
 The name of the attention icon to be used by the Status Notifier 
Item.

-- 




[EGIT] [bindings/python/python-efl] master 02/02: Elm: Move ecore events registration out of init

2015-04-19 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=c0239f30f8bc8f4707650cedd819a9a09b00

commit c0239f30f8bc8f4707650cedd819a9a09b00
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Mon Apr 20 06:25:43 2015 +0300

Elm: Move ecore events registration out of init
---
 efl/elementary/general.pxd |  16 --
 efl/elementary/general.pyx | 121 +++--
 efl/elementary/need.pxd|  23 +
 efl/elementary/need.pyx| 111 +++--
 4 files changed, 137 insertions(+), 134 deletions(-)

diff --git a/efl/elementary/general.pxd b/efl/elementary/general.pxd
index 134a03d..56de2f7 100644
--- a/efl/elementary/general.pxd
+++ b/efl/elementary/general.pxd
@@ -93,14 +93,6 @@ cdef extern from Elementary.h:
 ctypedef enum Elm_Policy_Throttle:
 pass
 
-cpdef enum Elm_Sys_Notify_Closed_Reason:
-ELM_SYS_NOTIFY_CLOSED_EXPIRED
-ELM_SYS_NOTIFY_CLOSED_DISMISSED
-ELM_SYS_NOTIFY_CLOSED_REQUESTED
-ELM_SYS_NOTIFY_CLOSED_UNDEFINED
-ctypedef enum Elm_Sys_Notify_Closed_Reason:
-pass
-
 cpdef enum Elm_Sys_Notify_Urgency:
 ELM_SYS_NOTIFY_URGENCY_LOW
 ELM_SYS_NOTIFY_URGENCY_NORMAL
@@ -208,14 +200,6 @@ cdef extern from Elementary.h:
 # sys_notify.h
 ctypedef void (*Elm_Sys_Notify_Send_Cb)(void *data, unsigned int id)
 
-ctypedef struct Elm_Sys_Notify_Notification_Closed:
-unsigned int id # ID of the notification.
-Elm_Sys_Notify_Closed_Reason reason # The Reason the notification was 
closed.
-
-ctypedef struct Elm_Sys_Notify_Action_Invoked:
-unsigned int id # ID of the notification.
-char *action_key # The key of the action invoked. These match the keys 
sent over in the list of actions.
-
 void  elm_sys_notify_close(unsigned int id)
 void  elm_sys_notify_send(  unsigned int replaces_id,
 const char *icon,
diff --git a/efl/elementary/general.pyx b/efl/elementary/general.pyx
index f2a6c28..f449785 100644
--- a/efl/elementary/general.pyx
+++ b/efl/elementary/general.pyx
@@ -290,8 +290,6 @@ from efl.eina cimport EINA_LOG_DOM_DBG, EINA_LOG_DOM_INFO, \
 EINA_LOG_DOM_WARN, EINA_LOG_DOM_ERR, EINA_LOG_DOM_CRIT
 
 from efl.ecore cimport Event, EventHandler, _event_mapping_register
-from efl.elementary.need cimport elm_need_sys_notify, elm_need_systray, \
-elm_need_ethumb
 
 import sys
 import traceback
@@ -302,86 +300,6 @@ elm_log = add_logger(efl.elementary)
 cdef int PY_EFL_ELM_LOG_DOMAIN = elm_log.eina_log_domain
 
 
-cdef class EventSystrayReady(Event):
-cdef int _set_obj(self, void *o) except 0:
-return 1
-
-def __repr__(self):
-return %s() % (self.__class__.__name__,)
-
-
-cdef class SysNotifyNotificationClosed(Event):
-
-cdef Elm_Sys_Notify_Notification_Closed *obj
-
-cdef int _set_obj(self, void *o) except 0:
-self.obj = Elm_Sys_Notify_Notification_Closed*o
-return 1
-
-def __repr__(self):
-# TODO: int - string for 'reason'
-return %s(id=%d, reason=%s) % \
-(type(self).__name__, self.id, self.reason)
-
-property id:
-ID of the notification.
-
-:type: int
-
-
-def __get__(self):
-return self.obj.id
-
-property reason:
-The Reason the notification was closed.
-
-:type: :ref:`Elm_Sys_Notify_Closed_Reason`
-
-
-def __get__(self):
-return self.obj.reason
-
-
-cdef class SysNotifyActionInvoked(Event):
-
-cdef Elm_Sys_Notify_Action_Invoked *obj
-
-cdef int _set_obj(self, void *o) except 0:
-self.obj = Elm_Sys_Notify_Action_Invoked*o
-return 1
-
-def __repr__(self):
-return %s(id=%d, action_key=%s) % \
-(type(self).__name__, self.id, self.action_key)
-
-property id:
-ID of the notification.
-
-:type: int
-
-
-def __get__(self):
-return self.obj.id
-
-property action_key:
-The key of the action invoked. These match the keys sent over in the
-list of actions.
-
-:type: string
-
-
-def __get__(self):
-return _touni(self.obj.action_key)
-
-
-cdef class EthumbConnect(Event):
-cdef int _set_obj(self, void *o) except 0:
-return 1
-
-def __repr__(self):
-return %s() % (self.__class__.__name__,)
-
-
 cdef class ConfigAllChanged(Event):
 cdef int _set_obj(self, void *o) except 0:
 return 1
@@ -463,39 +381,7 @@ def init():
 argv[i] = char *PyMem_Malloc(arg_len + 1)
 memcpy(argv[i], arg, arg_len + 1)
 
-ret = elm_init(argc, argv)
-
-if ret != 1:
-return ret
-
-if elm_need_ethumb():
-_event_mapping_register(ELM_ECORE_EVENT_ETHUMB_CONNECT, EthumbConnect)
-else:
-EINA_LOG_DOM_WARN(PY_EFL_ELM_LOG_DOMAIN, Ethumb

[EGIT] [bindings/python/python-efl] master 01/01: Bump version for 1.14.0 release

2015-05-04 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=1011cb76df9adf516be79426bbee298eb962ae3e

commit 1011cb76df9adf516be79426bbee298eb962ae3e
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Mon May 4 09:25:43 2015 +0300

Bump version for 1.14.0 release
---
 ChangeLog   | 2 +-
 api_coverage.py | 4 +---
 efl/__init__.py | 2 +-
 3 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 8449359..5cbe152 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,6 @@
 
 ===
-2015-05-03  v1.14.0
+2015-05-04  v1.14.0
 ===
 
 Fixes:
diff --git a/api_coverage.py b/api_coverage.py
index e51624f..f08a783 100755
--- a/api_coverage.py
+++ b/api_coverage.py
@@ -55,8 +55,6 @@ params = {
 elementary: (efl/elementary, Elementary, elm),
 }
 
-EFL_MIN_VERSION = 1.9.99
-
 parser = argparse.ArgumentParser(
 description=Reports EFL vs. Python-EFL API functions coverage
 )
@@ -205,7 +203,7 @@ print()
 
 for lib in args.libs:
 
-inc_paths = pkg_config(lib, EFL_MIN_VERSION)
+inc_paths = pkg_config(lib)
 inc_path = None
 for p in inc_paths:
 if lib in p:
diff --git a/efl/__init__.py b/efl/__init__.py
index 59b4312..de34739 100644
--- a/efl/__init__.py
+++ b/efl/__init__.py
@@ -20,5 +20,5 @@
 # pre-release: 1.13.0-beta1 ( 1, 13, 0 )
 # release: 1.13.0 ( 1, 13, 0 )
 
-__version__ = 1.14.0-beta1
+__version__ = 1.14.0
 __version_info__ = ( 1, 14, 0 )

-- 




[EGIT] [bindings/python/python-efl] master 02/02: Remove init/shutdown from elm and emotion main tests

2015-05-03 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=e37026ec17f20fecf91145e43f9133a3131a59a1

commit e37026ec17f20fecf91145e43f9133a3131a59a1
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Mon May 4 03:36:31 2015 +0300

Remove init/shutdown from elm and emotion main tests
---
 examples/elementary/test.py  |  2 --
 examples/emotion/test_emotion.py | 10 +-
 2 files changed, 1 insertion(+), 11 deletions(-)

diff --git a/examples/elementary/test.py b/examples/elementary/test.py
index e306cc0..0878178 100755
--- a/examples/elementary/test.py
+++ b/examples/elementary/test.py
@@ -309,7 +309,6 @@ def cb_filter(en, win):
 menu_create(en.text_get(), win)
 
 if __name__ == __main__:
-elementary.init()
 win = StandardWindow(test, Python EFL test application)
 win.callback_delete_request_add(destroy, test1, test2,
 str3=test3, str4=test4)
@@ -364,4 +363,3 @@ if __name__ == __main__:
 win.resize(480, 480)
 win.show()
 elementary.run()
-elementary.shutdown()
diff --git a/examples/emotion/test_emotion.py b/examples/emotion/test_emotion.py
index 54d8cde..21ca635 100755
--- a/examples/emotion/test_emotion.py
+++ b/examples/emotion/test_emotion.py
@@ -48,7 +48,7 @@ class MovieWindow(edje.Edje):
 self.part_text_set(video_alpha_txt, alpha 255)
 self.part_drag_value_set(video_volume, 0.0, 0.5)
 self.part_text_set(video_volume_txt, vol 0.50)
-
+
 self.part_swallow(video_swallow, self.vid)
 self.data[moving] = False
 self.data[resizing] = False
@@ -365,8 +365,6 @@ def cmdline_parse():
 if __name__ == __main__or True:
 options, args = cmdline_parse()
 
-elementary.init()
-
 # elementary window
 win = Window(test-emotion, ELM_WIN_BASIC)
 win.title_set(python-emotion test application)
@@ -414,9 +412,3 @@ if __name__ == __main__or True:
 del win.data[movie_windows]
 win.delete()
 del scene
-
-
-elementary.shutdown()
-emotion.shutdown()
-edje.shutdown()
-evas.shutdown()

-- 




[EGIT] [bindings/python/python-efl] master 01/02: Add automated init/shutdown to rest of the modules

2015-05-03 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=bc0f40e54c4790bd106b904eb0842fc46b42ee15

commit bc0f40e54c4790bd106b904eb0842fc46b42ee15
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Mon May 4 03:35:50 2015 +0300

Add automated init/shutdown to rest of the modules
---
 efl/ecore_x/efl.ecore_x.pyx | 5 +
 efl/edje/efl.edje.pyx   | 8 
 efl/emotion/efl.emotion.pyx | 3 +++
 efl/ethumb/efl.ethumb.pyx   | 3 +++
 4 files changed, 15 insertions(+), 4 deletions(-)

diff --git a/efl/ecore_x/efl.ecore_x.pyx b/efl/ecore_x/efl.ecore_x.pyx
index 4baf32b..cf0e90e 100644
--- a/efl/ecore_x/efl.ecore_x.pyx
+++ b/efl/ecore_x/efl.ecore_x.pyx
@@ -19,6 +19,8 @@
 from cpython cimport PyMem_Malloc, PyMem_Free, PyUnicode_AsUTF8String
 from efl.utils.deprecated cimport DEPRECATED
 
+import atexit
+
 
 def init(name=None):
 Initialize the X display connection to the given display.
@@ -322,3 +324,6 @@ def cursor_free(Ecore_X_Cursor c):
 
 include efl.ecore_x_window.pxi
 include efl.ecore_x_events.pxi
+
+init()
+atexit.register(shutdown)
diff --git a/efl/edje/efl.edje.pyx b/efl/edje/efl.edje.pyx
index b9201c6..dad8ff4 100644
--- a/efl/edje/efl.edje.pyx
+++ b/efl/edje/efl.edje.pyx
@@ -30,10 +30,6 @@ Classes
 
 
 
-
-import traceback
-import warnings
-
 from cpython cimport PyMem_Malloc, PyMem_Free, PyUnicode_AsUTF8String
 cimport libc.stdlib
 from libc.stdint cimport uintptr_t
@@ -45,6 +41,9 @@ from efl.eo cimport _object_mapping_register, 
object_from_instance, \
 from efl.utils.conversions cimport _ctouni, _touni, \
 eina_list_strings_to_python_list
 
+import traceback
+import warnings
+import atexit
 
 
 def init():
@@ -288,3 +287,4 @@ include efl.edje_object.pxi
 
 
 init()
+atexit.register(shutdown)
diff --git a/efl/emotion/efl.emotion.pyx b/efl/emotion/efl.emotion.pyx
index 809d250..ffe1318 100644
--- a/efl/emotion/efl.emotion.pyx
+++ b/efl/emotion/efl.emotion.pyx
@@ -41,6 +41,8 @@ from efl.utils.conversions cimport _ctouni
 from efl.evas cimport Canvas, evas_object_smart_callback_add, \
 evas_object_smart_callback_del
 
+import atexit
+
 
 cdef void _emotion_callback(void *data, Evas_Object *o, void *ei) with gil:
 cdef Emotion obj
@@ -1285,3 +1287,4 @@ _object_mapping_register(Emotion_Object, Emotion)
 
 
 init()
+atexit.register(shutdown)
diff --git a/efl/ethumb/efl.ethumb.pyx b/efl/ethumb/efl.ethumb.pyx
index 9f6f831..573f811 100644
--- a/efl/ethumb/efl.ethumb.pyx
+++ b/efl/ethumb/efl.ethumb.pyx
@@ -15,6 +15,8 @@
 # You should have received a copy of the GNU Lesser General Public License
 # along with this Python-EFL.  If not, see http://www.gnu.org/licenses/.
 
+import atexit
+
 def init():
 return ethumb_init()
 
@@ -28,3 +30,4 @@ cdef class PyEthumb:
 
 
 init()
+atexit.register(shutdown)

-- 




[EGIT] [bindings/python/python-efl] master 01/01: elm.Toolbar: Note earlier changes to events and update example

2015-05-03 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=59b2e1ee598d6c412dc496dd96e0bb529c4dd88f

commit 59b2e1ee598d6c412dc496dd96e0bb529c4dd88f
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Mon May 4 05:53:20 2015 +0300

elm.Toolbar: Note earlier changes to events and update example

See commit 61b53f24774de8690c6f1e4a8a6e55e30e514714
---
 ChangeLog   | 2 ++
 examples/elementary/test_toolbar.py | 3 ++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 1dab381..8449359 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -20,6 +20,8 @@ Changes:
 
  * elm.List.callback_highlighted_add: Added item param to func
  * elm.List.callback_unhighlighted_add: Added item param to func
+ * elm.Toolbar.callback_clicked_add: Added item param to func
+ * elm.Toolbar.callback_longpressed_add: Added item param to func
  * elm.Slideshow: item_data are now a single value, instead of args/kargs,
like is implemented in Gengrid/Genlist
 
diff --git a/examples/elementary/test_toolbar.py 
b/examples/elementary/test_toolbar.py
index 28568dd..932d8ad 100644
--- a/examples/elementary/test_toolbar.py
+++ b/examples/elementary/test_toolbar.py
@@ -46,9 +46,10 @@ def tb_4a(obj, it, ph):
 def tb_5(obj, it, ph):
 ph.file = None
 
-def cb_clicked(tb):
+def cb_clicked(tb, it):
 print(CLICKED)
 print(tb)
+print(it)
 
 def cb_item_focused(tb, item):
 print(ITEM FOCUSED)

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Open up development for 1.15

2015-05-07 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=d571c49e6f1e01ea8d5d6c24a676742bd4befd03

commit d571c49e6f1e01ea8d5d6c24a676742bd4befd03
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Thu May 7 13:10:20 2015 +0300

Open up development for 1.15
---
 ChangeLog   | 16 +++-
 efl/__init__.py |  4 ++--
 2 files changed, 17 insertions(+), 3 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 5cbe152..7e48b13 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,20 @@
+===
+2015-08-03  v1.15.0
+===
+
+Fixes:
+
+Improvements:
+
+Changes:
+
+Additions:
+
+Deprecation:
+
 
 ===
-2015-05-04  v1.14.0
+2015-05-07  v1.14.0
 ===
 
 Fixes:
diff --git a/efl/__init__.py b/efl/__init__.py
index de34739..480cbbe 100644
--- a/efl/__init__.py
+++ b/efl/__init__.py
@@ -20,5 +20,5 @@
 # pre-release: 1.13.0-beta1 ( 1, 13, 0 )
 # release: 1.13.0 ( 1, 13, 0 )
 
-__version__ = 1.14.0
-__version_info__ = ( 1, 14, 0 )
+__version__ = 1.14.99
+__version_info__ = ( 1, 14, 99 )

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Elm: Replace FIXME in init about argc/v with description

2015-05-09 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=3dd36bd7706090c148729531332a3441e4a8b0cd

commit 3dd36bd7706090c148729531332a3441e4a8b0cd
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Sat May 9 20:54:44 2015 +0300

Elm: Replace FIXME in init about argc/v with description
---
 efl/elementary/__init__.pyx | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/efl/elementary/__init__.pyx b/efl/elementary/__init__.pyx
index 9a2a602..2c0ca00 100644
--- a/efl/elementary/__init__.pyx
+++ b/efl/elementary/__init__.pyx
@@ -110,7 +110,10 @@ def init():
 EINA_LOG_DOM_INFO(PY_EFL_ELM_LOG_DOMAIN,
 Initializing efl.elementary, NULL)
 
-# FIXME: Why are we passing the cl args to elm_init here?
+# argc and argv are currently used by EFL to support app restart
+# and binary relocation. These are probably not useful to us but we
+# pass the information here regardless because useful functionality
+# may be added in the future.
 
 cdef:
 int argc = 0, i, arg_len

-- 




[EGIT] [website/www-content] master 01/01: Wiki page download-latest changed with summary [Bump Python-EFL version] by Kai Huuhko

2015-05-07 Thread Kai Huuhko
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=c205fb81199d808e03eaac909e1068c504954ad6

commit c205fb81199d808e03eaac909e1068c504954ad6
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Thu May 7 03:33:59 2015 -0700

Wiki page download-latest changed with summary [Bump Python-EFL version] by 
Kai Huuhko
---
 pages/download-latest.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pages/download-latest.txt b/pages/download-latest.txt
index 979671e..01bd4fa 100644
--- a/pages/download-latest.txt
+++ b/pages/download-latest.txt
@@ -3,7 +3,7 @@ efl_v = 1.14.0
 elm_v = 1.14.0
 emotion_generic_players_v = 1.14.0
 evas_generic_loaders_v= 1.14.0
-python_efl_v  = 1.13.0
+python_efl_v  = 1.14.0
 
 enlightenment_v   = 0.19.5
 terminology_v = 0.8.0

-- 




[EGIT] [apps/epour] master 01/03: Fix error on torrent removal

2015-04-15 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/apps/epour.git/commit/?id=9d83e78579971827bf5081715b83a3b821ae78af

commit 9d83e78579971827bf5081715b83a3b821ae78af
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 15 14:25:47 2015 +0300

Fix error on torrent removal
---
 epour/session.py | 72 
 1 file changed, 31 insertions(+), 41 deletions(-)

diff --git a/epour/session.py b/epour/session.py
index 3fe99f1..8164777 100644
--- a/epour/session.py
+++ b/epour/session.py
@@ -42,13 +42,6 @@ from efl.ecore import Timer
 from xdg.BaseDirectory import save_data_path, load_data_paths
 
 
-def torrent_path_get(ihash):
-for p in load_data_paths(epour):
-path = os.path.join(p, {0}.torrent.format(ihash))
-if os.path.isfile(path):
-return path
-
-
 class Session(lt.session):
 def __init__(self, conf):
 self.conf = conf
@@ -121,7 +114,6 @@ class Session(lt.session):
 h = a.handle
 ihash = str(h.info_hash())
 self.log.debug(Metadata received.)
-#self.write_torrent(h)
 t_info = h.get_torrent_info()
 t = {}
 t[info] = lt.bdecode(t_info.metadata())
@@ -255,36 +247,28 @@ class Session(lt.session):
 
 self.log.debug(List of torrents saved.)
 
-# Save fast resume data
-# for h in self.get_torrents():
-# if not h.is_valid() or not h.has_metadata():
-# continue
-# data = lt.bencode(h.write_resume_data())
-# with open(os.path.join(
-# data_dir, str(h.info_hash()) + .fastresume
-# ), 'wb') as f:
-# f.write(data)
-
-# self.log.debug(Fast resume data saved.)
-
-def write_torrent(self, h):
-if h is None:
-self.log.debug(Tried to write torrent while handle was empty.)
-return
+# def write_torrent(self, h):
+# if h is None:
+# self.log.debug(Tried to write torrent while handle was empty.)
+# return
 
-t_info = h.get_torrent_info()
-ihash = str(h.info_hash())
+# t_info = h.get_torrent_info()
+# ihash = str(h.info_hash())
 
-self.log.debug(Writing torrent file {}.format(ihash))
+# self.log.debug(Writing torrent file {}.format(ihash))
 
-md = lt.bdecode(t_info.metadata())
-t = {}
-t[info] = md
-t_path = torrent_path_get(ihash)
-with open(t_path, wb) as f:
-f.write(lt.bencode(t))
+# md = lt.bdecode(t_info.metadata())
+# t = {}
+# t[info] = md
+
+# p = save_data_path(epour)
+# t_path = os.path.join(p, {0}.torrent.format(ihash))
 
-return t_path
+# if t_path:
+# with open(t_path, wb) as f:
+# f.write(lt.bencode(t))
+
+# return t_path
 
 def remove_torrent(self, h, with_data=False):
 ihash = str(h.info_hash())
@@ -307,13 +291,19 @@ class Session(lt.session):
 else:
 os.remove(fr_path)
 
-try:
-with open(torrent_path_get(ihash)):
-pass
-except IOError:
-self.log.debug(Could not remove torrent file.)
-else:
-os.remove(torrent_path_get(ihash))
+t_path = None
+for p in load_data_paths(epour):
+t_path = os.path.join(p, {0}.torrent.format(ihash))
+break
+
+if t_path:
+try:
+with open(t_path):
+pass
+except IOError:
+self.log.debug(Could not remove torrent file.)
+else:
+os.remove(t_path)
 
 if not hasattr(lt, torrent_removed_alert):
 class torrent_removed_alert(object):

-- 




[EGIT] [apps/epour] master 02/03: Use pop_alerts() instead of looping with pop_alert

2015-04-15 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/apps/epour.git/commit/?id=18299f202cf4105c18070673243c0015fb0302ed

commit 18299f202cf4105c18070673243c0015fb0302ed
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 15 14:44:03 2015 +0300

Use pop_alerts() instead of looping with pop_alert

This saves CPU cycles on a busy session.
---
 epour/session.py | 13 -
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/epour/session.py b/epour/session.py
index 8164777..52471c7 100644
--- a/epour/session.py
+++ b/epour/session.py
@@ -1,7 +1,7 @@
 #
 #  Epour - A bittorrent client using EFL and libtorrent
 #
-#  Copyright 2012-2014 Kai Huuhko kai.huu...@gmail.com
+#  Copyright 2012-2015 Kai Huuhko kai.huu...@gmail.com
 #
 #  This program is free software; you can redistribute it and/or modify
 #  it under the terms of the GNU General Public License as published by
@@ -393,7 +393,7 @@ class AlertManager(object):
 self.timer = Timer(self.update_interval, self.update)
 
 def callback_add(self, alert_type, cb, *args, **kwargs):
-if not alert_type in self.alerts:
+if alert_type not in self.alerts:
 self.alerts[alert_type] = []
 self.alerts[alert_type].append((cb, args, kwargs))
 
@@ -405,7 +405,7 @@ class AlertManager(object):
 def signal(self, a):
 a_name = type(a).__name__
 
-if not a_name in self.alerts:
+if a_name not in self.alerts:
 self.log.debug(No handler: {} | {}.format(a_name, a))
 return
 
@@ -416,13 +416,8 @@ class AlertManager(object):
 self.log.exception(Exception while handling alerts)
 
 def update(self):
-# TODO: Use pop_alerts()
 #self.log.debug(Alerts TICK)
-while 1:
-a = self.session.pop_alert()
-if not a:
-break
-
+for a in self.session.pop_alerts():
 self.signal(a)
 
 return True

-- 




[EGIT] [bindings/python/python-efl] master 01/02: Elm.Entry: Fix compile warning and doc issues

2015-04-17 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=9ffa09d72948cb86140b250afd66404305317dda

commit 9ffa09d72948cb86140b250afd66404305317dda
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Fri Apr 17 10:34:00 2015 +0300

Elm.Entry: Fix compile warning and doc issues
---
 efl/elementary/entry.pyx | 118 +--
 1 file changed, 94 insertions(+), 24 deletions(-)

diff --git a/efl/elementary/entry.pyx b/efl/elementary/entry.pyx
index cda125d..5d49562 100644
--- a/efl/elementary/entry.pyx
+++ b/efl/elementary/entry.pyx
@@ -804,12 +804,41 @@ cdef class EntryAnchorInfo(object):
 The info sent in the callback for the ``anchor,clicked`` signals emitted
 by entries.
 
-:var name: The name of the anchor, as stated in its href.
-:var button: The mouse button used to click on it.
-:var x: Anchor geometry, relative to canvas.
-:var y: Anchor geometry, relative to canvas.
-:var w: Anchor geometry, relative to canvas.
-:var h: Anchor geometry, relative to canvas.
+.. attribute:: name
+
+The name of the anchor, as stated in its href.
+
+:type: string
+
+.. attribute:: button
+
+The mouse button used to click on it.
+
+:type: :class:`~efl.elementary.button.Button`
+
+.. attribute:: x
+
+Anchor geometry, relative to canvas.
+
+:type: int
+
+.. attribute:: y
+
+Anchor geometry, relative to canvas.
+
+:type: int
+
+.. attribute:: w
+
+Anchor geometry, relative to canvas.
+
+:type: int
+
+.. attribute:: h
+
+Anchor geometry, relative to canvas.
+
+:type: int
 
 
 cdef:
@@ -834,16 +863,50 @@ cdef object _entryanchor_conv(void *addr):
 cdef class EntryAnchorHoverInfo(object):
 EntryAnchorHoverInfo(...)
 
-The info sent in the callback for ``anchor,clicked`` signals emitted by
-the entries.
+The info sent in the callback for ``anchor,hover,opened`` signals emitted
+by the entries.
+
+.. attribute:: anchor_info
+
+The actual anchor info.
+
+:type: :class:`EntryAnchorInfo`
 
-:var anchor_info: The actual anchor info.
-:var hover: The hover object to use for the popup.
-:var hover_parent: Geometry of the object used as parent by the hover.
-:var hover_left: Hint indicating if there's space for content on the left 
side of the hover.
-:var hover_right: Hint indicating content fits on the right side of the 
hover.
-:var hover_top: Hint indicating content fits on top of the hover.
-:var hover_bottom: Hint indicating content fits below the hover.
+.. attribute:: hover
+
+The hover object to use for the popup.
+
+:type: :class:`~efl.elementary.hover.Hover`
+
+.. attribute:: hover_parent
+
+The object used as parent by the hover.
+
+:type: :class:`~efl.eo.Eo`
+
+.. attribute:: hover_left
+
+Hint indicating if there's space for content on the left side of the 
hover.
+
+:type: bool
+
+.. attribute:: hover_right
+
+Hint indicating content fits on the right side of the hover.
+
+:type: bool
+
+.. attribute:: hover_top
+
+Hint indicating content fits on top of the hover.
+
+:type: bool
+
+.. attribute:: hover_bottom
+
+Hint indicating content fits below the hover.
+
+:type: bool
 
 
 cdef:
@@ -855,7 +918,7 @@ cdef class EntryAnchorHoverInfo(object):
 @staticmethod
 cdef EntryAnchorHoverInfo create(Elm_Entry_Anchor_Hover_Info *addr):
 cdef EntryAnchorHoverInfo self = 
EntryAnchorHoverInfo.__new__(EntryAnchorHoverInfo)
-self.anchor_info = _entryanchor_conv(addr.anchor_info)
+self.anchor_info = _entryanchor_conv(void *addr.anchor_info)
 self.hover = object_from_instance(addr.hover)
 self.hover_parent = (addr.hover_parent.x, addr.hover_parent.y,
addr.hover_parent.w, addr.hover_parent.h)
@@ -908,9 +971,13 @@ cdef class Entry(LayoutClass):
 
 If there is styles in the user style stack, the properties in the
 top style of user style stack will replace the properties in current
-theme. The input style is specified in format
-``tag='property=value'`` (i.e. ``DEFAULT='font=Sans
-font_size=60'hilight=' + font_weight=Bold'``).
+theme. The input style is specified in format::
+
+tag='property=value'
+
+i.e.::
+
+DEFAULT='font=Sans font_size=60' hilight=' + font_weight=Bold'
 
 :param string style: The style user to push
 
@@ -1075,11 +1142,14 @@ cdef class Entry(LayoutClass):
 functions; The former will either not work at all, or break the correct
 functionality.
 
-IMPORTANT: Many functions may change (i.e delete and create a new one)
-the internal textblock object. Do NOT cache the returned object, and 
try

[EGIT] [bindings/python/python-efl] master 01/01: Elm.Systray: Fix compile

2015-04-17 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=b7040059817027a2b25a2541444fa35a2241a5d3

commit b7040059817027a2b25a2541444fa35a2241a5d3
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Fri Apr 17 14:59:11 2015 +0300

Elm.Systray: Fix compile

Here's a hint to any developer at home: CTRL-S *before* you commit.
---
 efl/elementary/systray.pxd | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/efl/elementary/systray.pxd b/efl/elementary/systray.pxd
index 7b634a5..f5b9f83 100644
--- a/efl/elementary/systray.pxd
+++ b/efl/elementary/systray.pxd
@@ -6,6 +6,9 @@ cdef extern from Elementary.h:
 
 ctypedef Eo Elm_Systray
 
+cpdef enum:
+ELM_EVENT_SYSTRAY_READY
+
 cpdef enum _Elm_Systray_Category:
 ELM_SYSTRAY_CATEGORY_APP_STATUS
 ELM_SYSTRAY_CATEGORY_COMMUNICATIONS

-- 




[EGIT] [enlightenment/modules/edgar] master 01/01: Remove explicit link to elm

2015-04-08 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/enlightenment/modules/edgar.git/commit/?id=3133ede876345abe372920f310f66b7f155f0c2b

commit 3133ede876345abe372920f310f66b7f155f0c2b
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 8 23:48:30 2015 +0300

Remove explicit link to elm

Not needed with =e18
---
 configure.ac | 1 -
 1 file changed, 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index 1c8af96..458a053 100644
--- a/configure.ac
+++ b/configure.ac
@@ -56,7 +56,6 @@ PKG_CHECK_MODULES(E,
 
 # Explicit link to Eo
 PKG_CHECK_MODULES(EO, [eo])
-PKG_CHECK_MODULES(ELEMENTARY, [elementary])
 
 # Check for python3 and required modules
 # PKG_CHECK_MODULES(PYTHON3, [python3 = 3.2])

-- 




[EGIT] [apps/terminology] master 01/01: L10N: Update Finnish translations

2015-04-14 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/apps/terminology.git/commit/?id=3f5297081368deea4b801d74ad4f645573c4701e

commit 3f5297081368deea4b801d74ad4f645573c4701e
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 15 04:17:13 2015 +0300

L10N: Update Finnish translations
---
 po/fi.po | 266 +--
 1 file changed, 140 insertions(+), 126 deletions(-)

diff --git a/po/fi.po b/po/fi.po
index 9895d1a..d978edd 100644
--- a/po/fi.po
+++ b/po/fi.po
@@ -7,16 +7,14 @@ msgid 
 msgstr 
 Project-Id-Version: enlightenment\n
 Report-Msgid-Bugs-To: enlightenment-de...@lists.sourceforge.net\n
-POT-Creation-Date: 2015-02-15 14:12+0100\n
-PO-Revision-Date: 2014-09-05 15:58+\n
+POT-Creation-Date: 2015-04-14 19:06+0300\n
+PO-Revision-Date: 2015-04-14 19:08+0300\n
 Last-Translator: Kai Huuhko kai.huu...@gmail.com\n
 Language-Team: Finnish f...@li.org\n
 Language: fi\n
 MIME-Version: 1.0\n
 Content-Type: text/plain; charset=UTF-8\n
 Content-Transfer-Encoding: 8bit\n
-X-Launchpad-Export-Date: 2014-10-05 12:16+\n
-X-Generator: Launchpad (build 17196)\n
 
 #: src/bin/controls.c:247
 msgid Controls
@@ -36,9 +34,9 @@ msgstr Jaa vaaka
 
 #: src/bin/controls.c:277
 msgid Miniview
-msgstr 
+msgstr Pienoisnäkymä
 
-#: src/bin/controls.c:287 src/bin/termio.c:956
+#: src/bin/controls.c:287 src/bin/termio.c:963 src/bin/termio.c:3934
 msgid Copy
 msgstr Kopioi
 
@@ -55,9 +53,8 @@ msgid About
 msgstr Tietoja
 
 #: src/bin/controls.c:315
-#, fuzzy
 msgid Close Terminal
-msgstr Sulje kohdistettu pääte
+msgstr Sulje pääte
 
 #: src/bin/about.c:56
 #, c-format
@@ -75,201 +72,213 @@ msgstr 
 %sbrbrJaetaan kahden ehdon BSD-lisenssin alaisuudessa joka on 
 kokonaisuudessaan seuraava:brbr%s
 
-#: src/bin/keyin.c:530
+#: src/bin/keyin.c:543
 msgid Scrolling
 msgstr Vieritys
 
-#: src/bin/keyin.c:531
+#: src/bin/keyin.c:544
 msgid Scroll one page up
 msgstr Vieritä yksi sivu ylöspäin
 
-#: src/bin/keyin.c:532
+#: src/bin/keyin.c:545
 msgid Scroll one page down
 msgstr Vieritä yksi sivu alaspäin
 
-#: src/bin/keyin.c:533
+#: src/bin/keyin.c:546
 msgid Scroll one line up
 msgstr Vieritä yksi rivi ylöspäin
 
-#: src/bin/keyin.c:534
+#: src/bin/keyin.c:547
 msgid Scroll one line down
 msgstr Vieritä yksi rivi alaspäin
 
-#: src/bin/keyin.c:536
+#: src/bin/keyin.c:549
 msgid Copy/Paste
 msgstr Kopioi/Liitä
 
-#: src/bin/keyin.c:537
+#: src/bin/keyin.c:550
 msgid Copy selection to Primary buffer
 msgstr Kopioi valinta primääripuskuriin
 
-#: src/bin/keyin.c:538
+#: src/bin/keyin.c:551
 msgid Copy selection to Clipboard buffer
 msgstr Kopioi valinta leikepöydän puskuriin
 
-#: src/bin/keyin.c:539
+#: src/bin/keyin.c:552
 msgid Paste Primary buffer (highlight)
 msgstr Liitä primääripuskuri (korostettu)
 
-#: src/bin/keyin.c:540
+#: src/bin/keyin.c:553
 msgid Paste Clipboard buffer (ctrl+c/v)
 msgstr Liitä leikepöydän puskuri (ctrl+c/v)
 
-#: src/bin/keyin.c:542
+#: src/bin/keyin.c:555
 msgid Splits/Tabs
 msgstr Jaot/välilehdet
 
-#: src/bin/keyin.c:543
+#: src/bin/keyin.c:556
 msgid Focus to the previous terminal
 msgstr Kohdista edelliseen päätteeseen
 
-#: src/bin/keyin.c:544
+#: src/bin/keyin.c:557
 msgid Focus to the next terminal
 msgstr Kohdista seuraavaan päätteeseen
 
-#: src/bin/keyin.c:545
+#: src/bin/keyin.c:558
 msgid Split horizontally (new below)
 msgstr Jaa vaakatasossa (uusi alla)
 
-#: src/bin/keyin.c:546
+#: src/bin/keyin.c:559
 msgid Split vertically (new on right)
 msgstr Jaa pystytasossa (uusi oikealla)
 
-#: src/bin/keyin.c:547
+#: src/bin/keyin.c:560
 msgid Create a new \tab\
 msgstr Luo uusi välilehti
 
-#: src/bin/keyin.c:548
+#: src/bin/keyin.c:561
 msgid Close the focused terminal
 msgstr Sulje kohdistettu pääte
 
-#: src/bin/keyin.c:549
+#: src/bin/keyin.c:562
 msgid Bring up \tab\ switcher
 msgstr Tuo esiin välilehtivalitsin
 
-#: src/bin/keyin.c:550
+#: src/bin/keyin.c:563
 msgid Switch to terminal tab 1
 msgstr Siirry päätevälilehdelle yksi
 
-#: src/bin/keyin.c:551
+#: src/bin/keyin.c:564
 msgid Switch to terminal tab 2
 msgstr Siirry päätevälilehdelle kaksi
 
-#: src/bin/keyin.c:552
+#: src/bin/keyin.c:565
 msgid Switch to terminal tab 3
 msgstr Siirry päätevälilehdelle kolme
 
-#: src/bin/keyin.c:553
+#: src/bin/keyin.c:566
 msgid Switch to terminal tab 4
 msgstr Siirry päätevälilehdelle neljä
 
-#: src/bin/keyin.c:554
+#: src/bin/keyin.c:567
 msgid Switch to terminal tab 5
 msgstr Siirry päätevälilehdelle viisi
 
-#: src/bin/keyin.c:555
+#: src/bin/keyin.c:568
 msgid Switch to terminal tab 6
 msgstr Siirry päätevälilehdelle kuusi
 
-#: src/bin/keyin.c:556
+#: src/bin/keyin.c:569
 msgid Switch to terminal tab 7
 msgstr Siirry päätevälilehdelle seitsemän
 
-#: src/bin/keyin.c:557
+#: src/bin/keyin.c:570
 msgid Switch to terminal tab 8
 msgstr Siirry päätevälilehdelle kahdeksan
 
-#: src/bin/keyin.c:558
+#: src/bin/keyin.c:571
 msgid Switch to terminal tab 9
 msgstr Siirry päätevälilehdelle yhdeksän
 
-#: src/bin/keyin.c:559

[EGIT] [bindings/python/python-efl] master 03/03: Elm: Add forgotten versionadded

2015-04-14 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=1d5ae5fbc9d06a7c3f2f2e299daa8d4f2a2ed1eb

commit 1d5ae5fbc9d06a7c3f2f2e299daa8d4f2a2ed1eb
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 15 00:37:50 2015 +0300

Elm: Add forgotten versionadded
---
 efl/elementary/general.pyx | 16 ++--
 1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/efl/elementary/general.pyx b/efl/elementary/general.pyx
index 301d0d7..4b1fa2c 100644
--- a/efl/elementary/general.pyx
+++ b/efl/elementary/general.pyx
@@ -452,7 +452,10 @@ cdef class EthumbConnect(Event):
 _event_mapping_register(ELM_ECORE_EVENT_ETHUMB_CONNECT, EthumbConnect)
 
 def on_ethumb_connect(func, *args, **kwargs):
-Use this to set a handler for the ethumb connect event.
+Use this to set a handler for the ethumb connect event.
+
+.. versionadded:: 1.14
+
 return EventHandler(ELM_ECORE_EVENT_ETHUMB_CONNECT, func, *args, **kwargs)
 
 
@@ -470,6 +473,8 @@ def on_config_all_changed(func, *args, **kwargs):
 
 Emitted when the application has reconfigured elementary settings due to an
 external configuration tool asking it to.
+
+.. versionadded:: 1.14
 
 return EventHandler(ELM_EVENT_CONFIG_ALL_CHANGED, func, *args, **kwargs)
 
@@ -499,7 +504,10 @@ _event_mapping_register(ELM_EVENT_POLICY_CHANGED, 
PolicyChanged)
 def on_policy_changed(func, *args, **kwargs):
 Use this to set a handler for the policy changed event.
 
-Emitted when any Elementary's policy value is changed.
+Emitted when any Elementary's policy value is changed.
+
+.. versionadded:: 1.14
+
 return EventHandler(ELM_EVENT_POLICY_CHANGED, func, *args, **kwargs)
 
 
@@ -517,6 +525,8 @@ def on_process_background(func, *args, **kwargs):
 
 Emitted when nothing is visible and the process as a whole should go into a
 background state.
+
+.. versionadded:: 1.14
 
 return EventHandler(ELM_EVENT_PROCESS_BACKGROUND, func, *args, **kwargs)
 
@@ -535,6 +545,8 @@ def on_process_background(func, *args, **kwargs):
 
 Emitted when going from nothing being visible to at least one window being
 visible.
+
+.. versionadded:: 1.14
 
 return EventHandler(ELM_EVENT_PROCESS_FOREGROUND, func, *args, **kwargs)
 

-- 




[EGIT] [bindings/python/python-efl] master 01/02: Elm: Handle init and shutdown inside the module

2015-04-14 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=75f3f3b70a49072caa2e697dce30c0ecaa73552a

commit 75f3f3b70a49072caa2e697dce30c0ecaa73552a
Author: Kai Huuhko kai.huu...@gmail.com
Date:   Wed Apr 15 00:12:03 2015 +0300

Elm: Handle init and shutdown inside the module
---
 efl/elementary/general.pyx | 114 -
 1 file changed, 61 insertions(+), 53 deletions(-)

diff --git a/efl/elementary/general.pyx b/efl/elementary/general.pyx
index 42bea89..0ba4467 100644
--- a/efl/elementary/general.pyx
+++ b/efl/elementary/general.pyx
@@ -262,6 +262,67 @@ from efl.elementary.need cimport elm_need_sys_notify
 
 import sys
 import traceback
+import atexit
+
+
+elm_log = add_logger(efl.elementary)
+cdef int PY_EFL_ELM_LOG_DOMAIN = elm_log.eina_log_domain
+
+def init():
+Initialize Elementary
+
+:return int: The init counter value.
+
+This function initializes Elementary and increments a counter of the number
+of calls to it. It returns the new counter's value.
+
+
+EINA_LOG_DOM_INFO(PY_EFL_ELM_LOG_DOMAIN,
+Initializing efl.elementary, NULL)
+
+# FIXME: Why are we passing the cl args to elm_init here?
+
+cdef:
+int argc, i, arg_len
+char **argv
+char *arg
+
+argc = len(sys.argv)
+argv = char **PyMem_Malloc(argc * sizeof(char *))
+for i in range(argc):
+t = sys.argv[i]
+if isinstance(t, unicode): t = PyUnicode_AsUTF8String(t)
+arg = t
+arg_len = len(arg)
+argv[i] = char *PyMem_Malloc(arg_len + 1)
+memcpy(argv[i], arg, arg_len + 1)
+
+return elm_init(argc, argv)
+
+def shutdown():
+Shut down Elementary
+
+:return int: The init counter value.
+
+This should be called at the end of your application, just before it ceases
+to do any more processing. This will clean up any permanent resources your
+application may have allocated via Elementary that would otherwise persist.
+
+.. note::
+
+shutdown() will iterate main loop until all ecore_evas are freed. There
+is a possibility to call your ecore callbacks(timer, animator, event,
+job, and etc.) in shutdown()
+
+
+EINA_LOG_DOM_INFO(PY_EFL_ELM_LOG_DOMAIN,
+Shutting down efl.elementary, NULL)
+return elm_shutdown()
+
+
+init()
+atexit.register(shutdown)
+
 
 cdef void py_elm_sys_notify_send_cb(void *data, unsigned int id):
 cdef object func, func_data
@@ -378,59 +439,6 @@ cdef class FontProperties(object):
 def __get__(self):
 return eina_list_strings_to_python_list(self.efp.styles)
 
-elm_log = add_logger(efl.elementary)
-cdef int PY_EFL_ELM_LOG_DOMAIN = elm_log.eina_log_domain
-
-def init():
-Initialize Elementary
-
-:return int: The init counter value.
-
-This function initializes Elementary and increments a counter of the number
-of calls to it. It returns the new counter's value.
-
-
-EINA_LOG_DOM_INFO(PY_EFL_ELM_LOG_DOMAIN,
-Initializing efl.elementary, NULL)
-
-# FIXME: Why are we passing the cl args to elm_init here?
-
-cdef:
-int argc, i, arg_len
-char **argv
-char *arg
-
-argc = len(sys.argv)
-argv = char **PyMem_Malloc(argc * sizeof(char *))
-for i in range(argc):
-t = sys.argv[i]
-if isinstance(t, unicode): t = PyUnicode_AsUTF8String(t)
-arg = t
-arg_len = len(arg)
-argv[i] = char *PyMem_Malloc(arg_len + 1)
-memcpy(argv[i], arg, arg_len + 1)
-
-return elm_init(argc, argv)
-
-def shutdown():
-Shut down Elementary
-
-:return int: The init counter value.
-
-This should be called at the end of your application, just before it ceases
-to do any more processing. This will clean up any permanent resources your
-application may have allocated via Elementary that would otherwise persist.
-
-.. note::
-
-shutdown() will iterate main loop until all ecore_evas are freed. There
-is a possibility to call your ecore callbacks(timer, animator, event,
-job, and etc.) in shutdown()
-
-
-EINA_LOG_DOM_INFO(PY_EFL_ELM_LOG_DOMAIN,
-Shutting down efl.elementary, NULL)
-return elm_shutdown()
 
 def run():
 Run Elementary's main loop

-- 




[EGIT] [bindings/python/python-efl] master 01/01: print()--

2015-12-09 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=5d73c59088961ece986c6754615b68d9bbd0475a

commit 5d73c59088961ece986c6754615b68d9bbd0475a
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Wed Dec 9 21:02:59 2015 +0200

print()--
---
 efl/elementary/cnp_callbacks.pxi | 10 --
 1 file changed, 10 deletions(-)

diff --git a/efl/elementary/cnp_callbacks.pxi b/efl/elementary/cnp_callbacks.pxi
index 83b4646..8c49ae7 100644
--- a/efl/elementary/cnp_callbacks.pxi
+++ b/efl/elementary/cnp_callbacks.pxi
@@ -106,7 +106,6 @@ cdef Eina_Bool py_elm_drop_cb(void *data, Evas_Object *obj, 
Elm_Selection_Data *
 :param ev: struct holding information about selected data
 
 """
-print("in drop_cb")
 assert data != NULL, "data is NULL"
 cdef:
 SelectionData sd = SelectionData.__new__(SelectionData)
@@ -136,7 +135,6 @@ cdef Elm_Object_Item *py_elm_xy_item_get_cb(Evas_Object 
*obj, Evas_Coord x, Evas
 :return: object under x,y cords or NULL if not found.
 
 """
-print("in xy_item_get_cb")
 assert obj != NULL, "obj is NULL"
 
 cdef:
@@ -187,7 +185,6 @@ cdef Evas_Object *py_elm_drag_icon_create_cb(
 :return: An object to fill the drag window with or NULL if not needed
 
 """
-print("in drag_icon_create_cb")
 assert data != NULL, "data is NULL"
 
 cdef:
@@ -227,7 +224,6 @@ cdef void py_elm_drag_state_cb(void *data, Evas_Object 
*obj) with gil:
 :param obj: The object where the drag started
 
 """
-print("in drag_state_cb")
 assert data != NULL, "data is NULL"
 
 cdef:
@@ -248,7 +244,6 @@ cdef void py_elm_drag_done_cb(void *data, Evas_Object *obj, 
Eina_Bool accepted)
 :param accepted: TRUE if the dropped-data is accepted on drop
 
 """
-print("in drag_done_cb")
 assert data != NULL, "data is NULL"
 
 cdef:
@@ -269,7 +264,6 @@ cdef void py_elm_drag_accept_cb(void *data, Evas_Object 
*obj, Eina_Bool doaccept
 :param doaccept: A boolean as to if the target accepts the drag or not
 
 """
-print("in drag_accept_cb")
 assert data != NULL, "data is NULL"
 
 cdef:
@@ -292,7 +286,6 @@ cdef void py_elm_drag_pos_cb(void *data, Evas_Object *obj,
 :param y: The Y coordinate relative to the top-left of the object
 
 """
-print("in drag_pos_cb")
 assert data != NULL, "data is NULL"
 
 cdef:
@@ -323,8 +316,6 @@ cdef void py_elm_drag_item_container_pos(
 :param action: The drag action to be done
 
 """
-print("in drag_item_container_pos")
-
 cdef:
 evasObject o = object_from_instance(cont)
 ObjectItem item = _object_item_to_python(it)
@@ -349,7 +340,6 @@ cdef Eina_Bool py_elm_drop_item_container_cb(
 :param yposret: Position relative to item (upper (-1), middle (0), bottom 
(1)
 
 """
-print("in drop_item_container_cb")
 assert obj != NULL, "obj is NULL"
 
 cdef:

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Elementary.dnd: Fix various leftover issues

2015-12-09 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=75fa5ff2565dec7ae002b33b4f9f12171c9c

commit 75fa5ff2565dec7ae002b33b4f9f12171c9c
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Wed Dec 9 21:26:29 2015 +0200

Elementary.dnd: Fix various leftover issues
---
 efl/elementary/object.pxi   | 69 +
 examples/elementary/test_dnd.py |  2 +-
 2 files changed, 43 insertions(+), 28 deletions(-)

diff --git a/efl/elementary/object.pxi b/efl/elementary/object.pxi
index 27c91fb..5c5ddad 100644
--- a/efl/elementary/object.pxi
+++ b/efl/elementary/object.pxi
@@ -1669,19 +1669,20 @@ cdef class Object(SmartObject):
 raise RuntimeError("Could not add drop target.")
 
 def drop_target_del(self, Elm_Sel_Format fmt,
-entercb, enterdata, leavecb, leavedata, poscb, posdata, dropcb, 
dropdata):
+entercb=None, enterdata=None, leavecb=None, leavedata=None,
+poscb=None, posdata=None, dropcb=None, dropdata=None):
 """Deletes the drop target status of an object
 
-@param format The formats supported for dropping
-@param entercb The function to call when the object is entered with a 
drag
-@param enterdata The application data to pass to enterdata
-@param leavecb The function to call when the object is left with a drag
-@param leavedata The application data to pass to leavedata
-@param poscb The function to call when the object has a drag over it
-@param posdata The application data to pass to posdata
-@param dropcb The function to call when a drop has occurred
-@param dropdata The application data to pass to dropcb
-@return Returns @c EINA_TRUE, if successful, or @c EINA_FALSE if not.
+:param format: The formats supported for dropping
+:param entercb: The function to call when the object is entered with a 
drag
+:param enterdata: The application data to pass to enterdata
+:param leavecb: The function to call when the object is left with a 
drag
+:param leavedata: The application data to pass to leavedata
+:param poscb: The function to call when the object has a drag over it
+:param posdata: The application data to pass to posdata
+:param dropcb: The function to call when a drop has occurred
+:param dropdata: The application data to pass to dropcb
+:raise RuntimeError: if drop target cannot be deleted
 
 .. versionadded:: 1.17
 
@@ -1717,8 +1718,8 @@ cdef class Object(SmartObject):
 raise RuntimeError("Could not del drop target.")
 
 def drag_start(self, Elm_Sel_Format format,
-data, Elm_Xdnd_Action action, createicon, createdata,
-dragpos, dragdata, acceptcb, acceptdata, dragdone, donecbdata):
+data, Elm_Xdnd_Action action, createicon=None, createdata=None,
+dragpos=None, dragdata=None, acceptcb=None, acceptdata=None, 
dragdone=None, donecbdata=None):
 """Begins a drag given a source object
 
 :param format: The drag formats supported by the data
@@ -1742,23 +1743,37 @@ cdef class Object(SmartObject):
 .. versionadded:: 1.17
 
 """
-if not callable(createicon) \
-or not callable(dragpos) \
-or not callable(acceptcb) \
-or not callable(dragdone):
-raise TypeError("A callback passed is not callable.")
-
-create = (createicon, createdata)
-pos = (dragpos, dragdata)
-accept = (acceptcb, acceptdata)
-done = (dragdone, donecbdata)
+if createicon:
+if not callable(createicon):
+raise TypeError("A callback passed is not callable.")
+create = (createicon, createdata)
+Py_INCREF(create)
+if dragpos:
+if not callable(dragpos):
+raise TypeError("A callback passed is not callable.")
+pos = (dragpos, dragdata)
+Py_INCREF(pos)
+if acceptcb:
+if not callable(acceptcb):
+raise TypeError("A callback passed is not callable.")
+accept = (acceptcb, acceptdata)
+Py_INCREF(accept)
+if dragdone:
+if not callable(dragdone):
+raise TypeError("A callback passed is not callable.")
+done = (dragdone, donecbdata)
+Py_INCREF(done)
 
 if not elm_drag_start(self.obj, format,
 data, action,
-py_elm_drag_icon_create_cb, create,
-py_elm_drag_pos_cb, pos,
-py_elm_drag_accept_cb, accept,
-py_elm_drag_state_cb, done
+py_elm_drag_icon_create_cb if createicon 
is not None else NULL,
+create if createicon is not None else 

[EGIT] [bindings/python/python-efl] master 01/01: Elementary: Implement drag and drop

2015-12-09 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=453c2a123c61c91d4af37c66e212ded6437e7796

commit 453c2a123c61c91d4af37c66e212ded6437e7796
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Wed Dec 9 20:54:07 2015 +0200

Elementary: Implement drag and drop

Has some issues which we can work on later, should be API stable now.
---
 efl/elementary/cnp_callbacks.pxi  | 176 +++-
 efl/elementary/gengrid_widget.pxi | 162 +-
 efl/elementary/genlist_widget.pxi | 169 ++-
 efl/elementary/object.pxi | 336 ++
 examples/elementary/test_dnd.py   | 255 +++--
 5 files changed, 626 insertions(+), 472 deletions(-)

diff --git a/efl/elementary/cnp_callbacks.pxi b/efl/elementary/cnp_callbacks.pxi
index 2e56c95..83b4646 100644
--- a/efl/elementary/cnp_callbacks.pxi
+++ b/efl/elementary/cnp_callbacks.pxi
@@ -18,6 +18,7 @@ cdef extern from "Elementary.h":
 ctypedef void(*Elm_Drag_Done)   (void *data, 
Evas_Object *obj, Eina_Bool accepted)
 ctypedef void(*Elm_Drag_Accept) (void *data, 
Evas_Object *obj, Eina_Bool doaccept)
 ctypedef void(*Elm_Drag_Pos)(void *data, 
Evas_Object *obj, Evas_Coord x, Evas_Coord y, Elm_Xdnd_Action action)
+ctypedef void(*Elm_Drag_Start)  (void *data, 
Evas_Object *obj)
 ctypedef void(*Elm_Drag_Item_Container_Pos) (void *data, 
Evas_Object *cont, Elm_Object_Item *it, Evas_Coord x, Evas_Coord y, int 
xposret, int yposret, Elm_Xdnd_Action action)
 ctypedef Eina_Bool   (*Elm_Drop_Item_Container_Cb)  (void *data, 
Evas_Object *obj, Elm_Object_Item *it, Elm_Selection_Data *ev, int xposret, int 
yposret)
 
@@ -37,30 +38,22 @@ cdef extern from "Elementary.h":
 
 ctypedef _Elm_Drag_User_Info Elm_Drag_User_Info
 
-ctypedef Eina_Bool  (*Elm_Item_Container_Data_Get_Cb)(
-Evas_Object *obj,
-Elm_Object_Item *it,
-Elm_Drag_User_Info *info)
-
-Eina_Bool elm_drag_item_container_add(Evas_Object *obj, double tm_to_anim, 
double tm_to_drag, Elm_Xy_Item_Get_Cb itemgetcb, Elm_Item_Container_Data_Get_Cb 
data_get)
-Eina_Bool elm_drag_item_container_del(Evas_Object *obj)
-Eina_Bool elm_drop_item_container_add(Evas_Object *obj,
-  Elm_Sel_Format format,
-  Elm_Xy_Item_Get_Cb itemgetcb,
-  Elm_Drag_State entercb, void *enterdata,
-  Elm_Drag_State leavecb, void *leavedata,
-  Elm_Drag_Item_Container_Pos poscb, void *posdata,
-  Elm_Drop_Item_Container_Cb dropcb, void *cbdata)
-Eina_Bool elm_drop_item_container_del(Evas_Object *obj)
+ctypedef Eina_Bool   (*Elm_Item_Container_Data_Get_Cb)(Evas_Object 
*obj, Elm_Object_Item *it, Elm_Drag_User_Info *info)
 
 Eina_Bool   elm_cnp_selection_set(Evas_Object *obj, 
Elm_Sel_Type selection, Elm_Sel_Format format, const void *buf, size_t buflen)
 Eina_Bool   elm_cnp_selection_get(Evas_Object *obj, 
Elm_Sel_Type selection, Elm_Sel_Format format, Elm_Drop_Cb datacb, void *udata)
 Eina_Bool   elm_object_cnp_selection_clear(Evas_Object *obj, 
Elm_Sel_Type selection)
 voidelm_cnp_selection_loss_callback_set(Evas_Object 
*obj, Elm_Sel_Type selection, Elm_Selection_Loss_Cb func, const void *data)
-# Eina_Bool   elm_drop_target_add(Evas_Object *obj, 
Elm_Sel_Format format, Elm_Drag_State entercb, void *enterdata, Elm_Drag_State 
leavecb, void *leavedata, Elm_Drag_Pos poscb, void *posdata, Elm_Drop_Cb 
dropcb, void *cbdata)
-# Eina_Bool   elm_drop_target_del(Evas_Object *obj)
-# Eina_Bool   elm_drag_start(Evas_Object *obj, Elm_Sel_Format 
format, const char *data, Elm_Xdnd_Action action, Elm_Drag_Icon_Create_Cb 
createicon, void *createdata, Elm_Drag_Pos dragpos, void *dragdata, 
Elm_Drag_Accept acceptcb, void *acceptdata, Elm_Drag_State dragdone, void 
*donecbdata)
-# Eina_Bool   elm_drag_action_set(Evas_Object *obj, 
Elm_Xdnd_Action action)
+Eina_Bool   elm_drop_target_add(Evas_Object *obj, 
Elm_Sel_Format format, Elm_Drag_State entercb, void *enterdata, Elm_Drag_State 
leavecb, void *leavedata, Elm_Drag_Pos poscb, void *posdata, Elm_Drop_Cb 
dropcb, void *dropdata)
+Eina_Bool   elm_drop_target_del(Evas_Object *obj, 
Elm_Sel_Format format, Elm_Drag_State entercb, void *enterdata, Elm_Drag_State 
leavecb, void *leavedata, Elm_Drag_Pos poscb, void *posdata, Elm_Drop_Cb 
dropcb, void *dropdata)
+Eina_Bool   elm_drag_start(Evas_Object *obj, Elm_Sel_Format 
format, const char *data, Elm_Xdnd_Action action, Elm_Drag_Icon_Create_Cb 
createicon, void *createdata, Elm_Drag_Pos dragpos, void *dragdata, 
Elm_Drag_Accept acceptcb, void *acceptdata, Elm_Drag_State dragdone, void 
*

[EGIT] [bindings/python/python-efl] master 01/02: api_coverage.py: Include all files in cdef search

2015-12-25 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=16f7cb1a24e93e1a52bdd02206e0e8a4e2054645

commit 16f7cb1a24e93e1a52bdd02206e0e8a4e2054645
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Thu Dec 17 06:12:40 2015 +0200

api_coverage.py: Include all files in cdef search

Fixes Elm
---
 api_coverage.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/api_coverage.py b/api_coverage.py
index f08a783..a0c988b 100755
--- a/api_coverage.py
+++ b/api_coverage.py
@@ -163,8 +163,8 @@ def get_pyapis(pxd_path, header_name, prefix):
 
 for path, dirs, files in os.walk(pxd_path):
 for f in files:
-if not f.endswith(".pxd"):
-continue
+# if not f.endswith(".pxd"):
+# continue
 open_args = (os.path.join(path, f),)
 open_kwargs = dict(mode="r")
 if sys.version_info[0] > 2:

-- 




[EGIT] [bindings/python/python-efl] master 02/02: Ecore.Exe: Add missing documentation for the Events

2015-12-25 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=6c16e2f7464e95cd6f0a26fcb4c1432baf1f97d9

commit 6c16e2f7464e95cd6f0a26fcb4c1432baf1f97d9
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Fri Dec 25 21:02:39 2015 +0200

Ecore.Exe: Add missing documentation for the Events
---
 efl/ecore/efl.ecore_exe.pxi | 23 +--
 1 file changed, 13 insertions(+), 10 deletions(-)

diff --git a/efl/ecore/efl.ecore_exe.pxi b/efl/ecore/efl.ecore_exe.pxi
index 14a3410..4f9171f 100644
--- a/efl/ecore/efl.ecore_exe.pxi
+++ b/efl/ecore/efl.ecore_exe.pxi
@@ -774,9 +774,9 @@ def exe_pipe_run(exe_cmd, int flags=0, data=None):
 cdef class EventExeAdd(Event):
 """Represents Ecore_Exe_Event_Add event from C-api.
 
-This event notifies the process created with :py:class:`Exe` was started.
+This event notifies that the process created with :py:class:`Exe` has been 
started.
 
-See property ``exe`` for ``Exe`` instance.
+:ivar Exe exe: Instance of :py:class:`Exe` that created this event.
 """
 cdef int _set_obj(self, void *o) except 0:
 cdef Ecore_Exe_Event_Add *obj
@@ -793,9 +793,14 @@ cdef class EventExeAdd(Event):
 cdef class EventExeDel(Event):
 """Represents Ecore_Exe_Event_Del from C-api.
 
-This event notifies the process created with ``Exe`` is now dead.
+This event notifies that the process created with ``Exe`` is now dead.
 
-See property ``exe`` for ``Exe`` instance.
+:ivar Exe exe: Instance of :py:class:`Exe` that created this event.
+:ivar int pid: Process ID
+:ivar int exit_code: Exit code
+:ivar int exit_signal: Exit signal
+:ivar bool exited: Has process exited
+:ivar bool signalled: Has process been signalled
 """
 cdef int _set_obj(self, void *o) except 0:
 cdef Ecore_Exe_Event_Del *obj
@@ -823,12 +828,10 @@ cdef class EventExeData(Event):
 This event is issued by :py:class:`Exe` instances created with flags that
 allow reading from either stdout or stderr.
 
-See properties:
-
-  - **exe** instance of :py:class:`Exe` that created this event.
-  - **data** the raw string buffer with binary data from child process.
-  - **size** the size of **data** (same as ``len(data)``)
-  - **lines** list of strings with all text lines
+:ivar Exe exe: Instance of :py:class:`Exe` that created this event.
+:ivar string ~EventExeData.data: The raw string buffer with binary data 
from child process.
+:ivar int ~EventExeData.size: The size of **data** (same as ``len(data)``)
+:ivar list lines: List of strings with all text lines
 """
 cdef int _set_obj(self, void *o) except 0:
 cdef Ecore_Exe_Event_Data *obj

-- 




[EGIT] [bindings/python/python-efl] master 01/02: Clean up cruft code

2016-02-02 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=fc987411daab68c60aa66c6ad3574426e3578ed4

commit fc987411daab68c60aa66c6ad3574426e3578ed4
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Tue Feb 2 21:37:02 2016 +0200

Clean up cruft code
---
 efl/edje/efl.edje_external.pxi |  3 ---
 efl/elementary/label.pxi   | 21 -
 2 files changed, 24 deletions(-)

diff --git a/efl/edje/efl.edje_external.pxi b/efl/edje/efl.edje_external.pxi
index 174f43d..564c414 100644
--- a/efl/edje/efl.edje_external.pxi
+++ b/efl/edje/efl.edje_external.pxi
@@ -78,9 +78,6 @@ cdef ExternalParam ExternalParam_from_ptr(Edje_External_Param 
*param):
 p.obj = param
 return p
 
-#def _ExternalParam_from_ptr(uintptr_t ptr):
-#return ExternalParam_from_ptr(ptr)
-
 
 cdef class ExternalParamInfo:
 property name:
diff --git a/efl/elementary/label.pxi b/efl/elementary/label.pxi
index 34cf742..3023e47 100644
--- a/efl/elementary/label.pxi
+++ b/efl/elementary/label.pxi
@@ -100,27 +100,6 @@ cdef class Label(LayoutClass):
 def ellipsis_get(self):
 return elm_label_ellipsis_get(self.obj)
 
-# FIXME: Why was this commented out???
-# property slide:
-# """
-#
-# .. deprecated:: 1.8
-# Use :py:attr:`slide_mode` instead.
-#
-# """
-# def __get__(self):
-# return self.slide_get()
-#
-# def __set__(self, slide):
-# self.slide_set(True if slide else False)
-#
-# @DEPRECATED("1.8", "Use :py:attr:`slide_mode` instead.")
-# def slide_set(self, bint slide):
-# elm_label_slide_mode_set(self.obj, 2 if slide else 0)
-# @DEPRECATED("1.8", "Use :py:attr:`slide_mode` instead.")
-# def slide_get(self):
-# return bool(elm_label_slide_mode_get(self.obj))
-
 property slide_duration:
 """The duration time in moving text from slide begin position to
 slide end position

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Elm.MultiButtonEntry: Fix filter callback

2016-02-02 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=523fe8ad4dc3e271586ade9972faec24a69e0a2c

commit 523fe8ad4dc3e271586ade9972faec24a69e0a2c
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Tue Feb 2 21:23:02 2016 +0200

Elm.MultiButtonEntry: Fix filter callback
---
 efl/elementary/multibuttonentry.pxi  | 31 ++--
 efl/elementary/multibuttonentry_cdef.pxi |  2 +-
 examples/elementary/test_multibuttonentry.py | 15 +++---
 3 files changed, 14 insertions(+), 34 deletions(-)

diff --git a/efl/elementary/multibuttonentry.pxi 
b/efl/elementary/multibuttonentry.pxi
index 13c28e3..8c6e272 100644
--- a/efl/elementary/multibuttonentry.pxi
+++ b/efl/elementary/multibuttonentry.pxi
@@ -18,45 +18,26 @@
 
 include "multibuttonentry_cdef.pxi"
 
-class MultiButtonEntryFilterOut(Exception):
-"""An exception you may raise in an item filter callback if you wish to 
prevent addition of the item"""
-pass
-
 cdef Eina_Bool _multibuttonentry_filter_callback(Evas_Object *obj, \
-char *item_label, void *item_data, void *data) with gil:
+const char *item_label, void *item_data, void *data) with gil:
 
 cdef:
 MultiButtonEntry mbe = object_from_instance(obj)
-object ret
+bint ret
 list callbacks = mbe._item_filters
 
 for func, args, kargs in callbacks:
 try:
-# raise MultiButtonEntryFilterOut -> cancels item add
-# ret is None -> no change, continue to next filter
-# ret is not None -> change label to value of ret, continue to 
next filter
 ret = func(mbe, _ctouni(item_label), *args, **kargs)
-except MultiButtonEntryFilterOut:
-#free(item_label) # FIXME: This will result in a double free, find 
out if it's bad elm documentation
-  #or wrong ref handling on our side.
-
-#item_label = NULL
-return 0
 except Exception:
 traceback.print_exc()
 continue
 
 if ret:
-if not isinstance(ret, basestring):
-EINA_LOG_DOM_WARN(PY_EFL_ELM_LOG_DOMAIN,
-"Ignoring invalid return value from MultiButtonEntry item 
filter callback!", NULL)
-continue
-if isinstance(ret, unicode): ret = PyUnicode_AsUTF8String(ret)
-#free(item_label) # FIXME: This will result in a double free, find 
out if it's bad elm documentation
-  #or wrong ref handling on our side.
-
-item_label = strdup(ret) # Elm will manage the string
- # FIXME: This doesn't apply, why?
+continue
+else:
+return 0 # This emulates the behavior of C code where callbacks
+ # are iterated until EINA_FALSE is returned by user
 
 return 1
 
diff --git a/efl/elementary/multibuttonentry_cdef.pxi 
b/efl/elementary/multibuttonentry_cdef.pxi
index 5b2aa34..f8b8218 100644
--- a/efl/elementary/multibuttonentry_cdef.pxi
+++ b/efl/elementary/multibuttonentry_cdef.pxi
@@ -1,6 +1,6 @@
 cdef extern from "Elementary.h":
 
-ctypedef Eina_Bool (*Elm_Multibuttonentry_Item_Filter_Cb)(Evas_Object 
*obj, char *item_label, void *item_data, void *data)
+ctypedef Eina_Bool (*Elm_Multibuttonentry_Item_Filter_Cb)(Evas_Object 
*obj, const char *item_label, void *item_data, void *data)
 ctypedef char * (*Elm_Multibuttonentry_Format_Cb)(int count, void *data)
 
 Evas_Object *elm_multibuttonentry_add(Evas_Object *parent)
diff --git a/examples/elementary/test_multibuttonentry.py 
b/examples/elementary/test_multibuttonentry.py
index 989598f..59681c4 100644
--- a/examples/elementary/test_multibuttonentry.py
+++ b/examples/elementary/test_multibuttonentry.py
@@ -6,7 +6,7 @@ from efl import elementary
 from efl.elementary import StandardWindow
 from efl.elementary import Box
 from efl.elementary import Button
-from efl.elementary import MultiButtonEntry, MultiButtonEntryFilterOut
+from efl.elementary import MultiButtonEntry
 from efl.elementary import Scroller, ELM_SCROLLER_POLICY_OFF, 
ELM_SCROLLER_POLICY_AUTO
 
 SCROLL_POLICY_VERT = ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_AUTO
@@ -55,13 +55,13 @@ def cb_btn_clear2(btn, mbe):
 
 def cb_filter1(mbe, text):
 print(text)
+return True
 
 def cb_filter2(mbe, text):
-return text[:-2]
-
-def cb_filter3(mbe, text):
-print(text)
-#raise MultiButtonEntryFilterOut
+if text == "nope":
+return False
+else:
+return True
 
 def cb_print(btn, mbe):
 for i in mbe.items:
@@ -86,10 +86,9 @@ def multibuttonentry_clicked(obj, item=None):
 mbe.callback_item_selected_add(cb_item_selected)
 mbe.callback_item_clicked_add(cb_item_clicked)
 mbe.callback_item_longp

[EGIT] [bindings/python/python-efl] master 01/03: Edje: Make ExternalParam_from_ptr a C only function

2016-02-02 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=684ad779dce9125dc8ca50f6dfb015075fb4338c

commit 684ad779dce9125dc8ca50f6dfb015075fb4338c
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Tue Feb 2 14:11:08 2016 +0200

Edje: Make ExternalParam_from_ptr a C only function
---
 efl/edje/efl.edje_edit.pyx| 2 +-
 efl/edje/efl.edje_edit_part_state.pxi | 2 +-
 efl/edje/efl.edje_external.pxi| 6 ++
 include/efl.edje.pxd  | 5 -
 4 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/efl/edje/efl.edje_edit.pyx b/efl/edje/efl.edje_edit.pyx
index d867f14..29187dc 100644
--- a/efl/edje/efl.edje_edit.pyx
+++ b/efl/edje/efl.edje_edit.pyx
@@ -23,7 +23,7 @@ from efl.utils.conversions cimport _touni, _ctouni, \
 eina_list_strings_to_python_list
 from efl.eo cimport _register_decorated_callbacks
 from efl.evas cimport Canvas
-from efl.edje cimport Edje_Part_Type, Edje
+from efl.edje cimport Edje_Part_Type, Edje, ExternalParam_from_ptr
 from efl.edje import EDJE_PART_TYPE_EXTERNAL
 
 
diff --git a/efl/edje/efl.edje_edit_part_state.pxi 
b/efl/edje/efl.edje_edit_part_state.pxi
index 0515734..f2fac28 100644
--- a/efl/edje/efl.edje_edit_part_state.pxi
+++ b/efl/edje/efl.edje_edit_part_state.pxi
@@ -528,7 +528,7 @@ cdef class State:
 # lst = edje_edit_state_external_params_list_get(self.edje.obj, 
self.part,
 #self.name, self.value)
 # while lst:
-# p = c_edje._ExternalParam_from_ptr(lst.data)
+# p = ExternalParam_from_ptr(lst.data)
 # if p is not None:
 # ret.append(p)
 # lst = lst.next
diff --git a/efl/edje/efl.edje_external.pxi b/efl/edje/efl.edje_external.pxi
index 021c509..174f43d 100644
--- a/efl/edje/efl.edje_external.pxi
+++ b/efl/edje/efl.edje_external.pxi
@@ -78,10 +78,8 @@ cdef ExternalParam 
ExternalParam_from_ptr(Edje_External_Param *param):
 p.obj = param
 return p
 
-# XXX: this should be C-only, but it would require edje_edit
-# XXX: being able to use it.
-def _ExternalParam_from_ptr(uintptr_t ptr):
-return ExternalParam_from_ptr(ptr)
+#def _ExternalParam_from_ptr(uintptr_t ptr):
+#return ExternalParam_from_ptr(ptr)
 
 
 cdef class ExternalParamInfo:
diff --git a/include/efl.edje.pxd b/include/efl.edje.pxd
index 177f52c..c87de8b 100644
--- a/include/efl.edje.pxd
+++ b/include/efl.edje.pxd
@@ -26,7 +26,7 @@ cdef extern from "Edje.h":
 cdef int EDJE_EXTERNAL_INT_UNSET
 cdef double EDJE_EXTERNAL_DOUBLE_UNSET
 cdef unsigned int EDJE_EXTERNAL_TYPE_ABI_VERSION
-
+
 
 # Enums
 #
@@ -567,3 +567,6 @@ cdef class Edje(Object):
 cdef void message_send_int_set(self, int id, data)
 cdef void message_send_float_set(self, int id, data)
 cdef message_send_set(self, int id, data)
+
+
+cdef ExternalParam ExternalParam_from_ptr(Edje_External_Param *param)
\ No newline at end of file

-- 




[EGIT] [bindings/python/python-efl] master 03/03: Elm.MultiButtonEntry: Attempt to fix leaks, add more docs

2016-02-02 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=3661a78c96a6a264f131d5b9d344248180b68c6b

commit 3661a78c96a6a264f131d5b9d344248180b68c6b
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Tue Feb 2 20:29:21 2016 +0200

Elm.MultiButtonEntry: Attempt to fix leaks, add more docs
---
 efl/elementary/multibuttonentry.pxi  | 150 +--
 efl/elementary/multibuttonentry_cdef.pxi |   4 +-
 examples/elementary/test_multibuttonentry.py |  46 +---
 3 files changed, 153 insertions(+), 47 deletions(-)

diff --git a/efl/elementary/multibuttonentry.pxi 
b/efl/elementary/multibuttonentry.pxi
index aa874bc..13c28e3 100644
--- a/efl/elementary/multibuttonentry.pxi
+++ b/efl/elementary/multibuttonentry.pxi
@@ -18,24 +18,51 @@
 
 include "multibuttonentry_cdef.pxi"
 
+class MultiButtonEntryFilterOut(Exception):
+"""An exception you may raise in an item filter callback if you wish to 
prevent addition of the item"""
+pass
+
 cdef Eina_Bool _multibuttonentry_filter_callback(Evas_Object *obj, \
-const char *item_label, void *item_data, void *data) with gil:
+char *item_label, void *item_data, void *data) with gil:
 
 cdef:
 MultiButtonEntry mbe = object_from_instance(obj)
-bint ret
-
-(callback, a, ka) = data
-
-try:
-ret = callback(mbe, _ctouni(item_label), *a, **ka)
-except Exception:
-traceback.print_exc()
-
-return ret
+object ret
+list callbacks = mbe._item_filters
+
+for func, args, kargs in callbacks:
+try:
+# raise MultiButtonEntryFilterOut -> cancels item add
+# ret is None -> no change, continue to next filter
+# ret is not None -> change label to value of ret, continue to 
next filter
+ret = func(mbe, _ctouni(item_label), *args, **kargs)
+except MultiButtonEntryFilterOut:
+#free(item_label) # FIXME: This will result in a double free, find 
out if it's bad elm documentation
+  #or wrong ref handling on our side.
+
+#item_label = NULL
+return 0
+except Exception:
+traceback.print_exc()
+continue
+
+if ret:
+if not isinstance(ret, basestring):
+EINA_LOG_DOM_WARN(PY_EFL_ELM_LOG_DOMAIN,
+"Ignoring invalid return value from MultiButtonEntry item 
filter callback!", NULL)
+continue
+if isinstance(ret, unicode): ret = PyUnicode_AsUTF8String(ret)
+#free(item_label) # FIXME: This will result in a double free, find 
out if it's bad elm documentation
+  #or wrong ref handling on our side.
+
+item_label = strdup(ret) # Elm will manage the string
+ # FIXME: This doesn't apply, why?
+
+return 1
 
 cdef char * _multibuttonentry_format_cb(int count, void *data) with gil:
-(callback, a, ka) = data
+cdef MultiButtonEntry obj = data
+(callback, a, ka) = obj.internal_data["multibuttonentry_format_cb"]
 
 try:
 s = callback(count, *a, **ka)
@@ -44,8 +71,7 @@ cdef char * _multibuttonentry_format_cb(int count, void 
*data) with gil:
 traceback.print_exc()
 return NULL
 
-# FIXME: leak here
-return strdup(s)
+return strdup(s) # Elm will manage the string
 
 
 cdef class MultiButtonEntryItem(ObjectItem):
@@ -198,6 +224,8 @@ cdef class MultiButtonEntry(Object):
 
 """
 
+cdef list _item_filters
+
 def __init__(self, evasObject parent, *args, **kwargs):
 """MultiButtonEntry(...)
 
@@ -213,6 +241,7 @@ cdef class MultiButtonEntry(Object):
 _py_elm_mbe_item_added_cb, NULL
 )
 self._set_properties_from_keyword_args(kwargs)
+self._item_filters = list()
 
 property entry:
 """The Entry object child of the multibuttonentry.
@@ -227,7 +256,10 @@ cdef class MultiButtonEntry(Object):
 return object_from_instance(elm_multibuttonentry_entry_get(self.obj))
 
 property expanded:
-"""The expanded state of the multibuttonentry.
+"""Control the multibuttonentry to expanded state.
+
+In expanded state, the complete entry will be displayed.
+Otherwise, only single line of the entry will be displayed.
 
 :type: bool
 
@@ -342,6 +374,11 @@ cdef class MultiButtonEntry(Object):
 return None
 
 property items:
+"""List of items in the multibuttonentry
+
+:type: list
+
+"""
 def __get__(self):
 return 
_object_item_list_to_python(elm_multibuttonentry_items_get(self.obj))
 
@@ -349,6 +386,11 @@ cdef class MultiButton

[EGIT] [bindings/python/python-efl] master 02/02: Elm.FileSelector: Fix ref leak

2016-02-02 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=1189e17fe0cd159190ebb6ae9b7a7f3dc9caee0b

commit 1189e17fe0cd159190ebb6ae9b7a7f3dc9caee0b
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Tue Feb 2 21:41:37 2016 +0200

Elm.FileSelector: Fix ref leak
---
 efl/elementary/fileselector.pxi | 8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/efl/elementary/fileselector.pxi b/efl/elementary/fileselector.pxi
index a861bfb..77ef2d7 100644
--- a/efl/elementary/fileselector.pxi
+++ b/efl/elementary/fileselector.pxi
@@ -34,6 +34,8 @@ cdef class Fileselector(LayoutClass):
 
 """
 
+cdef list _custom_filters
+
 def __init__(self, evasObject parent, *args, **kwargs):
 """Fileselector(...)
 
@@ -45,6 +47,7 @@ cdef class Fileselector(LayoutClass):
 """
 self._set_obj(elm_fileselector_add(parent.obj))
 self._set_properties_from_keyword_args(kwargs)
+self._custom_filters = list()
 
 property is_save:
 """Enable/disable the file name entry box where the user can type
@@ -351,9 +354,7 @@ cdef class Fileselector(LayoutClass):
 
 """
 cb_data = (func, data)
-# FIXME: This is now a ref leak. It should be stored somewhere and
-#deleted in the remove method.
-Py_INCREF(cb_data)
+self._custom_filters.append(cb_data)
 
 if isinstance(filter_name, unicode): filter_name = 
PyUnicode_AsUTF8String(filter_name)
 elm_fileselector_custom_filter_append(self.obj,
@@ -373,6 +374,7 @@ cdef class Fileselector(LayoutClass):
 .. versionadded:: 1.8
 
 """
+del self._custom_filters[:]
 elm_fileselector_filters_clear(self.obj)
 
 property hidden_visible:

-- 




[EGIT] [bindings/python/python-efl] master 02/03: Trivial todo note updates and doc fix

2016-02-02 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=caef23bb34d2183c8d9ee611a086713f084f7ed6

commit caef23bb34d2183c8d9ee611a086713f084f7ed6
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Tue Feb 2 14:11:33 2016 +0200

Trivial todo note updates and doc fix
---
 TODO|  1 +
 efl/edje/efl.edje_edit_program.pxi  |  2 +-
 efl/elementary/fileselector.pxi |  6 +++---
 efl/elementary/gengrid_item.pxi |  4 ++--
 efl/elementary/gengrid_widget.pxi   |  2 +-
 efl/elementary/genlist_widget.pxi   |  5 ++---
 efl/elementary/map.pxi  |  1 -
 efl/elementary/multibuttonentry.pxi |  6 --
 efl/elementary/notify.pxi   |  2 +-
 efl/elementary/object.pxi   |  5 ++---
 efl/elementary/transit.pxi  | 11 ++-
 efl/elementary/web.pxi  |  2 +-
 efl/eo/efl.eo.pyx   |  2 +-
 efl/evas/efl.evas_object_image.pxi  |  2 +-
 efl/utils/conversions.pyx   |  2 +-
 include/efl.evas.pxd| 12 ++--
 16 files changed, 33 insertions(+), 32 deletions(-)

diff --git a/TODO b/TODO
index 4e41a98..3a1396e 100644
--- a/TODO
+++ b/TODO
@@ -11,6 +11,7 @@ BUGS
 - Multibuttonentry.filter_append()
 - Multibuttonentry.filterprepend()
... maybe do like is done in genlist filter_set() ??
+* API break in 
https://git.enlightenment.org/bindings/python/python-efl.git/commit/efl/elementary/label.pyx?id=9be98bb979917932cc2850a54f6e79281c871401
 , find out if it had users anywhere, remove if not
 
 Failing unit tests
 --
diff --git a/efl/edje/efl.edje_edit_program.pxi 
b/efl/edje/efl.edje_edit_program.pxi
index 32479de..e6b3161 100644
--- a/efl/edje/efl.edje_edit_program.pxi
+++ b/efl/edje/efl.edje_edit_program.pxi
@@ -50,7 +50,7 @@ cdef class Program(object):
 def run(self):
 return bool(edje_edit_program_run(self.edje.obj, self.name))
 
-# XXX TODO: add (or better convert) all this to properties
+# TODO: add (or better convert) all this to properties
 #   like is done in Part()
 def source_get(self):
 cdef const char *s
diff --git a/efl/elementary/fileselector.pxi b/efl/elementary/fileselector.pxi
index 80ea7f6..a861bfb 100644
--- a/efl/elementary/fileselector.pxi
+++ b/efl/elementary/fileselector.pxi
@@ -351,8 +351,8 @@ cdef class Fileselector(LayoutClass):
 
 """
 cb_data = (func, data)
-# TODO: This is now a ref leak. It should be stored somewhere and
-#   deleted in the remove method.
+# FIXME: This is now a ref leak. It should be stored somewhere and
+#deleted in the remove method.
 Py_INCREF(cb_data)
 
 if isinstance(filter_name, unicode): filter_name = 
PyUnicode_AsUTF8String(filter_name)
@@ -443,7 +443,7 @@ cdef class Fileselector(LayoutClass):
 self._callback_del_full("selected", _cb_string_conv, func)
 
 #
-# FIXME: This seems to be a thing that the application should handle
+# TODO: This seems to be a thing that the application should handle
 #
 #def callback_selected_invalid_add(self, func, *args, **kwargs):
 #"""The user has tried to access a path which does not exist."""
diff --git a/efl/elementary/gengrid_item.pxi b/efl/elementary/gengrid_item.pxi
index ce4b8f4..4c7cda5 100644
--- a/efl/elementary/gengrid_item.pxi
+++ b/efl/elementary/gengrid_item.pxi
@@ -298,9 +298,9 @@ cdef class GengridItem(ObjectItem):
 elm_gengrid_item_pos_get(self.item, , )
 return (x, y)
 
-# XXX TODO elm_gengrid_item_item_class_update
+# TODO: elm_gengrid_item_item_class_update
 
-# XXX TODO elm_gengrid_item_item_class_get
+# TODO: elm_gengrid_item_item_class_get
 
 property select_mode:
 """Item's select mode. Possible values are:
diff --git a/efl/elementary/gengrid_widget.pxi 
b/efl/elementary/gengrid_widget.pxi
index 58e7a54..81ad765 100644
--- a/efl/elementary/gengrid_widget.pxi
+++ b/efl/elementary/gengrid_widget.pxi
@@ -210,7 +210,7 @@ cdef class Gengrid(Object):
 return GengridItem(item_class, item_data, func, item_data)\
   .insert_before(after_item)
 
-# XXX TODO elm_gengrid_item_sorted_insert()
+# TODO: elm_gengrid_item_sorted_insert()
 
 property selected_item:
 """This returns the selected item. If multi selection is enabled
diff --git a/efl/elementary/genlist_widget.pxi 
b/efl/elementary/genlist_widget.pxi
index b558f4a..98e28b0 100644
--- a/efl/elementary/genlist_widget.pxi
+++ b/efl/elementary/genlist_widget.pxi
@@ -256,7 +256,6 @@ cdef class Genlist(Object):
 ObjectItem parent_item=None,
 int flags=ELM_GENLIST_ITEM_NONE,
 func=None
-#API XXX: *args, **kwargs
   

[EGIT] [bindings/python/python-efl] master 03/03: Update TODO

2016-02-03 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=9a3d441f1c5a7bdf13d95af53062991bc8a0e009

commit 9a3d441f1c5a7bdf13d95af53062991bc8a0e009
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Wed Feb 3 11:08:39 2016 +0200

Update TODO
---
 TODO | 11 +--
 1 file changed, 1 insertion(+), 10 deletions(-)

diff --git a/TODO b/TODO
index 3a1396e..52d63a4 100644
--- a/TODO
+++ b/TODO
@@ -3,15 +3,7 @@ BUGS
 
 * EdjeEdit: PartState API does not work
 * Elm.Map: overlays_show segfaults, scrollers in examples are jumpy
-* Genlist: "filter,done" event is not always fired (see the genlist_filter.py 
test)
-* Elementary: when we use custom function callbacks we usually leak some
-reference around, some examples:
-- Fileselector.custom_filter_append()
-- Multibuttonentry.format_function_set()
-- Multibuttonentry.filter_append()
-- Multibuttonentry.filterprepend()
-   ... maybe do like is done in genlist filter_set() ??
-* API break in 
https://git.enlightenment.org/bindings/python/python-efl.git/commit/efl/elementary/label.pyx?id=9be98bb979917932cc2850a54f6e79281c871401
 , find out if it had users anywhere, remove if not
+* Genlist: "filter,done" event is sometimes fired before filter callbacks are 
done (see the genlist_filter.py test)
 
 Failing unit tests
 --
@@ -32,7 +24,6 @@ TODO
 
 Elm
 ---
-* Drag-n-Drop
 * Automate compilation of the example edje files.
 * Add more examples
 * Prefs (only supports simple types, not so great for us)

-- 




[EGIT] [bindings/python/python-efl] master 01/03: Elm.MultiButtonEntry: Correct documentation

2016-02-03 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=ba7bf818d88d3331781b055622842ef4a3943d7d

commit ba7bf818d88d3331781b055622842ef4a3943d7d
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Wed Feb 3 11:05:31 2016 +0200

Elm.MultiButtonEntry: Correct documentation
---
 efl/elementary/multibuttonentry.pxi | 92 +++--
 1 file changed, 78 insertions(+), 14 deletions(-)

diff --git a/efl/elementary/multibuttonentry.pxi 
b/efl/elementary/multibuttonentry.pxi
index 8c6e272..56e5329 100644
--- a/efl/elementary/multibuttonentry.pxi
+++ b/efl/elementary/multibuttonentry.pxi
@@ -163,6 +163,11 @@ cdef class MultiButtonEntryItem(ObjectItem):
 return self
 
 property selected:
+"""Control the selected state of an item
+
+:type: bool
+
+"""
 def __get__(self):
 return bool(elm_multibuttonentry_item_selected_get(self.item))
 
@@ -175,6 +180,11 @@ cdef class MultiButtonEntryItem(ObjectItem):
 return bool(elm_multibuttonentry_item_selected_get(self.item))
 
 property prev:
+"""Get the previous item in the multibuttonentry
+
+:type: :class:`MultiButtonEntryItem`
+
+"""
 def __get__(self):
 return 
_object_item_to_python(elm_multibuttonentry_item_prev_get(self.item))
 
@@ -182,6 +192,11 @@ cdef class MultiButtonEntryItem(ObjectItem):
 return 
_object_item_to_python(elm_multibuttonentry_item_prev_get(self.item))
 
 property next:
+"""Get the next item in the multibuttonentry
+
+:type: :class:`MultiButtonEntryItem`
+
+"""
 def __get__(self):
 return 
_object_item_to_python(elm_multibuttonentry_item_next_get(self.item))
 
@@ -239,8 +254,11 @@ cdef class MultiButtonEntry(Object):
 property expanded:
 """Control the multibuttonentry to expanded state.
 
-In expanded state, the complete entry will be displayed.
-Otherwise, only single line of the entry will be displayed.
+In expanded state the entry widget expands to accommodate all items.
+Otherwise a single line of items will be displayed with a counter for
+items that don't fit the line.
+
+.. seealso:: :meth:`format_function_set`
 
 :type: bool
 
@@ -257,6 +275,16 @@ cdef class MultiButtonEntry(Object):
 return bool(elm_multibuttonentry_expanded_get(self.obj))
 
 def item_prepend(self, label, func = None, *args, **kwargs):
+"""Prepend a new item to the multibuttonentry
+
+:param string label: The label of new item
+:param func: The callback function to be invoked when this item is 
pressed.
+:param \*args: The data to be attached for callback
+:param \*\*kwargs: The data to be attached for callback
+
+:return: :class:`MultiButtonEntryItem`
+
+"""
 cdef:
 Elm_Object_Item *item
 Evas_Smart_Cb cb = NULL
@@ -281,6 +309,16 @@ cdef class MultiButtonEntry(Object):
 return None
 
 def item_append(self, label, func = None, *args, **kwargs):
+"""Append a new item to the multibuttonentry
+
+:param string label: The label of new item
+:param func: The callback function to be invoked when this item is 
pressed.
+:param \*args: The data to be attached for callback
+:param \*\*kwargs: The data to be attached for callback
+
+:return: :class:`MultiButtonEntryItem`
+
+"""
 cdef:
 Elm_Object_Item *item
 Evas_Smart_Cb cb = NULL
@@ -305,6 +343,17 @@ cdef class MultiButtonEntry(Object):
 return None
 
 def item_insert_before(self, MultiButtonEntryItem before, label, func = 
None, *args, **kwargs):
+"""Add a new item to the multibuttonentry before the indicated object
+
+:param MultiButtonEntryItem before: The item before which to add it
+:param string label: The label of new item
+:param func: The callback function to be invoked when this item is 
pressed.
+:param \*args: The data to be attached for callback
+:param \*\*kwargs: The data to be attached for callback
+
+:return: :class:`MultiButtonEntryItem`
+
+"""
 cdef:
 Elm_Object_Item *item
 Evas_Smart_Cb cb = NULL
@@ -330,6 +379,17 @@ cdef class MultiButtonEntry(Object):
 return None
 
 def item_insert_after(self, MultiButtonEntryItem after, label, func = 
None, *args, **kwargs):
+"""Add a new item to the multibuttonentry after the indicated object
+
+:param MultiButtonEntryItem before: The item after which to add it
+:param string label: The label of new 

[EGIT] [bindings/python/python-efl] master 01/01: Eo: Add a private dict which can be used for callbacks etc.

2016-01-23 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=fa69908d712375ad599431eedeb7ef01bede83ff

commit fa69908d712375ad599431eedeb7ef01bede83ff
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Sat Jan 23 15:36:10 2016 +0200

Eo: Add a private dict which can be used for callbacks etc.
---
 efl/eo/efl.eo.pyx  | 1 +
 include/efl.eo.pxd | 1 +
 2 files changed, 2 insertions(+)

diff --git a/efl/eo/efl.eo.pyx b/efl/eo/efl.eo.pyx
index bd38c2f..13cf9df 100644
--- a/efl/eo/efl.eo.pyx
+++ b/efl/eo/efl.eo.pyx
@@ -235,6 +235,7 @@ cdef class Eo(object):
 
 def __cinit__(self):
 self.data = dict()
+self.internal_data = dict()
 
 def __init__(self, *args, **kwargs):
 if type(self) is Eo:
diff --git a/include/efl.eo.pxd b/include/efl.eo.pxd
index 6d87428..3bee06f 100644
--- a/include/efl.eo.pxd
+++ b/include/efl.eo.pxd
@@ -23,6 +23,7 @@ cdef:
 cdef:
 cEo *obj
 readonly dict data
+dict internal_data
 
 int _set_obj(self, cEo *obj) except 0
 int _set_properties_from_keyword_args(self, dict kwargs) except 0

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Elementary: Use the private internal_data dict instead of abusing user data dict

2016-01-23 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=6980ffb0e44d72c3ee4db711182de9c55828cbfd

commit 6980ffb0e44d72c3ee4db711182de9c55828cbfd
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Sat Jan 23 15:55:49 2016 +0200

Elementary: Use the private internal_data dict instead of abusing user data 
dict
---
 efl/elementary/cnp_callbacks.pxi  |  8 
 efl/elementary/gengrid_widget.pxi | 10 +-
 efl/elementary/genlist_widget.pxi | 18 +-
 3 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/efl/elementary/cnp_callbacks.pxi b/efl/elementary/cnp_callbacks.pxi
index 8c49ae7..8e6b7e4 100644
--- a/efl/elementary/cnp_callbacks.pxi
+++ b/efl/elementary/cnp_callbacks.pxi
@@ -143,7 +143,7 @@ cdef Elm_Object_Item *py_elm_xy_item_get_cb(Evas_Object 
*obj, Evas_Coord x, Evas
 ObjectItem it
 
 try:
-ret = o.data["xy_item_get_cb"](o, x, y)
+ret = o.internal_data["xy_item_get_cb"](o, x, y)
 it, xpos1, ypos1 = ret
 except Exception:
 traceback.print_exc()
@@ -321,7 +321,7 @@ cdef void py_elm_drag_item_container_pos(
 ObjectItem item = _object_item_to_python(it)
 
 try:
-o.data["drag_item_container_pos"](o, item, x, y, xposret, yposret, 
action, data if data is not NULL else None)
+o.internal_data["drag_item_container_pos"](o, item, x, y, xposret, 
yposret, action, data if data is not NULL else None)
 except Exception:
 traceback.print_exc()
 
@@ -352,7 +352,7 @@ cdef Eina_Bool py_elm_drop_item_container_cb(
 
 evdata.sel_data = ev
 
-cb = o.data["drop_item_container_cb"]
+cb = o.internal_data["drop_item_container_cb"]
 
 if data != NULL:
 cbdata = data
@@ -434,7 +434,7 @@ cdef Eina_Bool py_elm_item_container_data_get_cb(
 bint ret
 
 try:
-func = o.data["item_container_data_get_cb"]
+func = o.internal_data["item_container_data_get_cb"]
 ret = func(o, item, pyinfo)
 except Exception:
 traceback.print_exc()
diff --git a/efl/elementary/gengrid_widget.pxi 
b/efl/elementary/gengrid_widget.pxi
index a96c35d..58e7a54 100644
--- a/efl/elementary/gengrid_widget.pxi
+++ b/efl/elementary/gengrid_widget.pxi
@@ -651,9 +651,9 @@ cdef class Gengrid(Object):
 if itemgetcb is not None:
 if not callable(itemgetcb):
 raise TypeError("itemgetcb must be callable.")
-self.data["xy_item_get_cb"] = itemgetcb
+self.internal_data["xy_item_get_cb"] = itemgetcb
 
-self.data["item_container_data_get_cb"] = data_get
+self.internal_data["item_container_data_get_cb"] = data_get
 
 if not elm_drag_item_container_add(self.obj,
 tm_to_anim,
@@ -702,10 +702,10 @@ cdef class Gengrid(Object):
 if itemgetcb is not None:
 if not callable(itemgetcb):
 raise TypeError("itemgetcb must be callable.")
-self.data["xy_item_get_cb"] = itemgetcb
+self.internal_data["xy_item_get_cb"] = itemgetcb
 
-self.data["drag_item_container_pos"] = poscb
-self.data["drop_item_container_cb"] = dropcb
+self.internal_data["drag_item_container_pos"] = poscb
+self.internal_data["drop_item_container_cb"] = dropcb
 
 if not elm_drop_item_container_add(self.obj,
 format,
diff --git a/efl/elementary/genlist_widget.pxi 
b/efl/elementary/genlist_widget.pxi
index 416678b..b558f4a 100644
--- a/efl/elementary/genlist_widget.pxi
+++ b/efl/elementary/genlist_widget.pxi
@@ -723,17 +723,17 @@ cdef class Genlist(Object):
 
 """
 def __set__(self, object key):
-self.data['__filterkeyref'] = key # keep a reference for key
+self.internal_data['__filterkeyref'] = key # keep a reference for 
key
 elm_genlist_filter_set(self.obj, key if key is not None 
else NULL)
 
 def __get__(self):
-return self.data['__filterkeyref']
+return self.internal_data['__filterkeyref']
 
 def filter_set(self, key):
-self.data['__filterkeyref'] = key
+self.internal_data['__filterkeyref'] = key
 elm_genlist_filter_set(self.obj, <void*>key if key is not None else 
NULL)
 def filter_get(self):
-return self.data['__filterkeyref']
+return self.internal_data['__filterkeyref']
 
 #
 # Drag and Drop
@@ -757,9 +757,9 @@ cdef class Genlist(Object):
 if itemgetcb is not None:
 if not callable(itemgetcb):
 raise TypeError("itemgetcb must be callable.")
-self.data["xy_item_get_cb"] = itemgetcb
+self.internal_data["xy_item_get_cb"]

[EGIT] [bindings/python/python-efl] master 01/01: More Eo updates

2016-03-09 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=77d023dfe1fecfc980968c91bd8e170b06539e15

commit 77d023dfe1fecfc980968c91bd8e170b06539e15
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Wed Mar 9 20:07:05 2016 +0200

More Eo updates
---
 efl/elementary/systray.pxi |  4 +++-
 efl/eo/efl.eo.pyx  | 10 +-
 include/efl.c_eo.pxd   |  7 +++
 3 files changed, 11 insertions(+), 10 deletions(-)

diff --git a/efl/elementary/systray.pxi b/efl/elementary/systray.pxi
index e08cd80..4407ecc 100644
--- a/efl/elementary/systray.pxi
+++ b/efl/elementary/systray.pxi
@@ -26,7 +26,9 @@ cdef class Systray(Eo):
 """
 
 def __init__(self, Eo parent not None, *args, **kwargs):
-self._set_obj(eo_add(elm_systray_class_get(), parent.obj))
+cdef cEo *obj
+eo_add(, elm_systray_class_get(), parent.obj)
+self._set_obj(obj)
 self._set_properties_from_keyword_args(kwargs)
 
 property id:
diff --git a/efl/eo/efl.eo.pyx b/efl/eo/efl.eo.pyx
index aa5bbaf..73e905c 100644
--- a/efl/eo/efl.eo.pyx
+++ b/efl/eo/efl.eo.pyx
@@ -39,12 +39,12 @@ from efl.eina cimport Eina_Bool, \
 from efl.c_eo cimport Eo as cEo, eo_init, eo_shutdown, eo_del, \
 eo_class_name_get, eo_class_get, eo_base_class_get,\
 eo_key_data_set, eo_key_data_get, eo_key_data_del, \
-eo_event_callback_add, eo_event_callback_del, EO_EV_DEL, \
+eo_event_callback_add, eo_event_callback_del, EO_BASE_EVENT_DEL, \
 eo_parent_get, eo_parent_set, Eo_Event_Description, \
 eo_event_freeze, eo_event_thaw, eo_event_freeze_count_get, \
 eo_event_global_freeze, eo_event_global_thaw, \
 eo_event_global_freeze_count_get, EO_CALLBACK_STOP, \
-eo_children_iterator_new, Eo_Event2
+eo_children_iterator_new, Eo_Event
 
 from efl.utils.logger cimport add_logger
 
@@ -182,14 +182,14 @@ cdef void _register_decorated_callbacks(Eo obj):
 ##
 
 
-cdef Eina_Bool _eo_event_del_cb(void *data, const Eo_Event2 *event) with gil:
+cdef Eina_Bool _eo_event_del_cb(void *data, const Eo_Event *event) with gil:
 cdef:
 Eo self = data
 const char *cls_name = eo_class_name_get(eo_class_get(self.obj))
 
 EINA_LOG_DOM_DBG(PY_EFL_EO_LOG_DOMAIN, "Deleting Eo: %s", cls_name)
 
-eo_event_callback_del(self.obj, EO_EV_DEL, _eo_event_del_cb, self)
+eo_event_callback_del(self.obj, EO_BASE_EVENT_DEL, _eo_event_del_cb, 
self)
 eo_key_data_del(self.obj, "python-eo")
 self.obj = NULL
 Py_DECREF(self)
@@ -253,7 +253,7 @@ cdef class Eo(object):
 
 self.obj = obj
 eo_key_data_set(self.obj, "python-eo", self)
-eo_event_callback_add(self.obj, EO_EV_DEL, _eo_event_del_cb, self)
+eo_event_callback_add(self.obj, EO_BASE_EVENT_DEL, _eo_event_del_cb, 
self)
 Py_INCREF(self)
 
 return 1
diff --git a/include/efl.c_eo.pxd b/include/efl.c_eo.pxd
index 66207ab..d4906fa 100644
--- a/include/efl.c_eo.pxd
+++ b/include/efl.c_eo.pxd
@@ -77,20 +77,19 @@ cdef extern from "Eo.h":
 const Eo_Event_Description *desc # The event description. */
 void *event_info # Extra event information passed by the event caller. 
*/
 ctypedef _Eo_Event Eo_Event
-ctypedef _Eo_Event Eo_Event2
 
 
 
 # Eo Events
 #
 
-cdef const Eo_Event_Description *EO_EV_DEL
+cdef const Eo_Event_Description *EO_BASE_EVENT_DEL
 
 
 
 # Other typedefs
 #
-ctypedef Eina_Bool (*Eo_Event_Cb)(void *data, const Eo_Event2 *event)
+ctypedef Eina_Bool (*Eo_Event_Cb)(void *data, const Eo_Event *event)
 
 ctypedef void (*eo_key_data_free_func)(void *)
 
@@ -101,7 +100,7 @@ cdef extern from "Eo.h":
 int eo_init()
 int eo_shutdown()
 
-Eo *eo_add(const Eo_Class *klass, Eo *parent, ...)
+void eo_add(Eo **objp, const Eo_Class *klass, Eo *parent, ...)
 Eo *eo_ref(const Eo *obj)
 void eo_unref(const Eo *obj)
 int eo_ref_get(const Eo *obj)

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Shuffle in the latest Eo memes

2016-03-18 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=41c1779e81eb4388528bed6054855206c017f317

commit 41c1779e81eb4388528bed6054855206c017f317
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Sat Mar 19 01:08:33 2016 +0200

Shuffle in the latest Eo memes
---
 efl/elementary/systray.pxi | 3 +--
 include/efl.c_eo.pxd   | 2 +-
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/efl/elementary/systray.pxi b/efl/elementary/systray.pxi
index 4407ecc..ab76be3 100644
--- a/efl/elementary/systray.pxi
+++ b/efl/elementary/systray.pxi
@@ -26,8 +26,7 @@ cdef class Systray(Eo):
 """
 
 def __init__(self, Eo parent not None, *args, **kwargs):
-cdef cEo *obj
-eo_add(, elm_systray_class_get(), parent.obj)
+cdef cEo *obj = eo_add(elm_systray_class_get(), parent.obj)
 self._set_obj(obj)
 self._set_properties_from_keyword_args(kwargs)
 
diff --git a/include/efl.c_eo.pxd b/include/efl.c_eo.pxd
index d4906fa..390435f 100644
--- a/include/efl.c_eo.pxd
+++ b/include/efl.c_eo.pxd
@@ -100,7 +100,7 @@ cdef extern from "Eo.h":
 int eo_init()
 int eo_shutdown()
 
-void eo_add(Eo **objp, const Eo_Class *klass, Eo *parent, ...)
+Eo *eo_add(const Eo_Class *klass, Eo *parent, ...)
 Eo *eo_ref(const Eo *obj)
 void eo_unref(const Eo *obj)
 int eo_ref_get(const Eo *obj)

-- 




[EGIT] [bindings/python/python-efl] master 01/01: Follow changes in Eo

2016-03-04 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=05c19962dc966f4ca1d64435ad29c7f9d49ef170

commit 05c19962dc966f4ca1d64435ad29c7f9d49ef170
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Fri Mar 4 11:07:51 2016 +0200

Follow changes in Eo

- version 4 (eo_add changes coming later)
- events
---
 efl/elementary/elementary_cdef.pxi |   2 +-
 efl/elementary/systray.pxi | 130 -
 efl/elementary/systray_cdef.pxi|  34 +-
 efl/eo/efl.eo.pyx  |  62 +++---
 efl/evas/efl.evas_object_smart.pxi |  28 
 include/efl.c_eo.pxd   |  54 ---
 6 files changed, 128 insertions(+), 182 deletions(-)

diff --git a/efl/elementary/elementary_cdef.pxi 
b/efl/elementary/elementary_cdef.pxi
index 2e3c1cc..bf56d09 100644
--- a/efl/elementary/elementary_cdef.pxi
+++ b/efl/elementary/elementary_cdef.pxi
@@ -1,4 +1,4 @@
-from efl.c_eo cimport Eo as cEo, Eo_Class, eo_add, eo_do, eo_do_ret
+from efl.c_eo cimport Eo as cEo, Eo_Class, eo_add
 from efl.eina cimport Eina_Rectangle, Eina_Compare_Cb, \
 eina_list_free, eina_list_append, eina_stringshare_del
 from efl.evas cimport Eina_List, Eina_Bool, Evas_Object, Evas_Font_Size, \
diff --git a/efl/elementary/systray.pxi b/efl/elementary/systray.pxi
index 7bf021b..e08cd80 100644
--- a/efl/elementary/systray.pxi
+++ b/efl/elementary/systray.pxi
@@ -37,27 +37,21 @@ cdef class Systray(Eo):
 """
 def __set__(self, value):
 if isinstance(value, unicode): value = 
PyUnicode_AsUTF8String(value)
-eo_do(self.obj, elm_obj_systray_id_set(
-value if value is not None else NULL
+elm_obj_systray_id_set(
+self.obj, value if value is not None else NULL
 )
-)
 
 def __get__(self):
-cdef const char *value = ""
-eo_do_ret(self.obj, value, elm_obj_systray_id_get())
-return _ctouni(value)
+return _ctouni(elm_obj_systray_id_get(self.obj))
 
 def id_set(self, value):
 if isinstance(value, unicode): value = PyUnicode_AsUTF8String(value)
-eo_do(self.obj, elm_obj_systray_id_set(
-value if value is not None else NULL
+elm_obj_systray_id_set(
+self.obj, value if value is not None else NULL
 )
-)
 
 def id_get(self):
-cdef const char *value = ""
-eo_do_ret(self.obj, value, elm_obj_systray_id_get())
-return _ctouni(value)
+return _ctouni(elm_obj_systray_id_get(self.obj))
 
 property category:
 """
@@ -68,20 +62,16 @@ cdef class Systray(Eo):
 
 """
 def __set__(self, Elm_Systray_Category value):
-eo_do(self.obj, elm_obj_systray_category_set(value))
+elm_obj_systray_category_set(self.obj, value)
 
 def __get__(self):
-cdef Elm_Systray_Category value = ELM_SYSTRAY_CATEGORY_APP_STATUS
-eo_do_ret(self.obj, value, elm_obj_systray_category_get())
-return value
+return elm_obj_systray_category_get(self.obj)
 
 def category_set(self, Elm_Systray_Category value):
-eo_do(self.obj, elm_obj_systray_category_set(value))
+elm_obj_systray_category_set(self.obj, value)
 
 def category_get(self):
-cdef Elm_Systray_Category value = ELM_SYSTRAY_CATEGORY_APP_STATUS
-eo_do_ret(self.obj, value, elm_obj_systray_category_get())
-return value
+return elm_obj_systray_category_get(self.obj)
 
 property icon_theme_path:
 """The path to the theme where the icons can be found.
@@ -92,27 +82,21 @@ cdef class Systray(Eo):
 """
 def __set__(self, value):
 if isinstance(value, unicode): value = 
PyUnicode_AsUTF8String(value)
-eo_do(self.obj, elm_obj_systray_icon_theme_path_set(
-value if value is not None else NULL
+elm_obj_systray_icon_theme_path_set(
+self.obj, value if value is not None else NULL
 )
-)
 
 def __get__(self):
-cdef const char *value = ""
-eo_do_ret(self.obj, value, elm_obj_systray_icon_theme_path_get())
-return _ctouni(value)
+return _ctouni(elm_obj_systray_icon_theme_path_get(self.obj))
 
 def icon_theme_path_set(self, value):
 if isinstance(value, unicode): value = PyUnicode_AsUTF8String(value)
-eo_do(self.obj, elm_obj_systray_icon_theme_path_set(
-value if value is not None else NULL
+elm_obj_systray_icon_theme_path_set(
+self.obj, value if value is not None else NULL
 )
-)
 
 def icon_theme_path_get(self):
-cdef const char *valu

[EGIT] [apps/econnman] master 01/01: Add support for IPv6

2016-03-04 Thread Kai Huuhko
kuuko pushed a commit to branch master.

http://git.enlightenment.org/apps/econnman.git/commit/?id=18e7be6bf80df6b86965ba93391b205339fc7267

commit 18e7be6bf80df6b86965ba93391b205339fc7267
Author: Kai Huuhko <kai.huu...@gmail.com>
Date:   Sat Mar 5 08:20:56 2016 +0200

Add support for IPv6
---
 econnman-bin.in | 212 
 1 file changed, 197 insertions(+), 15 deletions(-)

diff --git a/econnman-bin.in b/econnman-bin.in
index 2715f1d..4f23acb 100755
--- a/econnman-bin.in
+++ b/econnman-bin.in
@@ -56,10 +56,10 @@ except:
 
 dbus_ml = DBusEcoreMainLoop()
 bus = dbus.SystemBus(mainloop=dbus_ml)
-log = logging.getLogger("econnman")
+log = logging.getLogger("econnman-bin")
 log_handler = logging.StreamHandler()
 log_formatter = logging.Formatter(
-"%(relativeCreated)d %(levelname)s %(name)s: %(message)s"
+"%(created)d %(name)s [%(levelname)s]:: %(message)s (@lineno %(lineno)d)"
 )
 log_handler.setFormatter(log_formatter)
 log.addHandler(log_handler)
@@ -347,6 +347,20 @@ class ObjectView(object):
 sc.callback_changed_add(callback)
 return sc, items
 
+def add_label_and_segment_control(self, box, options, callback, label):
+lb = self.add_label(box, label)
+
+sc = SegmentControl(box)
+sc.size_hint_weight = EXPAND_HORIZ
+sc.size_hint_align = FILL_BOTH
+items = {}
+for o in options:
+items[o] = sc.item_add(None, o)
+sc.show()
+box.pack_end(sc)
+sc.callback_changed_add(callback)
+return lb, sc, items
+
 def add_frame_and_box(self, box, label):
 fr = Frame(box)
 fr.size_hint_weight = EXPAND_HORIZ
@@ -925,6 +939,28 @@ class ServiceView(ObjectView):
 """
 bus_interface = "net.connman.Service"
 
+ipv4_fields = (#("Method", "ipv4_method"),
+   ("Address", "ipv4_address"),
+   ("Netmask", "ipv4_netmask"),
+   ("Gateway", "ipv4_gateway"),
+   )
+ipv6_fields = (#("Method", "ipv6_method"),
+   ("Address", "ipv6_address"),
+   ("Prefix Length", "ipv6_prefix_length"),
+   ("Gateway", "ipv6_gateway"),
+   #("Privacy", "ipv6_privacy"),
+   )
+proxy_fields = (("Method", "proxy_method"),
+("URL", "proxy_url"),
+("Servers", "proxy_servers"),
+("Excludes", "proxy_excludes"),
+)
+vpn_fields = (  # named Provider in spec
+  ("Host", "vpn_host"),
+  ("Domain", "vpn_domain"),
+  ("Name", "vpn_name"),
+  ("Type", "vpn_type"),
+  )
 eth_fields = (("Method", "eth_method"),
   ("Interface", "eth_iface"),
   ("Address", "eth_addr"),
@@ -932,15 +968,6 @@ class ServiceView(ObjectView):
   ("Speed", "eth_speed"),
   ("Duplex", "eth_duplex"),
   )
-vpn_fields = (("Host", "vpn_host"),
-  ("Domain", "vpn_domain"),
-  ("Name", "vpn_name"),
-  ("Type", "vpn_type"),
-  )
-ipv4_fields = (("Address", "ipv4_address"),
-   ("Netmask", "ipv4_netmask"),
-   ("Gateway", "ipv4_gateway"),
-   )
 
 top_widgets = (
 "connect",
@@ -959,6 +986,7 @@ class ServiceView(ObjectView):
 "domains_label",
 "domains_entry",
 "ipv4_frame",
+"ipv6_frame",
 "proxy_frame",
 "ethernet_frame",
 "vpn_frame",
@@ -1033,10 +1061,22 @@ class ServiceView(ObjectView):
 en.callback_unfocused_add(self._on_ipv4_property_unfocused)
 setattr(self, attr, en)
 
-# section: IPv6: similar to ipv4? refactor ipv4?
-if properties.get("IPv6"):
-fr, bx = self.add_frame_and_box(self.box, "IPv6")
-lb = self.add_label(bx, "TODO")
+# section: IPv6
+self.ipv6_properties = {"IPv6": {}, "IPv6.Configuration": {}}
+fr, bx = self.add_frame_and_box(self.box, "IPv6"

[EGIT] [apps/epour] feature/create-torrent 01/01: Add bin/epour-create-torrent

2020-05-23 Thread Kai Huuhko
kuuko pushed a commit to branch feature/create-torrent.

http://git.enlightenment.org/apps/epour.git/commit/?id=5eb19682ff67eaf85bf7fd5c0a455c9d531a76f4

commit 5eb19682ff67eaf85bf7fd5c0a455c9d531a76f4
Author: Kai Huuhko 
Date:   Sat May 23 16:42:02 2020 +0300

Add bin/epour-create-torrent
---
 bin/epour-create-torrent | 249 +++
 1 file changed, 249 insertions(+)

diff --git a/bin/epour-create-torrent b/bin/epour-create-torrent
new file mode 100755
index 000..6f095b8
--- /dev/null
+++ b/bin/epour-create-torrent
@@ -0,0 +1,249 @@
+#!/usr/bin/env python3
+#
+#  Epour - A bittorrent client using EFL and libtorrent
+#
+#  Copyright 2012-2017 Kai Huuhko 
+#
+#  This program is free software; you can redistribute it and/or modify
+#  it under the terms of the GNU General Public License as published by
+#  the Free Software Foundation; either version 3 of the License, or
+#  (at your option) any later version.
+#
+#  This program is distributed in the hope that it will be useful,
+#  but WITHOUT ANY WARRANTY; without even the implied warranty of
+#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#  GNU General Public License for more details.
+#
+#  You should have received a copy of the GNU General Public License
+#  along with this program; if not, write to the Free Software
+#  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+#  MA 02110-1301, USA.
+#
+
+import os
+
+import libtorrent as lt
+
+from efl import elementary as elm
+from efl.evas import EXPAND_BOTH, FILL_BOTH, EXPAND_HORIZ, FILL_HORIZ
+
+
+data = {"trackers": list()}
+
+class CreateTorrentGui(elm.StandardWindow):
+def __init__(self):
+super().__init__("testi", "testi", autodel=True)
+
+data["storage"] = lt.file_storage()
+
+nf = elm.Naviframe(self, size_hint_weight=EXPAND_BOTH)
+self.resize_object_add(nf)
+nf.show()
+
+first_next = elm.Button(self, text="Files/Directories")
+second_prev = elm.Button(self, text="Base Directory")
+second_next = elm.Button(self, text="Tracker URLs")
+third_prev = elm.Button(self, text="Files/Directories")
+third_next = elm.Button(self, text="Generate")
+fourth_prev = elm.Button(self, text="Tracker URLs")
+
+first_content = BaseDirectorySelection(self)
+second_content = FileSelection(self)
+third_content = TrackerAddition(self)
+fourth_content = TorrentGenerate(self)
+
+first = elm.NaviframeItem("Select Base Directory", 
next_btn=first_next, content=first_content)
+second = elm.NaviframeItem("Select Files/Directories", 
prev_btn=second_prev, next_btn=second_next, content=second_content)
+third = elm.NaviframeItem("Add Tracker URLs", prev_btn=third_prev, 
next_btn=third_next, content=third_content)
+fourth = elm.NaviframeItem("Generate Torrent", prev_btn=fourth_prev, 
content=fourth_content)
+
+def first_next_cb(obj):
+second.promote()
+
+def second_prev_cb(obj):
+first.promote()
+
+def second_next_cb(obj):
+third.promote()
+
+def third_prev_cb(obj):
+second.promote()
+
+def third_next_cb(obj):
+fourth.promote()
+
+def fourth_prev_cb(obj):
+third.promote()
+
+
first_content.selector.callback_directory_open_add(second_content.basedir_changed_cb)
+
+
+first_next.callback_clicked_add(first_next_cb)
+second_prev.callback_clicked_add(second_prev_cb)
+second_next.callback_clicked_add(second_next_cb)
+third_prev.callback_clicked_add(third_prev_cb)
+third_next.callback_clicked_add(third_next_cb)
+fourth_prev.callback_clicked_add(fourth_prev_cb)
+
+for page in first, second, third, fourth:
+page.push_to(nf)
+
+first.promote()
+
+self.size = 400, 400
+self.show()
+
+
+class BaseDirectorySelection(elm.Box):
+def __init__(self, parent, *args, **kwargs):
+super().__init__(parent, *args, **kwargs)
+
+def bdir_cb(obj, path):
+if not path:
+return
+data["base_dir"] = path
+
+selector = self.selector = elm.Fileselector(
+self,
+size_hint_weight=EXPAND_BOTH,
+size_hint_align=FILL_BOTH,
+buttons_ok_cancel=False,
+folder_only=True,
+expandable=False
+)
+selector.callback_directory_open_add(bdir_cb)
+selector.show()
+self.pack_end(selector)
+
+class FileSelection(elm.Box):
+def __init__(self, parent, *args, **kwargs):
+super().__init__(parent, *args, **kwargs)
+
+self.size_hint_weight=EXPAND_BOTH
+self.size_hint_align=FILL_BOT

[EGIT] [website/www-content] master 01/01: Wiki page download-latest changed with summary [Bump Epour version (released in 2017!)] by Kai Huuhko

2020-10-21 Thread Kai Huuhko
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=d4214997c107869c99759c5ceef1de9d11876292

commit d4214997c107869c99759c5ceef1de9d11876292
Author: Kai Huuhko 
Date:   Wed Oct 21 12:57:18 2020 -0700

Wiki page download-latest changed with summary [Bump Epour version 
(released in 2017!)] by Kai Huuhko
---
 pages/download-latest.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pages/download-latest.txt b/pages/download-latest.txt
index 74f86e6a7..55150f859 100644
--- a/pages/download-latest.txt
+++ b/pages/download-latest.txt
@@ -7,7 +7,7 @@ terminology_v = 1.8.1
 rage_v= 0.3.1
 econnman_v= 1.1
 ephoto_v  = 1.5
-epour_v   = 0.6.0
+epour_v   = 0.7.0
 evisum_v  = 0.5.7
 extra_v   = 0.0.1
 

--