Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void menu::DragMenu(int &menuPosX, int &menuPosY, int x, int y, int w, int h, int MenuWindowIndex, int &DragOffsetX, int &DragOffsetY)
- {
- if (!CheckForActiveWindowDrag())
- {
- if (g_Mouse.IsOver(x, y, w, h))
- {
- if (GetKeyPress(VK_LBUTTON))
- {
- //if (!CheckForActiveComboBoxes()
- // && !CheckForActiveKeyBind()
- // && !CheckForActiveSliders()
- // && !CheckForActiveCheckBoxes())
- //{
- // DraggingMenu[MenuWindowIndex] = true;
- //}
- //else
- DraggingMenu[MenuWindowIndex] = true;
- }
- }
- }
- if (DraggingMenu[MenuWindowIndex])
- {
- menuPosX = g_Mouse.pHackMouse.x - DragOffsetX;
- menuPosY = g_Mouse.pHackMouse.y - DragOffsetY;
- }
- if (g_Mouse.mouse1released)
- {
- DraggingMenu[MenuWindowIndex] = false;
- }
- DragOffsetX = g_Mouse.pHackMouse.x - menuPosX;
- DragOffsetY = g_Mouse.pHackMouse.y - menuPosY;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement