posted 15 years ago
> But when I am trying to open and close any module multiple times, the
> window is moving down and to the right, so that the window buttons like
> minimum, restore, close are going outside the screen.
sounds like you are using setLocationRelativeTo(...), but adding the line
PRIOR to giving the frame a size (setSize or pack), so its positioning
is based on a size of (0,0) i.e. positions its top-left corner in the middle
of the relativeTo(...), which makes subsequent frame/s show "down and to the right"