Package nextapp.echo2.app.button

Examples of nextapp.echo2.app.button.ButtonModel.addActionListener()


        });
        controlsColumn.add(nullButton);
       
        Button customButton = new Button("Custom Style Sheet (Edit Below)");
        customButton.setStyleName("Default");
        customButton.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                try {
                    StyleSheet styleSheet = loadStyleSheet(styleSheetEntryTextArea.getDocument().getText());
                    getApplicationInstance().setStyleSheet(styleSheet);
                } catch (ComponentXmlException ex) {
View Full Code Here


     * @param clickCount the number of buttons to click
     */
    private void addRandomClickButton(final int clickCount) {
        Button button = new Button("Perform " + clickCount + " Random Click" + (clickCount == 1 ? "" : "s"));
        button.setStyleName("Default");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                for (int i = 0; i < clickCount; ++i) {
                    RandomClick.clickRandomButton();
                }
            }
View Full Code Here

    public Button createGridCellButton() {
        Button button = new Button("Grid Cell #" + nextCellNumber++);
        GridLayoutData layoutData = new GridLayoutData();
        button.setLayoutData(layoutData);
        button.addActionListener(cellButtonActionListener);
        return button;
    }
   
    private void retitle(Button button) {
        StringBuffer out = new StringBuffer();
View Full Code Here

       
        Button button;
       
        button = new Button("Enqueue Redirect Command");
        button.setStyleName("Default");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                getApplicationInstance().enqueueCommand(new BrowserRedirectCommand("http://echo.nextapp.com"));
            }
        });
        add(button);
View Full Code Here

        });
        add(button);
       
        button = new Button("Enqueue Redirect Command to mailto: URL");
        button.setStyleName("Default");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                getApplicationInstance().enqueueCommand(new BrowserRedirectCommand("mailto:info@nextapp.com"));
            }
        });
        add(button);
View Full Code Here

        });
        add(button);
       
        button = new Button("Enqueue Simple Window Open Command");
        button.setStyleName("Default");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                getApplicationInstance().enqueueCommand(
                        new BrowserOpenWindowCommand("http://echo.nextapp.com", null, null));
            }
        });
View Full Code Here

        });
        add(button);
       
        button = new Button("Enqueue 640x240 Named Window Open Command");
        button.setStyleName("Default");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                getApplicationInstance().enqueueCommand(
                        new BrowserOpenWindowCommand("http://echo.nextapp.com",
                        "auxwindow", "width=640,height=240"));
            }
View Full Code Here

            switch (column) {
                case 0:
                    if (selectable) {
                        final CheckBox checkBox = new CheckBox("");
                        checkBox.setSelected((Boolean) value);
                        checkBox.addActionListener(new ActionListener() {

                            public void actionPerformed(ActionEvent arg0) {
                                if (checkBox.isSelected())
                                    tableModel.selectInvoice(invoice);
                                else
View Full Code Here

        for (int i = 1; i <= 3; ++i) {
            CheckBox checkBox = new CheckBox("CheckBox #" + i);
            checkBox.setStyleName("Default");
            componentSamplerColumn.add(checkBox);
            if (launchModals && i == 1) {
                checkBox.addActionListener(new ActionListener() {
                    public void actionPerformed(ActionEvent e) {
                        getApplicationInstance().getDefaultWindow().getContent().add(createComponentSamplerModalTestWindow());
                    }
                });
            }
View Full Code Here

        }
        componentSamplerColumn.add(table);
       
        ListBox listBox = new ListBox(ListBoxTest.NUMBERS);
        if (launchModals) {
            listBox.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    getApplicationInstance().getDefaultWindow().getContent().add(createComponentSamplerModalTestWindow());
                }
            });
        }
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.