Skip to main content
gamedev.net
🔒 Locked

listbox notify

Started by aboeing 2 replies 350+ views
Original Post
aboeing
aboeing
hi i just wanted to know how to know when someone right clicks in a listbox control. im using win32 and as far as i can see there only seems to be a LBN_DBLCLK notification... (i want to display a pop-up menu when this happens..) cheerz
aboeing
aboeing
figured it out, just using the WM_CONTEXTMENU message to get all right clicks and then testing if the mouse position is within the controls rectange (GetWindowRect( hwt, &pos)

ive actually got another problem, in that the list box contains a fair number of items, however i want to refresh this information every second or so, and clearing the listbox and re-adding the items is highly annoying, is there a better way to do this? (can you simply replace the existing text for an item somehow?)

cheers

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.