aboutsummaryrefslogtreecommitdiff
path: root/gui/widgets/LineSeparator.cpp
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2015-02-09 01:51:14 +0100
committerPetr Mrázek <peterix@gmail.com>2015-04-12 20:57:18 +0200
commitdb877ba121ff87a4e029daf8555d85dfef45993a (patch)
tree7673f83c404b3883f0a4fcf6b492f0c4125c293c /gui/widgets/LineSeparator.cpp
parent4730f54df7edf4775dfddf45f77c60edd86c32d9 (diff)
downloadPrismLauncher-db877ba121ff87a4e029daf8555d85dfef45993a.tar.gz
PrismLauncher-db877ba121ff87a4e029daf8555d85dfef45993a.tar.bz2
PrismLauncher-db877ba121ff87a4e029daf8555d85dfef45993a.zip
NOISSUE move everything.
Diffstat (limited to 'gui/widgets/LineSeparator.cpp')
-rw-r--r--gui/widgets/LineSeparator.cpp37
1 files changed, 0 insertions, 37 deletions
diff --git a/gui/widgets/LineSeparator.cpp b/gui/widgets/LineSeparator.cpp
deleted file mode 100644
index f4ee173d..00000000
--- a/gui/widgets/LineSeparator.cpp
+++ /dev/null
@@ -1,37 +0,0 @@
-#include "LineSeparator.h"
-
-#include <QStyle>
-#include <QStyleOption>
-#include <QLayout>
-#include <QPainter>
-
-void LineSeparator::initStyleOption(QStyleOption *option) const
-{
- option->initFrom(this);
- // in a horizontal layout, the line is vertical (and vice versa)
- if (m_orientation == Qt::Vertical)
- option->state |= QStyle::State_Horizontal;
-}
-
-LineSeparator::LineSeparator(QWidget *parent, Qt::Orientation orientation)
- : QWidget(parent), m_orientation(orientation)
-{
- setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
-}
-
-QSize LineSeparator::sizeHint() const
-{
- QStyleOption opt;
- initStyleOption(&opt);
- const int extent =
- style()->pixelMetric(QStyle::PM_ToolBarSeparatorExtent, &opt, parentWidget());
- return QSize(extent, extent);
-}
-
-void LineSeparator::paintEvent(QPaintEvent *)
-{
- QPainter p(this);
- QStyleOption opt;
- initStyleOption(&opt);
- style()->drawPrimitive(QStyle::PE_IndicatorToolBarSeparator, &opt, &p, parentWidget());
-}