Author | Message | Time |
---|---|---|
LordVader | Building up my dialog in my bot, so far im able to handle check boxes and combo boxes altering states, and adding data where needed.. One thing I can't seem to find searching msdn/google/here is how to send a message to a specific dialog item, to disable/enable it.. Example when a user clicks.. Diablo II: Lord of Destruction <-- A button in my dialog.. I wish to send a message to the edit box item IDC_CONFIG_CDKEY2, to enable it. So I can bring it from a disabled gray stay to an active state and the reverse also to disable it again when D2XP is not the selected client. I'm assuming a sendmessage, or senddlgitemmessage to accomplish this, but unsure of the paramaters to send to enable|disable. MF_ENABLED or BM_ENABLED maybe sent in WPARAM|LPARAM? *Edit Problem solved: [code] EnableWindow(IDC_CONFIG_CDKEY2,true); //enables EnableWindow(IDC_CONFIG_CDKEY2,false); //disables [/code] Just place where you need to toggle things in your WM_INITDIALOG & WM_COMMANDS good deal. *Edit fixed typo: goodle! :P to google heh | March 6, 2005, 11:19 PM |
Maddox | Windows GUI programming is crap. I find GTK much more intuitive. | March 7, 2005, 8:14 AM |
LordVader | I've not thought about that, is GTK platform independant and can be used in visual studio, just include core files? If so ill look into it.. I've looked into boost, and also wxWidgets so far been thinking about trying to shift into something like that. | March 7, 2005, 4:50 PM |
Maddox | [quote author=LordVader link=topic=10839.msg102761#msg102761 date=1110214210] I've not thought about that, is GTK platform independant and can be used in visual studio, just include core files? If so ill look into it.. I've looked into boost, and also wxWidgets so far been thinking about trying to shift into something like that. [/quote] yes, yes, and yes for GTK. There is a windows GTK skin as well for those wanting their GTK apps to look like windows ones. There are GTK libraries for .NET also and glade can be used to build user interfaces. wxWidgets is also a viable option, but you lose a lot of the advantages of using the GTK API when you use it. | March 8, 2005, 4:57 AM |
K | [quote author=LordVader link=topic=10839.msg102761#msg102761 date=1110214210] I've looked into boost, and also wxWidgets so far been thinking about trying to shift into something like that. [/quote] boost doesn't have a gui library. Qt is also going to be available for free (soon) on Windows. You can already get Qt free on *nix. | March 11, 2005, 2:22 AM |