forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Window Problem - execution does not halt after %aw

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support
View previous topic :: View next topic  
Author Message
ursuselasticus



Joined: 26 Mar 2005
Posts: 43

PostPosted: Sun Jun 12, 2005 6:14 am    Post subject: Window Problem - execution does not halt after %aw Reply with quote

Hi, if you are still patient enough to help me....

here is just another one that beats me.

What I want:
(1) a big frame covering all the screen, giving the program's name in the caption
(2) small window to give options to the user.

My solution:

(1) iwin=winio@('%ww[maximise]&')
(2) iwin=winio@('%fr&',800,600)
(3) iwin=winio@('%ca[MapMaker 3.01]&')
(4) iwin=winio@('%lw',kcm)
...
...
(5) iwin=winio@('%ww[toolwindow]&')
(6) iwin=winio@('%aw&',kcm)
(7) iwin=winio@('%ca[Select Project]%sp&',260,150)
(Cool iwin=winio@('%cnWhich Project do you select ?&')
(9) iwin=winio@('%2nl%cn%20.3ls&',dir,ndir,iselect)
(10) iwin=winio@('%2nl%cn%^tt[abort]&',irgpn1)
(11) iwin=winio@('%ta%`^tt[okay]',irgpn2)

lines 1 to 4 define the big bachground window covering all the screen

5 to 11 define a window with a menue to give all the projects available. The project is selected by clicking on it and then press 'okay' or 'abort' to stop execution.

irgpn1 and irgpn2 are call back functions making the user's selection available to the prog and return -1 to winio@ in order to close the small selection window.

Trouble is line 6.
If I do not have it to the code, the window behaves as I want it to do, meaning after displaying it execution terminates until the user either clicks on 'okay' or 'abort'. But if by mistake the user clicks utside of it, the background window gets control and supercedes the selection window.

However if I add line 6 as done here, execution of the program does not stop after line 11 to wait for the user's input but carries on - naturally to produce errors on end because of the lacking input. :confused: :confused: :confused:

Where do I go wrong ??


Norbert
Back to top
View user's profile Send private message
Martin



Joined: 09 Sep 2004
Posts: 43

PostPosted: Mon Jun 13, 2005 6:03 am    Post subject: Window Problem - execution does not halt after %aw Reply with quote

If you use the topmost option for %ww the window will stay on top.
i.e. iwin=winio@('%ww[toolwindow, topmost]&')
Back to top
View user's profile Send private message
ursuselasticus



Joined: 26 Mar 2005
Posts: 43

PostPosted: Mon Jun 13, 2005 9:51 am    Post subject: Window Problem - execution does not halt after %aw Reply with quote

[small]Martin Alderson wrote:[/small]
If you use the topmost option for %ww the window will stay on top.
i.e. iwin=winio@('%ww[toolwindow, topmost]&')


:confused: :confused: :confused:

... but will it stop execution after creation to wait for user input ??

sorry, but it will be some days till I get back to my system to test.

Norbert
Back to top
View user's profile Send private message
Martin



Joined: 09 Sep 2004
Posts: 43

PostPosted: Mon Jun 13, 2005 10:32 am    Post subject: Window Problem - execution does not halt after %aw Reply with quote

Because of the way %fr and %aw were designed, the child window will always act as though %lw had been specified.

I think the best way to get what you want is to use a %cc format code to attach a close window callback function to the child window. Then you can move the program code that you wish to execute after the window has closed to that routine.
Back to top
View user's profile Send private message
ursuselasticus



Joined: 26 Mar 2005
Posts: 43

PostPosted: Thu Jun 16, 2005 2:11 am    Post subject: Window Problem - execution does not halt after %aw Reply with quote

Well, nice to know this one.

Sad Sad
You should expect to find info like this somewhere in the docs about %fr and/or %aw though, don't you ?
Sad Sad

Norbert
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group