mirror of
https://invent.kde.org/system/dolphin
synced 2024-10-28 03:21:56 +00:00
Align location bar splitter with view area splitter
https://commits.kde.org/breeze/18734eea941446d81624a505a18ceed132f0f480 has turned the splitter in our default Breeze style visible. This made it very apparent that the two splitters visible when Dolphin is in split view area mode are not aligned perfectly. The computation is slightly off because the width of the splitter itself was not taken into account. This commit fixes this.
This commit is contained in:
parent
86c59879ec
commit
5ae081658e
|
@ -45,7 +45,7 @@ void DolphinNavigatorsWidgetAction::adjustSpacing()
|
||||||
m_previousWindowWidth = qobject_cast<QWidget *>(parent())->window()->width();
|
m_previousWindowWidth = qobject_cast<QWidget *>(parent())->window()->width();
|
||||||
auto viewGeometries = m_viewGeometriesHelper.viewGeometries();
|
auto viewGeometries = m_viewGeometriesHelper.viewGeometries();
|
||||||
const int widthOfSplitterPrimary = viewGeometries.globalXOfPrimary + viewGeometries.widthOfPrimary - viewGeometries.globalXOfNavigatorsWidget;
|
const int widthOfSplitterPrimary = viewGeometries.globalXOfPrimary + viewGeometries.widthOfPrimary - viewGeometries.globalXOfNavigatorsWidget;
|
||||||
const QList<int> splitterSizes = {widthOfSplitterPrimary, m_splitter->width() - widthOfSplitterPrimary};
|
const QList<int> splitterSizes = {widthOfSplitterPrimary, m_splitter->width() - widthOfSplitterPrimary - m_splitter->handleWidth()};
|
||||||
m_splitter->setSizes(splitterSizes);
|
m_splitter->setSizes(splitterSizes);
|
||||||
|
|
||||||
// primary side of m_splitter
|
// primary side of m_splitter
|
||||||
|
|
Loading…
Reference in a new issue