Newbie question

Just starting out? Need help? Post your questions and find answers here.
kpeters58
Posts: 19
Joined: Fri Dec 07, 2018 7:27 pm
Location: BC, Canada

Newbie question

Post by kpeters58 »

Just running the Gadget.sb demo code from the Gadgets help

The code led me to believe that pressing the QUIT button would hide the window - but nothing at all happens...

Am I missing something? Bug?
User avatar
Paul
Posts: 195
Joined: Wed Feb 26, 2014 6:46 pm
Location: Canada
Contact:

Re: Newbie question

Post by Paul »

That's because someone used
#PB_Window_TitleBar
instead of
#PB_Window_SystemMenu
with the OpenWindow command.

The other option would be to change
BindEvent(#PB_Event_CloseWindow, @CloseWindowEvent())
to
BindEvent(#PB_Event_Gadget, @CloseWindowEvent(),0,8)
so it uses the "Quit" button instead.


Yeah it's a bug cause it's not doing what the end user expects it to do ;)
kpeters58
Posts: 19
Joined: Fri Dec 07, 2018 7:27 pm
Location: BC, Canada

Re: Newbie question

Post by kpeters58 »

Thanks for the detailed explanation, Paul!
Post Reply