Code: Select all
/**
* Primefaces widget: ACE Editor.
*/
@ResourceDependencies({//
@ResourceDependency(library = "app", name = "ace/ace.js"),//
@ResourceDependency(library = "app", name = "ace/ext-searchbox.js"),//
@ResourceDependency(library = "app", name = "ace/worker-json.js"),//
@ResourceDependency(library = "app", name = "ace/worker-xml.js"),//
@ResourceDependency(library = "app", name = "ace/mode-text.js"),//
@ResourceDependency(library = "app", name = "ace/mode-yaml.js"),//
@ResourceDependency(library = "app", name = "ace/mode-json.js"),//
@ResourceDependency(library = "app", name = "ace/mode-xml.js"),//
@ResourceDependency(library = "app", name = "ace/mode-sql.js"),//
@ResourceDependency(library = "app", name = "ace/ext-language_tools.js"),//
@ResourceDependency(library = "primefaces", name = "jquery/jquery.js"),//
@ResourceDependency(library = "primefaces", name = "core.js"),//
@ResourceDependency(library = "primefaces", name = "components.js"),//
@ResourceDependency(library = "app", name = "codecompletion/codecompletion.js"),//
@ResourceDependency(library = "app", name = "primefaces/widget/aceeditor.js"),//
@ResourceDependency(library = "app", name = "codecompletion/codecompletion.css")//
})
@FacesComponent(createTag = true, tagName = "aceEditor", namespace = "http://myapp.com/app", value = "com.myapp.aceeditor.AceEditor")
public class AceEditor extends UIInput implements Widget, ClientBehaviorHolder {
private static final Logger log = Slf4jLoggerFactory.getLogger(AceEditor.class);
[...]
}
Code: Select all
/**
* Update a component with AJAX.
*
* @param clientId Client side identifier of the component.
*/
public static void update(String clientId) {
if(PrimeFaces.current().isAjaxRequest() && clientId != null)
PrimeFaces.current().ajax().update(clientId);
}
I've seen the very same behaviour also for some PrimeFaces components (maybe not all PrimeFaces components use a resource dependency).
My current guess it that this behaviour has something to do with the Dynamic Resource Loading implementation of PrimeFaces.
I use PrimeFaces 10.0.7 within a JBoss 7.4.0 running Mojarra 2.3.14.SP04-redhat-00001.