Commit a31fa7a4 authored by Ismael Asensio's avatar Ismael Asensio
Browse files

[sidebarmode] Fix header height for QWidget KCMs

Take the height value from the sidebar header and set it to the
custom QWidget header, so both headers look aligned.

There was a helpful method already set-up for this, but not used
before.

CCBUG: 433028
FIXED-IN: 5.21.1
parent 8e430aca
......@@ -798,6 +798,9 @@ void SidebarMode::initWidget()
d->quickWidget->setFixedWidth(240);
}
});
setHeaderHeight(d->quickWidget->rootObject()->property("headerHeight").toReal());
connect(d->quickWidget->rootObject(), SIGNAL(focusNextRequest()), d->mainWidget, SLOT(focusNext()));
connect(d->quickWidget->rootObject(), SIGNAL(focusPreviousRequest()), d->mainWidget, SLOT(focusPrevious()));
......
......@@ -25,11 +25,12 @@ Kirigami.ApplicationItem {
implicitWidth: wideScreen ? Kirigami.Units.gridUnit * 30 : Kirigami.Units.gridUnit * 15
pageStack.initialPage: mainColumn
pageStack.defaultColumnWidth: wideScreen ? root.width / 2 : root.width
LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft
LayoutMirroring.childrenInherit: true
property alias searchMode: mainColumn.searchMode
readonly property real headerHeight: mainColumn.header.height
signal focusNextRequest()
signal focusPreviousRequest()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment