Use a single nick to color map

This commit is contained in:
Konstantinos Sideris 2017-04-11 22:48:02 +03:00
parent 5c964f3246
commit c431eee401
4 changed files with 49 additions and 47 deletions

View file

@ -44,12 +44,8 @@ public slots:
void sliderRangeChanged(int min, int max);
private:
static const QList<QString> COLORS;
void init();
QString chooseRandomColor();
QVBoxLayout *top_layout_;
QVBoxLayout *scroll_layout_;
@ -57,7 +53,6 @@ private:
QWidget *scroll_widget_;
QString last_sender_;
QMap<QString, QString> nick_colors_;
};
#endif // HISTORY_VIEW_H

View file

@ -38,6 +38,10 @@ public:
void sync(const Rooms &rooms);
void clearAll();
static QString chooseRandomColor();
static QMap<QString, QString> NICK_COLORS;
static const QList<QString> COLORS;
public slots:
void setHistoryView(const RoomInfo &info);