* [ 1684137 ] File Logout is not closing Viewer windows

This commit is contained in:
Heng Sin Low 2007-03-22 16:05:18 +00:00
parent 032b64d168
commit 7eb00b551e
3 changed files with 4 additions and 2 deletions

View File

@ -315,7 +315,7 @@ public final class AEnv
}
else if (actionCommand.equals("Logout"))
{
AMenu aMenu = (AMenu)Env.getWindow(WindowNo);
AMenu aMenu = (AMenu)Env.getWindow(0);
aMenu.logout();
}

View File

@ -211,7 +211,8 @@ public class AReport implements ActionListener
{
// It's a default report using the standard printing engine
ReportEngine re = new ReportEngine (Env.getCtx(), pf, m_query, info);
new Viewer(re);
Viewer viewer = new Viewer(re);
AEnv.addToWindowManager(viewer);
}
// if (m_popup.isVisible())
// m_popup.setVisible(false);

View File

@ -386,6 +386,7 @@ public class Viewer extends CFrame
AEnv.addMenuItem("Export", null, null, mFile, this);
mFile.addSeparator();
AEnv.addMenuItem("End", null, KeyStroke.getKeyStroke(KeyEvent.VK_X, Event.ALT_MASK), mFile, this);
AEnv.addMenuItem("Logout", null, KeyStroke.getKeyStroke(KeyEvent.VK_L, Event.SHIFT_MASK+Event.ALT_MASK), mFile, this);
AEnv.addMenuItem("Exit", null, KeyStroke.getKeyStroke(KeyEvent.VK_X, Event.SHIFT_MASK+Event.ALT_MASK), mFile, this);
// View