Package com.google.gwt.user.client.ui

Examples of com.google.gwt.user.client.ui.Image$State


    }

    private Image createEmoticon(final AbstractImagePrototype imageProto, final String emoticonText,
      final EmoticonPaletteListener listener)
    {
      final Image img = new Image();
      imageProto.applyTo(img);
      img.addClickListener(new ClickListener()
      {

        public void onClick(final Widget arg0)
        {
          listener.onEmoticonSelected(emoticonText);
        }
      });
      img.setTitle(emoticonText);
      return img;
    }
View Full Code Here


        return message;
    }

    private static String getImgHtml(final AbstractImagePrototype img) {
        final Image image = new Image();
        DOM.setStyleAttribute(image.getElement(), "vertical-align", "bottom");
        img.applyTo(image);
        image.setStyleName("vamiddle");
        return img.getHTML();
    }
View Full Code Here

    }
       
    private String formatStatusIcon(XmppContactStatus status)
    {
      final AbstractImagePrototype icon = iconFromStatus(status);
      final Image iconImg = new Image();
      icon.applyTo(iconImg);
      return iconImg.toString();
    }
View Full Code Here

      HorizontalPanel hp2 = new HorizontalPanel();
      hp2.setVerticalAlignment(HorizontalPanel.ALIGN_MIDDLE);
      focusPanel = new FocusPanel(hp2);

      if ( tooltip != null && tooltip.length() > 0 ) {
        Image ttIcon = new TooltipIcon(tooltip).getIcon();
        hp1.add(ttIcon);
      }
     
      hp1.add(focusPanel);
     
View Full Code Here

    public GameImageSupplier() {
      gameImages = GWT.create(GameImages.class);
    }
   
    public Image getPokerTable() {
      return new Image(gameImages.pokertable());
    }
View Full Code Here

    public Image getPokerTable() {
      return new Image(gameImages.pokertable());
    }
   
    public Image getPlayerplace() {
      return new Image(gameImages.playerplace());
    }
View Full Code Here

   * set background
   */
  @Override
  public void setBackground(ArrayList<String> playerIds) {
    // set the background image
    Image pokertable = gameimages.getPokerTable();
    int picWidth = pokertable.getWidth();
    int picHeight = pokertable.getHeight();
    int numPlayer = playerIds.size();
    backgroundArea.setPixelSize(picWidth, picHeight);
    backgroundArea.add(pokertable);
    // set chip images
    int chipWidth = 60;
    int chipHeight = 60;

    chip10.setPixelSize(chipWidth, chipHeight);
    backgroundArea.add(chip10);
    backgroundArea.setWidgetPosition(chip10, 300, 450);

    chip20.setPixelSize(chipWidth, chipHeight);
    backgroundArea.add(chip20);
    backgroundArea.setWidgetPosition(chip20, 400, 450);

    chip50.setPixelSize(chipWidth, chipHeight);
    backgroundArea.add(chip50);
    backgroundArea.setWidgetPosition(chip50, 500, 450);

    chip100.setPixelSize(chipWidth, chipHeight);
    backgroundArea.add(chip100);
    backgroundArea.setWidgetPosition(chip100, 600, 450);

    PairsPlus = new Image(chipImages.PairsPlus());
    PairsPlus.setPixelSize(chipWidth + 40, chipHeight + 40);
    backgroundArea.add(PairsPlus);
    backgroundArea.setWidgetPosition(PairsPlus, 380, 300);

    Ante = new Image(chipImages.Ante());
    Ante.setPixelSize(chipWidth + 40, chipHeight + 40);
    backgroundArea.add(Ante);
    backgroundArea.setWidgetPosition(Ante, 500, 300);

    // set dealer's place
    int dealerNameTop = (int) (pokertable.getHeight() * 0.22);
    int dealerCardTop = dealerNameTop + NAME_HEIGHT;

    namePlaces.add(new Label(messages.setDealer()));
    cardPlaces.add(new FlowPanel());
    int left = (int) (0.5 * picWidth - 0.5 * CARD_WIDTH);
 
View Full Code Here

    placeAnimationImages(cardPlaces.get(i), playerCardImages);
  }

  private void placeImages(FlowPanel panel, List<Image> images) {
    panel.clear();
    Image last = images.isEmpty() ? null : images.get(images.size() - 1);
    for (Image image : images) {
      if (image != last) {
        // crop the image
        image.setPixelSize(20, 100);
      } else {
View Full Code Here

    * @param panel
    * @param images
    */
  private void placeInitiateImages(FlowPanel panel, List<Image> images) {
    panel.clear();
    Image last = images.isEmpty() ? null : images.get(images.size() - 1);
    for (Image image : images) {
      if (image != last) {
        // crop the image
        animation = new CardMovingAnimation(panel, image, image, 20,
            100);
View Full Code Here

    }
  }

  private void placeAnimationImages(FlowPanel panel, List<Image> images) {
    panel.clear();
    Image last = images.isEmpty() ? null : images.get(images.size() - 1);
    for (Image image : images) {
      if (image != last) {
        image.setPixelSize(40, 100);
        animation = new CardMovingAnimation(panel, image, image, 40,
            100);
View Full Code Here

TOP

Related Classes of com.google.gwt.user.client.ui.Image$State

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.