2010-11-26 18:31:14 -05:00
|
|
|
/*
|
2019-08-02 17:26:43 -04:00
|
|
|
* Copyright (C) 2010-2011 Carl Hetherington <carl@carlh.net>
|
|
|
|
* Copyright (C) 2011-2012 David Robillard <d@drobilla.net>
|
|
|
|
* Copyright (C) 2011-2016 Paul Davis <paul@linuxaudiosystems.com>
|
|
|
|
* Copyright (C) 2013-2016 Robin Gareus <robin@gareus.org>
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
|
|
*/
|
2010-11-26 18:31:14 -05:00
|
|
|
|
|
|
|
#include <gtkmm/label.h>
|
2021-07-06 18:17:17 -04:00
|
|
|
|
|
|
|
#include "pbd/compose.h"
|
2010-11-26 18:31:14 -05:00
|
|
|
#include "missing_plugin_dialog.h"
|
2021-07-06 18:17:17 -04:00
|
|
|
|
2016-07-14 14:44:52 -04:00
|
|
|
#include "pbd/i18n.h"
|
2010-11-26 18:31:14 -05:00
|
|
|
|
|
|
|
using namespace Gtk;
|
|
|
|
using namespace std;
|
|
|
|
using namespace ARDOUR;
|
|
|
|
using namespace PBD;
|
|
|
|
|
2021-07-06 18:33:50 -04:00
|
|
|
MissingPluginDialog::MissingPluginDialog (Gtk::Window& parent, Session* s, list<string> const & plugins, bool cache_valid)
|
|
|
|
: ArdourDialog (parent, _("Missing Plugins"), true, false)
|
2010-11-26 18:31:14 -05:00
|
|
|
{
|
Fix typos in gtk2_ardour/ directory
Found via `codespell -q 3 -S *.po,./share/patchfiles,./libs -L ba,buss,busses,doubleclick,hsi,ontop,ro,seh,siz,sur,te,trough,ue`
2022-01-26 12:35:38 -05:00
|
|
|
/* This dialog is always shown programmatically. Center the window.*/
|
2015-10-22 11:14:03 -04:00
|
|
|
set_position (Gtk::WIN_POS_CENTER);
|
|
|
|
|
|
|
|
set_session (s);
|
2010-11-26 18:31:14 -05:00
|
|
|
|
|
|
|
stringstream t;
|
2016-02-17 08:44:22 -05:00
|
|
|
t << _("This session contains the following plugins that cannot be found on this system:\n\n");
|
2010-11-26 18:31:14 -05:00
|
|
|
|
|
|
|
for (list<string>::const_iterator i = plugins.begin(); i != plugins.end(); ++i) {
|
|
|
|
t << *i << "\n";
|
|
|
|
}
|
2021-07-07 13:40:47 -04:00
|
|
|
t << _("\nThose plugins will be replaced with inactive stubs until the session is reloaded.\n");
|
2021-07-06 18:17:17 -04:00
|
|
|
|
|
|
|
if (cache_valid) {
|
|
|
|
add_button (_("OK"), RESPONSE_OK);
|
|
|
|
set_default_response (RESPONSE_OK);
|
2021-10-06 21:10:48 -04:00
|
|
|
t << _("It is recommended that you install missing, re-scan updated plugins, and re-load the session.\n");
|
2021-07-06 18:17:17 -04:00
|
|
|
} else {
|
2021-07-07 13:40:47 -04:00
|
|
|
t << _("Third party plugins have not yet been indexed.") << "\n";
|
2021-07-06 18:17:17 -04:00
|
|
|
t << string_compose (_("Scan %1 plugins now?"),
|
|
|
|
#ifdef __APPLE__
|
|
|
|
_("AudioUnit and VST")
|
|
|
|
#else
|
|
|
|
_("VST")
|
|
|
|
#endif
|
|
|
|
);
|
2010-11-26 18:31:14 -05:00
|
|
|
|
2021-07-06 18:17:17 -04:00
|
|
|
add_button (_("Yes"), RESPONSE_YES);
|
|
|
|
add_button (_("No"), RESPONSE_NO);
|
|
|
|
set_default_response (RESPONSE_YES);
|
|
|
|
}
|
2011-06-01 13:00:29 -04:00
|
|
|
|
2021-07-06 18:17:17 -04:00
|
|
|
Label* m = manage (new Label);
|
2017-07-01 12:42:24 -04:00
|
|
|
m->set_markup (t.str ());
|
|
|
|
get_vbox()->pack_start (*m, false, false);
|
2010-11-26 18:31:14 -05:00
|
|
|
|
|
|
|
show_all ();
|
|
|
|
}
|