Ejemplo n.º 1
0
 public CharSequence decorateScript(CharSequence script) {
   IVeilScope veilScope = getVeilScope();
   if (veilScope != null) {
     return "if(Wicket.Veil){"
         + VeilResources.Javascript.Generic.show(veilScope.getVeilId())
         + ";};"
         + script;
   }
   return "if(Wicket.Veil){" + VeilResources.Javascript.Generic.show("AT_body") + ";};" + script;
 }
Ejemplo n.º 2
0
 public CharSequence decorateOnSuccessScript(CharSequence script) {
   IVeilScope veilScope = getVeilScope();
   if (veilScope != null) {
     return script
         + ";if(Wicket.Veil){"
         + VeilResources.Javascript.Generic.toggle(veilScope.getVeilId())
         + ";};";
   }
   return script
       + ";if(Wicket.Veil){"
       + VeilResources.Javascript.Generic.toggle("AT_body")
       + ";};";
 }
Ejemplo n.º 3
0
 public CharSequence decorateOnFailureScript(CharSequence script) {
   IVeilScope veilScope = getVeilScope();
   String errorMessage =
       ";alert('"
           + this.veilFinder.getDefiningComponent().getString("ServerDown", null, "Server Down!")
           + "');";
   if (veilScope != null) {
     return script
         + ";if(Wicket.Veil){"
         + VeilResources.Javascript.Generic.toggle(veilScope.getVeilId())
         + ";};"
         + errorMessage;
   }
   return script
       + ";if(Wicket.Veil){"
       + VeilResources.Javascript.Generic.toggle("AT_body")
       + ";};"
       + errorMessage;
 }