// This function runs "configure" and then rereads lyx.defaults to
// reconfigure the automatic settings.
-static void reconfigure(GuiView * lv, string const & option)
+void GuiApplication::reconfigure(string const & option)
{
// emit message signal.
- if (lv)
- lv->message(_("Running configure..."));
+ if (current_view_)
+ current_view_->message(_("Running configure..."));
// Run configure in user lyx directory
PathChanger p(package().user_support());
int ret = one.startscript(Systemcall::Wait, configure_command);
p.pop();
// emit message signal.
- if (lv)
- lv->message(_("Reloading configuration..."));
+ if (current_view_)
+ current_view_->message(_("Reloading configuration..."));
lyxrc.read(libFileSearch(QString(), "lyxrc.defaults"));
// Re-read packages.lst
LaTeXFeatures::getAvailable();
"not be able to work properly.\n"
"Please reconfigure again if needed."));
else
-
Alert::information(_("System reconfigured"),
_("The system has been reconfigured.\n"
"You need to restart LyX to make use of any\n"
}
-
void GuiApplication::dispatch(FuncRequest const & cmd, DispatchResult & dr)
{
string const argument = to_utf8(cmd.argument());
// --- Menus -----------------------------------------------
case LFUN_RECONFIGURE:
// argument is any additional parameter to the configure.py command
- reconfigure(currentView(), to_utf8(cmd.argument()));
+ reconfigure(to_utf8(cmd.argument()));
break;
// --- lyxserver commands ----------------------------