mirror of
https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System.git
synced 2024-12-26 08:01:32 +08:00
Fixed demo application to properly use default settings
This commit is contained in:
parent
8af53b4199
commit
a1de28c969
@ -320,11 +320,13 @@ CMainWindow::CMainWindow(QWidget *parent) :
|
|||||||
// a QToolButton instead of a QPushButton
|
// a QToolButton instead of a QPushButton
|
||||||
// CDockManager::setConfigFlags(CDockManager::configFlags() | CDockManager::TabCloseButtonIsToolButton);
|
// CDockManager::setConfigFlags(CDockManager::configFlags() | CDockManager::TabCloseButtonIsToolButton);
|
||||||
|
|
||||||
// uncomment the following line if you wand a fixed tab width that does
|
// uncomment the following line if you want a fixed tab width that does
|
||||||
// not change if the visibility of the close button changes
|
// not change if the visibility of the close button changes
|
||||||
//CDockManager::setConfigFlag(CDockManager::OpaqueUndocking, false);
|
// CDockManager::setConfigFlag(CDockManager::RetainTabSizeWhenCloseButtonHidden, true);
|
||||||
//CDockManager::setConfigFlag(CDockManager::DragPreviewIsDynamic, false);
|
|
||||||
CDockManager::setConfigFlags(CDockManager::NonOpaqueWithWindowFrame);
|
// uncomment the follwing line if you want to use non opaque undocking and splitter
|
||||||
|
// moevements
|
||||||
|
//CDockManager::setConfigFlags(CDockManager::DefaultNonOpaqueConfig);
|
||||||
|
|
||||||
// Now create the dock manager and its content
|
// Now create the dock manager and its content
|
||||||
d->DockManager = new CDockManager(this);
|
d->DockManager = new CDockManager(this);
|
||||||
|
@ -507,17 +507,9 @@ void CFloatingDockContainer::startFloating(const QPoint &DragStartMousePos,
|
|||||||
d->setState(DragState);
|
d->setState(DragState);
|
||||||
d->DragStartMousePosition = DragStartMousePos;
|
d->DragStartMousePosition = DragStartMousePos;
|
||||||
#ifdef Q_OS_LINUX
|
#ifdef Q_OS_LINUX
|
||||||
// I have not found a way on Linux to display the floating widget behind the
|
|
||||||
// dock overlay. That means if the user drags this floating widget around,
|
|
||||||
// it is always painted in front of the dock overlay and dock overlay cross.
|
|
||||||
// and the user will not see the dock overlay. To work around this issue,
|
|
||||||
// the window opacity is set to 0.6 to make the dock overlay visible
|
|
||||||
// again. If someone has an idea, how to place the dragged floating widget
|
|
||||||
// behind the dock overlay, then a pull request would be welcome.
|
|
||||||
if (DraggingFloatingWidget == DragState)
|
if (DraggingFloatingWidget == DragState)
|
||||||
{
|
{
|
||||||
setAttribute(Qt::WA_X11NetWmWindowTypeDock, true);
|
setAttribute(Qt::WA_X11NetWmWindowTypeDock, true);
|
||||||
setWindowOpacity(0.6);
|
|
||||||
d->MouseEventHandler = MouseEventHandler;
|
d->MouseEventHandler = MouseEventHandler;
|
||||||
if (d->MouseEventHandler)
|
if (d->MouseEventHandler)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user