FBA The Creator

The True Multiplatform PC / PocketPC Opensource Development Tool - Read Only Mode - Kept only for historical purposes - Thank you all ;)
It is currently Thu Jun 04, 2026 4:09 am

All times are UTC




Post new topic  Reply to topic  [ 13 posts ]  Go to page Previous 1 2
Author Message
PostPosted: Thu Jul 10, 2008 11:36 am 
Offline
FBA Startup-Logo Creator
FBA Startup-Logo Creator
User avatar

Joined: Wed Jun 18, 2008 11:40 am
Posts: 100
Location: Brighton, UK
Hmm, yes it just minmises - but the display is partially showing the running app...

_________________
http://www.boiledsweets.com


Top
   
PostPosted: Thu Jul 10, 2008 12:58 pm 
Offline
FBA Administrator
FBA Administrator
User avatar

Joined: Fri Mar 21, 2008 11:19 pm
Posts: 238
Location: Rome - Italy
Yes, but i still haven't found a better way to handle this. :(
I also looked several tips from other ppc developers and from pockethal forum, but no luck..this is the best way i found to do this.
Fortunately incoming calls while playing could be not so frequent ;)


Top
   
PostPosted: Fri Jul 11, 2008 2:36 am 
Offline

Joined: Tue Apr 01, 2008 4:23 am
Posts: 36
Hi, I tried to quit() the app during onlostfocus, but strangely it doesn't quit, the program is still in memory. It only quits when I goto Memory->Running Program and try to activate the Fba app. I'm using WM6, activate generally brings up a hidden app to the fore.

If quit() works, then we can programatically save state during interruption and load it back when the app is run again.

However form what I see here onlostfocus does not seem get executed immediately, so my previous code of a possible softening effect (ie attached below) has no effect? The consequence is an intensive task will continue to execute during a call interruption, hence causing phone to be sluggish and possibly not be able to take calls/need reset.

Code:
a = "apple"
b = "hasn't lost focus"

function onmainloop()       
        if a == "apple" then
                clear(0,0,0)
                print(20,20,clock(), 255, 255,255)       
                print(20,70,b, 255, 255,255)
        end
end

function onstylusdown(x,y)
        quit()
end

function onlostfocus()
        a = "zero"
        b = "lost focus"
end       

function ongotfocus()
        a = "apple"       
end


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 13 posts ]  Go to page Previous 1 2

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Limited