I am creating a small GUI applications with multiple frames. Like a login screen, admin screen, member screen etc. The main frame is the login frame and then you could log in either as administrator or member. The administrator and member frames also has a bunch of buttons and clicking each each button again gives you another new frame for doing other stuffs.
So now my problem is how do you switch back and forth between the frames. How do you make it like when I am in the admin screen the login screen disappears and when I am in admin panel and click one button and it shows another frame. And when I am currently in that frame then how do I make my Admin frame freeze. And when I logout of the admin panel it should also take me back to the login screen.
I tried windowListener but cannot really figure out how to get it done.
How do I really implement these kinds of things.