Changeset 3615
- Timestamp:
- 03/11/07 19:03:41 (2 years ago)
- Files:
-
- trunk/Controllers/MVApplicationController.m (modified) (1 diff)
- trunk/Models/JVEmoticonSet.m (modified) (1 diff)
- trunk/Models/JVStyle.m (modified) (3 diffs)
- trunk/Preferences/JVAppearancePreferences.m (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/Controllers/MVApplicationController.m
r3459 r3615 67 67 if( _hidEntry ) { 68 68 IOObjectRelease( _hidEntry ); 69 _hidEntry = nil;69 _hidEntry = 0; 70 70 } 71 71 trunk/Models/JVEmoticonSet.m
r3418 r3615 246 246 NSString *contents = nil; 247 247 if( floor( NSAppKitVersionNumber ) <= NSAppKitVersionNumber10_3 ) // test for 10.3 248 contents = [NSString stringWithContentsOfURL:[self styleSheetLocation]];248 contents = [NSString performSelector:@selector( stringWithContentsOfURL: ) withObject:[self styleSheetLocation]]; 249 249 else contents = [NSString stringWithContentsOfURL:[self styleSheetLocation] encoding:NSUTF8StringEncoding error:NULL]; 250 250 return ( contents ? contents : @"" ); trunk/Models/JVStyle.m
r3418 r3615 495 495 NSString *contents = nil; 496 496 if( floor( NSAppKitVersionNumber ) <= NSAppKitVersionNumber10_3 ) // test for 10.3 497 contents = [NSString stringWithContentsOfURL:[self mainStyleSheetLocation]];497 contents = [NSString performSelector:@selector( stringWithContentsOfURL: ) withObject:[self mainStyleSheetLocation]]; 498 498 else contents = [NSString stringWithContentsOfURL:[self mainStyleSheetLocation] encoding:NSUTF8StringEncoding error:NULL]; 499 499 return ( contents ? contents : @"" ); … … 503 503 NSString *contents = nil; 504 504 if( floor( NSAppKitVersionNumber ) <= NSAppKitVersionNumber10_3 ) // test for 10.3 505 contents = [NSString stringWithContentsOfURL:[self variantStyleSheetLocationWithName:name]];505 contents = [NSString performSelector:@selector( stringWithContentsOfURL: ) withObject:[self variantStyleSheetLocationWithName:name]]; 506 506 else contents = [NSString stringWithContentsOfURL:[self variantStyleSheetLocationWithName:name] encoding:NSUTF8StringEncoding error:NULL]; 507 507 return ( contents ? contents : @"" ); … … 514 514 NSString *contents = nil; 515 515 if( floor( NSAppKitVersionNumber ) <= NSAppKitVersionNumber10_3 ) // test for 10.3 516 contents = [NSString stringWithContentsOfURL:url];516 contents = [NSString performSelector:@selector( stringWithContentsOfURL: ) withObject:url]; 517 517 else contents = [NSString stringWithContentsOfURL:url encoding:NSUTF8StringEncoding error:NULL]; 518 518 trunk/Preferences/JVAppearancePreferences.m
r3471 r3615 7 7 #import "JVDetailCell.h" 8 8 #import "NSBundleAdditions.h" 9 10 #import <objc/objc-runtime.h> 9 11 10 12 @interface WebView (WebViewPrivate) // WebKit 1.3 pending public API … … 561 563 - (void) saveStyleOptions { 562 564 if( _variantLocked ) return; 563 [_userStyle writeToURL:[_style variantStyleSheetLocationWithName:[_style defaultVariantName]] atomically:YES]; 565 566 if( floor( NSAppKitVersionNumber ) <= NSAppKitVersionNumber10_3 ) // test for 10.3 567 ((void(*)(id, SEL, id, BOOL))objc_msgSend)( _userStyle, @selector( writeToURL: ), [_style variantStyleSheetLocationWithName:[_style defaultVariantName]], YES ); 568 else [_userStyle writeToURL:[_style variantStyleSheetLocationWithName:[_style defaultVariantName]] atomically:YES encoding:NSUTF8StringEncoding error:NULL]; 564 569 565 570 NSDictionary *info = [NSDictionary dictionaryWithObjectsAndKeys:[_style defaultVariantName], @"variant", nil]; … … 759 764 760 765 NSString *path = [[NSString stringWithFormat:@"~/Library/Application Support/Colloquy/Styles/Variants/%@/%@.css", [_style identifier], name] stringByExpandingTildeInPath]; 761 [_userStyle writeToFile:path atomically:YES]; 766 767 if( floor( NSAppKitVersionNumber ) <= NSAppKitVersionNumber10_3 ) // test for 10.3 768 ((void(*)(id, SEL, id, BOOL))objc_msgSend)( _userStyle, @selector( writeToFile: ), path, YES ); 769 else [_userStyle writeToFile:path atomically:YES encoding:NSUTF8StringEncoding error:NULL]; 762 770 763 771 [_style setDefaultVariantName:name];
