Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DLL Talk / Blue GUI Menues

Author
Message
Daryn Alsup
11
Years of Service
User Offline
Joined: 5th Jul 2008
Location: In your head... dun dun DUN!!!!!!!!
Posted: 23rd Dec 2009 06:19
So this is probably going to either very easy to answer and hard to explain or very hard to answer and easy to explain <.<

I have a menu with several options (save, save as..., load - options -cut, paste etc...) I have never had to use a menu gadget before and I have no idea how you register which item in the menu has been clicked on. I have tried several variations of code



I cannot figure out how to return the item clicked. I feel noobish. It's probably really very simple. Any understanding would help. TY

-Daryn

Jack and Jill went up a hill to fetch a pale of water... but Jill got tired of his s#%& so she shot him.
chaos60556 2000
10
Years of Service
User Offline
Joined: 28th Jan 2009
Location:
Posted: 23rd Dec 2009 10:28 Edited at: 23rd Dec 2009 10:28
Look on this page:

http://forum.thegamecreators.com/?m=forum_view&t=148694&b=18

There is a code section that will show you how to do menus. Plus a few other things with bluegui and the windows api.
Rudolpho
13
Years of Service
User Offline
Joined: 28th Dec 2005
Location: Sweden
Posted: 23rd Dec 2009 21:09
When adding an item to a menu, you assign it a return value.
You can then tell when a certain menu item has been clicked by looking for a menu click event type, event source beeing the relevant menu handle and the item's return value is returned by eventData().

Login to post a reply

Server time is: 2019-10-15 10:51:38
Your offset time is: 2019-10-15 10:51:38