Skip to content

Commit

Permalink
Merge branch '2.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
iamsergio committed May 8, 2024
2 parents 07f09ec + 1c7e1bf commit c9fa8fd
Show file tree
Hide file tree
Showing 15 changed files with 216 additions and 99 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ project(
)

set(KDDockWidgets_VERSION_MAJOR 2)
set(KDDockWidgets_VERSION_MINOR 0)
set(KDDockWidgets_VERSION_PATCH 95)
set(KDDockWidgets_VERSION_MINOR 1)
set(KDDockWidgets_VERSION_PATCH 1)
set(KDDockWidgets_VERSION ${KDDockWidgets_VERSION_MAJOR}.${KDDockWidgets_VERSION_MINOR}.${KDDockWidgets_VERSION_PATCH})
set(PROJECT_VERSION ${KDDockWidgets_VERSION}) # PROJECT_VERSION is needed by some ECM modules
set(KDDockWidgets_SOVERSION "2.1")
Expand Down
6 changes: 4 additions & 2 deletions Changelog
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
* v2.1.0 (unreleased)
* v2.1.1 (unreleased)
-

* v2.1.0 (08 May 2024)
- Added standalone layouting example using Slint
- Fixed DPI of icons in TitleBar.qml Looks better when using 150% and 200% scalling now.
- QtQuick: Fixed redock not working when mixing MDI with docking
Expand All @@ -11,7 +14,6 @@
- QtWidgets: Introduced MainWindowOption_QDockWidgets and MainWindowOption_ManualInit
- QtWidgets: Honours overriding DockWidget::closeEvent() to prevent closing
- QtWidgets: Fixed crash when unpinning a window
- Planned: #448 Implement docking indicator for MDI area
- Fix crash when doing sequential open() and close() calls (#326)
- Fix double-clicking the guest widget would make window float
- 3rdparty: Update to nlohmann json v3.11.3, from v3.10.5. Only relevant if you're not using
Expand Down
2 changes: 1 addition & 1 deletion conan/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

class KDDockWidgetsConan(ConanFile):
name = "kddockwidgets"
version = "2.0.0"
version = "2.1.0"
default_user = "kdab"
default_channel = "stable"
license = ("https://raw.githubusercontent.com/KDAB/KDDockWidgets/master/LICENSES/GPL-2.0-only.txt",
Expand Down
6 changes: 6 additions & 0 deletions distro/debian.changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
kddockwidgets (2.1.0) release candidate; urgency=high

* 2.1.0 final

-- Allen Winter <[email protected]> Wed, 08 May 2024 12:00:00 -0500

kddockwidgets (2.0.0) release candidate; urgency=high

* 2.0.0 final
Expand Down
4 changes: 2 additions & 2 deletions distro/qt5-kddockwidgets.dsc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
Format: 1.0
Source: kddockwidgets
Version: 2.0.0-1
Version: 2.1.0-1
Binary: kddockwidgets
Maintainer: Allen Winter <[email protected]>
Architecture: any
Build-Depends: debhelper (>=9), cdbs, cmake, qtbase5-dev, qtbase5-private-dev, libqt5x11extras5-dev, libfontconfig-dev, libfreetype-dev

Files:
00000000000000000000000000000000 00000 qt5-kddockwidgets-2.0.0.tar.gz
00000000000000000000000000000000 00000 qt5-kddockwidgets-2.1.0.tar.gz
4 changes: 3 additions & 1 deletion distro/qt5-kddockwidgets.spec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Name: qt5-kddockwidgets
Version: 2.0.0
Version: 2.1.0
Release: 1
Summary: KDAB's Dock Widget Framework for Qt5
Source0: %{name}-%{version}.tar.gz
Expand Down Expand Up @@ -98,6 +98,8 @@ cmake . -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release
%{_libdir}/libkddockwidgets.so

%changelog
* Wed May 08 2024 Allen Winter <[email protected]> 2.1.0
2.1.0 final
* Tue Dec 05 2023 Allen Winter <[email protected]> 2.0.0
2.0.0 final
* Wed May 03 2023 Allen Winter <[email protected]> 1.7.0
Expand Down
4 changes: 2 additions & 2 deletions distro/qt6-kddockwidgets.dsc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
Format: 1.0
Source: kddockwidgets
Version: 2.0.0-1
Version: 2.1.0-1
Binary: kddockwidgets
Maintainer: Allen Winter <[email protected]>
Architecture: any
Build-Depends: debhelper (>=9), cdbs, cmake, qt6-base-dev, qt6-base-private-dev, libgl1-mesa-dev, libfontconfig-dev, libfreetype-dev

Files:
00000000000000000000000000000000 00000 qt6-kddockwidgets-2.0.0.tar.gz
00000000000000000000000000000000 00000 qt6-kddockwidgets-2.1.0.tar.gz
4 changes: 3 additions & 1 deletion distro/qt6-kddockwidgets.spec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Name: qt6-kddockwidgets
Version: 2.0.0
Version: 2.1.0
Release: 1
Summary: KDAB's Dock Widget Framework for Qt6
Source0: %{name}-%{version}.tar.gz
Expand Down Expand Up @@ -87,6 +87,8 @@ cmake . -DCMAKE_INSTALL_PREFIX=/usr -DKDDockWidgets_QT6=True -DCMAKE_BUILD_TYPE=
%{_libdir}/qt6/mkspecs/modules/*

%changelog
* Wed May 08 2024 Allen Winter <[email protected]> 2.1.0
2.1.0 final
* Tue Dec 05 2023 Allen Winter <[email protected]> 2.0.0
2.0.0 final
* Wed May 03 2023 Allen Winter <[email protected]> 1.7.0
Expand Down
21 changes: 7 additions & 14 deletions src/LayoutSaver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -527,21 +527,14 @@ bool LayoutSaver::restoreLayout(const QByteArray &data)

if (!(d->m_restoreOptions & InternalRestoreOption::SkipMainWindowGeometry)) {
Window::Ptr window = mainWindow->view()->window();

if (window->windowState() == WindowState::Maximized && mw.windowState != WindowState::Maximized) {
// Never call deserializeWindowGeometry() on a maximized window.
// If window is maximized and we're restoring it to "normal", then 1st change state, then set geometry
window->setWindowState(mw.windowState);
d->deserializeWindowGeometry(mw, window);
} else if (mw.windowState != window->windowState()) {
// If window is normal and we're restoring it to maximized, then set geometry 1st
// so its normal geometry gets remembered, only then maximize

d->deserializeWindowGeometry(mw, window);
window->setWindowState(mw.windowState);
} else {
d->deserializeWindowGeometry(mw, window);
if (window->windowState() == WindowState::Maximized) {
// Restoring geometry needs to be done in normal state.
// Qt doesn't support restoring normal geometry on maximized windows.
window->setWindowState(WindowState::None);
}

d->deserializeWindowGeometry(mw, window);
window->setWindowState(mw.windowState);
}

if (!mainWindow->deserialize(mw))
Expand Down
5 changes: 5 additions & 0 deletions src/core/layouting/Item.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3735,6 +3735,11 @@ LayoutingSeparator *ItemBoxContainer::adjacentSeparatorForChild(Item *child, Sid
return nullptr;
}

bool ItemBoxContainer::isDeserializing() const
{
return d->m_isDeserializing;
}

bool ItemBoxContainer::isOverflowing() const
{
// This never returns true, unless when loading a buggy layout
Expand Down
1 change: 1 addition & 0 deletions src/core/layouting/Item_p.h
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,7 @@ class DOCKS_EXPORT ItemBoxContainer : public ItemContainer
int length() const;
bool hasOrientation() const;
bool isOverflowing() const;
bool isDeserializing() const;

/// @brief Returns the number of visible items layed-out horizontally or vertically
/// But honours nesting
Expand Down
Loading

0 comments on commit c9fa8fd

Please sign in to comment.