Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Consolidate ArgumentCodersMac and ArgumentCodersCocoa.
https://bugs.webkit.org/show_bug.cgi?id=195636 rdar://problem/45055697 Reviewed by Ryosuke Niwa. Source/WebCore: * editing/DictionaryPopupInfo.h: (WebCore::DictionaryPopupInfo::encodingRequiresPlatformData const): Added. * editing/FontAttributes.h: (WebCore::FontAttributes::encodingRequiresPlatformData const): Added. Source/WebKit: Merge the two similar encoders and decoders. This avoids issues where one encoder could be used and the other decoder, which caused a crash. It also stops handling NSAttributedString specifically and just uses the NSSecureCoding path to handle more complex attributes. Some WebCore encoders code needed to move to platform files, since ArgumentCodersCocoa.h requires an ObjectiveC++ implementation to work. * Shared/Cocoa/ArgumentCodersCocoa.h: (IPC::encode): (IPC::decode): (IPC::ArgumentCoder<RetainPtr<T>>::encode): (IPC::ArgumentCoder<RetainPtr<T>>::decode): * Shared/Cocoa/ArgumentCodersCocoa.mm: (IPC::typeFromObject): (IPC::isSerializableFont): (IPC::isSerializableValue): (IPC::encodeObject): (IPC::decodeObject): * Shared/Cocoa/LoadParametersCocoa.mm: * Shared/Cocoa/WebCoreArgumentCodersCocoa.mm: (IPC::ArgumentCoder<WebCore::DictionaryPopupInfo>::encodePlatformData): (IPC::ArgumentCoder<WebCore::DictionaryPopupInfo>::decodePlatformData): (IPC::ArgumentCoder<WebCore::FontAttributes>::encodePlatformData): (IPC::ArgumentCoder<WebCore::FontAttributes>::decodePlatformData): * Shared/WebCoreArgumentCoders.cpp: (IPC::ArgumentCoder<DictionaryPopupInfo>::encode): (IPC::ArgumentCoder<DictionaryPopupInfo>::decode): (IPC::ArgumentCoder<FontAttributes>::encode): (IPC::ArgumentCoder<FontAttributes>::decode): * Shared/WebCoreArgumentCoders.h: * Shared/mac/ArgumentCodersMac.h: Removed. * Shared/mac/ArgumentCodersMac.mm: Removed. * Shared/mac/AttributedString.mm: (WebKit::AttributedString::encode const): * Shared/mac/ObjCObjectGraph.mm: * SourcesCocoa.txt: * WebKit.xcodeproj/project.pbxproj: Canonical link: https://commits.webkit.org/209999@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242908 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
18 changed files
with
640 additions
and
779 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.