Image gadget

Windows specific forum
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by Shagwana.

I have a simple request, how would I go about creating a image button that can be toggled. When the image button is up it will display image #x and when the button is down it will display image #y (two different images)?.

http://www.sublimegames.com
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by Shagwana.

Heh, well I have sort of figured out half the answer myself

The 'ButtonImageGadget' command returns a usefull pointer to the gadget like;

hn=ButtonImageGadget(1, 384, 5, 50, 36, UseImage(0))

Then when I want to change the image in the gadget, i dito;

SendMessage_(hn,#BM_SETIMAGE,0,UseImage(1))

And the image changes

http://www.sublimegames.com
Post Reply