Diffstat (limited to 'noncore/graphics/drawpad/colorpanel.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/graphics/drawpad/colorpanel.cpp | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/noncore/graphics/drawpad/colorpanel.cpp b/noncore/graphics/drawpad/colorpanel.cpp index 1db0d7b..9327012 100644 --- a/noncore/graphics/drawpad/colorpanel.cpp +++ b/noncore/graphics/drawpad/colorpanel.cpp | |||
@@ -24,3 +24,3 @@ ColorPanelButton::ColorPanelButton(const QColor& color, QWidget* parent, const c | |||
24 | setFixedSize(16, 16); | 24 | setFixedSize(16, 16); |
25 | setActive(false); | 25 | setFrameStyle(NoFrame); |
26 | } | 26 | } |
@@ -31,13 +31,2 @@ ColorPanelButton::~ColorPanelButton() | |||
31 | 31 | ||
32 | void ColorPanelButton::setActive(bool active) | ||
33 | { | ||
34 | m_active = active; | ||
35 | |||
36 | if (m_active) { | ||
37 | setFrameStyle(Panel | Sunken); | ||
38 | } else { | ||
39 | setFrameStyle(NoFrame); | ||
40 | } | ||
41 | } | ||
42 | |||
43 | void ColorPanelButton::enterEvent(QEvent* e) | 32 | void ColorPanelButton::enterEvent(QEvent* e) |
@@ -46,5 +35,3 @@ void ColorPanelButton::enterEvent(QEvent* e) | |||
46 | 35 | ||
47 | if (!m_active) { | 36 | setFrameStyle(Panel | Sunken); |
48 | setFrameStyle(Panel | Sunken); | ||
49 | } | ||
50 | } | 37 | } |
@@ -55,5 +42,3 @@ void ColorPanelButton::leaveEvent(QEvent* e) | |||
55 | 42 | ||
56 | if (!m_active) { | 43 | setFrameStyle(NoFrame); |
57 | setFrameStyle(NoFrame); | ||
58 | } | ||
59 | } | 44 | } |
@@ -127,2 +112,3 @@ void ColorPanel::addColor(const QColor& color, int row, int col) | |||
127 | connect(panelButton, SIGNAL(selected(const QColor&)), this, SLOT(buttonSelected(const QColor&))); | 112 | connect(panelButton, SIGNAL(selected(const QColor&)), this, SLOT(buttonSelected(const QColor&))); |
113 | |||
128 | m_pGridLayout->addWidget(panelButton, row, col); | 114 | m_pGridLayout->addWidget(panelButton, row, col); |