Package com.ponysdk.ui.server.rich

Examples of com.ponysdk.ui.server.rich.POptionPane


        final PButton anchor4 = addButton("Open");
        anchor4.addClickHandler(new PClickHandler() {

            @Override
            public void onClick(final PClickEvent clickEvent) {
                final POptionPane dialodBox = POptionPane.showConfirmDialog(new PActionHandler() {

                    @Override
                    public void onAction(final PDialogBox dialogBox, final String option) {
                        dialogBox.hide();
                    }
                }, "Your custom text");

                dialodBox.getDialogBox().addCloseHandler(new PCloseHandler() {

                    @Override
                    public void onClose(final PCloseEvent closeEvent) {
                        final DemoBusinessEvent event = new DemoBusinessEvent(this);
                        event.setBusinessMessage("Dialog box closed");
View Full Code Here


            @Override
            public void onClick(final PClickEvent clickEvent) {
                optionsAnchor.removeStyleName(PonySDKTheme.HEADER_ACCOUNT_MENU_SELECTED);
                popup.hide();

                final POptionPane optionPane = POptionPane.showConfirmDialog(new PActionHandler() {

                    @Override
                    public void onAction(final PDialogBox dialogBox, final String option) {
                        if (POption.YES_OPTION.equals(option)) {
                            dialogBox.hide();
                            final UserLoggedOutEvent userLoggedOutEvent = new UserLoggedOutEvent(this, userLogged);
                            fireEvent(userLoggedOutEvent);
                        } else {
                            dialogBox.hide();
                        }
                    }
                }, "Really logout user " + userLogged.getName() + " ?", "Sign out", POptionType.YES_NO_OPTION);

                optionPane.getDialogBox().ensureDebugId("sign_out_dialog");
            }
        });

        optionsAnchor.addClickHandler(new PClickHandler() {
View Full Code Here

TOP

Related Classes of com.ponysdk.ui.server.rich.POptionPane

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.