Skip to content

Commit

Permalink
minor tweak to ensure jQuery-ui is loaded before the datapicker.js
Browse files Browse the repository at this point in the history
  • Loading branch information
stephanrauh committed Mar 1, 2015
1 parent f809f4a commit b014190
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/net/bootsfaces/component/DatePicker.java
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
@ResourceDependency(library = "bsf", name = "css/jq.ui.datepicker.css", target = "head"),
@ResourceDependency(library = "bsf", name = "css/bsf.css", target = "head"),
/* moved to constructor @ResourceDependency(library = "bsf", name = "jq/ui/datepicker.js", target = "head") */
@ResourceDependency(library = "bsf", name = "js/bsf.js", target = "head"),
/* moved to constructor @ResourceDependency(library = "bsf", name = "js/bsf.js", target = "head"), */
@ResourceDependency(library = "bsf", name = "jq/ui/core.js", target = "body")

})
Expand Down Expand Up @@ -101,7 +101,8 @@ public class DatePicker extends HtmlInputText {
public DatePicker() {
setRendererType(null); // this component renders itself

AddResourcesListener.addResourceToHeadButAfterJQuery(C.BSF_LIBRARY, "jq/jquery.js");
AddResourcesListener.addResourceToHeadButAfterJQuery(C.BSF_LIBRARY, "jq/jquery.js");
AddResourcesListener.addResourceToHeadButAfterJQuery(C.BSF_LIBRARY, "jq/ui/core.js");
AddResourcesListener.addResourceToHeadButAfterJQuery(C.BSF_LIBRARY, "jq/ui/datepicker.js");
FacesContext context = FacesContext.getCurrentInstance();
Application app = context.getApplication();
Expand Down

0 comments on commit b014190

Please sign in to comment.