Changeset 204678 in webkit
- Timestamp:
- Aug 20, 2016 2:38:41 AM (8 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/CMakeLists.txt
r204676 r204678 221 221 Platform/IPC/Connection.cpp 222 222 Platform/IPC/DataReference.cpp 223 Platform/IPC/Decoder.cpp 223 224 Platform/IPC/Encoder.cpp 224 Platform/IPC/Decoder.cpp225 225 Platform/IPC/MessageReceiverMap.cpp 226 226 Platform/IPC/MessageSender.cpp -
trunk/Source/WebKit2/ChangeLog
r204677 r204678 1 2016-08-20 Javier Fernandez <jfernandez@igalia.com> 2 3 [GTK] Unreviewed GTK build fix since r204665 and 204668 4 https://bugs.webkit.org/show_bug.cgi?id=161020 5 6 * CMakeLists.txt: 7 * Platform/IPC/MessageRecorder.cpp: 8 (IPC::MessageRecorder::recordOutgoingMessage): 9 * Platform/IPC/unix/ConnectionUnix.cpp: 10 (IPC::Connection::processMessage): 11 (IPC::Connection::sendOutgoingMessage): 12 * Platform/unix/SharedMemoryUnix.cpp: 13 (WebKit::SharedMemory::Handle::encode): 14 (WebKit::SharedMemory::Handle::decode): 15 * PlatformGTK.cmake: 16 * Scripts/webkit/LegacyMessageReceiver-expected.cpp: 17 (Messages::WebPage::GetPluginProcessConnection::DelayedReply::DelayedReply): 18 (Messages::WebPage::TestMultipleAttributes::DelayedReply::DelayedReply): 19 (WebKit::WebPage::didReceiveWebPageMessage): 20 (WebKit::WebPage::didReceiveSyncWebPageMessage): 21 * Scripts/webkit/LegacyMessages-expected.h: 22 * Scripts/webkit/MessageReceiver-expected.cpp: 23 (Messages::WebPage::GetPluginProcessConnection::DelayedReply::DelayedReply): 24 (Messages::WebPage::TestMultipleAttributes::DelayedReply::DelayedReply): 25 (WebKit::WebPage::didReceiveMessage): 26 (WebKit::WebPage::didReceiveSyncMessage): 27 * Scripts/webkit/Messages-expected.h: 28 * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp: 29 (IPC::ArgumentCoder<WebCore::FilterOperations>::encode): 30 (IPC::ArgumentCoder<WebCore::FilterOperations>::decode): 31 (IPC::ArgumentCoder<TransformOperations>::encode): 32 (IPC::ArgumentCoder<TransformOperations>::decode): 33 (IPC::encodeTimingFunction): 34 (IPC::decodeTimingFunction): 35 (IPC::ArgumentCoder<TextureMapperAnimation>::encode): 36 (IPC::ArgumentCoder<TextureMapperAnimation>::decode): 37 (IPC::ArgumentCoder<TextureMapperAnimations>::encode): 38 (IPC::ArgumentCoder<TextureMapperAnimations>::decode): 39 (IPC::ArgumentCoder<WebCore::GraphicsSurfaceToken>::encode): 40 (IPC::ArgumentCoder<WebCore::GraphicsSurfaceToken>::decode): 41 (IPC::ArgumentCoder<SurfaceUpdateInfo>::encode): 42 (IPC::ArgumentCoder<SurfaceUpdateInfo>::decode): 43 (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::encode): 44 (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::decode): 45 (IPC::ArgumentCoder<TileUpdateInfo>::encode): 46 (IPC::ArgumentCoder<TileUpdateInfo>::decode): 47 (IPC::ArgumentCoder<TileCreationInfo>::encode): 48 (IPC::ArgumentCoder<TileCreationInfo>::decode): 49 (IPC::encodeCoordinatedSurface): 50 (IPC::decodeCoordinatedSurface): 51 (IPC::ArgumentCoder<CoordinatedGraphicsState>::encode): 52 (IPC::ArgumentCoder<CoordinatedGraphicsState>::decode): 53 * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.h: 54 * Shared/CoordinatedGraphics/WebCoordinatedSurface.cpp: 55 (WebKit::WebCoordinatedSurface::Handle::encode): 56 (WebKit::WebCoordinatedSurface::Handle::decode): 57 * Shared/CoordinatedGraphics/WebCoordinatedSurface.h: 58 * Shared/WebBatteryStatus.cpp: 59 (WebKit::WebBatteryStatus::Data::encode): 60 (WebKit::WebBatteryStatus::Data::decode): 61 * Shared/WebBatteryStatus.h: 62 * Shared/gtk/ArgumentCodersGtk.cpp: 63 (IPC::encodeImage): 64 (IPC::decodeImage): 65 (IPC::encodeDataObject): 66 (IPC::decodeDataObject): 67 (IPC::ArgumentCoder<DragData>::encode): 68 (IPC::ArgumentCoder<DragData>::decode): 69 (IPC::encodeGKeyFile): 70 (IPC::decodeGKeyFile): 71 (IPC::encode): 72 (IPC::decode): 73 * Shared/gtk/ArgumentCodersGtk.h: 74 * Shared/soup/WebCoreArgumentCodersSoup.cpp: 75 (IPC::ArgumentCoder<ResourceRequest>::encodePlatformData): 76 (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData): 77 (IPC::ArgumentCoder<CertificateInfo>::encode): 78 (IPC::ArgumentCoder<CertificateInfo>::decode): 79 (IPC::ArgumentCoder<ResourceError>::encodePlatformData): 80 (IPC::ArgumentCoder<ResourceError>::decodePlatformData): 81 (IPC::ArgumentCoder<ProtectionSpace>::encodePlatformData): 82 (IPC::ArgumentCoder<ProtectionSpace>::decodePlatformData): 83 (IPC::ArgumentCoder<Credential>::encodePlatformData): 84 (IPC::ArgumentCoder<Credential>::decodePlatformData): 85 * UIProcess/LegacySessionStateCodingNone.cpp: 86 (WebKit::encodeLegacySessionState): 87 (WebKit::decodeLegacySessionState): 88 * UIProcess/WebBatteryManagerProxy.h: 89 1 90 2016-08-20 Yusuke Suzuki <utatane.tea@gmail.com> 2 91 -
trunk/Source/WebKit2/Platform/IPC/MessageRecorder.cpp
r204668 r204678 30 30 31 31 #include "Connection.h" 32 #include " MessageDecoder.h"33 #include " MessageEncoder.h"32 #include "Decoder.h" 33 #include "Encoder.h" 34 34 #include "MessageRecorderProbes.h" 35 35 #include <wtf/CurrentTime.h> … … 42 42 } 43 43 44 std::unique_ptr<MessageRecorder::MessageProcessingToken> MessageRecorder::recordOutgoingMessage(Connection& connection, MessageEncoder& encoder)44 std::unique_ptr<MessageRecorder::MessageProcessingToken> MessageRecorder::recordOutgoingMessage(Connection& connection, Encoder& encoder) 45 45 { 46 46 if (!isEnabled() || !connection.isValid()) -
trunk/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp
r203155 r204678 246 246 messageBody = reinterpret_cast<uint8_t*>(oolMessageBody->data()); 247 247 248 auto decoder = std::make_unique< MessageDecoder>(DataReference(messageBody, messageInfo.bodySize()), WTFMove(attachments));248 auto decoder = std::make_unique<Decoder>(DataReference(messageBody, messageInfo.bodySize()), WTFMove(attachments)); 249 249 250 250 processIncomingMessage(WTFMove(decoder)); … … 403 403 } 404 404 405 bool Connection::sendOutgoingMessage(std::unique_ptr< MessageEncoder> encoder)405 bool Connection::sendOutgoingMessage(std::unique_ptr<Encoder> encoder) 406 406 { 407 407 COMPILE_ASSERT(sizeof(MessageInfo) + attachmentMaxAmount * sizeof(size_t) <= messageMaxSize, AttachmentsFitToMessageInline); -
trunk/Source/WebKit2/Platform/unix/SharedMemoryUnix.cpp
r203954 r204678 30 30 #include "SharedMemory.h" 31 31 32 #include " ArgumentDecoder.h"33 #include " ArgumentEncoder.h"32 #include "Decoder.h" 33 #include "Encoder.h" 34 34 #include <errno.h> 35 35 #include <fcntl.h> … … 65 65 } 66 66 67 void SharedMemory::Handle::encode(IPC:: ArgumentEncoder& encoder) const67 void SharedMemory::Handle::encode(IPC::Encoder& encoder) const 68 68 { 69 69 encoder << releaseAttachment(); 70 70 } 71 71 72 bool SharedMemory::Handle::decode(IPC:: ArgumentDecoder& decoder, Handle& handle)72 bool SharedMemory::Handle::decode(IPC::Decoder& decoder, Handle& handle) 73 73 { 74 74 ASSERT_ARG(handle, handle.isNull()); -
trunk/Source/WebKit2/Scripts/webkit/LegacyMessageReceiver-expected.cpp
r194496 r204678 38 38 #include "MachPort.h" 39 39 #endif 40 #include " MessageDecoder.h"40 #include "Decoder.h" 41 41 #include "Plugin.h" 42 42 #include "WebCoreArgumentCoders.h" … … 60 60 namespace WebPage { 61 61 62 GetPluginProcessConnection::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC:: MessageEncoder> encoder)62 GetPluginProcessConnection::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC::Encoder> encoder) 63 63 : m_connection(connection) 64 64 , m_encoder(WTFMove(encoder)) … … 80 80 } 81 81 82 TestMultipleAttributes::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC:: MessageEncoder> encoder)82 TestMultipleAttributes::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC::Encoder> encoder) 83 83 : m_connection(connection) 84 84 , m_encoder(WTFMove(encoder)) … … 105 105 namespace WebKit { 106 106 107 void WebPage::didReceiveWebPageMessage(IPC::Connection*, IPC:: MessageDecoder& decoder)107 void WebPage::didReceiveWebPageMessage(IPC::Connection*, IPC::Decoder& decoder) 108 108 { 109 109 if (decoder.messageName() == Messages::WebPage::LoadURL::name()) { … … 189 189 } 190 190 191 void WebPage::didReceiveSyncWebPageMessage(IPC::Connection* connection, IPC:: MessageDecoder& decoder, std::unique_ptr<IPC::MessageEncoder>& replyEncoder)191 void WebPage::didReceiveSyncWebPageMessage(IPC::Connection* connection, IPC::Decoder& decoder, std::unique_ptr<IPC::Encoder>& replyEncoder) 192 192 { 193 193 if (decoder.messageName() == Messages::WebPage::CreatePlugin::name()) { -
trunk/Source/WebKit2/Scripts/webkit/LegacyMessages-expected.h
r180441 r204678 30 30 #include "Arguments.h" 31 31 #include "Connection.h" 32 #include " MessageEncoder.h"32 #include "Encoder.h" 33 33 #include "Plugin.h" 34 34 #include "StringReference.h" … … 366 366 367 367 struct DelayedReply : public ThreadSafeRefCounted<DelayedReply> { 368 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC:: MessageEncoder>);368 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC::Encoder>); 369 369 ~DelayedReply(); 370 370 … … 373 373 private: 374 374 RefPtr<IPC::Connection> m_connection; 375 std::unique_ptr<IPC:: MessageEncoder> m_encoder;375 std::unique_ptr<IPC::Encoder> m_encoder; 376 376 }; 377 377 … … 400 400 401 401 struct DelayedReply : public ThreadSafeRefCounted<DelayedReply> { 402 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC:: MessageEncoder>);402 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC::Encoder>); 403 403 ~DelayedReply(); 404 404 … … 407 407 private: 408 408 RefPtr<IPC::Connection> m_connection; 409 std::unique_ptr<IPC:: MessageEncoder> m_encoder;409 std::unique_ptr<IPC::Encoder> m_encoder; 410 410 }; 411 411 -
trunk/Source/WebKit2/Scripts/webkit/MessageReceiver-expected.cpp
r194496 r204678 38 38 #include "MachPort.h" 39 39 #endif 40 #include " MessageDecoder.h"40 #include "Decoder.h" 41 41 #include "Plugin.h" 42 42 #include "WebCoreArgumentCoders.h" … … 60 60 namespace WebPage { 61 61 62 GetPluginProcessConnection::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC:: MessageEncoder> encoder)62 GetPluginProcessConnection::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC::Encoder> encoder) 63 63 : m_connection(connection) 64 64 , m_encoder(WTFMove(encoder)) … … 80 80 } 81 81 82 TestMultipleAttributes::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC:: MessageEncoder> encoder)82 TestMultipleAttributes::DelayedReply::DelayedReply(PassRefPtr<IPC::Connection> connection, std::unique_ptr<IPC::Encoder> encoder) 83 83 : m_connection(connection) 84 84 , m_encoder(WTFMove(encoder)) … … 105 105 namespace WebKit { 106 106 107 void WebPage::didReceiveMessage(IPC::Connection* connection, IPC:: MessageDecoder& decoder)107 void WebPage::didReceiveMessage(IPC::Connection* connection, IPC::Decoder& decoder) 108 108 { 109 109 if (decoder.messageName() == Messages::WebPage::LoadURL::name()) { … … 190 190 } 191 191 192 void WebPage::didReceiveSyncMessage(IPC::Connection* connection, IPC:: MessageDecoder& decoder, std::unique_ptr<IPC::MessageEncoder>& replyEncoder)192 void WebPage::didReceiveSyncMessage(IPC::Connection* connection, IPC::Decoder& decoder, std::unique_ptr<IPC::Encoder>& replyEncoder) 193 193 { 194 194 if (decoder.messageName() == Messages::WebPage::CreatePlugin::name()) { -
trunk/Source/WebKit2/Scripts/webkit/Messages-expected.h
r180441 r204678 30 30 #include "Arguments.h" 31 31 #include "Connection.h" 32 #include " MessageEncoder.h"32 #include "Encoder.h" 33 33 #include "Plugin.h" 34 34 #include "StringReference.h" … … 366 366 367 367 struct DelayedReply : public ThreadSafeRefCounted<DelayedReply> { 368 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC:: MessageEncoder>);368 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC::Encoder>); 369 369 ~DelayedReply(); 370 370 … … 373 373 private: 374 374 RefPtr<IPC::Connection> m_connection; 375 std::unique_ptr<IPC:: MessageEncoder> m_encoder;375 std::unique_ptr<IPC::Encoder> m_encoder; 376 376 }; 377 377 … … 400 400 401 401 struct DelayedReply : public ThreadSafeRefCounted<DelayedReply> { 402 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC:: MessageEncoder>);402 DelayedReply(PassRefPtr<IPC::Connection>, std::unique_ptr<IPC::Encoder>); 403 403 ~DelayedReply(); 404 404 … … 407 407 private: 408 408 RefPtr<IPC::Connection> m_connection; 409 std::unique_ptr<IPC:: MessageEncoder> m_encoder;409 std::unique_ptr<IPC::Encoder> m_encoder; 410 410 }; 411 411 -
trunk/Source/WebKit2/Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp
r201759 r204678 61 61 namespace IPC { 62 62 63 void ArgumentCoder<WebCore::FilterOperations>::encode( ArgumentEncoder& encoder, const WebCore::FilterOperations& filters)63 void ArgumentCoder<WebCore::FilterOperations>::encode(Encoder& encoder, const WebCore::FilterOperations& filters) 64 64 { 65 65 encoder << static_cast<uint32_t>(filters.size()); … … 100 100 } 101 101 102 bool ArgumentCoder<WebCore::FilterOperations>::decode( ArgumentDecoder& decoder, WebCore::FilterOperations& filters)102 bool ArgumentCoder<WebCore::FilterOperations>::decode(Decoder& decoder, WebCore::FilterOperations& filters) 103 103 { 104 104 uint32_t size; … … 169 169 } 170 170 171 void ArgumentCoder<TransformOperations>::encode( ArgumentEncoder& encoder, const TransformOperations& transformOperations)171 void ArgumentCoder<TransformOperations>::encode(Encoder& encoder, const TransformOperations& transformOperations) 172 172 { 173 173 encoder << static_cast<uint32_t>(transformOperations.size()); … … 235 235 } 236 236 237 bool ArgumentCoder<TransformOperations>::decode( ArgumentDecoder& decoder, TransformOperations& transformOperations)237 bool ArgumentCoder<TransformOperations>::decode(Decoder& decoder, TransformOperations& transformOperations) 238 238 { 239 239 uint32_t operationsSize; … … 336 336 } 337 337 338 static void encodeTimingFunction( ArgumentEncoder& encoder, const TimingFunction* timingFunction)338 static void encodeTimingFunction(Encoder& encoder, const TimingFunction* timingFunction) 339 339 { 340 340 if (!timingFunction) { … … 377 377 } 378 378 379 bool decodeTimingFunction( ArgumentDecoder& decoder, RefPtr<TimingFunction>& timingFunction)379 bool decodeTimingFunction(Decoder& decoder, RefPtr<TimingFunction>& timingFunction) 380 380 { 381 381 TimingFunction::TimingFunctionType type; … … 444 444 } 445 445 446 void ArgumentCoder<TextureMapperAnimation>::encode( ArgumentEncoder& encoder, const TextureMapperAnimation& animation)446 void ArgumentCoder<TextureMapperAnimation>::encode(Encoder& encoder, const TextureMapperAnimation& animation) 447 447 { 448 448 encoder << animation.name(); … … 483 483 } 484 484 485 bool ArgumentCoder<TextureMapperAnimation>::decode( ArgumentDecoder& decoder, TextureMapperAnimation& animation)485 bool ArgumentCoder<TextureMapperAnimation>::decode(Decoder& decoder, TextureMapperAnimation& animation) 486 486 { 487 487 String name; … … 576 576 } 577 577 578 void ArgumentCoder<TextureMapperAnimations>::encode( ArgumentEncoder& encoder, const TextureMapperAnimations& animations)578 void ArgumentCoder<TextureMapperAnimations>::encode(Encoder& encoder, const TextureMapperAnimations& animations) 579 579 { 580 580 encoder << animations.animations(); 581 581 } 582 582 583 bool ArgumentCoder<TextureMapperAnimations>::decode( ArgumentDecoder& decoder, TextureMapperAnimations& animations)583 bool ArgumentCoder<TextureMapperAnimations>::decode(Decoder& decoder, TextureMapperAnimations& animations) 584 584 { 585 585 return decoder.decode(animations.animations()); … … 587 587 588 588 #if USE(GRAPHICS_SURFACE) 589 void ArgumentCoder<WebCore::GraphicsSurfaceToken>::encode( ArgumentEncoder& encoder, const WebCore::GraphicsSurfaceToken& token)589 void ArgumentCoder<WebCore::GraphicsSurfaceToken>::encode(Encoder& encoder, const WebCore::GraphicsSurfaceToken& token) 590 590 { 591 591 #if OS(DARWIN) … … 597 597 } 598 598 599 bool ArgumentCoder<WebCore::GraphicsSurfaceToken>::decode( ArgumentDecoder& decoder, WebCore::GraphicsSurfaceToken& token)599 bool ArgumentCoder<WebCore::GraphicsSurfaceToken>::decode(Decoder& decoder, WebCore::GraphicsSurfaceToken& token) 600 600 { 601 601 #if OS(DARWIN) … … 615 615 #endif 616 616 617 void ArgumentCoder<SurfaceUpdateInfo>::encode( ArgumentEncoder& encoder, const SurfaceUpdateInfo& surfaceUpdateInfo)617 void ArgumentCoder<SurfaceUpdateInfo>::encode(Encoder& encoder, const SurfaceUpdateInfo& surfaceUpdateInfo) 618 618 { 619 619 SimpleArgumentCoder<SurfaceUpdateInfo>::encode(encoder, surfaceUpdateInfo); 620 620 } 621 621 622 bool ArgumentCoder<SurfaceUpdateInfo>::decode( ArgumentDecoder& decoder, SurfaceUpdateInfo& surfaceUpdateInfo)622 bool ArgumentCoder<SurfaceUpdateInfo>::decode(Decoder& decoder, SurfaceUpdateInfo& surfaceUpdateInfo) 623 623 { 624 624 return SimpleArgumentCoder<SurfaceUpdateInfo>::decode(decoder, surfaceUpdateInfo); 625 625 } 626 626 627 void ArgumentCoder<CoordinatedGraphicsLayerState>::encode( ArgumentEncoder& encoder, const CoordinatedGraphicsLayerState& state)627 void ArgumentCoder<CoordinatedGraphicsLayerState>::encode(Encoder& encoder, const CoordinatedGraphicsLayerState& state) 628 628 { 629 629 encoder << state.changeMask; … … 706 706 } 707 707 708 bool ArgumentCoder<CoordinatedGraphicsLayerState>::decode( ArgumentDecoder& decoder, CoordinatedGraphicsLayerState& state)708 bool ArgumentCoder<CoordinatedGraphicsLayerState>::decode(Decoder& decoder, CoordinatedGraphicsLayerState& state) 709 709 { 710 710 if (!decoder.decode(state.changeMask)) … … 803 803 } 804 804 805 void ArgumentCoder<TileUpdateInfo>::encode( ArgumentEncoder& encoder, const TileUpdateInfo& updateInfo)805 void ArgumentCoder<TileUpdateInfo>::encode(Encoder& encoder, const TileUpdateInfo& updateInfo) 806 806 { 807 807 SimpleArgumentCoder<TileUpdateInfo>::encode(encoder, updateInfo); 808 808 } 809 809 810 bool ArgumentCoder<TileUpdateInfo>::decode( ArgumentDecoder& decoder, TileUpdateInfo& updateInfo)810 bool ArgumentCoder<TileUpdateInfo>::decode(Decoder& decoder, TileUpdateInfo& updateInfo) 811 811 { 812 812 return SimpleArgumentCoder<TileUpdateInfo>::decode(decoder, updateInfo); 813 813 } 814 814 815 void ArgumentCoder<TileCreationInfo>::encode( ArgumentEncoder& encoder, const TileCreationInfo& updateInfo)815 void ArgumentCoder<TileCreationInfo>::encode(Encoder& encoder, const TileCreationInfo& updateInfo) 816 816 { 817 817 SimpleArgumentCoder<TileCreationInfo>::encode(encoder, updateInfo); 818 818 } 819 819 820 bool ArgumentCoder<TileCreationInfo>::decode( ArgumentDecoder& decoder, TileCreationInfo& updateInfo)820 bool ArgumentCoder<TileCreationInfo>::decode(Decoder& decoder, TileCreationInfo& updateInfo) 821 821 { 822 822 return SimpleArgumentCoder<TileCreationInfo>::decode(decoder, updateInfo); 823 823 } 824 824 825 static void encodeCoordinatedSurface( ArgumentEncoder& encoder, const RefPtr<CoordinatedSurface>& surface)825 static void encodeCoordinatedSurface(Encoder& encoder, const RefPtr<CoordinatedSurface>& surface) 826 826 { 827 827 bool isValidSurface = false; … … 842 842 } 843 843 844 static bool decodeCoordinatedSurface( ArgumentDecoder& decoder, RefPtr<CoordinatedSurface>& surface)844 static bool decodeCoordinatedSurface(Decoder& decoder, RefPtr<CoordinatedSurface>& surface) 845 845 { 846 846 bool isValidSurface; … … 859 859 } 860 860 861 void ArgumentCoder<CoordinatedGraphicsState>::encode( ArgumentEncoder& encoder, const CoordinatedGraphicsState& state)861 void ArgumentCoder<CoordinatedGraphicsState>::encode(Encoder& encoder, const CoordinatedGraphicsState& state) 862 862 { 863 863 encoder << state.rootCompositingLayer; … … 890 890 } 891 891 892 bool ArgumentCoder<CoordinatedGraphicsState>::decode( ArgumentDecoder& decoder, CoordinatedGraphicsState& state)892 bool ArgumentCoder<CoordinatedGraphicsState>::decode(Decoder& decoder, CoordinatedGraphicsState& state) 893 893 { 894 894 if (!decoder.decode(state.rootCompositingLayer)) -
trunk/Source/WebKit2/Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.h
r178182 r204678 55 55 56 56 template<> struct ArgumentCoder<WebCore::FilterOperations> { 57 static void encode( ArgumentEncoder&, const WebCore::FilterOperations&);58 static bool decode( ArgumentDecoder&, WebCore::FilterOperations&);57 static void encode(Encoder&, const WebCore::FilterOperations&); 58 static bool decode(Decoder&, WebCore::FilterOperations&); 59 59 }; 60 60 61 61 template<> struct ArgumentCoder<WebCore::TransformOperations> { 62 static void encode( ArgumentEncoder&, const WebCore::TransformOperations&);63 static bool decode( ArgumentDecoder&, WebCore::TransformOperations&);62 static void encode(Encoder&, const WebCore::TransformOperations&); 63 static bool decode(Decoder&, WebCore::TransformOperations&); 64 64 }; 65 65 66 66 template<> struct ArgumentCoder<WebCore::TextureMapperAnimations> { 67 static void encode( ArgumentEncoder&, const WebCore::TextureMapperAnimations&);68 static bool decode( ArgumentDecoder&, WebCore::TextureMapperAnimations&);67 static void encode(Encoder&, const WebCore::TextureMapperAnimations&); 68 static bool decode(Decoder&, WebCore::TextureMapperAnimations&); 69 69 }; 70 70 71 71 template<> struct ArgumentCoder<WebCore::TextureMapperAnimation> { 72 static void encode( ArgumentEncoder&, const WebCore::TextureMapperAnimation&);73 static bool decode( ArgumentDecoder&, WebCore::TextureMapperAnimation&);72 static void encode(Encoder&, const WebCore::TextureMapperAnimation&); 73 static bool decode(Decoder&, WebCore::TextureMapperAnimation&); 74 74 }; 75 75 76 76 #if USE(GRAPHICS_SURFACE) 77 77 template<> struct ArgumentCoder<WebCore::GraphicsSurfaceToken> { 78 static void encode( ArgumentEncoder&, const WebCore::GraphicsSurfaceToken&);79 static bool decode( ArgumentDecoder&, WebCore::GraphicsSurfaceToken&);78 static void encode(Encoder&, const WebCore::GraphicsSurfaceToken&); 79 static bool decode(Decoder&, WebCore::GraphicsSurfaceToken&); 80 80 }; 81 81 #endif 82 82 83 83 template<> struct ArgumentCoder<WebCore::SurfaceUpdateInfo> { 84 static void encode( ArgumentEncoder&, const WebCore::SurfaceUpdateInfo&);85 static bool decode( ArgumentDecoder&, WebCore::SurfaceUpdateInfo&);84 static void encode(Encoder&, const WebCore::SurfaceUpdateInfo&); 85 static bool decode(Decoder&, WebCore::SurfaceUpdateInfo&); 86 86 }; 87 87 88 88 template<> struct ArgumentCoder<WebCore::CoordinatedGraphicsLayerState> { 89 static void encode( ArgumentEncoder&, const WebCore::CoordinatedGraphicsLayerState&);90 static bool decode( ArgumentDecoder&, WebCore::CoordinatedGraphicsLayerState&);89 static void encode(Encoder&, const WebCore::CoordinatedGraphicsLayerState&); 90 static bool decode(Decoder&, WebCore::CoordinatedGraphicsLayerState&); 91 91 }; 92 92 93 93 template<> struct ArgumentCoder<WebCore::TileUpdateInfo> { 94 static void encode( ArgumentEncoder&, const WebCore::TileUpdateInfo&);95 static bool decode( ArgumentDecoder&, WebCore::TileUpdateInfo&);94 static void encode(Encoder&, const WebCore::TileUpdateInfo&); 95 static bool decode(Decoder&, WebCore::TileUpdateInfo&); 96 96 }; 97 97 98 98 template<> struct ArgumentCoder<WebCore::TileCreationInfo> { 99 static void encode( ArgumentEncoder&, const WebCore::TileCreationInfo&);100 static bool decode( ArgumentDecoder&, WebCore::TileCreationInfo&);99 static void encode(Encoder&, const WebCore::TileCreationInfo&); 100 static bool decode(Decoder&, WebCore::TileCreationInfo&); 101 101 }; 102 102 103 103 template<> struct ArgumentCoder<WebCore::CoordinatedGraphicsState> { 104 static void encode( ArgumentEncoder&, const WebCore::CoordinatedGraphicsState&);105 static bool decode( ArgumentDecoder&, WebCore::CoordinatedGraphicsState&);104 static void encode(Encoder&, const WebCore::CoordinatedGraphicsState&); 105 static bool decode(Decoder&, WebCore::CoordinatedGraphicsState&); 106 106 }; 107 107 -
trunk/Source/WebKit2/Shared/CoordinatedGraphics/WebCoordinatedSurface.cpp
r202812 r204678 41 41 } 42 42 43 void WebCoordinatedSurface::Handle::encode(IPC:: ArgumentEncoder& encoder) const43 void WebCoordinatedSurface::Handle::encode(IPC::Encoder& encoder) const 44 44 { 45 45 encoder << m_size << m_flags; … … 52 52 } 53 53 54 bool WebCoordinatedSurface::Handle::decode(IPC:: ArgumentDecoder& decoder, Handle& handle)54 bool WebCoordinatedSurface::Handle::decode(IPC::Decoder& decoder, Handle& handle) 55 55 { 56 56 if (!decoder.decode(handle.m_size)) -
trunk/Source/WebKit2/Shared/CoordinatedGraphics/WebCoordinatedSurface.h
r202812 r204678 44 44 Handle(); 45 45 46 void encode(IPC:: ArgumentEncoder&) const;47 static bool decode(IPC:: ArgumentDecoder&, Handle&);46 void encode(IPC::Encoder&) const; 47 static bool decode(IPC::Decoder&, Handle&); 48 48 49 49 #if USE(GRAPHICS_SURFACE) -
trunk/Source/WebKit2/Shared/WebBatteryStatus.cpp
r161156 r204678 46 46 } 47 47 48 void WebBatteryStatus::Data::encode(IPC:: ArgumentEncoder& encoder) const48 void WebBatteryStatus::Data::encode(IPC::Encoder& encoder) const 49 49 { 50 50 encoder << isCharging; … … 54 54 } 55 55 56 bool WebBatteryStatus::Data::decode(IPC:: ArgumentDecoder& decoder, Data& result)56 bool WebBatteryStatus::Data::decode(IPC::Decoder& decoder, Data& result) 57 57 { 58 58 if (!decoder.decode(result.isCharging)) -
trunk/Source/WebKit2/Shared/WebBatteryStatus.h
r204466 r204678 30 30 31 31 #include "APIObject.h" 32 #include " ArgumentDecoder.h"33 #include " ArgumentEncoder.h"32 #include "Decoder.h" 33 #include "Encoder.h" 34 34 35 35 namespace WebKit { … … 38 38 public: 39 39 struct Data { 40 void encode(IPC:: ArgumentEncoder&) const;41 static bool decode(IPC:: ArgumentDecoder&, Data&);40 void encode(IPC::Encoder&) const; 41 static bool decode(IPC::Decoder&, Data&); 42 42 43 43 bool isCharging; -
trunk/Source/WebKit2/Shared/gtk/ArgumentCodersGtk.cpp
r202242 r204678 42 42 namespace IPC { 43 43 44 static void encodeImage( ArgumentEncoder& encoder, const GdkPixbuf* pixbuf)44 static void encodeImage(Encoder& encoder, const GdkPixbuf* pixbuf) 45 45 { 46 46 IntSize imageSize(gdk_pixbuf_get_width(pixbuf), gdk_pixbuf_get_height(pixbuf)); … … 58 58 } 59 59 60 static bool decodeImage( ArgumentDecoder& decoder, GRefPtr<GdkPixbuf>& pixbuf)60 static bool decodeImage(Decoder& decoder, GRefPtr<GdkPixbuf>& pixbuf) 61 61 { 62 62 ShareableBitmap::Handle handle; … … 83 83 } 84 84 85 static void encodeDataObject( ArgumentEncoder& encoder, const DataObjectGtk* dataObject)85 static void encodeDataObject(Encoder& encoder, const DataObjectGtk* dataObject) 86 86 { 87 87 bool hasText = dataObject->hasText(); … … 116 116 } 117 117 118 static bool decodeDataObject( ArgumentDecoder& decoder, RefPtr<DataObjectGtk>& dataObject)118 static bool decodeDataObject(Decoder& decoder, RefPtr<DataObjectGtk>& dataObject) 119 119 { 120 120 RefPtr<DataObjectGtk> data = DataObjectGtk::create(); … … 189 189 190 190 #if ENABLE(DRAG_SUPPORT) 191 void ArgumentCoder<DragData>::encode( ArgumentEncoder& encoder, const DragData& dragData)191 void ArgumentCoder<DragData>::encode(Encoder& encoder, const DragData& dragData) 192 192 { 193 193 encoder << dragData.clientPosition(); … … 202 202 } 203 203 204 bool ArgumentCoder<DragData>::decode( ArgumentDecoder& decoder, DragData& dragData)204 bool ArgumentCoder<DragData>::decode(Decoder& decoder, DragData& dragData) 205 205 { 206 206 IntPoint clientPosition; … … 237 237 #endif // ENABLE(DRAG_SUPPORT) 238 238 239 static void encodeGKeyFile( ArgumentEncoder& encoder, GKeyFile* keyFile)239 static void encodeGKeyFile(Encoder& encoder, GKeyFile* keyFile) 240 240 { 241 241 gsize dataSize; … … 244 244 } 245 245 246 static bool decodeGKeyFile( ArgumentDecoder& decoder, GUniquePtr<GKeyFile>& keyFile)246 static bool decodeGKeyFile(Decoder& decoder, GUniquePtr<GKeyFile>& keyFile) 247 247 { 248 248 DataReference dataReference; … … 262 262 } 263 263 264 void encode( ArgumentEncoder& encoder, GtkPrintSettings* printSettings)264 void encode(Encoder& encoder, GtkPrintSettings* printSettings) 265 265 { 266 266 GUniquePtr<GKeyFile> keyFile(g_key_file_new()); … … 269 269 } 270 270 271 bool decode( ArgumentDecoder& decoder, GRefPtr<GtkPrintSettings>& printSettings)271 bool decode(Decoder& decoder, GRefPtr<GtkPrintSettings>& printSettings) 272 272 { 273 273 GUniquePtr<GKeyFile> keyFile; … … 285 285 } 286 286 287 void encode( ArgumentEncoder& encoder, GtkPageSetup* pageSetup)287 void encode(Encoder& encoder, GtkPageSetup* pageSetup) 288 288 { 289 289 GUniquePtr<GKeyFile> keyFile(g_key_file_new()); … … 292 292 } 293 293 294 bool decode( ArgumentDecoder& decoder, GRefPtr<GtkPageSetup>& pageSetup)294 bool decode(Decoder& decoder, GRefPtr<GtkPageSetup>& pageSetup) 295 295 { 296 296 GUniquePtr<GKeyFile> keyFile; -
trunk/Source/WebKit2/Shared/gtk/ArgumentCodersGtk.h
r185502 r204678 42 42 #if ENABLE(DRAG_SUPPORT) 43 43 template<> struct ArgumentCoder<WebCore::DragData> { 44 static void encode( ArgumentEncoder&, const WebCore::DragData&);45 static bool decode( ArgumentDecoder&, WebCore::DragData&);44 static void encode(Encoder&, const WebCore::DragData&); 45 static bool decode(Decoder&, WebCore::DragData&); 46 46 }; 47 47 #endif 48 48 49 void encode( ArgumentEncoder&, GtkPrintSettings*);50 bool decode( ArgumentDecoder&, GRefPtr<GtkPrintSettings>&);49 void encode(Encoder&, GtkPrintSettings*); 50 bool decode(Decoder&, GRefPtr<GtkPrintSettings>&); 51 51 52 void encode( ArgumentEncoder&, GtkPageSetup*);53 bool decode( ArgumentDecoder&, GRefPtr<GtkPageSetup>&);52 void encode(Encoder&, GtkPageSetup*); 53 bool decode(Decoder&, GRefPtr<GtkPageSetup>&); 54 54 55 55 } // namespace IPC -
trunk/Source/WebKit2/Shared/soup/WebCoreArgumentCodersSoup.cpp
r201856 r204678 40 40 namespace IPC { 41 41 42 void ArgumentCoder<ResourceRequest>::encodePlatformData( ArgumentEncoder& encoder, const ResourceRequest& resourceRequest)42 void ArgumentCoder<ResourceRequest>::encodePlatformData(Encoder& encoder, const ResourceRequest& resourceRequest) 43 43 { 44 44 encoder << resourceRequest.url().string(); … … 65 65 } 66 66 67 bool ArgumentCoder<ResourceRequest>::decodePlatformData( ArgumentDecoder& decoder, ResourceRequest& resourceRequest)67 bool ArgumentCoder<ResourceRequest>::decodePlatformData(Decoder& decoder, ResourceRequest& resourceRequest) 68 68 { 69 69 String url; … … 135 135 } 136 136 137 void ArgumentCoder<CertificateInfo>::encode( ArgumentEncoder& encoder, const CertificateInfo& certificateInfo)137 void ArgumentCoder<CertificateInfo>::encode(Encoder& encoder, const CertificateInfo& certificateInfo) 138 138 { 139 139 if (!certificateInfo.certificate()) { … … 155 155 } 156 156 157 bool ArgumentCoder<CertificateInfo>::decode( ArgumentDecoder& decoder, CertificateInfo& certificateInfo)157 bool ArgumentCoder<CertificateInfo>::decode(Decoder& decoder, CertificateInfo& certificateInfo) 158 158 { 159 159 bool hasCertificate; … … 185 185 } 186 186 187 void ArgumentCoder<ResourceError>::encodePlatformData( ArgumentEncoder& encoder, const ResourceError& resourceError)187 void ArgumentCoder<ResourceError>::encodePlatformData(Encoder& encoder, const ResourceError& resourceError) 188 188 { 189 189 encoder.encodeEnum(resourceError.type()); … … 199 199 } 200 200 201 bool ArgumentCoder<ResourceError>::decodePlatformData( ArgumentDecoder& decoder, ResourceError& resourceError)201 bool ArgumentCoder<ResourceError>::decodePlatformData(Decoder& decoder, ResourceError& resourceError) 202 202 { 203 203 ResourceErrorBase::Type errorType; … … 237 237 } 238 238 239 void ArgumentCoder<ProtectionSpace>::encodePlatformData( ArgumentEncoder&, const ProtectionSpace&)240 { 241 ASSERT_NOT_REACHED(); 242 } 243 244 bool ArgumentCoder<ProtectionSpace>::decodePlatformData( ArgumentDecoder&, ProtectionSpace&)239 void ArgumentCoder<ProtectionSpace>::encodePlatformData(Encoder&, const ProtectionSpace&) 240 { 241 ASSERT_NOT_REACHED(); 242 } 243 244 bool ArgumentCoder<ProtectionSpace>::decodePlatformData(Decoder&, ProtectionSpace&) 245 245 { 246 246 ASSERT_NOT_REACHED(); … … 248 248 } 249 249 250 void ArgumentCoder<Credential>::encodePlatformData( ArgumentEncoder&, const Credential&)251 { 252 ASSERT_NOT_REACHED(); 253 } 254 255 bool ArgumentCoder<Credential>::decodePlatformData( ArgumentDecoder&, Credential&)250 void ArgumentCoder<Credential>::encodePlatformData(Encoder&, const Credential&) 251 { 252 ASSERT_NOT_REACHED(); 253 } 254 255 bool ArgumentCoder<Credential>::decodePlatformData(Decoder&, Credential&) 256 256 { 257 257 ASSERT_NOT_REACHED(); -
trunk/Source/WebKit2/UIProcess/LegacySessionStateCodingNone.cpp
r191103 r204678 28 28 29 29 #include "APIData.h" 30 #include "ArgumentDecoder.h" 31 #include "ArgumentEncoder.h" 30 #include "DataReference.h" 31 #include "Decoder.h" 32 #include "Encoder.h" 32 33 #include "SessionState.h" 33 34 #include "WebCoreArgumentCoders.h" … … 37 38 RefPtr<API::Data> encodeLegacySessionState(const SessionState& sessionState) 38 39 { 39 IPC::ArgumentEncoder encoder; 40 // FIXME: I'm not sure whether these are the proper arguments for the encoder. 41 IPC::Encoder encoder("IPC", "LegacySessionState", 0); 40 42 encoder << sessionState.backForwardListState; 41 43 encoder << sessionState.renderTreeSize; … … 46 48 bool decodeLegacySessionState(const uint8_t* data, size_t dataSize, SessionState& sessionState) 47 49 { 48 IPC:: ArgumentDecoder decoder(data, dataSize);50 IPC::Decoder decoder(IPC::DataReference(data, dataSize), Vector<IPC::Attachment>()); 49 51 if (!decoder.decode(sessionState.backForwardListState)) 50 52 return false; -
trunk/Source/WebKit2/UIProcess/WebBatteryManagerProxy.h
r197563 r204678 65 65 66 66 // IPC::MessageReceiver 67 void didReceiveMessage(IPC::Connection&, IPC:: MessageDecoder&) override;67 void didReceiveMessage(IPC::Connection&, IPC::Decoder&) override; 68 68 69 69 void startUpdating();
Note: See TracChangeset
for help on using the changeset viewer.