diff --git a/Classes/FanControl.m b/Classes/FanControl.m index b051425..29ff0fb 100755 --- a/Classes/FanControl.m +++ b/Classes/FanControl.m @@ -228,6 +228,9 @@ NSUserDefaults *defaults; if (numLaunches != 0 && (numLaunches % 5 == 0) && ![[[NSUserDefaults standardUserDefaults] objectForKey:@"DonationMessageShown"] boolValue]) { [self displayDonationMessage]; } + + [[NSDistributedNotificationCenter defaultCenter] addObserver:self selector:@selector(readFanData:) name:@"AppleInterfaceThemeChangedNotification" object:nil]; + } -(void)displayDonationMessage @@ -415,6 +418,14 @@ NSUserDefaults *defaults; if (!([[menuColor colorUsingColorSpaceName: NSCalibratedWhiteColorSpace] whiteComponent] == 0.0) || ![statusItem respondsToSelector:@selector(button)]) setColor = YES; + + NSString *osxMode = [[NSUserDefaults standardUserDefaults] stringForKey:@"AppleInterfaceStyle"]; + + if (osxMode && !setColor) { + menuColor = [NSColor whiteColor]; + setColor = YES; + } + switch (menuBarSetting) { default: case 1: { @@ -438,6 +449,7 @@ NSUserDefaults *defaults; if (setColor) [s_status addAttribute:NSForegroundColorAttributeName value:menuColor range:NSMakeRange(0,[s_status length])]; + if ([statusItem respondsToSelector:@selector(button)]) { [statusItem.button setAttributedTitle:s_status]; [statusItem.button setImage:nil]; @@ -873,6 +885,11 @@ NSUserDefaults *defaults; } +-(void)dealloc +{ + [[NSDistributedNotificationCenter defaultCenter] removeObserver:self]; +} + @end diff --git a/Info.plist b/Info.plist index a35707e..aa7ba50 100644 --- a/Info.plist +++ b/Info.plist @@ -11,7 +11,7 @@ CFBundleIconFile smcfancontrol_v2 CFBundleIdentifier - com.eidac.smcFanControl2 + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName diff --git a/Ressources/French.lproj/Localizable.strings b/Ressources/French.lproj/Localizable.strings index 7006954..eaa0c46 100644 Binary files a/Ressources/French.lproj/Localizable.strings and b/Ressources/French.lproj/Localizable.strings differ diff --git a/smcFanControl.xcodeproj/project.pbxproj b/smcFanControl.xcodeproj/project.pbxproj index fd612a8..ecc7848 100644 --- a/smcFanControl.xcodeproj/project.pbxproj +++ b/smcFanControl.xcodeproj/project.pbxproj @@ -75,7 +75,7 @@ 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 29B97324FDCFA39411CA2CEA /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; }; 29B97325FDCFA39411CA2CEA /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; }; - 4C65C0201AC83BED006E760F /* French */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = French; path = French.lproj/Localizable.strings; sourceTree = ""; }; + 4C65C0201AC83BED006E760F /* French */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = French; path = French.lproj/Localizable.strings; sourceTree = ""; }; 4C65C0211AC83BF2006E760F /* French */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = French; path = French.lproj/MainMenu.nib; sourceTree = ""; }; 4C65C0221AC83BF7006E760F /* French */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = French; path = French.lproj/F.A.Q.rtf; sourceTree = ""; }; 89033CA10B80E1DF00FDAF43 /* English */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = English; path = English.lproj/F.A.Q.rtf; sourceTree = ""; }; @@ -303,10 +303,15 @@ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0610; + LastUpgradeCheck = 0800; TargetAttributes = { 8924ECED15AC96E70031730C = { - DevelopmentTeam = MC98392EJC; + DevelopmentTeam = H4G85G26BP; + ProvisioningStyle = Manual; + }; + 8D1107260486CEB800E47090 = { + DevelopmentTeam = H4G85G26BP; + ProvisioningStyle = Manual; }; }; }; @@ -435,9 +440,10 @@ ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - CODE_SIGN_IDENTITY = ""; - "CODE_SIGN_IDENTITY[sdk=macosx*]" = ""; + CODE_SIGN_IDENTITY = "Developer ID Application"; + "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Developer ID Application"; COPY_PHASE_STRIP = NO; + DEVELOPMENT_TEAM = H4G85G26BP; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; GCC_ENABLE_OBJC_EXCEPTIONS = YES; @@ -462,10 +468,11 @@ ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - CODE_SIGN_IDENTITY = ""; - "CODE_SIGN_IDENTITY[sdk=macosx*]" = ""; + CODE_SIGN_IDENTITY = "Developer ID Application"; + "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Developer ID Application"; COPY_PHASE_STRIP = YES; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = H4G85G26BP; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_ENABLE_OBJC_EXCEPTIONS = YES; GCC_PREPROCESSOR_DEFINITIONS = CMD_TOOL_BUILD; @@ -483,11 +490,11 @@ C01FCF4B08A954540054247B /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD)"; CLANG_ENABLE_OBJC_ARC = YES; - CODE_SIGN_IDENTITY = "Developer ID Application: Hendrik Holtmann"; + CODE_SIGN_IDENTITY = "Developer ID Application"; COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = NO; + DEVELOPMENT_TEAM = H4G85G26BP; FRAMEWORK_SEARCH_PATHS = ( ".//**", "$(inherited)", @@ -510,6 +517,7 @@ MACOSX_DEPLOYMENT_TARGET = 10.7; ONLY_ACTIVE_ARCH = NO; OTHER_CODE_SIGN_FLAGS = "--deep"; + PRODUCT_BUNDLE_IDENTIFIER = com.eidac.smcFanControl2; PRODUCT_NAME = smcFanControl; PROVISIONING_PROFILE = ""; SDKROOT = macosx; @@ -521,10 +529,10 @@ C01FCF4C08A954540054247B /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD)"; CLANG_ENABLE_OBJC_ARC = YES; - CODE_SIGN_IDENTITY = "Developer ID Application: Hendrik Holtmann"; + CODE_SIGN_IDENTITY = "Developer ID Application"; COMBINE_HIDPI_IMAGES = YES; + DEVELOPMENT_TEAM = H4G85G26BP; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", @@ -547,6 +555,7 @@ MACOSX_DEPLOYMENT_TARGET = 10.7; ONLY_ACTIVE_ARCH = NO; OTHER_CODE_SIGN_FLAGS = "--deep"; + PRODUCT_BUNDLE_IDENTIFIER = com.eidac.smcFanControl2; PRODUCT_NAME = smcFanControl; PROVISIONING_PROFILE = ""; SDKROOT = macosx; @@ -558,7 +567,9 @@ C01FCF4F08A954540054247B /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { + CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CODE_SIGN_IDENTITY = "Developer ID Application: Hendrik Holtmann"; + ENABLE_TESTABILITY = YES; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; @@ -574,6 +585,7 @@ C01FCF5008A954540054247B /* Release */ = { isa = XCBuildConfiguration; buildSettings = { + CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CODE_SIGN_IDENTITY = "Developer ID Application: Hendrik Holtmann"; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_RETURN_TYPE = YES; diff --git a/smcFanControl.xcodeproj/project.xcworkspace/xcuserdata/hendrikh.xcuserdatad/UserInterfaceState.xcuserstate b/smcFanControl.xcodeproj/project.xcworkspace/xcuserdata/hendrikh.xcuserdatad/UserInterfaceState.xcuserstate index 8c32c6c..e62635f 100644 Binary files a/smcFanControl.xcodeproj/project.xcworkspace/xcuserdata/hendrikh.xcuserdatad/UserInterfaceState.xcuserstate and b/smcFanControl.xcodeproj/project.xcworkspace/xcuserdata/hendrikh.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist index d64e322..f551a32 100644 --- a/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist +++ b/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -21,5 +21,21 @@ + + + + diff --git a/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcschemes/smcFanControl.xcscheme b/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcschemes/smcFanControl.xcscheme index f9c7357..50c6def 100644 --- a/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcschemes/smcFanControl.xcscheme +++ b/smcFanControl.xcodeproj/xcuserdata/hendrikh.xcuserdatad/xcschemes/smcFanControl.xcscheme @@ -1,6 +1,6 @@