Revision: 6653
http://skim-app.svn.sourceforge.net/skim-app/?rev=6653&view=rev
Author: hofman
Date: 2010-07-26 11:00:41 +0000 (Mon, 26 Jul 2010)
Log Message:
-----------
use switch statement
Modified Paths:
--------------
trunk/SKApplication.m
Modified: trunk/SKApplication.m
===================================================================
--- trunk/SKApplication.m 2010-07-26 10:02:24 UTC (rev 6652)
+++ trunk/SKApplication.m 2010-07-26 11:00:41 UTC (rev 6653)
@@ -88,17 +88,22 @@
}
- (void)updatePresentationOptions {
- SystemUIMode currentMode, mode = kUIModeNormal;
- SystemUIOptions currentOptions, options = 0;
+ SystemUIMode currentMode, mode;
+ SystemUIOptions currentOptions, options;
GetSystemUIMode(¤tMode, ¤tOptions);
- NSDocument *doc = [[[self mainWindow] windowController] document];
- SKInteractionMode interactionMode = [doc systemInteractionMode];
- if (interactionMode == SKPresentationMode) {
- mode = kUIModeAllHidden;
- options = kUIOptionDisableProcessSwitch;
- } else if (interactionMode == SKFullScreenMode) {
- mode = kUIModeAllHidden;
- options = kUIOptionAutoShowMenuBar;
+ switch ([[[[self mainWindow] windowController] document]
systemInteractionMode]) {
+ case SKPresentationMode:
+ mode = kUIModeAllHidden;
+ options = kUIOptionDisableProcessSwitch;
+ break;
+ case SKFullScreenMode:
+ mode = kUIModeAllHidden;
+ options = kUIOptionAutoShowMenuBar;
+ break;
+ default:
+ mode = kUIModeNormal;
+ options = 0;
+ break;
}
if (mode != currentMode || options != currentOptions)
SetSystemUIMode(mode, options);
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://ad.doubleclick.net/clk;226879339;13503038;l?
http://clk.atdmt.com/CRS/go/247765532/direct/01/
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit