From 48ee36f6b2bcb9d25eec298dda2e77878ab321e1 Mon Sep 17 00:00:00 2001 From: Konstantinos Sideris Date: Sun, 18 Mar 2018 17:38:57 +0200 Subject: Add border in community list & minor refactorings (#204) --- include/SideBarActions.h | 7 +++++++ include/TopRoomBar.h | 8 ++++++++ include/UserInfoWidget.h | 7 +++++++ 3 files changed, 22 insertions(+) (limited to 'include') diff --git a/include/SideBarActions.h b/include/SideBarActions.h index 763f3b2d..a29757dd 100644 --- a/include/SideBarActions.h +++ b/include/SideBarActions.h @@ -18,9 +18,14 @@ class SideBarActions : public QWidget { Q_OBJECT + Q_PROPERTY(QColor borderColor READ borderColor WRITE setBorderColor) + public: SideBarActions(QWidget *parent = nullptr); + QColor borderColor() const { return borderColor_; } + void setBorderColor(QColor &color) { borderColor_ = color; } + signals: void showSettings(); void joinRoom(const QString &room); @@ -40,4 +45,6 @@ private: FlatButton *settingsBtn_; FlatButton *createRoomBtn_; FlatButton *joinRoomBtn_; + + QColor borderColor_; }; diff --git a/include/TopRoomBar.h b/include/TopRoomBar.h index 5b2ee506..0df31ee8 100644 --- a/include/TopRoomBar.h +++ b/include/TopRoomBar.h @@ -36,6 +36,9 @@ class RoomSettings; class TopRoomBar : public QWidget { Q_OBJECT + + Q_PROPERTY(QColor borderColor READ borderColor WRITE setBorderColor) + public: TopRoomBar(QWidget *parent = 0); @@ -48,6 +51,9 @@ public: void reset(); + QColor borderColor() const { return borderColor_; } + void setBorderColor(QColor &color) { borderColor_ = color; } + signals: void inviteUsers(QStringList users); @@ -77,4 +83,6 @@ private: QString roomName_; QString roomTopic_; + + QColor borderColor_; }; diff --git a/include/UserInfoWidget.h b/include/UserInfoWidget.h index 5e0ed85b..ea2d5400 100644 --- a/include/UserInfoWidget.h +++ b/include/UserInfoWidget.h @@ -28,6 +28,8 @@ class UserInfoWidget : public QWidget { Q_OBJECT + Q_PROPERTY(QColor borderColor READ borderColor WRITE setBorderColor) + public: UserInfoWidget(QWidget *parent = 0); @@ -37,6 +39,9 @@ public: void reset(); + QColor borderColor() const { return borderColor_; } + void setBorderColor(QColor &color) { borderColor_ = color; } + signals: void logout(); @@ -63,4 +68,6 @@ private: QImage avatar_image_; int logoutButtonSize_; + + QColor borderColor_; }; -- cgit 1.5.1