diff options
author | Guy Harris <guy@alum.mit.edu> | 2013-11-08 09:53:01 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2013-11-08 09:53:01 +0000 |
commit | 853da2eb9ba1732b37d3f47319bc94471d9c0e16 (patch) | |
tree | 94f8afdae71f496fe638550f9e2cea926195b8ee /ui/qt/capture_file_dialog.cpp | |
parent | 5cec175b071b85c7cd392350e2fcc246dc20d41d (diff) | |
download | wireshark-853da2eb9ba1732b37d3f47319bc94471d9c0e16.tar.gz |
The "file types" we have are actually combinations of types and
subtypes, e.g. Network Monitor version 1 and Network Monitor version 2
are separate "file types", even though they both come from Network
Monitor.
Rename various functions, #defines, and variables appropriately.
svn path=/trunk/; revision=53166
Diffstat (limited to 'ui/qt/capture_file_dialog.cpp')
-rw-r--r-- | ui/qt/capture_file_dialog.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/ui/qt/capture_file_dialog.cpp b/ui/qt/capture_file_dialog.cpp index 2ff11b190a..6b452352ed 100644 --- a/ui/qt/capture_file_dialog.cpp +++ b/ui/qt/capture_file_dialog.cpp @@ -334,7 +334,7 @@ QString CaptureFileDialog::fileType(int ft, bool extension_globs) QString filter; GSList *extensions_list; - filter = wtap_file_type_string(ft); + filter = wtap_file_type_subtype_string(ft); if (!extension_globs) { return filter; @@ -672,7 +672,7 @@ int CaptureFileDialog::merge(QString &file_name) { QStringList CaptureFileDialog::buildFileSaveAsTypeList(bool must_support_all_comments) { QStringList filters; guint32 required_comment_types; - GArray *savable_file_types; + GArray *savable_file_types_subtypes; guint i; type_hash_.clear(); @@ -684,25 +684,25 @@ QStringList CaptureFileDialog::buildFileSaveAsTypeList(bool must_support_all_com required_comment_types = 0; /* none of them */ /* What types of file can we save this file as? */ - savable_file_types = wtap_get_savable_file_types(cap_file_->cd_t, - cap_file_->linktypes, - required_comment_types); + savable_file_types_subtypes = wtap_get_savable_file_types_subtypes(cap_file_->cd_t, + cap_file_->linktypes, + required_comment_types); - if (savable_file_types != NULL) { + if (savable_file_types_subtypes != NULL) { QString file_type; int ft; /* OK, we have at least one file type we can save this file as. (If we didn't, we shouldn't have gotten here in the first place.) Add them all to the combo box. */ - for (i = 0; i < savable_file_types->len; i++) { - ft = g_array_index(savable_file_types, int, i); + for (i = 0; i < savable_file_types_subtypes->len; i++) { + ft = g_array_index(savable_file_types_subtypes, int, i); if (default_ft_ < 1) default_ft_ = ft; /* first file type is the default */ file_type = fileType(ft); filters << file_type; type_hash_[file_type] = ft; } - g_array_free(savable_file_types, TRUE); + g_array_free(savable_file_types_subtypes, TRUE); } return filters; @@ -777,7 +777,7 @@ void CaptureFileDialog::preview(const QString & path) } // Format - preview_format_.setText(QString::fromUtf8(wtap_file_type_string(wtap_file_type(wth)))); + preview_format_.setText(QString::fromUtf8(wtap_file_type_subtype_string(wtap_file_type_subtype(wth)))); // Size preview_size_.setText(QString(tr("%1 bytes")).arg(wtap_file_size(wth, &err))); |