diff options
author | Gerald Combs <gerald@wireshark.org> | 2012-11-03 22:48:29 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2012-11-03 22:48:29 +0000 |
commit | 5b2890e573dd855795c6a55d9a00f3564d2f564e (patch) | |
tree | 08e1f7d29782f8a9cec379dffa75dbbae3d106ce /ui/qt/wireshark_application.h | |
parent | bdcdec560c5546529b1c97a6952b83d68ac2fe1e (diff) |
Move the main window creation to the top of main() in anticipation of a
splash pane.
Add an "initialized" state to WiresharkApplication and set it when we're
done calling our init routines. Handle FileOpen events. Wait until we're
initialized to try to open the files. On OS X
open -a /path/to/qtshark.app /path/to/some/file.pcap
now works as expected, and
osascript -e 'tell application "qtshark" to open posix file "'"/path/to/some/file.pcap"'"'
works but returns "missing value".
svn path=/trunk/; revision=45885
Diffstat (limited to 'ui/qt/wireshark_application.h')
-rw-r--r-- | ui/qt/wireshark_application.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/ui/qt/wireshark_application.h b/ui/qt/wireshark_application.h index 49b103f4d9..868ce47e0d 100644 --- a/ui/qt/wireshark_application.h +++ b/ui/qt/wireshark_application.h @@ -56,7 +56,9 @@ class WiresharkApplication : public QApplication Q_OBJECT public: explicit WiresharkApplication(int &argc, char **argv); - QList<recent_item_status *> recent_item_list() const; + + void allSystemsGo(); + QList<recent_item_status *> recentItems() const; void addRecentItem(const QString &filename, qint64 size, bool accessible); #ifdef HAVE_LIBPCAP void captureCallback(int event, capture_options * capture_opts); @@ -68,10 +70,17 @@ public: void helpTopicAction(topic_action_e action); QFont monospaceFont(bool bold = false); + private: + bool initialized_; QTimer *recent_timer_; + QList<QString> pending_open_files_; + +protected: + bool event(QEvent *event); signals: + void openCaptureFile(QString &cf_path); void updateRecentItemStatus(const QString &filename, qint64 size, bool accessible); #ifdef HAVE_LIBPCAP |