Consolidate runtime application checks for Apple Mail and Safari
Reviewed by Mark Rowe and Darin Adler.
WebCore:
* WebCore.base.exp: Added exports.
* WebCore.xcodeproj/project.pbxproj: Added
RuntimeApplicationChecks.{h|mm} source files to the project.
* page/mac/EventHandlerMac.mm:
(WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
Removed local checkedSafari and isSafari variables and switched
to use applicationIsSafari().
* platform/mac/RuntimeApplicationChecks.h: Added.
* platform/mac/RuntimeApplicationChecks.mm: Added.
(WebCore::applicationIsAppleMail): Runtime application check for
Apple Mail.
(WebCore::applicationIsSafari): Runtime application check for
Safari.
WebKit:
* WebCoreSupport/WebContextMenuClient.mm:
(isAppleMail): Removed.
(fixMenusToSendToOldClients): Switched to use
applicationIsAppleMail().
* WebView/WebFrame.mm:
(-[WebFrame reload]): Switched to use applicationIsSafari().
* WebView/WebPDFView.mm:
(-[WebPDFView menuForEvent:]): Ditto.
* WebView/WebResource.mm:
(+[WebResource _needMailThreadWorkaroundIfCalledOffMainThread]):
Switched to use applicationIsAppleMail().
* WebView/WebView.mm:
(runningLeopardMail): Ditto.
(runningTigerMail): Ditto.
(-[WebView _needsKeyboardEventDisambiguationQuirks]): Switched
to use applicationIsSafari().
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@42909 268f45cc-cd09-0410-ab3c-d52691b4dbfc
12 files changed