- Timestamp:
- 08/23/07 22:15:34 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
bbtracker/trunk/src/org/bbtracker/mobile/gui/AboutForm.java
r61 r88 27 27 28 28 public class AboutForm extends Form implements CommandListener { 29 private final Command backCommand; 30 31 private final Command activeDebugCommand; 32 33 private final Command deactiveDebugCommand; 34 29 35 public AboutForm() { 30 36 super("About " + BBTracker.getName()); … … 33 39 "bbTracker is released under the GNU General Public License v2. See http://www.gnu.org/licenses/.")); 34 40 append("Icons have been taken (and sometimes modified) from the Tango Project (http://tango-project.org/) and the Human Icon Theme (Copyright 2004-2006 Canonical Ltd.). Both projects release their icons under the Creative Commons Attribution-ShareAlike 2.5 license. Any modifications I did on those icons are released under the same license."); 35 addCommand(new Command("Back", Command.BACK, 0)); 41 backCommand = new Command("Back", Command.BACK, 0); 42 activeDebugCommand = new Command("Activate Debug Log", Command.SCREEN, 1); 43 deactiveDebugCommand = new Command("Deactivate Debug Log", Command.SCREEN, 1); 44 addCommand(backCommand); 45 updateDebugCommands(); 36 46 setCommandListener(this); 37 47 } 38 48 49 private void updateDebugCommands() { 50 removeCommand(activeDebugCommand); 51 removeCommand(deactiveDebugCommand); 52 addCommand(BBTracker.isLogActive() ? deactiveDebugCommand : activeDebugCommand); 53 } 54 39 55 public void commandAction(final Command command, final Displayable source) { 40 BBTracker.getInstance().showMainCanvas(); 56 if (command == backCommand) { 57 BBTracker.getInstance().showMainCanvas(); 58 } else if (command == deactiveDebugCommand) { 59 BBTracker.setLogActive(false); 60 updateDebugCommands(); 61 } else if (command == activeDebugCommand) { 62 BBTracker.setLogActive(true); 63 updateDebugCommands(); 64 } 41 65 } 42 66
Note: See TracChangeset
for help on using the changeset viewer.