Package org.itsnat.comp

Examples of org.itsnat.comp.ItsNatComponentManager.findItsNatComponent()


    public void initInputPassword()
    {
        org.w3c.dom.Document doc = itsNatDoc.getDocument();
        HTMLInputElement inputElem = (HTMLInputElement)doc.getElementById("passwordInputId");
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        ItsNatHTMLInputPassword input = (ItsNatHTMLInputPassword)componentMgr.findItsNatComponent(inputElem);
        PlainDocument dataModel = new PlainDocument();
        input.setDocument(dataModel);

        input.addEventListener("change",this);
View Full Code Here


    {
        // Evento "change"
        ItsNatDOMStdEvent itsNatEvent = (ItsNatDOMStdEvent)evt;
        ItsNatHTMLDocument itsNatDoc = (ItsNatHTMLDocument)itsNatEvent.getItsNatDocument();
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        ItsNatHTMLInputTextBased input = (ItsNatHTMLInputTextBased)componentMgr.findItsNatComponent((Node)evt.getCurrentTarget());

        if (updateAgainToTest)
            input.setText(input.getText() + "-ok-"); // Para testear que hemos recibido el valor del cliente y que podemos cambiarlo desde el servidor. Al llegar al navegador no provoca a su vez un nuevo evento change pues el evento est� asociado a la p�rdida de foco (lo cual no ocurre en la actualizaci�n via JavaScript)

        outText("OK " + evt.getType() + " "); // Para que se vea
View Full Code Here

    public void init(String id)
    {
        Document doc = itsNatDoc.getDocument();
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        HTMLAnchorElement elem = (HTMLAnchorElement)doc.getElementById(id);
        this.button = (ItsNatHTMLAnchor)componentMgr.findItsNatComponent(elem);
        DefaultButtonModel dataModel = new DefaultButtonModel();
        button.setButtonModel(dataModel);

        button.addEventListener("click",this);
View Full Code Here

    public static ItsNatHTMLInputText getInputText(String id,Node containerNode,ItsNatList list)
    {
        Element firstName = ItsNatDOMUtil.getElementById(id,containerNode);
        ItsNatComponentManager compMgr = list.getItsNatComponentManager();
        return (ItsNatHTMLInputText)compMgr.findItsNatComponent(firstName);
    }

    public void renderListCell(ItsNatList list, int index, Object value, boolean isSelected, boolean hasFocus, Element cellContentElem, boolean isNew)
    {
        ItsNatListMultSel listMult = (ItsNatListMultSel)list;
View Full Code Here

    public void load()
    {
        Document doc = itsNatDoc.getDocument();
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        HTMLInputElement inputElem = (HTMLInputElement)doc.getElementById("fileUploadInputId");
        this.input = (ItsNatHTMLInputFile)componentMgr.findItsNatComponent(inputElem);
        HTMLIFrameElement iframeElem = (HTMLIFrameElement)doc.getElementById("fileUploadIFrameId");
        this.iframe = (ItsNatHTMLIFrame)componentMgr.findItsNatComponent(iframeElem);
        HTMLButtonElement buttonElem = (HTMLButtonElement)doc.getElementById("fileUploadButtonId");
        this.button = (ItsNatHTMLButton)componentMgr.findItsNatComponent(buttonElem);
        button.addEventListener("click", this);
View Full Code Here

        Document doc = itsNatDoc.getDocument();
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        HTMLInputElement inputElem = (HTMLInputElement)doc.getElementById("fileUploadInputId");
        this.input = (ItsNatHTMLInputFile)componentMgr.findItsNatComponent(inputElem);
        HTMLIFrameElement iframeElem = (HTMLIFrameElement)doc.getElementById("fileUploadIFrameId");
        this.iframe = (ItsNatHTMLIFrame)componentMgr.findItsNatComponent(iframeElem);
        HTMLButtonElement buttonElem = (HTMLButtonElement)doc.getElementById("fileUploadButtonId");
        this.button = (ItsNatHTMLButton)componentMgr.findItsNatComponent(buttonElem);
        button.addEventListener("click", this);
    }
View Full Code Here

        HTMLInputElement inputElem = (HTMLInputElement)doc.getElementById("fileUploadInputId");
        this.input = (ItsNatHTMLInputFile)componentMgr.findItsNatComponent(inputElem);
        HTMLIFrameElement iframeElem = (HTMLIFrameElement)doc.getElementById("fileUploadIFrameId");
        this.iframe = (ItsNatHTMLIFrame)componentMgr.findItsNatComponent(iframeElem);
        HTMLButtonElement buttonElem = (HTMLButtonElement)doc.getElementById("fileUploadButtonId");
        this.button = (ItsNatHTMLButton)componentMgr.findItsNatComponent(buttonElem);
        button.addEventListener("click", this);
    }

    public void handleEvent(Event evt)
    {
View Full Code Here

    public void initTree(String treeId,String addButtonId,String removeButtonId,String reloadButtonId,String joystickCheckboxId)
    {
        Document doc = itsNatDoc.getDocument();
        HTMLElement rootElem = (HTMLElement)doc.getElementById(treeId);
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        this.comp = (ItsNatFreeTree)componentMgr.findItsNatComponent(rootElem);

        comp.setToggleClickCount(2);

        DefaultMutableTreeNode rootNode = new DefaultMutableTreeNode("Root Item");
        DefaultTreeModel dataModel = new DefaultTreeModel(rootNode);
View Full Code Here

    public void initButton()
    {
        Document doc = itsNatDoc.getDocument();
        HTMLInputElement inputElem = (HTMLInputElement)doc.getElementById("inputButtonId");
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        ItsNatHTMLInputButton input = (ItsNatHTMLInputButton)componentMgr.findItsNatComponent(inputElem);
        DefaultButtonModel dataModel = new DefaultButtonModel();
        input.setButtonModel(dataModel);

        input.setLabelValue("Text Button");
        input.setEnabled(false); // Para testear la propagaci�n al DOM (getDisabled)
View Full Code Here

    public void handleEvent(Event evt)
    {
        ItsNatDOMStdEvent itsNatEvent = (ItsNatDOMStdEvent)evt;
        ItsNatHTMLDocument itsNatDoc = (ItsNatHTMLDocument)itsNatEvent.getItsNatDocument();
        ItsNatComponentManager componentMgr = itsNatDoc.getItsNatComponentManager();
        ItsNatHTMLInputButton input = (ItsNatHTMLInputButton)componentMgr.findItsNatComponent((Node)evt.getCurrentTarget());
        outText("OK " + evt.getType() + " "); // Para que se vea

        input.setLabelValue("Button " + evt.getType());
    }
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.