Package com.wiquery.plugin.antilia.link

Examples of com.wiquery.plugin.antilia.link.ActionsPanel


   * @param parameters
   *            Page parameters
   */
    public EffectsPanel(String id) {
      super(id);
      ActionsPanel actions  = new ActionsPanel("actions");     
      add(actions);
     
      actions.addItem(effectSpeedPanel = new EffectSpeedPanel(actions.newChildId(), EffectSpeed.SLOW));
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(),"Toggle") {
       
        private static final long serialVersionUID = 1L;

      public void onClick(AjaxRequestTarget target) {
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new Toggle(effectSpeedPanel.getSpeed())).render(true)).toString());
        };       
      });

      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(),"Show") {
       
        private static final long serialVersionUID = 1L;

      public void onClick(AjaxRequestTarget target) {
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new Show(effectSpeedPanel.getSpeed())).render(true)).toString());
        };       
      });
     
     
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "Hide"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new Hide(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });
     
     
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "FadeIn"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new FadeIn(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });   
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "FadeOut"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new FadeOut(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "SlideDown"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new SlideDown(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });

      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "SlideUp"){
       
        private static final long serialVersionUID = 1L;
      @Override
        public void onClick(AjaxRequestTarget target) {       
View Full Code Here


      add(JavascriptPackageResource.getHeaderContribution(ScaleEffectJavaScriptResourceReference.get()));
      add(JavascriptPackageResource.getHeaderContribution(PulsateEffectJavaScriptResourceReference.get()));
      add(JavascriptPackageResource.getHeaderContribution(BounceEffectJavaScriptResourceReference.get()));
      add(JavascriptPackageResource.getHeaderContribution(HighlightEffectJavaScriptResourceReference.get()));
     
      ActionsPanel actions = new ActionsPanel("actions");
     
      add(actions);
     
      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Show Explode") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
          return new JsStatement().$(null, "#explode").chain(new ExplodeEffect(Mode.show, 16, 2000));
        }
      });

      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Shake") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
        return new JsStatement().$(null, "#explode").chain(new ShakeEffect(Direction.down));
        }
      })
     
      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Scale UP") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
          return new JsStatement().$(null, "#explode").chain(
              new ScaleEffect(org.odlabs.wiquery.ui.effects.ScaleEffect.Direction.both,
                  Scale.box,
                  120, 1000));
        }
      });
     
      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Scale Down") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
        return new JsStatement().$(null, "#explode").chain(
              new ScaleEffect(org.odlabs.wiquery.ui.effects.ScaleEffect.Direction.both,
                  Scale.box,
                  80, 1000));
        }
      });
     
      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Pulsate") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
        return new JsStatement().$(null, "#explode").chain(new PulsateEffect());
        }
      });
     
      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Bounce") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
        return new JsStatement().$(null, "#explode")
        .chain(new BounceEffect(BounceDirection.up, BounceMode.show, 5, 40, 200));
        }
      });
     
      actions.addItem(new ScriptTextLinkPanel(actions.newChildId(), "Highlight") {
       
        private static final long serialVersionUID = 1L;

      @Override
        protected JsStatement getClickAction() {
View Full Code Here

   * @param parameters
   *            Page parameters
   */
    public EffectsPanel(String id) {
      super(id);
      ActionsPanel actions  = new ActionsPanel("actions");     
      add(actions);
     
      actions.addItem(effectSpeedPanel = new EffectSpeedPanel(actions.newChildId(), EffectSpeed.SLOW));
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(),"Toggle") {
       
        private static final long serialVersionUID = 1L;

      public void onClick(AjaxRequestTarget target) {
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new Toggle()).render(true)).toString());
        };       
      });

      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(),"Show") {
       
        private static final long serialVersionUID = 1L;

      public void onClick(AjaxRequestTarget target) {
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new Show(effectSpeedPanel.getSpeed())).render(true)).toString());
        };       
      });
     
     
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "Hide"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new Hide(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });
     
     
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "FadeIn"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new FadeIn(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });   
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "FadeOut"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new FadeOut(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });
     
      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "SlideDown"){
       
        private static final long serialVersionUID = 1L;

      @Override
        public void onClick(AjaxRequestTarget target) {       
        target.appendJavascript(new StringBuffer(new JsStatement().$(effects).chain(new SlideDown(effectSpeedPanel.getSpeed())).render(true)).toString());
        }
     
      });

      actions.addItem(new AjaxTextLinkPanel(actions.newChildId(), "SlideUp"){
       
        private static final long serialVersionUID = 1L;
      @Override
        public void onClick(AjaxRequestTarget target) {       
View Full Code Here

TOP

Related Classes of com.wiquery.plugin.antilia.link.ActionsPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.