All Downloads are FREE. Search and download functionalities are using the official Maven repository.

xworker.javafx.control.PasswordFieldActions Maven / Gradle / Ivy

There is a newer version: 2.0.2
Show newest version
package xworker.javafx.control;

import javafx.scene.control.PasswordField;
import javafx.scene.text.Font;
import org.xmeta.ActionContext;
import org.xmeta.Thing;

public class PasswordFieldActions {
    public static void init(PasswordField node, Thing thing, ActionContext actionContext){
        TextFieldActions.init(node, thing, actionContext);
    }

    public static PasswordField create(ActionContext actionContext){
        Thing self = actionContext.getObject("self");

        PasswordField node = new PasswordField();
        init(node, self, actionContext);
        actionContext.g().put(self.getMetadata().getName(), node);

        actionContext.peek().put("parent", node);
        for(Thing child : self.getChilds()){
            Object obj = child.doAction("create", actionContext);
            if(obj instanceof Font){
                node.setFont((Font) obj);
            }
        }

        return node;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy