diff options
author | Gerald Combs <gerald@zing.org> | 2015-09-06 12:00:48 -0700 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2015-09-06 19:01:57 +0000 |
commit | 628f65a9846acd68cec035e6d7b206b68de88715 (patch) | |
tree | 670a3161738559986014878a4c1d815aeaed955a | |
parent | 4cb37376e7328359e560f07c5a946a4e086f82ba (diff) | |
download | wireshark-628f65a9846acd68cec035e6d7b206b68de88715.tar.gz |
Keep focus rects from showing through the welcome screen.
Change-Id: I5785890c70f3a3f6f4ccb0c7b609a19e5d2b88c9
Reviewed-on: https://code.wireshark.org/review/10406
Reviewed-by: Gerald Combs <gerald@wireshark.org>
-rw-r--r-- | ui/qt/main_window.cpp | 3 | ||||
-rw-r--r-- | ui/qt/main_window.h | 1 | ||||
-rw-r--r-- | ui/qt/main_window_slots.cpp | 9 |
3 files changed, 13 insertions, 0 deletions
diff --git a/ui/qt/main_window.cpp b/ui/qt/main_window.cpp index dd1af34907..620f75d4c8 100644 --- a/ui/qt/main_window.cpp +++ b/ui/qt/main_window.cpp @@ -435,6 +435,9 @@ MainWindow::MainWindow(QWidget *parent) : connect(wsApp, SIGNAL(fieldsChanged()), this, SLOT(fieldsChanged())); + connect(main_ui_->mainStack, SIGNAL(currentChanged(int)), + this, SLOT(mainStackChanged(int))); + connect(main_welcome_, SIGNAL(startCapture()), this, SLOT(startCapture())); connect(main_welcome_, SIGNAL(recentFileActivated(QString&)), diff --git a/ui/qt/main_window.h b/ui/qt/main_window.h index 6129880c73..5bc0084449 100644 --- a/ui/qt/main_window.h +++ b/ui/qt/main_window.h @@ -257,6 +257,7 @@ private slots: void loadWindowGeometry(); void saveWindowGeometry(); + void mainStackChanged(int); void updateRecentFiles(); void recentActionTriggered(); void setMenusForSelectedPacket(); diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp index d3594d4d8c..f6a5a5e573 100644 --- a/ui/qt/main_window_slots.cpp +++ b/ui/qt/main_window_slots.cpp @@ -935,6 +935,15 @@ void MainWindow::stopCapture() { packet_list_->setAutoScroll(false); } +// Keep focus rects from showing through the welcome screen. Primarily for +// OS X. +void MainWindow::mainStackChanged(int) +{ + for (int i = 0; i < main_ui_->mainStack->count(); i++) { + main_ui_->mainStack->widget(i)->setEnabled(i == main_ui_->mainStack->currentIndex()); + } +} + // XXX - Copied from ui/gtk/menus.c /** |