diff --git a/AppKit/CPWebView.j b/AppKit/CPWebView.j index 2ec39a794..7efeee16e 100644 --- a/AppKit/CPWebView.j +++ b/AppKit/CPWebView.j @@ -883,7 +883,7 @@ CPWebViewAppKitScrollMaxPollCount = 3; #endif [self setBackgroundColor:[CPColor whiteColor]]; - [_updateEffectiveScrollMode]; + [self _updateEffectiveScrollMode]; } return self; diff --git a/AppKit/Platform/DOM/CPPlatformWindow+DOM.j b/AppKit/Platform/DOM/CPPlatformWindow+DOM.j index aa7d79c0f..5a2c4b4ec 100644 --- a/AppKit/Platform/DOM/CPPlatformWindow+DOM.j +++ b/AppKit/Platform/DOM/CPPlatformWindow+DOM.j @@ -483,7 +483,7 @@ var ModifierKeyCodes = [ _DOMBodyElement.ondrag = function () { return NO; }; _DOMBodyElement.onselectstart = function () { return _DOMWindow.event.srcElement === _DOMPasteboardElement; }; - _DOMWindow.attachEvent("onbeforeunload", function() + _DOMWindow.attachEvent("onunload", function() { [self updateFromNativeContentRect]; [self _removeLayers]; diff --git a/Tools/NativeHost/Jakefile b/Tools/NativeHost/Jakefile index aff3d15cd..a092ea137 100644 --- a/Tools/NativeHost/Jakefile +++ b/Tools/NativeHost/Jakefile @@ -9,17 +9,20 @@ task ("build", function() { if (executableExists("xcodebuild")) { - if (OS.popen("xcodebuild -version").stdout.read().match("Xcode 4.0")) - stream.print("\0red(Building NativeHost was skipped due to your Xcode 4.0 pre-release not including the Mac OS X 10.5 SDK.\0)"); + var args = "-alltargets -configuration Release"; + + if (FILE.exists(FILE.join("/", "Developer", "SDKs", "MacOSX10.5.sdk"))) + args = "-sdk macosx10.5 " + args; + else - { - if (OS.system("xcodebuild -alltargets -configuration Release")) - OS.exit(1); - - rm_rf(FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app")); - FILE.mkdirs(FILE.join($BUILD_CJS_CAPPUCCINO, "support")) - cp_r(FILE.join("build", "Release", "NativeHost.app"), FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app")); - } + args = "-sdk macosx " + args; + + if (OS.system("xcodebuild " + args)) + OS.exit(1); + + rm_rf(FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app")); + FILE.mkdirs(FILE.join($BUILD_CJS_CAPPUCCINO, "support")) + cp_r(FILE.join("build", "Release", "NativeHost.app"), FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app")); } else { diff --git a/Tools/NativeHost/NativeHost.xcodeproj/project.pbxproj b/Tools/NativeHost/NativeHost.xcodeproj/project.pbxproj index f7d2bbc37..f229afa22 100644 --- a/Tools/NativeHost/NativeHost.xcodeproj/project.pbxproj +++ b/Tools/NativeHost/NativeHost.xcodeproj/project.pbxproj @@ -254,7 +254,11 @@ isa = PBXProject; buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "NativeHost" */; compatibilityVersion = "Xcode 3.1"; + developmentRegion = English; hasScannedForEncodings = 1; + knownRegions = ( + en, + ); mainGroup = 29B97314FDCFA39411CA2CEA /* NativeHost */; projectDirPath = ""; projectRoot = ""; @@ -373,7 +377,7 @@ GCC_WARN_UNUSED_VARIABLE = YES; ONLY_ACTIVE_ARCH = YES; PREBINDING = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Debug; }; @@ -385,7 +389,7 @@ GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; PREBINDING = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Release; };