merge of 'a3d362477b328c80ac2cd052f635d3ddd3b39c81'

and 'c21005b174cec3b4ae419318758f1a9c2071cf64'
This commit is contained in:
str4d
2012-01-17 03:03:07 +00:00
26 changed files with 322 additions and 44 deletions

View File

@ -54,6 +54,10 @@ public class ConfigClientsHandler extends FormHandler {
installPlugin();
return;
}
if (_action.equals(_("Update All Installed Plugins"))) {
updateAllPlugins();
return;
}
// value
if (_action.startsWith("Start ")) {
String app = _action.substring(6);
@ -322,6 +326,16 @@ public class ConfigClientsHandler extends FormHandler {
installPlugin(url);
}
/** @since 0.8.13 */
private void updateAllPlugins() {
addFormNotice(_("Updating all plugins"));
PluginStarter.updateAll(_context);
// So that update() will post a status to the summary bar before we reload
try {
Thread.sleep(1000);
} catch (InterruptedException ie) {}
}
private void installPlugin(String url) {
if ("true".equals(System.getProperty(UpdateHandler.PROP_UPDATE_IN_PROGRESS))) {
addFormError(_("Plugin or update download already in progress."));