use new macros to get whether we allow move/resize correct
2002-07-02 Havoc Pennington <hp@pobox.com> * src/window.c (meta_window_show_menu): use new macros to get whether we allow move/resize correct * src/frame.c (meta_frame_get_flags): use new macros to get whether we can move/resize correct, considering maximized/fullscreen for the move case. * src/window.h (META_WINDOW_ALLOWS_RESIZE, META_WINDOW_ALLOWS_MOVE): new macros * src/keybindings.c (process_keyboard_resize_grab): finish the right/left resize, patch from Jayaraj #78179. Has the same old move/resize bug, if it hits a constraint it starts to break because we move without resizing.
This commit is contained in:

committed by
Havoc Pennington

parent
1db28d3b3f
commit
d826e620a9
19
src/frame.c
19
src/frame.c
@ -229,21 +229,14 @@ meta_frame_get_flags (MetaFrame *frame)
|
||||
flags |= META_FRAME_ALLOWS_SHADE;
|
||||
}
|
||||
|
||||
if (frame->window->has_move_func)
|
||||
if (META_WINDOW_ALLOWS_MOVE (frame->window))
|
||||
flags |= META_FRAME_ALLOWS_MOVE;
|
||||
|
||||
if (frame->window->has_resize_func &&
|
||||
!frame->window->maximized &&
|
||||
!frame->window->shaded)
|
||||
{
|
||||
if (frame->window->size_hints.min_width <
|
||||
frame->window->size_hints.max_width)
|
||||
flags |= META_FRAME_ALLOWS_HORIZONTAL_RESIZE;
|
||||
|
||||
if (frame->window->size_hints.min_height <
|
||||
frame->window->size_hints.max_height)
|
||||
flags |= META_FRAME_ALLOWS_VERTICAL_RESIZE;
|
||||
}
|
||||
if (META_WINDOW_ALLOWS_HORIZONTAL_RESIZE (frame->window))
|
||||
flags |= META_FRAME_ALLOWS_HORIZONTAL_RESIZE;
|
||||
|
||||
if (META_WINDOW_ALLOWS_VERTICAL_RESIZE (frame->window))
|
||||
flags |= META_FRAME_ALLOWS_VERTICAL_RESIZE;
|
||||
|
||||
if (frame->window->has_focus)
|
||||
flags |= META_FRAME_HAS_FOCUS;
|
||||
|
Reference in New Issue
Block a user