flaithbheartaigh / appuifw2

Automatically exported from code.google.com/p/appuifw2
Apache License 2.0
0 stars 0 forks source link

The code "appuifw2.app.body = appuiwf2.Text(...)" fails in standalone app with no traceback #7

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Here is a piece of code which cause an error (the full text see in test2.py
attached)
{{{...
    text = appuifw2.Text(move_callback=moveEvent,
edit_callback=changeEvent, skinned=True)
    log('Text widget created')
    appuifw2.app.body = text
    log('Text widget binded')
...}}}

When running from interpreter as a script, it works fine. But when I'm
creating an application (using Ensymple), it fails with no traceback, nor
error message. The application just "disappear". The last log message is
"Text widget created" in this case.

When I change appuifw2 with the regular appuifw, everything is fine in both
cases.

See
http://discussion.forum.nokia.com/forum/showpost.php?p=520587&postcount=23
for more info.

Original issue reported on code.google.com by dbrechalov on 22 Dec 2008 at 2:20

Attachments:

GoogleCodeExporter commented 8 years ago
Sorry, I've resolved the issue adding "e32.ao_yield()" before 
"appuifw2.app.body =
appuiwf2.Text(...)".
It seems to work. :)

Original comment by dbrechalov on 23 Dec 2008 at 2:23

GoogleCodeExporter commented 8 years ago
Yes using e32.ao_yield() will 
work, but the network & 
battery symbol will hidden... 
bytheway i have others code 
to resolve it use e32.Ao_timer
() & the symbol will not hidden.

    import e32, appuifw2
    timer = e32.Ao_timer()
    app = appuifw2.app
    def main():
        app.body = appuifw2.Text
()
        body.set(u'Main 
Application')
    timer.after(0, main)

Original comment by nem....@gmail.com on 17 Jan 2009 at 9:34