Package com.extjs.gxt.ui.client.widget

Examples of com.extjs.gxt.ui.client.widget.Dialog


          return;
        MessageBox.confirm("Confirm","Do you want to quit this room when you close the window?", new Listener<WindowEvent>()
        {
          public void handleEvent(WindowEvent be)
          {
            Dialog dialog = (Dialog) be.component;
            Button btn = dialog.getButtonPressed();
            if(btn.getItemId().equals(Dialog.YES))
            {
              room.logout();
              setCloseAction(CloseAction.CLOSE);
              unRegisterChatWindow(jid);
View Full Code Here


        String msg = JabberApp.getConstants().DeleteConfirm() +" "+jid+"?";
        MessageBox.confirm("Confirm",msg, new Listener<WindowEvent>()
        {
          public void handleEvent(WindowEvent be)
          {
            Dialog dialog = (Dialog) be.component;
            Button btn = dialog.getButtonPressed();
            if(btn.getItemId().equals(Dialog.YES))
              JabberApp.instance().removeUser(XmppID.parseId(jid));
             
          }
View Full Code Here

      public void onClick(ClickEvent event) {
        showAddDialog();
      }

      private void showAddDialog() {
        Dialog dialog = new Dialog();
        dialog.setHeading(messages.titlePopup());
        dialog.setLayout(new BorderLayout());
        dialog.setWidth(500);
        dialog.setHeight(220);
        dialog.setBodyBorder(false);
        dialog.setHideOnButtonClick(true);
        dialog.setButtons(Dialog.OKCANCEL);
        dialog.setButtonAlign(HorizontalAlignment.CENTER);
        dialog.setScrollMode(Scroll.AUTO);
        dialog.setModal(true);
        dialog.setBlinkModal(true);
        Button cancelButton = dialog.getButtonById(Dialog.CANCEL);
        cancelButton.setText(messages.cancel());
        Button okButton = dialog.getButtonById(Dialog.OK);
        okButton.setText(messages.ok());

        final AddAvancementForm addDataForm = new AddAvancementForm();
        dialog.add(addDataForm, new BorderLayoutData(LayoutRegion.CENTER));

        okButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
          public void componentSelected(ButtonEvent ce) {
            ProgressDto model = addDataForm.getDataModel();
            progressGrid.getStore().add(model);
            progressGrid.getView().refresh(true);
            //bus.fireEvent(new EtatAvancementEvent(listGestion,progressGrid.getStore().getModels()));
          }
        });

        dialog.show();
      }
    });

    LayoutContainer leftPanel = new LayoutContainer();
    leftPanel.setLayout(new TableLayout(1));
View Full Code Here

      public void onClick(ClickEvent event) {
        showAddDialog();
      }

      private void showAddDialog() {
        Dialog dialog = new Dialog();
        dialog.setHeading(messages.titlePopup());
        dialog.setLayout(new BorderLayout());
        dialog.setWidth(450);
        dialog.setHeight(180);
        dialog.setBodyBorder(false);
        dialog.setHideOnButtonClick(true);
        dialog.setButtons(Dialog.OKCANCEL);
        dialog.setButtonAlign(HorizontalAlignment.CENTER);
        dialog.setScrollMode(Scroll.AUTO);
        dialog.setModal(true);
        dialog.setBlinkModal(true);
        Button cancelButton = dialog.getButtonById(Dialog.CANCEL);
        cancelButton.setText(messages.cancel());
        Button okButton = dialog.getButtonById(Dialog.OK);
        okButton.setText(messages.ok());

        final AddCautionFournieForm addCautionFournieForm = new AddCautionFournieForm();
        dialog.add(addCautionFournieForm, new BorderLayoutData(LayoutRegion.CENTER));

        okButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
          public void componentSelected(ButtonEvent ce) {
            CautionFournieDto model = addCautionFournieForm.getDataModel();
            cautionFournieGrid.getStore().add(model);
          }
        });

        dialog.show();
      }
    });

    flexTable.setWidget(0, 1, addRow);
    cautionFieldset.add(layoutContainer_9);
View Full Code Here

      public void onClick(ClickEvent event) {
    showAddDialog();
      }

      private void showAddDialog() {
    Dialog dialog = new Dialog();
    dialog.setHeading(messages.titlePopup());
    dialog.setLayout(new BorderLayout());
    dialog.setWidth(600);
    dialog.setHeight(350);
    dialog.setBodyBorder(false);
    dialog.setHideOnButtonClick(true);
    dialog.setButtons(Dialog.OKCANCEL);
    dialog.setButtonAlign(HorizontalAlignment.CENTER);
    dialog.setScrollMode(Scroll.AUTO);
    dialog.setModal(true);
    dialog.setBlinkModal(true);
    Button cancelButton = dialog.getButtonById(Dialog.CANCEL);
    cancelButton.setText(messages.cancel());
    Button okButton = dialog.getButtonById(Dialog.OK);
    okButton.setText(messages.ok());
    final AddTransfertPpForm addTransferPpForm = new AddTransfertPpForm();
    dialog.add(addTransferPpForm, new BorderLayoutData(LayoutRegion.CENTER));
    okButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
        @Override
        public void componentSelected(ButtonEvent ce) {
      LigTransfertppModel model = addTransferPpForm.getDataModel();
      gridligModel.getStore().add(model);
      isSave = false;
        }
    });
    dialog.show();
      }
  });
  layoutContainer_11.add(gridligModel);
  btnRetour = new Button();
  btnRetour.setId("btnValider");
