Nifty window

hi guys,

today i have a problem with the window Control…well

i am confused on how to set the visibility of the window … or reopen it after closing…


WindowControl w = this.screen.findNiftyControl("window-3", WindowControl.class);




i seems to get a nullpointer exception… but java finds the window since i can change the title for example

but how to hide/show the window in general? didnt find anything except :

w.getContent() gets the content of the window…

there i thought getElement() should get the Element itself and i can hide/show it…but doesnt seem so

plz enlighten me :slight_smile:



1 Like

lol … solved it after another 2 mins…

for others :


WindowControl w = this.screen.findNiftyControl(“window-3”, WindowControl.class);


Element z = this.screen.findElementByName(“window-3”);



but i have another problem :

how to add the draggable function within xml?


<layer id=“windows” childLayout=“absolute”>

<control id=“window-3” name=“window” title=“Please Drag Me Too!” width=“500px” height=“400px” x=“400px”>

<text text=“I’m Another Window!” style=“base-font” color="#eeef" valign=“center” width=“100%” />




so far it disapears and console says “WARNUNG: missing popup [draggablePopup] o_O”

from this statement i conclude it should be withing a popup and not within the same screen where i want to open it…but that didnt solve it …

thx in advance