Library->save_changes ();
}
-SoundFileBrowser::SoundFileBrowser (Gtk::Window& parent, string title, ARDOUR::Session* s, bool persistent)
- : ArdourWindow (parent, title)
+SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persistent)
+ : ArdourWindow (title)
, found_list (ListStore::create(found_list_columns))
, freesound_list (ListStore::create(freesound_list_columns))
, chooser (FILE_CHOOSER_ACTION_OPEN)
Gtkmm2ext::UI::instance()->set_tip (cancel_button, _("Press to close this window without importing any files"));
vpacker.pack_end (*button_box, false, false);
+
+ set_wmclass (X_("import"), PROGRAM_NAME);
}
SoundFileBrowser::~SoundFileBrowser ()
}
freesound_progress_bar.set_text(
- string_compose(_("found %1 matche(s)"), matches));
+ string_compose(P_("found %1 match", "found %1 matches", matches), matches));
preview.setup_labels (file);
}
gdk_window_set_cursor (get_window()->gobj(), prev_cursor);
freesound_progress_bar.set_fraction(0.0);
- switch (matches) {
- case 0:
- freesound_progress_bar.set_text(_("Search returned no results."));
- break;
- case 1:
- freesound_progress_bar.set_text(_("Found one match."));
- break;
- default:
- freesound_progress_bar.set_text(string_compose(_("Found %1 matche(s)"), matches));
+ if (matches == 0) {
+ freesound_progress_bar.set_text(_("Search returned no results."));
+ } else {
+ freesound_progress_bar.set_text(string_compose(P_("Found %1 match", "Found %1 matches", matches), matches));
}
freesound_list_view.get_column(1)->set_sizing(TREE_VIEW_COLUMN_AUTOSIZE);
#endif
return ret;
}
-SoundFileChooser::SoundFileChooser (Gtk::Window& parent, string title, ARDOUR::Session* s)
- : SoundFileBrowser (parent, title, s, false)
+SoundFileChooser::SoundFileChooser (string title, ARDOUR::Session* s)
+ : SoundFileBrowser (title, s, false)
{
chooser.set_select_multiple (false);
found_list_view.get_selection()->set_mode (SELECTION_SINGLE);
return paths.front();
}
-SoundFileOmega::SoundFileOmega (Gtk::Window& parent, string title, ARDOUR::Session* s,
+SoundFileOmega::SoundFileOmega (string title, ARDOUR::Session* s,
uint32_t selected_audio_tracks,
uint32_t selected_midi_tracks,
bool persistent,
Editing::ImportMode mode_hint)
- : SoundFileBrowser (parent, title, s, persistent)
+ : SoundFileBrowser (title, s, persistent)
, copy_files_btn ( _("Copy files to session"))
, selected_audio_track_cnt (selected_audio_tracks)
, selected_midi_track_cnt (selected_midi_tracks)