mirror of
https://github.com/MacPass/MacPass.git
synced 2025-12-14 12:52:21 +00:00
Added DDHotKeyTextField to settings to be able to customise global auto type hotkey. (still disabled for now)
49 lines
1.6 KiB
Objective-C
49 lines
1.6 KiB
Objective-C
//
|
|
// MPServerSettingsController.m
|
|
// MacPass
|
|
//
|
|
// Created by Michael Starke on 17.06.13.
|
|
// Copyright (c) 2013 HicknHack Software GmbH. All rights reserved.
|
|
//
|
|
|
|
#import "MPIntegrationSettingsController.h"
|
|
#import "MPSettingsHelper.h"
|
|
#import "MPIconHelper.h"
|
|
|
|
@interface MPIntegrationSettingsController ()
|
|
|
|
@end
|
|
|
|
@implementation MPIntegrationSettingsController
|
|
|
|
- (NSString *)identifier {
|
|
return @"Integration";
|
|
}
|
|
|
|
- (NSImage *)image {
|
|
return [NSImage imageNamed:NSImageNameComputer];
|
|
}
|
|
|
|
- (NSString *)label {
|
|
return NSLocalizedString(@"INTEGRATION_SETTINGS", "");
|
|
}
|
|
|
|
- (id)init {
|
|
self = [super initWithNibName:@"IntegrationSettings" bundle:nil];
|
|
return self;
|
|
}
|
|
|
|
- (void)awakeFromNib {
|
|
NSUserDefaultsController *defaultsController = [NSUserDefaultsController sharedUserDefaultsController];
|
|
NSString *serverKeyPath = [MPSettingsHelper defaultControllerPathForKey:kMPSettingsKeyEnableHttpServer];
|
|
NSString *globalAutotypeKeyPath = [MPSettingsHelper defaultControllerPathForKey:kMPSettingsKeyEnableGlobalAutotype];
|
|
NSString *quicklookKeyPath = [MPSettingsHelper defaultControllerPathForKey:kMPSettingsKeyEnableQuicklookPreview];
|
|
[self.enableServerCheckbutton bind:NSValueBinding toObject:defaultsController withKeyPath:serverKeyPath options:nil];
|
|
[self.enableServerCheckbutton setEnabled:NO];
|
|
[self.enableGlobalAutotypeCheckbutton bind:NSValueBinding toObject:defaultsController withKeyPath:globalAutotypeKeyPath options:nil];
|
|
[self.enableQuicklookCheckbutton bind:NSValueBinding toObject:defaultsController withKeyPath:quicklookKeyPath options:nil];
|
|
|
|
}
|
|
|
|
@end
|