author | drw <drw> | 2002-12-05 17:13:45 (UTC) |
---|---|---|
committer | drw <drw> | 2002-12-05 17:13:45 (UTC) |
commit | 675ab68194cc25793a18fd9e495958a90aaf0173 (patch) (unidiff) | |
tree | e2599a7dbef3184f015593f0b7ffe533c45a5ba5 /libopie | |
parent | 1eb333726ccf7c608b9f987aac1a04d37d35936c (diff) | |
download | opie-675ab68194cc25793a18fd9e495958a90aaf0173.zip opie-675ab68194cc25793a18fd9e495958a90aaf0173.tar.gz opie-675ab68194cc25793a18fd9e495958a90aaf0173.tar.bz2 |
Modified OColorButton to pass color to color dialog. Impacts appearance, launcher settings and liquid settings.
-rw-r--r-- | libopie/ocolorbutton.cpp | 20 | ||||
-rw-r--r-- | libopie/ocolorbutton.h | 14 |
2 files changed, 17 insertions, 17 deletions
diff --git a/libopie/ocolorbutton.cpp b/libopie/ocolorbutton.cpp index 4734c0c..ddb6c4f 100644 --- a/libopie/ocolorbutton.cpp +++ b/libopie/ocolorbutton.cpp | |||
@@ -33,5 +33,5 @@ | |||
33 | #include <qimage.h> | 33 | #include <qimage.h> |
34 | 34 | ||
35 | #include <qpe/resource.h> | 35 | #include <qpe/resource.h> |
36 | 36 | ||
37 | class OColorButtonPrivate { | 37 | class OColorButtonPrivate { |
@@ -42,3 +42,3 @@ public: | |||
42 | 42 | ||
43 | OColorButton::OColorButton ( QWidget *parent, const char *name ) | 43 | OColorButton::OColorButton ( QWidget *parent, const QColor &color, const char *name ) |
44 | : QPushButton ( parent, name ) | 44 | : QPushButton ( parent, name ) |
@@ -46,4 +46,4 @@ OColorButton::OColorButton ( QWidget *parent, const char *name ) | |||
46 | d = new OColorButtonPrivate; | 46 | d = new OColorButtonPrivate; |
47 | 47 | ||
48 | d-> m_menu = new ColorPopupMenu ( black, 0, 0 ); | 48 | d-> m_menu = new ColorPopupMenu ( color, 0, 0 ); |
49 | setPopup ( d-> m_menu ); | 49 | setPopup ( d-> m_menu ); |
@@ -51,8 +51,8 @@ OColorButton::OColorButton ( QWidget *parent, const char *name ) | |||
51 | connect ( d-> m_menu, SIGNAL( colorSelected ( const QColor & )), this, SLOT( updateColor ( const QColor & ))); | 51 | connect ( d-> m_menu, SIGNAL( colorSelected ( const QColor & )), this, SLOT( updateColor ( const QColor & ))); |
52 | 52 | ||
53 | updateColor ( black ); | 53 | updateColor ( color ); |
54 | 54 | ||
55 | QSize s = sizeHint ( ) + QSize ( 12, 0 ); | 55 | QSize s = sizeHint ( ) + QSize ( 12, 0 ); |
56 | setMinimumSize ( s ); | 56 | setMinimumSize ( s ); |
57 | setMaximumSize ( s. width ( ) * 2, s. height ( )); | 57 | setMaximumSize ( s. width ( ) * 2, s. height ( )); |
58 | } | 58 | } |
diff --git a/libopie/ocolorbutton.h b/libopie/ocolorbutton.h index ec04833..fe40fae 100644 --- a/libopie/ocolorbutton.h +++ b/libopie/ocolorbutton.h | |||
@@ -29,4 +29,4 @@ | |||
29 | #ifndef __OPIE_OCOLORBUTTON_H__ | 29 | #ifndef __OPIE_OCOLORBUTTON_H__ |
30 | #define __OPIE_OCOLORBUTTON_H__ | 30 | #define __OPIE_OCOLORBUTTON_H__ |
31 | 31 | ||
32 | #include <qpushbutton.h> | 32 | #include <qpushbutton.h> |
@@ -39,10 +39,10 @@ class OColorButton : public QPushButton { | |||
39 | public: | 39 | public: |
40 | OColorButton ( QWidget *parent = 0, const char *name = 0 ); | 40 | OColorButton ( QWidget *parent = 0, const QColor & = black, const char *name = 0 ); |
41 | virtual ~OColorButton ( ); | 41 | virtual ~OColorButton ( ); |
42 | 42 | ||
43 | QColor color ( ) const; | 43 | QColor color ( ) const; |
44 | 44 | ||
45 | signals: | 45 | signals: |
46 | void colorSelected ( const QColor & ); | 46 | void colorSelected ( const QColor & ); |
47 | 47 | ||
48 | public slots: | 48 | public slots: |