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 

why not the X

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



Joined: 20 Aug 2014
Posts: 12

PostPosted: Sat Sep 20, 2014 12:19 am    Post subject: why not the X Reply with quote

Seems to me that I ought to have the Windows Title Bar X (Kill)
available to use. But I don't - which seems strange.
How is this feature shown but made non functional.
Just curious.
BYW the Silverfrost app is excellent!
Bob
Back to top
View user's profile Send private message
Wilfried Linder



Joined: 14 Nov 2007
Posts: 311
Location: Düsseldorf, Germany

PostPosted: Sat Sep 20, 2014 7:43 am    Post subject: Reply with quote

Bob,

you create the window with

j = winio@(%ca[Title] ......... )

Then if you click X, j has the value zero. Therefore in the following line you can do something like

if (j == 0) return

Wilfried
Back to top
View user's profile Send private message
LitusSaxonicum



Joined: 23 Aug 2005
Posts: 1878
Location: Yateley, Hants, UK

PostPosted: Sat Sep 20, 2014 6:58 pm    Post subject: Reply with quote

Just to enlarge on what Wilfried has said, many controls can have a callback function to service that control when it is selected, and some types of controls MUST have a callback (e.g. menus) and some can be specified without a callback - usually %bt buttons. The Close Window X is an example of that. Because WINIO@ is a function, it returns a value that can be tested for in the code that follows the last WINIO@. The codes start at zero (for the close X) and are assigned one by one to the controls as Clearwin+ set them up.

You probably need an introduction to %ww and %sy as well, if you want to produce the normal appearance of a master window, but do beware of generating the system menu on dialog boxes as that permits the user to maximise them.

Eddie
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 -> General 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