Java Reference
In-Depth Information
77. private class WindowCloseManager extends WindowAdapter{
78. public void windowClosing(WindowEvent evt){
79. exitApplication();
80. }
81. }
82.
83. private void addCommand(String message){
84. HistoryList.getInstance().addCommand((++historyCount) + message);
85. refreshDisplay("Add Command: " + message);
86. }
87.
88. private void undoCommand(){
89. Object result = HistoryList.getInstance().undoCommand();
90. historyCount--;
91. refreshDisplay("Undo Command: " + result);
92. }
93.
94. private void exitApplication(){
95. System.exit(0);
96. }
97. }
Search WWH ::




Custom Search