diff options
author | Ben Murdoch <benm@google.com> | 2011-06-02 12:07:03 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2011-06-10 10:47:21 +0100 |
commit | 2daae5fd11344eaa88a0d92b0f6d65f8d2255c00 (patch) | |
tree | e4964fbd1cb70599f7718ff03e50ea1dab33890b /Source/WebKit2/WebProcess/WebCoreSupport/mac | |
parent | 87bdf0060a247bfbe668342b87e0874182e0ffa9 (diff) | |
download | external_webkit-2daae5fd11344eaa88a0d92b0f6d65f8d2255c00.zip external_webkit-2daae5fd11344eaa88a0d92b0f6d65f8d2255c00.tar.gz external_webkit-2daae5fd11344eaa88a0d92b0f6d65f8d2255c00.tar.bz2 |
Merge WebKit at r84325: Initial merge by git.
Change-Id: Ic1a909300ecc0a13ddc6b4e784371d2ac6e3d59b
Diffstat (limited to 'Source/WebKit2/WebProcess/WebCoreSupport/mac')
6 files changed, 25 insertions, 23 deletions
diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm index 6aa83f8..84b7d50 100644 --- a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm +++ b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm @@ -80,9 +80,7 @@ void WebContextMenuClient::searchWithSpotlight() if (selectedString.isEmpty()) return; - NSString *convertedSelectedString = selectedString; - - [[NSWorkspace sharedWorkspace] showSearchResultsForQueryString:convertedSelectedString]; + m_page->send(Messages::WebPageProxy::SearchWithSpotlight(selectedString)); } } // namespace WebKit diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm index 75d92e2..b9806f4 100644 --- a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm +++ b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm @@ -152,7 +152,7 @@ void WebDragClient::declareAndWriteDragImage(NSPasteboard *pasteboard, DOMElemen RetainPtr<WKPasteboardFilePromiseOwner> filePromiseOwner(AdoptNS, [(WKPasteboardFilePromiseOwner *)[WKPasteboardFilePromiseOwner alloc] initWithSource:pasteboardOwner.get()]); m_page->setDragSource(filePromiseOwner.get()); - [pasteboard declareTypes:types.get() owner:pasteboardOwner.get()]; + [pasteboard declareTypes:types.get() owner:pasteboardOwner.leakRef()]; [pasteboard setPropertyList:[NSArray arrayWithObject:extension] forType:NSFilesPromisePboardType]; @@ -252,6 +252,7 @@ static CachedResourceClient* promisedDataClient() - (void)pasteboardChangedOwner:(NSPasteboard *)pasteboard { [self clearImage]; + CFRelease(self); // Balanced by the leakRef that WebDragClient::declareAndWriteDragImage does when making this pasteboard owner. } static bool matchesExtensionOrEquivalent(NSString *filename, NSString *extension) diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm index 7a95a72..17fd5fe 100644 --- a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm +++ b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm @@ -46,9 +46,6 @@ #import <WebCore/Page.h> #import <WebKit/WebResource.h> #import <WebKit/WebNSURLExtras.h> -#if !defined(BUILDING_ON_SNOW_LEOPARD) -#import <AppKit/NSTextChecker.h> -#endif using namespace WebCore; @@ -64,13 +61,13 @@ namespace WebKit { void WebEditorClient::handleKeyboardEvent(KeyboardEvent* event) { - if (m_page->interceptEditingKeyboardEvent(event, false)) + if (m_page->handleEditingKeyboardEvent(event, false)) event->setDefaultHandled(); } void WebEditorClient::handleInputMethodKeydown(KeyboardEvent* event) { - if (m_page->interceptEditingKeyboardEvent(event, true)) + if (m_page->handleEditingKeyboardEvent(event, true)) event->setDefaultHandled(); } @@ -176,8 +173,9 @@ void WebEditorClient::showSubstitutionsPanel(bool) bool WebEditorClient::substitutionsPanelIsShowing() { - notImplemented(); - return false; + bool isShowing; + m_page->sendSync(Messages::WebPageProxy::SubstitutionsPanelIsShowing(), Messages::WebPageProxy::SubstitutionsPanelIsShowing::Reply(isShowing)); + return isShowing; } void WebEditorClient::toggleSmartInsertDelete() @@ -240,7 +238,7 @@ void WebEditorClient::toggleAutomaticSpellingCorrection() notImplemented(); } -void WebEditorClient::checkTextOfParagraph(const UChar* text, int length, uint64_t checkingTypes, Vector<TextCheckingResult>& results) +void WebEditorClient::checkTextOfParagraph(const UChar* text, int length, WebCore::TextCheckingTypeMask checkingTypes, Vector<TextCheckingResult>& results) { // FIXME: It would be nice if we wouldn't have to copy the text here. m_page->sendSync(Messages::WebPageProxy::CheckTextOfParagraph(String(text, length), checkingTypes), Messages::WebPageProxy::CheckTextOfParagraph::Reply(results)); diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm index 70e7607..3ae02a9 100644 --- a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm +++ b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebErrorsMac.mm @@ -43,17 +43,17 @@ static NSString * const WebKitErrorPlugInNameKey = @"WebKitErrorPlug static NSString * const WebKitErrorPlugInPageURLStringKey = @"WebKitErrorPlugInPageURLStringKey"; // Policy errors -#define WebKitErrorDescriptionCannotShowMIMEType UI_STRING("Content with specified MIME type can’t be shown", "WebKitErrorCannotShowMIMEType description") -#define WebKitErrorDescriptionCannotShowURL UI_STRING("The URL can’t be shown", "WebKitErrorCannotShowURL description") -#define WebKitErrorDescriptionFrameLoadInterruptedByPolicyChange UI_STRING("Frame load interrupted", "WebKitErrorFrameLoadInterruptedByPolicyChange description") -#define WebKitErrorDescriptionCannotUseRestrictedPort UI_STRING("Not allowed to use restricted network port", "WebKitErrorCannotUseRestrictedPort description") +#define WebKitErrorDescriptionCannotShowMIMEType WEB_UI_STRING("Content with specified MIME type can’t be shown", "WebKitErrorCannotShowMIMEType description") +#define WebKitErrorDescriptionCannotShowURL WEB_UI_STRING("The URL can’t be shown", "WebKitErrorCannotShowURL description") +#define WebKitErrorDescriptionFrameLoadInterruptedByPolicyChange WEB_UI_STRING("Frame load interrupted", "WebKitErrorFrameLoadInterruptedByPolicyChange description") +#define WebKitErrorDescriptionCannotUseRestrictedPort WEB_UI_STRING("Not allowed to use restricted network port", "WebKitErrorCannotUseRestrictedPort description") // Plug-in and java errors -#define WebKitErrorDescriptionCannotFindPlugin UI_STRING("The plug-in can’t be found", "WebKitErrorCannotFindPlugin description") -#define WebKitErrorDescriptionCannotLoadPlugin UI_STRING("The plug-in can’t be loaded", "WebKitErrorCannotLoadPlugin description") -#define WebKitErrorDescriptionJavaUnavailable UI_STRING("Java is unavailable", "WebKitErrorJavaUnavailable description") -#define WebKitErrorDescriptionPlugInCancelledConnection UI_STRING("Plug-in cancelled", "WebKitErrorPlugInCancelledConnection description") -#define WebKitErrorDescriptionPlugInWillHandleLoad UI_STRING("Plug-in handled load", "WebKitErrorPlugInWillHandleLoad description") +#define WebKitErrorDescriptionCannotFindPlugin WEB_UI_STRING("The plug-in can’t be found", "WebKitErrorCannotFindPlugin description") +#define WebKitErrorDescriptionCannotLoadPlugin WEB_UI_STRING("The plug-in can’t be loaded", "WebKitErrorCannotLoadPlugin description") +#define WebKitErrorDescriptionJavaUnavailable WEB_UI_STRING("Java is unavailable", "WebKitErrorJavaUnavailable description") +#define WebKitErrorDescriptionPlugInCancelledConnection WEB_UI_STRING("Plug-in cancelled", "WebKitErrorPlugInCancelledConnection description") +#define WebKitErrorDescriptionPlugInWillHandleLoad WEB_UI_STRING("Plug-in handled load", "WebKitErrorPlugInWillHandleLoad description") static pthread_once_t registerErrorsControl = PTHREAD_ONCE_INIT; static void registerErrors(void); diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm index e36f438..b9bc48f 100644 --- a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm +++ b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010 Apple Inc. All rights reserved. + * Copyright (C) 2010, 2011 Apple Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -46,6 +46,7 @@ void WebPopupMenu::setUpPlatformData(const IntRect&, PlatformPopupMenuData& data return; data.fontInfo.fontAttributeDictionary = fontDescriptorAttributes; + data.shouldPopOver = m_popupClient->shouldPopOver(); } } // namespace WebKit diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm index 06faa2f..a4fbc09 100644 --- a/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm +++ b/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm @@ -65,7 +65,6 @@ void InitWebCoreSystemInterface(void) INIT(GetWheelEventDeltas); INIT(HitTestMediaUIPart); INIT(InitializeMaximumHTTPConnectionCountPerHost); - INIT(IsLatchingWheelEvent); INIT(MeasureMediaUIPart); INIT(MediaControllerThemeAvailable); INIT(PopupMenu); @@ -85,7 +84,9 @@ void InitWebCoreSystemInterface(void) INIT(SetCONNECTProxyForStream); INIT(SetCookieStoragePrivateBrowsingEnabled); INIT(SetDragImage); + INIT(SetHTTPPipeliningMaximumPriority); INIT(SetHTTPPipeliningPriority); + INIT(SetHTTPPipeliningMinimumFastLanePriority); INIT(SetNSURLConnectionDefersCallbacks); INIT(SetNSURLRequestShouldContentSniff); INIT(SetPatternBaseCTM); @@ -135,9 +136,12 @@ void InitWebCoreSystemInterface(void) INIT(WillEndLiveResize); INIT(ContentAreaDidShow); INIT(ContentAreaDidHide); + INIT(DidBeginScrollGesture); + INIT(DidEndScrollGesture); INIT(ScrollbarPainterUsesOverlayScrollers); #else INIT(GetHyphenationLocationBeforeIndex); + INIT(GetNSEventMomentumPhase); #endif INIT(GetAXTextMarkerTypeID); |