+ m_zoomLabel->setVisible(showZoomSlider);
+ updateContentsMargins();
+}
+
+void DolphinStatusBar::updateContentsMargins()
+{
+ if (GeneralSettings::showSpaceInfo()) {
+ // We reduce the outside margin for the flat button so it visually has the same margin as the status bar text label on the other end of the bar.
+ m_topLayout->setContentsMargins(6, 0, 2, 0);
+ } else {
+ m_topLayout->setContentsMargins(6, 0, 6, 0);
+ }
+}
+
+void DolphinStatusBar::paintEvent(QPaintEvent *paintEvent)
+{
+ Q_UNUSED(paintEvent)
+ QPainter p(this);
+ QStyleOption opt;
+ opt.initFrom(this);
+ style()->drawPrimitive(QStyle::PE_PanelStatusBar, &opt, &p, this);
+}
+
+int DolphinStatusBar::preferredHeight() const
+{
+ return m_spaceInfo->height();