Chameleon Applications

Chameleon Applications Svn Source Tree

Root/trunk/ChameleonPrefPane/Sources/BootFlagsController.mm

1//
2// BootFlagsController.mm
3// ChameleonPrefPane
4//
5// Created by Rekursor on 1/22/10.
6//
7
8#import "BootFlagsController.h"
9
10// Constants
11
12// File static variables
13static BootFlagsController *gInstance = NULL;
14
15
16@implementation BootFlagsController
17
18//--------------------------------------------------------------------------
19- (id) init
20{
21self = [super init];
22return (gInstance = self);
23}
24
25//--------------------------------------------------------------------------
26-(void) addOptionsDesc
27{
28prop->addOptionDesc(mVerbose, nil, OptionUnix, "-v", "");
29prop->addOptionDesc(mSafeBoot, nil, OptionUnix, "-x", "");
30prop->addOptionDesc(mIgnoreBootConfig, nil, OptionUnix, "-F", "");
31prop->addOptionDesc(mSingleUser, nil, OptionUnix, "-s", "");
32prop->addOptionDesc(mTimeOut, mTimeOutText, OptionString,"Timeout", "5");
33prop->addOptionDesc(mQuietBoot, nil, OptionYesNo, "Quiet Boot", "No");
34prop->addOptionDesc(mInstantMenu, nil, OptionYesNo, "Instant Menu", "No");
35prop->addOptionDesc(mWait, nil, OptionYesNo, "Wait", "No");
36prop->addOptionDesc(mRescan, nil, OptionYesNo, "Rescan", "No");
37prop->addOptionDesc(mRescanPrompt, nil, OptionYesNo, "Rescan Prompt", "No");
38prop->addOptionDesc(mRescanSingleDrive, nil, OptionYesNo, "Rescan SingleDrive", "No");
39}
40
41//--------------------------------------------------------------------------
42- (void) refreshLockStates
43{
44 [self refreshLockState: mVerbose];
45 [self refreshLockState: mSafeBoot];
46 [self refreshLockState: mIgnoreBootConfig];
47 [self refreshLockState: mTimeOut];
48 [self refreshLockState: mTimeOutText];
49 [self refreshLockState: mSingleUser];
50 [self refreshLockState: mQuietBoot];
51 [self refreshLockState: mInstantMenu];
52 [self refreshLockState: mWait];
53 [self refreshLockState: mRescan];
54 [self refreshLockState: mRescanPrompt];
55 [self refreshLockState: mRescanSingleDrive];
56}
57
58//--------------------------------------------------------------------------
59-(void) loadOptionsFromPreferencesFile: (NSMutableDictionary*) dict
60{
61
62}
63
64//--------------------------------------------------------------------------
65-(IBAction) onCheckButtonChange: (NSButton*) sender
66{
67[self handleSender: sender];
68}
69
70//--------------------------------------------------------------------------
71-(IBAction) onTextFiedChange: (NSTextField*) sender
72{
73[self handleSender: sender];
74}
75
76+ (BootFlagsController *)instance { return(gInstance);}
77
78@end
79

Archive Download this file

Revision: 48