refactored BaseWidget
This commit is contained in:
@@ -267,11 +267,11 @@ void SelectChannelDialog::closeEvent(QCloseEvent *)
|
||||
this->closed.invoke();
|
||||
}
|
||||
|
||||
void SelectChannelDialog::themeRefreshEvent()
|
||||
void SelectChannelDialog::themeChangedEvent()
|
||||
{
|
||||
BaseWindow::themeRefreshEvent();
|
||||
BaseWindow::themeChangedEvent();
|
||||
|
||||
if (this->themeManager->isLightTheme()) {
|
||||
if (this->theme->isLightTheme()) {
|
||||
this->setStyleSheet("QRadioButton { color: #000 } QLabel { color: #000 }");
|
||||
} else {
|
||||
this->setStyleSheet("QRadioButton { color: #fff } QLabel { color: #fff }");
|
||||
|
||||
@@ -24,7 +24,7 @@ public:
|
||||
|
||||
protected:
|
||||
virtual void closeEvent(QCloseEvent *) override;
|
||||
virtual void themeRefreshEvent() override;
|
||||
virtual void themeChangedEvent() override;
|
||||
|
||||
private:
|
||||
class EventFilter : public QObject
|
||||
|
||||
@@ -175,9 +175,9 @@ void SettingsDialog::scaleChangedEvent(float newDpi)
|
||||
this->ui_.tabContainerContainer->setFixedWidth(int(200 * newDpi));
|
||||
}
|
||||
|
||||
void SettingsDialog::themeRefreshEvent()
|
||||
void SettingsDialog::themeChangedEvent()
|
||||
{
|
||||
BaseWindow::themeRefreshEvent();
|
||||
BaseWindow::themeChangedEvent();
|
||||
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::Background, QColor("#444"));
|
||||
|
||||
@@ -29,7 +29,7 @@ public:
|
||||
|
||||
protected:
|
||||
virtual void scaleChangedEvent(float newDpi) override;
|
||||
virtual void themeRefreshEvent() override;
|
||||
virtual void themeChangedEvent() override;
|
||||
|
||||
private:
|
||||
void refresh();
|
||||
|
||||
@@ -158,9 +158,9 @@ UserInfoPopup::UserInfoPopup()
|
||||
this->installEvents();
|
||||
}
|
||||
|
||||
void UserInfoPopup::themeRefreshEvent()
|
||||
void UserInfoPopup::themeChangedEvent()
|
||||
{
|
||||
BaseWindow::themeRefreshEvent();
|
||||
BaseWindow::themeChangedEvent();
|
||||
|
||||
this->setStyleSheet("background: #333");
|
||||
}
|
||||
|
||||
@@ -21,7 +21,7 @@ public:
|
||||
void setData(const QString &name, const ChannelPtr &channel);
|
||||
|
||||
protected:
|
||||
virtual void themeRefreshEvent() override;
|
||||
virtual void themeChangedEvent() override;
|
||||
|
||||
private:
|
||||
bool isMod_;
|
||||
|
||||
Reference in New Issue
Block a user