Examples of bindText()


Examples of org.terasology.rendering.nui.widgets.UIButton.bindText()

                    public Boolean get() {
                        return moduleList.getSelection() != null
                                && (moduleList.getSelection().isSelected() || moduleList.getSelection().isValidToSelect());
                    }
                });
                toggle.bindText(new ReadOnlyBinding<String>() {
                    @Override
                    public String get() {
                        if (moduleList.getSelection() != null) {
                            if (moduleList.getSelection().isExplicitSelection()) {
                                return "Deactivate";
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

                }
            }
        });

        final UILabel history = find("messageHistory", UILabel.class);
        history.bindText(new ReadOnlyBinding<String>() {
            @Override
            public String get() {
                StringBuilder messageList = new StringBuilder();
                for (Message msg : console.getMessages(CoreMessageType.CHAT, CoreMessageType.NOTIFICATION)) {
                    messageList.append(msg.getMessage());
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

            });

            final ListSelectionBinding<ServerInfo> infoBinding = new ListSelectionBinding<ServerInfo>(serverList);

            UILabel name = find("name", UILabel.class);
            name.bindText(BindHelper.bindBoundBeanProperty("name", infoBinding, ServerInfo.class, String.class));

            UILabel address = find("address", UILabel.class);
            address.bindText(BindHelper.bindBoundBeanProperty("address", infoBinding, ServerInfo.class, String.class));

            UILabel port = find("port", UILabel.class);
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

            UILabel name = find("name", UILabel.class);
            name.bindText(BindHelper.bindBoundBeanProperty("name", infoBinding, ServerInfo.class, String.class));

            UILabel address = find("address", UILabel.class);
            address.bindText(BindHelper.bindBoundBeanProperty("address", infoBinding, ServerInfo.class, String.class));

            UILabel port = find("port", UILabel.class);
            port.bindText(new IntToStringBinding(BindHelper.bindBoundBeanProperty("port", infoBinding, ServerInfo.class, int.class)));

            WidgetUtil.trySubscribe(this, "add", new ActivateEventListener() {
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

            UILabel address = find("address", UILabel.class);
            address.bindText(BindHelper.bindBoundBeanProperty("address", infoBinding, ServerInfo.class, String.class));

            UILabel port = find("port", UILabel.class);
            port.bindText(new IntToStringBinding(BindHelper.bindBoundBeanProperty("port", infoBinding, ServerInfo.class, int.class)));

            WidgetUtil.trySubscribe(this, "add", new ActivateEventListener() {
                @Override
                public void onActivated(UIWidget button) {
                    getManager().pushScreen(AddServerPopup.ASSET_URI);
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

                }
            };

            UILabel name = find("name", UILabel.class);
            if (name != null) {
                name.bindText(new ReadOnlyBinding<String>() {
                    @Override
                    public String get() {
                        if (moduleInfoBinding.get() != null) {
                            return moduleInfoBinding.get().getDisplayName().toString();
                        }
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

                });
            }

            UILabel version = find("version", UILabel.class);
            if (version != null) {
                version.bindText(new ReadOnlyBinding<String>() {
                    @Override
                    public String get() {
                        if (moduleInfoBinding.get() != null) {
                            return moduleInfoBinding.get().getVersion().toString();
                        }
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

                });
            }

            UILabel description = find("description", UILabel.class);
            if (description != null) {
                description.bindText(new ReadOnlyBinding<String>() {
                    @Override
                    public String get() {
                        if (moduleInfoBinding.get() != null) {
                            return moduleInfoBinding.get().getDescription().toString();
                        }
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

                });
            }

            UILabel error = find("errorMessage", UILabel.class);
            if (error != null) {
                error.bindText(new ReadOnlyBinding<String>() {
                    @Override
                    public String get() {
                        if (moduleList.getSelection() != null) {
                            if (!moduleList.getSelection().isValidToSelect()) {
                                return "Incompatible with existing selection, or dependencies cannot be resolved";
View Full Code Here

Examples of org.terasology.rendering.nui.widgets.UILabel.bindText()

                return value.getMetadata().getDisplayName().value();
            }
        });

        UILabel gameplayDescription = find("gameplayDescription", UILabel.class);
        gameplayDescription.bindText(new ReadOnlyBinding<String>() {
            @Override
            public String get() {
                Module selectedModule = gameplay.getSelection();
                if (selectedModule != null) {
                    return selectedModule.getMetadata().getDescription().value();
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.