Finished the sticky buttons (didn't have any visible effect)

git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@919 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
Yves Rizoud 2009-07-13 21:36:53 +00:00
parent 77728125fb
commit 3a5b460184
2 changed files with 65 additions and 57 deletions

View File

@ -2661,6 +2661,13 @@ short Window_clicked_button(void)
}
}
if (Input_sticky_control != 0 && !Window_click_in_control(Input_sticky_control))
{
// do nothing
}
else
{
if (Mouse_Y < Window_pos_Y+(12*Menu_factor_Y))
{
Move_window(Mouse_X-Window_pos_X,Mouse_Y-Window_pos_Y);
@ -2669,6 +2676,7 @@ short Window_clicked_button(void)
{
short clicked_button;
T_List_button * list;
// Check which controls was clicked (by rectangular area)
clicked_button = Window_get_clicked_button();
@ -2725,6 +2733,7 @@ short Window_clicked_button(void)
return clicked_button;
}
}
}
// Intercept keys
if (Key)

View File

@ -306,7 +306,6 @@ int Handle_mouse_release(SDL_MouseButtonEvent event)
Input_new_mouse_K &= ~2;
break;
}
Input_sticky_control = -1;
return Move_cursor_with_constraints();
}