Package com.google.gwt.query.client

Examples of com.google.gwt.query.client.GQuery.data()


      return;
    }
    //String oldZIndex = $element.css(ZINDEX_CSS);
    String oldZIndex = getZIndex($element.get(0).getStyle());
    if (oldZIndex != null) {
      $element.data(OLD_ZINDEX_KEY, oldZIndex);
    }
    $element.css(ZINDEX_CSS, handler.getOptions().getZIndex().toString());

  }
View Full Code Here


    //helper can be null if the draggableElement was unloaded and after loaded
    GQuery $element = (handler.getOptions().getHelperType() == HelperType.ORIGINAL) ? handler.getHelper() : $(ctx.getDraggable());
    if ($element == null || $element.length() == 0) {
      return;
    }
    String oldZIndex = $element.data(OLD_ZINDEX_KEY, String.class);
    $element.css(ZINDEX_CSS, oldZIndex);
  }

  /**
   * Force the zIndex property to be a String object
View Full Code Here

    Float opacity = handler.getOptions().getOpacity();

    GQuery $helper = handler.getHelper();

    double oldOpacity = $helper.cur(OPACITY_CSS_KEY, true);
    $helper.data(OLD_OPACITY_KEY, new Double(oldOpacity));

    $helper.css(OPACITY_CSS_KEY, opacity.toString());

  }
View Full Code Here

    GQuery $element = (handler.getOptions().getHelperType() == HelperType.ORIGINAL) ? handler.getHelper() : $(ctx.getDraggable());
    if ($element == null || $element.length() == 0) {
      return;
    }

    if ($element.data(OLD_OPACITY_KEY) == null) {
      return;
    }
    Double oldOpacity = $element.data(OLD_OPACITY_KEY, Double.class);
    $element.css(OPACITY_CSS_KEY, oldOpacity != null ? String.valueOf(oldOpacity) : "");
    $element.removeData(OLD_OPACITY_KEY);
View Full Code Here

    }

    if ($element.data(OLD_OPACITY_KEY) == null) {
      return;
    }
    Double oldOpacity = $element.data(OLD_OPACITY_KEY, Double.class);
    $element.css(OPACITY_CSS_KEY, oldOpacity != null ? String.valueOf(oldOpacity) : "");
    $element.removeData(OLD_OPACITY_KEY);

  }
View Full Code Here

    if (ctx.getInitialDraggable() == ctx.getDraggable() && !isStarting) {
      isStarting = true;
      GQuery $body = $(body);
      String oldCursor = $body.css(CURSOR_CSS);
      if (oldCursor != null) {
        $body.data(OLD_CURSOR_KEY, oldCursor);
      }
      $body.css(CURSOR_CSS, handler.getOptions().getCursor().getCssName());
    }

  }
View Full Code Here

  public void onStop(DraggableHandler handler, DragContext ctx, GqEvent e) {
    if (ctx.getInitialDraggable() != ctx.getDraggable()) {
      return;
    }
    GQuery $body = $(body);
    String oldCursor = $body.data(OLD_CURSOR_KEY, String.class);
    $body.css(CURSOR_CSS, oldCursor);
    isStarting = false;
  }

}
View Full Code Here

    Offset newPosition = null;

    switch (groupingMode) {
      case DOWN:
        HelperInfo lastDown = $initialDraggable.data(LAST_DOWN, HelperInfo.class);
        if (lastDown == null) {
          lastDown = new HelperInfo(initialDragHandler.getAbsolutePosition(),
              initialDragHandler.getHelper());
        }
View Full Code Here

              initialDragHandler.getHelper());
        }

        newPosition = lastDown.offset.add(0, lastDown.height + groupSpacing);
        HelperInfo newLastDown = new HelperInfo(newPosition, handler.getHelper());
        $initialDraggable.data(LAST_DOWN, newLastDown);

        break;

      case UP:
        HelperInfo lastUp = $initialDraggable.data(LAST_UP, HelperInfo.class);
View Full Code Here

        $initialDraggable.data(LAST_DOWN, newLastDown);

        break;

      case UP:
        HelperInfo lastUp = $initialDraggable.data(LAST_UP, HelperInfo.class);
        if (lastUp == null) {
          lastUp = new HelperInfo(initialDragHandler.getAbsolutePosition(),
              initialDragHandler.getHelper());
        }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.