static CGColor Red_;
static CGColor White_;
+static NSString *Home_;
+static BOOL Sounds_Keyboard_;
+
const char *Firmware_ = NULL;
const char *Machine_ = NULL;
const char *SerialNumber_ = NULL;
CGSize keysize = [UIKeyboard defaultSize];
CGRect keyrect = {{0, [overlay_ bounds].size.height - keysize.height}, keysize};
keyboard_ = [[UIKeyboard alloc] initWithFrame:keyrect];
+ [[UIKeyboardImpl sharedInstance] setSoundsEnabled:(Sounds_Keyboard_ ? YES : NO)];
[self reloadData];
[book_ update];
}*/
int main(int argc, char *argv[]) {
+ NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+
bootstrap_ = argc > 1 && strcmp(argv[1], "--bootstrap") == 0;
+ Home_ = NSHomeDirectory();
+
+ {
+ NSString *plist = [Home_ stringByAppendingString:@"/Library/Preferences/com.apple.preferences.sounds.plist"];
+ if (NSDictionary *sounds = [NSDictionary dictionaryWithContentsOfFile:plist])
+ if (NSNumber *keyboard = [sounds objectForKey:@"keyboard"])
+ Sounds_Keyboard_ = [keyboard boolValue];
+ }
+
setuid(0);
setgid(0);
dealloc_ = dealloc->method_imp;
dealloc->method_imp = (IMP) &Dealloc_;*/
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
-
if (NSDictionary *sysver = [NSDictionary dictionaryWithContentsOfFile:@"/System/Library/CoreServices/SystemVersion.plist"]) {
if (NSString *prover = [sysver valueForKey:@"ProductVersion"]) {
Firmware_ = strdup([prover UTF8String]);