Jump to content
  • Advertisement
  • entries
  • comments
  • views

Wewt, progress!!!

Sign in to follow this  


DragonForge Technology SettingsDialog class.

Shown above is my brand new (first one actually) settings dialog system. After being supplied a Device instance, it sets up the dialog and displays it (it will enumerate the Device first if needed.) I'm pretty sure it's not being handled right at the moment as I don't know how to handle listbox selection changes correctly (at the moment I just wait for a notify-code of 9 which seems to work right.) If anybody knows how I'm actually supposed to handle this, I'd appreciate it.

I have a short-poll question: Which solution do you prefer for maps that are smaller than the current resolution?
A) Restrict maps to certain size. (Won't work since support for different resolutions is required. I really don't want to require that houses or caves fit into a resolution greater than or even equal to 1680x1050.)
B) Display black area around the map.
C) Center the map and display black around it.
D) Center the map and display a tiled background (tile will be set by the map maker.) (For example, if I was in a house I'd use a grass tile background.)
E) Center the map and display a tiled, scrolling background (like the sky.) (This won't really work for an example like the above one.)
F) Other

Btw, I started a LiveJournal (on the advice of my niece and her friends.) I'll probably be moving all of my non-gamedev stuff over there.

Anyway, back to work.

stuff <_< >_>
Almost let it slip ahead of schedule lol. I guess this is one thing I'm going to have to figure out on my own.

Guess I'm going with 'C) Center the map and display black around it.'
Sign in to follow this  


Recommended Comments

C for sure!

To deal with selection of items in the list-view you'll need to process WM_NOTIFY messages when the LOWORD(wParam) == the id of your list-view. Then treat the lParam as a LPNMHDR and check the code. It should be NM_CLICK or NM_DBCLICK depending on what you're wanting to handle (dragging selection is a separate issue). Something like

// Figure out what was clicked on
if(LOWORD(wParam) == ID_YOURLISTVIEW && ((LPNMHDR)lParam))->code == NM_CLICK)
int index = ::SendMessage(hWndOfYourListView, LVM_GETNEXTITEM, -1, LVNI_FOCUSED);
// index now contains what's selected, you can then get the text via
// the LVM_GETITEMTEXT message.
// If for some reason nothing is selected index will be -1.

Share this comment

Link to comment
Yes, I definitively recommend method #C as well. It just seems to be the "nicest" one. It would be great for rooms, small shops, etc.

Share this comment

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!