Changeset 64336 in vbox for trunk/src/VBox
- Timestamp:
- Oct 20, 2016 3:16:06 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.cpp
r64334 r64336 51 51 # include <QScreen> 52 52 # include <xcb/xcb.h> 53 # include <xcb/xcb_icccm.h>54 53 # endif /* VBOX_WS_X11 && QT_VERSION >= 0x050000 */ 55 54 … … 3705 3704 } 3706 3705 3706 typedef struct { 3707 /** User specified flags */ 3708 uint32_t flags; 3709 /** User-specified position */ 3710 int32_t x, y; 3711 /** User-specified size */ 3712 int32_t width, height; 3713 /** Program-specified minimum size */ 3714 int32_t min_width, min_height; 3715 /** Program-specified maximum size */ 3716 int32_t max_width, max_height; 3717 /** Program-specified resize increments */ 3718 int32_t width_inc, height_inc; 3719 /** Program-specified minimum aspect ratios */ 3720 int32_t min_aspect_num, min_aspect_den; 3721 /** Program-specified maximum aspect ratios */ 3722 int32_t max_aspect_num, max_aspect_den; 3723 /** Program-specified base size */ 3724 int32_t base_width, base_height; 3725 /** Program-specified window gravity */ 3726 uint32_t win_gravity; 3727 } xcb_size_hints_t; 3728 3707 3729 /* static */ 3708 3730 void VBoxGlobal::setTopLevelGeometry(QWidget *pWidget, int x, int y, int w, int h) … … 3724 3746 fMask, values); 3725 3747 xcb_size_hints_t hints; 3726 hints.flags = XCB_ICCCM_SIZE_HINT_US_POSITION | XCB_ICCCM_SIZE_HINT_US_SIZE; 3748 hints.flags = 1 /* XCB_ICCCM_SIZE_HINT_US_POSITION */ 3749 | 2 /* XCB_ICCCM_SIZE_HINT_US_SIZE */; 3727 3750 hints.x = x; 3728 3751 hints.y = y; … … 3734 3757 hints.max_height = pWidget->maximumSize().height(); 3735 3758 if (hints.min_width > 0 || hints.min_height > 0) 3736 hints.flags |= XCB_ICCCM_SIZE_HINT_P_MIN_SIZE;3759 hints.flags |= 16 /* XCB_ICCCM_SIZE_HINT_P_MIN_SIZE */; 3737 3760 if (hints.max_width < QWINDOWSIZE_MAX || hints.max_height < QWINDOWSIZE_MAX) 3738 hints.flags |= XCB_ICCCM_SIZE_HINT_P_MAX_SIZE;3761 hints.flags |= 32 /* XCB_ICCCM_SIZE_HINT_P_MAX_SIZE */; 3739 3762 xcb_change_property(QX11Info::connection(), XCB_PROP_MODE_REPLACE, 3740 3763 (xcb_window_t)pWidget->winId(), XCB_ATOM_WM_NORMAL_HINTS,
Note:
See TracChangeset
for help on using the changeset viewer.