|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
hiya,
I'm trying to do a game interface in visual c++ but i'm having loads of problems. I want to be able to use the mouse to drag the pieces into a position. The problem is, that I don't know how to get the bitmap that the mouse clicks and make it follow the mouse. void CNineMensMorrisInterfaceDlg::OnMouseMove(UINT nFlags, CPoint point) { CBitmap *bitmap1; //check to see if the left mouse button is down if ((nFlags & MK_LBUTTON) == MK_LBUTTON) { //get this devicecontext CClientDC dc(this); bitmap1 = dc.GetCurrentBitmap();//returns a pointer to the current bitmap } i don't even know if the getCurrentBitmap is what i should be doing there. i'd appreciate any suggestions |
|
#2
|
||||
|
||||
|
That feature is called "drag and drop". I haven't played with it myself, but at least with the name you should be able to find it described.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages > C Programming > mouse events in visual c++ |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|