Add plugin JS resource paths to /config/server/info

This requires WebUiPlugins to be bound in the system module.  Existing
plugins that do this binding in the HttpModule are supported by
copying the DynamicSet from the system module.

The Maven plugin archetype is adapted to generate a correct example
for WebUiPlugin bindings.

Bug: issue 3915
Change-Id: Ic976ba1b4a3fc8d08975fd841e5013f7348b32cf
This commit is contained in:
Andrew Bonventre
2016-03-03 16:01:59 -05:00
committed by Jonathan Nieder
parent 8682415768
commit c8a2ed9c6c
14 changed files with 92 additions and 99 deletions

View File

@@ -18,6 +18,7 @@ import com.google.gerrit.client.rpc.NativeMap;
import com.google.gerrit.client.rpc.NativeString;
import com.google.gerrit.client.rpc.Natives;
import com.google.gwt.core.client.JavaScriptObject;
import com.google.gwt.core.client.JsArrayString;
import java.util.HashMap;
import java.util.Map;
@@ -68,6 +69,8 @@ public class ServerInfo extends JavaScriptObject {
public static class PluginConfigInfo extends JavaScriptObject {
public final native boolean hasAvatars() /*-{ return this.has_avatars || false; }-*/;
public final native JsArrayString jsResourcePaths() /*-{
return this.js_resource_paths || []; }-*/;
protected PluginConfigInfo() {
}