use of org.apache.wicket.request.resource.JavaScriptResourceReference in project openmeetings by apache.
the class UploadDialog method renderHead.
@Override
public void renderHead(IHeaderResponse response) {
super.renderHead(response);
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forReference(new JavaScriptResourceReference(UploadDialog.class, "upload.js"))));
}
use of org.apache.wicket.request.resource.JavaScriptResourceReference in project openmeetings by apache.
the class RoomPanel method renderHead.
@Override
public void renderHead(IHeaderResponse response) {
super.renderHead(response);
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forReference(interview ? INTERVIEWWB_JS_REFERENCE : WB_JS_REFERENCE)));
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forReference(new JavaScriptResourceReference(RoomPanel.class, "room.js"))));
if (room.isVisible()) {
response.render(OnDomReadyHeaderItem.forScript(roomEnter.getCallbackScript()));
}
}
use of org.apache.wicket.request.resource.JavaScriptResourceReference in project openmeetings by apache.
the class BasePage method internalRenderHead.
protected void internalRenderHead(IHeaderResponse response) {
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forReference(Application.get().getJavaScriptLibrarySettings().getJQueryReference())));
super.renderHead(response);
final String suffix = DEVELOPMENT == getApplication().getConfigurationType() ? "" : ".min";
response.render(CssHeaderItem.forUrl(String.format("css/theme_om/jquery-ui%s.css", suffix)));
response.render(CssHeaderItem.forUrl(String.format("css/theme%s.css", suffix)));
if (isRtl()) {
response.render(CssHeaderItem.forUrl(String.format("css/theme-rtl%s.css", suffix)));
}
if (!Strings.isEmpty(getGaCode())) {
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forReference(new JavaScriptResourceReference(BasePage.class, "om-ga.js"))));
StringBuilder script = new StringBuilder("initGA('");
script.append(getGaCode()).append("');").append(isMainPage() ? "initHash()" : "init()").append(';');
response.render(OnDomReadyHeaderItem.forScript(script));
}
}
use of org.apache.wicket.request.resource.JavaScriptResourceReference in project openmeetings by apache.
the class UserMultiChoice method renderHead.
@Override
public void renderHead(IHeaderResponse response) {
super.renderHead(response);
response.render(new PriorityHeaderItem(JavaScriptHeaderItem.forReference(new JavaScriptResourceReference(getClass(), "user-multi-choice.js"), "user-multi-choice")));
}
use of org.apache.wicket.request.resource.JavaScriptResourceReference in project wicket by apache.
the class FilteredHeaderPage method renderHead.
@Override
public void renderHead(IHeaderResponse response) {
// rendered at the default header bucket
final JavaScriptResourceReference topJsReference = new JavaScriptResourceReference(FilteredHeaderPage.class, "top.js");
response.render(new FilteredHeaderItem(JavaScriptHeaderItem.forReference(topJsReference), FilteringHeaderResponse.DEFAULT_HEADER_FILTER_NAME));
// rendered at the bottom of the body bucket
JQueryPluginResourceReference bottomJs = new JQueryPluginResourceReference(FilteredHeaderPage.class, "bottom.js") {
private static final long serialVersionUID = 1L;
@Override
public List<HeaderItem> getDependencies() {
List<HeaderItem> dependencies = super.getDependencies();
// WICKET-4566 : depend on a resource which is rendered in a different bucket
dependencies.add(JavaScriptHeaderItem.forReference(topJsReference));
return dependencies;
}
};
response.render(JavaScriptHeaderItem.forReference(bottomJs));
}
Aggregations