View Full Code Here

  @Override
  protected void onRender(Element parent, int pos) {
    super.onRender(parent, pos);

    final Dialog simple = new Dialog();
    simple.setHeading("Dialog Test");
    simple.setButtons(Dialog.YESNO);
    simple.setBodyStyleName("pad-text");
    simple.addText(TestData.DUMMY_TEXT_SHORT);
    simple.getItem(0).getFocusSupport().setIgnore(true);
    simple.setScrollMode(Scroll.AUTO);
    simple.setHideOnButtonClick(true);

    final Dialog complex = new Dialog();
    complex.setBodyBorder(false);
    complex.setIcon(Resources.ICONS.side_list());
    complex.setHeading("BorderLayout Dialog");
    complex.setWidth(400);
    complex.setHeight(225);
    complex.setHideOnButtonClick(true);

    BorderLayout layout = new BorderLayout();
    complex.setLayout(layout);

    // west
    ContentPanel panel = new ContentPanel();
    panel.setHeading("West");
    BorderLayoutData data = new BorderLayoutData(LayoutRegion.WEST, 150, 100, 250);
    data.setMargins(new Margins(0, 5, 0, 0));
    data.setSplit(true);
    data.setCollapsible(true);
    complex.add(panel, data);

    // center
    panel = new ContentPanel();
    panel.setHeading("Center");
    data = new BorderLayoutData(LayoutRegion.CENTER);
    complex.add(panel, data);

    ButtonBar buttons = new ButtonBar();

    buttons.add(new Button("Simple", new SelectionListener<ButtonEvent>() {
      public void componentSelected(ButtonEvent ce) {
        simple.show();
      }
    }));

    buttons.add(new Button("Layout", new SelectionListener<ButtonEvent>() {
      public void componentSelected(ButtonEvent ce) {
        complex.show();
      }
    }));

    add(buttons, new FlowData(10));
  }
View Full Code Here

      public void onClick(ClickEvent event) {
        showAddAccomptesDialog();
      }

      private void showAddAccomptesDialog() {
        final Dialog dialog = new Dialog();
        dialog.setHeading(messages.titlePopup());
        dialog.setLayout(new BorderLayout());
        dialog.setWidth(600);
        dialog.setHeight(400);
        dialog.setBodyBorder(false);
        dialog.setHideOnButtonClick(false);
        dialog.setButtons(Dialog.OKCANCEL);
        dialog.setButtonAlign(HorizontalAlignment.CENTER);
        dialog.setScrollMode(Scroll.AUTO);
        dialog.setModal(true);
        dialog.setBlinkModal(true);
        Button cancelButton = dialog.getButtonById(Dialog.CANCEL);
        cancelButton.setText(messages.cancel());
        Button okButton = dialog.getButtonById(Dialog.OK);
        okButton.setText(messages.ok());

        final AddAccomptesForm addDataForm = new AddAccomptesForm();
        dialog.add(addDataForm, new BorderLayoutData(LayoutRegion.CENTER));

        okButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
          @Override
          public void componentSelected(ButtonEvent ce) {
            if (addDataForm.isValid()) {
              DeductionDto model = addDataForm.getDataModel();
              deductionGrid.getStore().add(model);
              deductionGrid.getView().refresh(true);
              // bus.fireEvent(new
              // DeductionGridUpdateEvent(deductionGrid.getStore().getModels()));
              dialog.hide();
            }
          }
        });

        cancelButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
          @Override
          public void componentSelected(ButtonEvent ce) {
            dialog.hide();
          }
        });

        dialog.show();
      }
    });

    flexTable.setWidget(0, 1, addRow);
    deductionsPaymentsFieldSet.add(flexTable);

    paymentFieldSet.add(deductionsPaymentsFieldSet);

    LayoutContainer accomptesPanel3 = new LayoutContainer();
    accomptesPanel3.setWidth("75%");
    TableLayout tl2 = new TableLayout(3);
    tl2.setWidth("100%");
    accomptesPanel3.setLayout(tl2);

    FieldSet penaltyFielSet = new FieldSet();
    // penaltyFielSet.setWidth("80%");
    setBackgroundColor(penaltyFielSet, BACKGROUD_COLOR_2);
    penaltyFielSet.setHeading(messages.penalites().toUpperCase());
    TableData td4 = new TableData();
    td4.setWidth("55%");

    createPenaltyGrid();
    penaltyFielSet.add(penaltyGrid);

    FlexTable flexTable2 = new FlexTable();
    HTML space2 = new HTML(SPACES_4);
    flexTable2.setWidget(0, 0, space2);
    addRow2.setStyleName("actionHTML2");
    addRow2.addClickHandler(new ClickHandler() {
      @Override
      public void onClick(ClickEvent event) {
        showAddPenaltyDialog();
      }

      private void showAddPenaltyDialog() {
        Dialog dialog = new Dialog();
        dialog.setHeading(messages.titlePopup());
        dialog.setLayout(new BorderLayout());
        dialog.setWidth(500);
        dialog.setHeight(260);
        dialog.setBodyBorder(false);
        dialog.setHideOnButtonClick(true);
        dialog.setButtons(Dialog.OKCANCEL);
        dialog.setButtonAlign(HorizontalAlignment.CENTER);
        dialog.setScrollMode(Scroll.AUTO);
        dialog.setModal(true);
        dialog.setBlinkModal(true);
        Button cancelButton = dialog.getButtonById(Dialog.CANCEL);
        cancelButton.setText(messages.cancel());
        Button okButton = dialog.getButtonById(Dialog.OK);
        okButton.setText(messages.ok());

        final AddPenaltyForm addDataForm = new AddPenaltyForm();
        dialog.add(addDataForm, new BorderLayoutData(LayoutRegion.CENTER));

        okButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
          @Override
          public void componentSelected(ButtonEvent ce) {
            PenaltyDto model = addDataForm.getDataModel();
            penaltyGrid.getStore().add(model);
            penaltyGrid.getView().refresh(true);
          }
        });

        dialog.show();
      }
    });

    flexTable2.setWidget(0, 1, addRow2);
