Example #1
0
  /**
   * mode =1 info 2:help
   *
   * @param text
   * @param mode
   */
  public StaticMessage(String text, int mode) {
    Image image = null;
    switch (mode) {
      case 1:
        image = new Image(BaseResource.INSTANCE.info_24());
        break;
      case 2:
        image = new Image(BaseResource.INSTANCE.help2_24());
        break;
      default:
        image = new Image(BaseResource.INSTANCE.info_24());
        break;
    }

    HTML html = new HTML("<a>" + text + "</a>");
    // this.setLayout(new RowLayout());
    this.setLayout(new RowLayout(Orientation.VERTICAL));
    this.add(image);
    this.add(html);
    setWordWrap(true);
  }
Example #2
0
  public void init() {
    toolBar = new PagingToolBar(5, true);
    getStore();
    // initwidget();
    store.addBaseStoreListener(BaseStoreEvent.EventType.LOAD_COMPLETE, this);

    printer = new Button("打印");
    // printer.setStyleName("printer");
    // printer.setIconStyle("printer");
    // printer.setId("printer");
    printer.setIcon(AbstractImagePrototype.create(BaseResource.INSTANCE.print_16()));

    printer.addListener(Events.Select, this);
  }
Example #3
0
  private void initWidget() {
    initmainpanel();
    addfinace.setIcon(AbstractImagePrototype.create(BaseResource.INSTANCE.addfinance()));
    d.setHeading("添加新会员");
    d.setIcon(AbstractImagePrototype.create(BaseResource.INSTANCE.contact24()));
    d.setLayout(new RowLayout(Orientation.HORIZONTAL));

    d.setButtons(Dialog.YESNO);
    d.getButtonById(Dialog.YES).setText("添加新会员");
    d.getButtonById(Dialog.NO).setText("关闭");
    d.getButtonById(Dialog.YES)
        .setIcon(AbstractImagePrototype.create(BaseResource.INSTANCE.contact24()));

    d.getButtonById(Dialog.YES).addListener(Events.Select, this);
    d.getButtonById(Dialog.NO).addListener(Events.Select, this);

    d.add(w, new RowData(1, 1));

    d.setSize(607, 373);
    // d.setAutoHeight(true);
    // d.setAutoWidth(true);

    store._LoadComplete();
  }