#ifdef TOP_MENUBAR
- _auto_display_errors = false;
+ // _auto_display_errors = false;
+ /*
+ * This was commented out as it wasn't defined
+ * in A3 IIRC. If this is not needed it should
+ * be completely removed.
+ */
#endif
about = 0;
}
gboolean
-ARDOUR_UI::configure_handler (GdkEventConfigure* conf)
+ARDOUR_UI::configure_handler (GdkEventConfigure* /*conf*/)
{
if (have_configure_timeout) {
last_configure_time = get_microseconds();
if (session->transport_rolling()) {
session->request_stop ();
- usleep (2500000);
+ usleep (250000);
}
if (session->dirty()) {
}
gint
-ARDOUR_UI::session_menu (GdkEventButton *ev)
+ARDOUR_UI::session_menu (GdkEventButton */*ev*/)
{
session_popup_menu->popup (0, 0);
return TRUE;
void
ARDOUR_UI::build_session_selector ()
{
- session_selector_window = new ArdourDialog ("session selector");
+ session_selector_window = new ArdourDialog (_("Recent Sessions"));
Gtk::ScrolledWindow *scroller = manage (new Gtk::ScrolledWindow);
}
void
-ARDOUR_UI::recent_session_row_activated (const TreePath& path, TreeViewColumn* col)
+ARDOUR_UI::recent_session_row_activated (const TreePath& /*path*/, TreeViewColumn* /*col*/)
{
session_selector_window->response (RESPONSE_ACCEPT);
}
void
-ARDOUR_UI::session_add_midi_route (bool disk, RouteGroup* edit_group, uint32_t how_many)
+ARDOUR_UI::session_add_midi_route (bool disk, RouteGroup* route_group, uint32_t how_many)
{
list<boost::shared_ptr<MidiTrack> > tracks;
try {
if (disk) {
- tracks = session->new_midi_track (ARDOUR::Normal, edit_group, how_many);
+ tracks = session->new_midi_track (ARDOUR::Normal, route_group, how_many);
if (tracks.size() != how_many) {
if (how_many == 1) {
void
-ARDOUR_UI::session_add_audio_route (bool track, int32_t input_channels, int32_t output_channels, ARDOUR::TrackMode mode, RouteGroup* edit_group, uint32_t how_many)
+ARDOUR_UI::session_add_audio_route (bool track, int32_t input_channels, int32_t output_channels, ARDOUR::TrackMode mode, RouteGroup* route_group, uint32_t how_many)
{
list<boost::shared_ptr<AudioTrack> > tracks;
RouteList routes;
try {
if (track) {
- tracks = session->new_audio_track (input_channels, output_channels, mode, edit_group, how_many);
+ tracks = session->new_audio_track (input_channels, output_channels, mode, route_group, how_many);
if (tracks.size() != how_many) {
if (how_many == 1) {
} else {
- routes = session->new_audio_route (input_channels, output_channels, edit_group, how_many);
+ routes = session->new_audio_route (input_channels, output_channels, route_group, how_many);
if (routes.size() != how_many) {
if (how_many == 1) {
return 0;
}
+void
+ARDOUR_UI::idle_load (const Glib::ustring& path)
+{
+ if (session) {
+ if (Glib::file_test (path, Glib::FILE_TEST_IS_DIR)) {
+ /* /path/to/foo => /path/to/foo, foo */
+ load_session (path, basename_nosuffix (path));
+ } else {
+ /* /path/to/foo/foo.ardour => /path/to/foo, foo */
+ load_session (Glib::path_get_dirname (path), basename_nosuffix (path));
+ }
+ } else {
+
+ ARDOUR_COMMAND_LINE::session_name = path;
+
+ /*
+ * new_session_dialog doens't exist in A3
+ * Try to remove all references to it to
+ * see if it will compile. NOTE: this will
+ * likely cause a runtime issue is my somewhat
+ * uneducated guess.
+ */
+
+ //if (new_session_dialog) {
+
+
+ /* make it break out of Dialog::run() and
+ start again.
+ */
+
+ //new_session_dialog->response (1);
+ //}
+ }
+}
+
void
ARDOUR_UI::end_loading_messages ()
{
}
void
-ARDOUR_UI::loading_message (const std::string& msg)
+ARDOUR_UI::loading_message (const std::string& /*msg*/)
{
// show_splash ();
// splash->message (msg);
unload_session (true);
+ ARDOUR_COMMAND_LINE::session_name = "";
get_session_parameters (false);
}
}
void
-ARDOUR_UI::about_signal_response(int response)
+ARDOUR_UI::about_signal_response (int /*response*/)
{
hide_about();
}
}
void
-ARDOUR_UI::display_cleanup_results (Session::cleanup_report& rep, const gchar* list_title, const string & msg)
+ARDOUR_UI::display_cleanup_results (Session::cleanup_report& rep, const gchar* list_title,
+ const string& plural_msg, const string& singular_msg)
{
size_t removed;
const string dead_sound_directory = session->session_directory().dead_sound_path().to_string();
+
+
+
+ /* subst:
+ %1 - number of files removed
+ %2 - location of "dead_sounds"
+ %3 - size of files affected
+ %4 - prefix for "bytes" to produce sensible results (e.g. mega, kilo, giga)
+ */
+
+ const char* bprefix;
+
if (rep.space < 1048576.0f) {
- if (removed > 1) {
- txt.set_text (string_compose (msg, removed, _("files were"), dead_sound_directory, (float) rep.space / 1024.0f, "kilo"));
- } else {
- txt.set_text (string_compose (msg, removed, _("file was"), dead_sound_directory, (float) rep.space / 1024.0f, "kilo"));
- }
+ bprefix = X_("kilo");
+ } else if (rep.space < 1048576.0f * 1000) {
+ bprefix = X_("mega");
} else {
- if (removed > 1) {
- txt.set_text (string_compose (msg, removed, _("files were"), dead_sound_directory, (float) rep.space / 1048576.0f, "mega"));
- } else {
- txt.set_text (string_compose (msg, removed, _("file was"), dead_sound_directory, (float) rep.space / 1048576.0f, "mega"));
- }
+ bprefix = X_("giga");
+ }
+
+ if (removed > 1) {
+ txt.set_text (string_compose (plural_msg, removed, dead_sound_directory, (float) rep.space / 1024.0f, bprefix));
+ } else {
+ txt.set_text (string_compose (singular_msg, removed, dead_sound_directory, (float) rep.space / 1024.0f, bprefix));
}
dhbox.pack_start (*dimage, true, false, 5);
display_cleanup_results (rep,
_("cleaned files"),
_("\
-The following %1 %2 not in use and \n\
+The following %1 files were not in use and \n\
have been moved to:\n\
-%3. \n\n\
+%2. \n\n\
+Flushing the wastebasket will \n\
+release an additional\n\
+%3 %4bytes of disk space.\n"),
+ _("\
+The following file was not in use and \n \
+has been moved to:\n \
+%2. \n\n\
Flushing the wastebasket will \n\
release an additional\n\
-%4 %5bytes of disk space.\n"
+%3 %4bytes of disk space.\n"
));
}
display_cleanup_results (rep,
_("deleted file"),
- _("The following %1 %2 deleted from\n\
-%3,\n\
-releasing %4 %5bytes of disk space"));
+ _("The following %1 files were deleted from\n\
+%2,\n\
+releasing %3 %4bytes of disk space"),
+ _("The following file was deleted from\n\
+%2,\n\
+releasing %3 %4bytes of disk space"));
}
void
uint32_t output_chan;
string name_template = add_route_dialog->name_template ();
bool track = add_route_dialog->track ();
- RouteGroup* edit_group = add_route_dialog->edit_group ();
+ RouteGroup* route_group = add_route_dialog->route_group ();
AutoConnectOption oac = Config->get_output_auto_connect();
if (add_route_dialog->type() == ARDOUR::DataType::MIDI) {
if (track) {
- session_add_midi_track(edit_group, count);
+ session_add_midi_track (route_group, count);
} else {
MessageDialog msg (*editor,
_("Sorry, MIDI Busses are not supported at this time."));
}
} else {
if (track) {
- session_add_audio_track (input_chan, output_chan, add_route_dialog->mode(), edit_group, count);
+ session_add_audio_track (input_chan, output_chan, add_route_dialog->mode(), route_group, count);
} else {
- session_add_audio_bus (input_chan, output_chan, edit_group, count);
+ session_add_audio_bus (input_chan, output_chan, route_group, count);
}
}
}
}
void
-ARDOUR_UI::disk_speed_dialog_gone (int ignored_response, MessageDialog* msg)
+ARDOUR_UI::disk_speed_dialog_gone (int /*ignored_response*/, MessageDialog* msg)
{
have_disk_speed_dialog_displayed = false;
delete msg;