View Full Code Here

      public void onClick(ClickEvent event) {
    showAddDialog();
      }

      private void showAddDialog() {
    final Dialog dialog = new Dialog();
    dialog.setHeading(messages.titlePopup());
    dialog.setLayout(new BorderLayout());
    dialog.setWidth(600);
    dialog.setHeight(550);
    dialog.setBodyBorder(false);
    dialog.setHideOnButtonClick(false);
    dialog.setButtons(Dialog.OKCANCEL);
    dialog.setButtonAlign(HorizontalAlignment.CENTER);
    dialog.setScrollMode(Scroll.AUTO);
    dialog.setModal(true);
    dialog.setBlinkModal(true);
    Button cancelButton = dialog.getButtonById(Dialog.CANCEL);
    cancelButton.setText(messages.cancel());
    Button okButton = dialog.getButtonById(Dialog.OK);
    okButton.setText(messages.ok());

    final AddGestionForm addGestionForm = new AddGestionForm();
    dialog.add(addGestionForm, new BorderLayoutData(LayoutRegion.CENTER));

    okButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
        @Override
        public void componentSelected(ButtonEvent ce) {
      if (addGestionForm.isValid()) {
          GestionDto model = addGestionForm.getDataModel();
          gestionGrid.getStore().add(model);

          bus.fireEvent(new EtatAvancementEvent(gestionGrid.getStore().getModels(), null));
          dialog.hide();
      }
        }
    });

    cancelButton.addSelectionListener(new SelectionListener<ButtonEvent>() {
        @Override
        public void componentSelected(ButtonEvent ce) {
      dialog.hide();
        }
    });

    dialog.show();
      }
  });

  addFicheST.setStyleName("actionHTML2");
  ft1.setWidget(0, 1, addFicheST);
View Full Code Here

    ListLoader<ListLoadResult<BeanModel>> loader = new BaseListLoader<ListLoadResult<BeanModel>>(proxy,
        new BeanModelReader());
    store = new ListStore<BeanModel>(loader);
    loader.load();

    chooser = new Dialog();
    chooser.setId("img-chooser-dlg");
    chooser.setHeading("Choose an Image");
    chooser.setMinWidth(500);
    chooser.setMinHeight(300);
    chooser.setModal(true);
View Full Code Here

                }

                public void onSuccess(String url) {
                    if (url != null) {
                        HTML link = new HTML(Messages.get("webFolderMessage.label") + "<br /><br /><a target=\"_new\" folder=\"" + url + "\" style=\"behavior:url(#default#AnchorClick)\">" + selection.getName() + "</a>");
                        final Dialog dl = new Dialog();
                        dl.setModal(true);
                        dl.setHeading(Messages.get("label.openIEFolder"));
                        dl.setHideOnButtonClick(true);
                        dl.setLayout(new FlowLayout());
                        dl.setScrollMode(Style.Scroll.AUTO);
                        dl.add(link);
                        dl.setHeight(150);
                        linker.loaded();
                        dl.show();
                    }
                }
            });
        }
    }
View Full Code Here

TOP

Related Classes of com.extjs.gxt.ui.client.widget.Dialog

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.