111 info_data_t *captureInfoData() {
return &info_data_; }
114 virtual QMenu *createPopupMenu();
116 CaptureFile *captureFile() {
return &capture_file_; }
118 void removeAdditionalToolbar(QString toolbarName);
120 void addInterfaceToolbar(
const iface_toolbar *toolbar_entry);
121 void removeInterfaceToolbar(
const char *menu_title);
123 QString getMwFileName();
124 void setMwFileName(QString fileName);
127 virtual bool eventFilter(QObject *obj, QEvent *event);
128 virtual bool event(QEvent *event);
129 virtual void keyPressEvent(QKeyEvent *event);
130 virtual void closeEvent(QCloseEvent *event);
131 virtual void dragEnterEvent(QDragEnterEvent *event);
132 virtual void dropEvent(QDropEvent *event);
133 virtual void changeEvent(QEvent* event);
138 MatchSelectedReplace,
146 enum FileCloseContext {
154 Ui::WiresharkMainWindow *main_ui_;
156 QMap<QString, QTextCodec *> text_codec_map_;
157#if defined(HAVE_LIBNL) && defined(HAVE_NL80211)
160 QWidget *previous_focus_;
162 QActionGroup *show_hide_actions_;
163 QActionGroup *time_display_actions_;
164 QActionGroup *time_precision_actions_;
166 QList<QPair<QAction *, bool> > freeze_actions_;
167 QPointer<QWidget> freeze_focus_;
168 QMap<QAction *, ts_type> td_actions;
169 QMap<QAction *, ts_precision> tp_actions;
176 bool capture_stopping_;
177 bool capture_filter_valid_;
180 CaptureOptionsDialog *capture_options_dialog_;
188#ifdef HAVE_SOFTWARE_UPDATE
189 QAction *update_action_;
192 QPoint dragStartPosition;
194 QPointer<TLSKeylogDialog> tlskeylog_dialog_;
199 void mergeCaptureFile();
200 void importCaptureFile();
201 bool saveCaptureFile(
capture_file *cf,
bool dont_reopen);
202 bool saveAsCaptureFile(
capture_file *cf,
bool must_support_comments =
false,
bool dont_reopen =
false);
203 void exportSelectedPackets();
204 void exportDissections(export_type_e export_type);
207 void fileAddExtension(QString &file_name,
int file_type, wtap_compression_type compression_type);
209 bool testCaptureFileClose(QString before_what, FileCloseContext context = Default);
210 void captureStop(
bool discard =
false);
212 void findTextCodecs();
214 void initMainToolbarIcons();
215 void initShowHideMainWidgets();
216 void initTimeDisplayFormatMenu();
217 void initTimePrecisionFormatMenu();
218 void initFreezeActions();
220 void setMenusForCaptureFile(
bool force_disable =
false);
221 void setMenusForCaptureInProgress(
bool capture_in_progress =
false);
222 void setMenusForCaptureStopping();
223 void setForCapturedPackets(
bool have_captured_packets);
224 void setMenusForFileSet(
bool enable_list_files);
225 void setWindowIcon(
const QIcon &icon);
226 void updateStyleSheet();
228 void externalMenuHelper(
ext_menu_t * menu, QMenu * subMenu,
int depth);
230 void setForCaptureInProgress(
bool capture_in_progress =
false,
bool handle_toolbars =
false, GArray *ifaces = NULL);
231 QMenu* findOrAddMenu(QMenu *parent_menu,
const QStringList& menu_parts);
233 void captureFileReadStarted(
const QString &action);
235 void addMenuActions(QList<QAction *> &actions,
int menu_group);
236 void removeMenuActions(QList<QAction *> &actions,
int menu_group);
237 void goToConversationFrame(
bool go_next,
bool start_current =
true);
238 void colorizeWithFilter(QByteArray filter,
int color_number = -1);
242 void closePacketDialogs();
245 void fieldFilterChanged(
const QByteArray field_filter);
251 void showExtcapOptions(QString &device_name,
bool startCaptureOnClose);
273 bool openCaptureFile(QString cf_path, QString display_filter,
unsigned int type,
bool is_tempfile =
false);
274 bool openCaptureFile(QString cf_path = QString(), QString display_filter = QString()) {
return openCaptureFile(cf_path, display_filter, WTAP_TYPE_AUTO); }
275 void filterPackets(QString new_filter = QString(),
bool force =
false);
276 void layoutToolbars();
277 void updatePreferenceActions();
278 void updateRecentActions();
280 void setTitlebarForCaptureFile();
282 void showCaptureOptionsDialog();
292 void captureFileOpened();
293 void captureFileReadFinished();
294 void captureFileClosing();
295 void captureFileClosed();
297 void launchRLCGraph(
bool channelKnown, uint8_t RAT, uint16_t ueid, uint8_t rlcMode,
298 uint16_t channelType, uint16_t channelId, uint8_t direction);
300 void rtpPlayerDialogReplaceRtpStreams(QVector<rtpstream_id_t *> stream_ids);
301 void rtpPlayerDialogAddRtpStreams(QVector<rtpstream_id_t *> stream_ids);
302 void rtpPlayerDialogRemoveRtpStreams(QVector<rtpstream_id_t *> stream_ids);
303 void rtpAnalysisDialogReplaceRtpStreams(QVector<rtpstream_id_t *> stream_ids);
304 void rtpAnalysisDialogAddRtpStreams(QVector<rtpstream_id_t *> stream_ids);
305 void rtpAnalysisDialogRemoveRtpStreams(QVector<rtpstream_id_t *> stream_ids);
306 void rtpStreamsDialogSelectRtpStreams(QVector<rtpstream_id_t *> stream_ids);
307 void rtpStreamsDialogDeselectRtpStreams(QVector<rtpstream_id_t *> stream_ids);
313 void initViewColorizeMenu();
314 void initConversationMenus();
315 static bool addExportObjectsMenuItem(
const void *key,
void *value,
void *userdata);
316 void initExportObjectsMenus();
317 static bool addFollowStreamMenuItem(
const void *key,
void *value,
void *userdata);
318 void initFollowStreamMenus();
326 void startCapture(QStringList);
328 void pushLiveCaptureInProgress();
329 void popLiveCaptureInProgress();
332 void loadWindowGeometry();
333 void saveWindowGeometry();
334 void mainStackChanged(
int);
335 void updateRecentCaptures();
336 void recentActionTriggered();
337 void addPacketComment();
338 void editPacketComment();
339 void deletePacketComment();
340 void deleteCommentsFromPackets();
341 QString commentToMenuText(QString text,
int max_len = 40);
342 void setEditCommentsMenu();
343 void setMenusForSelectedPacket();
345 void interfaceSelectionChanged();
346 void captureFilterSyntaxChanged(
bool valid);
347 void redissectPackets();
348 void checkDisplayFilter();
349 void fieldsChanged();
350 void reloadLuaPlugins();
351 void showAccordionFrame(
AccordionFrame *show_frame,
bool toggle =
false);
352 void showColumnEditor(
int column);
353 void showPreferenceEditor();
354 void addStatsPluginsToMenu();
355 void addDynamicMenus();
356 void reloadDynamicMenus();
357 void addPluginIFStructures();
358 QMenu * searchSubMenu(QString objectName);
359 void activatePluginIFToolbar(
bool);
361 void startInterfaceCapture(
bool valid,
const QString capture_filter);
363 void applyGlobalCommandLineOptions();
364 void setFeaturesEnabled(
bool enabled =
true);
366 void on_actionNewDisplayFilterExpression_triggered();
367 void onFilterSelected(QString,
bool);
368 void onFilterPreferences();
369 void onFilterEdit(
int uatIndex);
372 void queuedFilterAction(QString filter, FilterAction::Action action, FilterAction::ActionType type);
379 void openStatCommandDialog(
const QString &menu_path,
const char *arg,
void *userdata);
386 void openTapParameterDialog(
const QString cfg_str,
const QString arg,
void *userdata);
387 void openTapParameterDialog();
389#if defined(HAVE_SOFTWARE_UPDATE) && defined(Q_OS_WIN)
390 void softwareUpdateRequested();
396 void connectFileMenuActions();
397 void exportPacketBytes();
399 void stripPacketHeaders();
400 void exportTLSSessionKeys();
403 void connectEditMenuActions();
404 void copySelectedItems(WiresharkMainWindow::CopySelected selection_type);
406 void editTimeShift();
407 void editConfigurationProfiles();
408 void editTimeShiftFinished(
int);
410 void editPacketCommentFinished(
PacketCommentDialog* pc_dialog,
int result,
unsigned nComment);
411 void deleteAllPacketComments();
412 void deleteAllPacketCommentsFinished(
int result);
413 void injectSecrets();
414 void discardAllSecrets();
415 void discardAllSecretsFinished(
int result);
416 void showPreferencesDialog(QString module_name);
418 void connectViewMenuActions();
419 void showHideMainWidgets(QAction *action);
420 void setTimestampFormat(QAction *action);
421 void setTimestampPrecision(QAction *action);
422 void setTimeDisplaySecondsWithHoursAndMinutes(
bool checked);
423 void editResolvedName();
424 void setNameResolution();
426 void showColoringRulesDialog();
427 void colorizeConversation(
bool create_rule =
false);
428 void colorizeActionTriggered();
429 void openPacketDialog(
bool from_reference =
false);
430 void reloadCaptureFileAsFormatOrCapture();
431 void reloadCaptureFile();
433 void connectGoMenuActions();
435 void setPreviousFocus();
436 void resetPreviousFocus();
438 void connectCaptureMenuActions();
439 void startCaptureTriggered();
441 void connectAnalyzeMenuActions();
443 void matchFieldFilter(FilterAction::Action action, FilterAction::ActionType filter_type);
444 void applyFieldAsColumn();
446 void filterMenuAboutToShow();
448 void applyConversationFilter();
449 void applyExportObject();
451 void openFollowStreamDialog(
int proto_id,
unsigned stream_num,
unsigned sub_stream_num,
bool use_stream_index =
true);
452 void openFollowStreamDialog(
int proto_id);
454 void statCommandExpertInfo(
const char *,
void *);
456 void connectHelpMenuActions();
458#ifdef HAVE_SOFTWARE_UPDATE
459 void checkForUpdates();
462 void goToCancelClicked();
463 void goToGoClicked();
464 void goToLineEditReturnPressed();
466 void connectStatisticsMenuActions();
468 void showResolvedAddressesDialog();
469 void showConversationsDialog();
470 void showEndpointsDialog();
472 void openTcpStreamDialog(
int graph_type);
473 void openSCTPAllAssocsDialog();
474 void on_actionSCTPShowAllAssociations_triggered();
475 void on_actionSCTPAnalyseThisAssociation_triggered();
476 void on_actionSCTPFilterThisAssociation_triggered();
477 void statCommandMulticastStatistics(
const char *arg,
void *);
479 void statCommandWlanStatistics(
const char *arg,
void *);
481 void openStatisticsTreeDialog(
const char *abbr);
482 void statCommandIOGraph(
const char *,
void *);
483 void showIOGraphDialog(io_graph_item_unit_t value_units, QString);
485 void connectTelephonyMenuActions();
490 void statCommandLteMacStatistics(
const char *arg,
void *);
491 void statCommandLteRlcStatistics(
const char *arg,
void *);
492 void openRtpStreamAnalysisDialog();
493 void openRtpPlayerDialog();
495 void connectWirelessMenuActions();
497 void connectToolsMenuActions();
499 void externalMenuItemTriggered();
501 void on_actionContextWikiProtocolPage_triggered();
502 void on_actionContextFilterFieldReference_triggered();
504 void extcap_options_finished(
int result);
505 void showExtcapOptionsDialog(QString & device_name,
bool startCaptureOnClose);
507 QString findRtpStreams(QVector<rtpstream_id_t *> *stream_ids,
bool reverse);
509 void openTLSKeylogDialog();