aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2023-11-11 18:25:12 +0100
committerAndersBroman <a.broman58@gmail.com>2023-11-12 10:09:07 +0000
commit814dc49d61144adf8e5f7c4287f6531c11dfce86 (patch)
treed60fc5f4937d03a61ec15fc6274ec8fb74aadb87 /ui/qt
parent7b726e3f6ea23ba1737d0a07ff8653497d5a2711 (diff)
Qt: More missing ApplicationPaletteChange event workarounds
Add missing ApplicationPaletteChange event workarounds for DisplayFilterCombo and WelcomePage, which is not updated on macOS.
Diffstat (limited to 'ui/qt')
-rw-r--r--ui/qt/welcome_page.h3
-rw-r--r--ui/qt/widgets/display_filter_combo.h2
-rw-r--r--ui/qt/wireshark_main_window.cpp5
3 files changed, 7 insertions, 3 deletions
diff --git a/ui/qt/welcome_page.h b/ui/qt/welcome_page.h
index 9d48cd8b42..d6243d1abe 100644
--- a/ui/qt/welcome_page.h
+++ b/ui/qt/welcome_page.h
@@ -32,6 +32,7 @@ public:
InterfaceFrame *getInterfaceFrame();
const QString captureFilter();
void setCaptureFilter(const QString capture_filter);
+ void updateStyleSheets();
public slots:
void interfaceSelected();
@@ -47,8 +48,6 @@ protected slots:
void on_helpLabel_clicked();
private:
- void updateStyleSheets();
-
Ui::WelcomePage *welcome_ui_;
QString flavor_;
QString show_in_str_;
diff --git a/ui/qt/widgets/display_filter_combo.h b/ui/qt/widgets/display_filter_combo.h
index f2695fe0ba..81fa11bae1 100644
--- a/ui/qt/widgets/display_filter_combo.h
+++ b/ui/qt/widgets/display_filter_combo.h
@@ -20,12 +20,12 @@ public:
explicit DisplayFilterCombo(QWidget *parent = 0);
bool addRecentCapture(const char *filter);
void writeRecent(FILE *rf);
+ void updateStyleSheet();
protected:
virtual bool event(QEvent *event);
private:
- void updateStyleSheet();
public slots:
bool checkDisplayFilter();
diff --git a/ui/qt/wireshark_main_window.cpp b/ui/qt/wireshark_main_window.cpp
index 16011bb3b3..5b855fb537 100644
--- a/ui/qt/wireshark_main_window.cpp
+++ b/ui/qt/wireshark_main_window.cpp
@@ -865,6 +865,7 @@ void WiresharkMainWindow::removeInterfaceToolbar(const gchar *menu_title)
void WiresharkMainWindow::updateStyleSheet()
{
+#ifdef Q_OS_MAC
// TODO: The event type QEvent::ApplicationPaletteChange is not sent to all child widgets.
// Workaround this by doing it manually for all AccordionFrame.
main_ui_->addressEditorFrame->updateStyleSheet();
@@ -873,6 +874,10 @@ void WiresharkMainWindow::updateStyleSheet()
main_ui_->goToFrame->updateStyleSheet();
main_ui_->preferenceEditorFrame->updateStyleSheet();
main_ui_->searchFrame->updateStyleSheet();
+
+ df_combo_box_->updateStyleSheet();
+ welcome_page_->updateStyleSheets();
+#endif
}
bool WiresharkMainWindow::eventFilter(QObject *obj, QEvent *event) {