Commit 0a62cead authored by andersca@apple.com's avatar andersca@apple.com

Begin stubbing out a KeyedEncoder class in WebCore

https://bugs.webkit.org/show_bug.cgi?id=124079

Reviewed by Sam Weinig.

Source/WebCore:

* WebCore.exp.in:
Add symbol needed by WebCore.

* WebCore.xcodeproj/project.pbxproj:
Add new header file.

* history/HistoryItem.cpp:
(WebCore::HistoryItem::encodeBackForwardTree):
* history/HistoryItem.h:
Add an encodeBackForwardTree overload that takes a KeyedEncoder object. Encode the version.

* platform/KeyedCoding.h:
Add a KeyedEncoder class that just has a single encodeUInt32 member function for now.

Source/WebKit2:

* Shared/KeyedEncoder.h: Removed.
* Shared/cf/KeyedCodingValueCF.cpp: Removed.
* Shared/cf/KeyedEncoder.cpp: Added.
Remove old keyed encoders.

(WebKit::createDictionary):
Helper function to create a mutable dictionary.
(WebKit::KeyedEncoder::KeyedEncoder):
Create the root dictionary.

(WebKit::KeyedEncoder::encodeUInt32):
Create a CFNumberRef and add it to the dictionary.

* Shared/cf/KeyedEncoder.h: Added.
* WebKit2.xcodeproj/project.pbxproj:
Add new files.

* WebProcess/WebPage/WebBackForwardListProxy.cpp:
(WebKit::updateBackForwardItem):
Create a KeyedEncoder and encode the history tree.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@158971 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 37036791
2013-11-08 Anders Carlsson <andersca@apple.com>
Begin stubbing out a KeyedEncoder class in WebCore
https://bugs.webkit.org/show_bug.cgi?id=124079
Reviewed by Sam Weinig.
* WebCore.exp.in:
Add symbol needed by WebCore.
* WebCore.xcodeproj/project.pbxproj:
Add new header file.
* history/HistoryItem.cpp:
(WebCore::HistoryItem::encodeBackForwardTree):
* history/HistoryItem.h:
Add an encodeBackForwardTree overload that takes a KeyedEncoder object. Encode the version.
* platform/KeyedCoding.h:
Add a KeyedEncoder class that just has a single encodeUInt32 member function for now.
2013-11-08 Brady Eidson <beidson@apple.com>
Merge IDBTransactionBackendInterface and IDBTransactionBackendImpl
......
......@@ -1425,6 +1425,7 @@ __ZNK7WebCore11HistoryItem19childItemWithTargetERKN3WTF6StringE
__ZNK7WebCore11HistoryItem20getTransientPropertyERKN3WTF6StringE
__ZNK7WebCore11HistoryItem20hasCachedPageExpiredEv
__ZNK7WebCore11HistoryItem21encodeBackForwardTreeERN3WTF7EncoderE
__ZNK7WebCore11HistoryItem21encodeBackForwardTreeERNS_12KeyedEncoderE
__ZNK7WebCore11HistoryItem3urlEv
__ZNK7WebCore11HistoryItem4copyEv
__ZNK7WebCore11HistoryItem5titleEv
......
......@@ -756,6 +756,7 @@
1AD8F81C11CAB9E900E93E54 /* PlatformStrategies.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AD8F81A11CAB9E900E93E54 /* PlatformStrategies.cpp */; };
1ADA14100E1AE5D900023EE5 /* PluginMainThreadScheduler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ADA140E0E1AE5D900023EE5 /* PluginMainThreadScheduler.cpp */; };
1ADA14110E1AE5D900023EE5 /* PluginMainThreadScheduler.h in Headers */ = {isa = PBXBuildFile; fileRef = 1ADA140F0E1AE5D900023EE5 /* PluginMainThreadScheduler.h */; settings = {ATTRIBUTES = (Private, ); }; };
1AE00D59182DAC8D00087DD7 /* KeyedCoding.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AE00D57182DAC8D00087DD7 /* KeyedCoding.h */; settings = {ATTRIBUTES = (Private, ); }; };
1AE2AA1E0A1CDAB400B42B25 /* JSHTMLAreaElement.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE2AA0A0A1CDAB300B42B25 /* JSHTMLAreaElement.cpp */; };
1AE2AA1F0A1CDAB400B42B25 /* JSHTMLAreaElement.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AE2AA0B0A1CDAB300B42B25 /* JSHTMLAreaElement.h */; };
1AE2AA200A1CDAB400B42B25 /* JSHTMLBaseFontElement.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE2AA0C0A1CDAB300B42B25 /* JSHTMLBaseFontElement.cpp */; };
......@@ -7331,6 +7332,7 @@
1AD8F81A11CAB9E900E93E54 /* PlatformStrategies.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PlatformStrategies.cpp; sourceTree = "<group>"; };
1ADA140E0E1AE5D900023EE5 /* PluginMainThreadScheduler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PluginMainThreadScheduler.cpp; sourceTree = "<group>"; };
1ADA140F0E1AE5D900023EE5 /* PluginMainThreadScheduler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PluginMainThreadScheduler.h; sourceTree = "<group>"; };
1AE00D57182DAC8D00087DD7 /* KeyedCoding.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KeyedCoding.h; sourceTree = "<group>"; };
1AE2A9F00A1CDA5700B42B25 /* HTMLAreaElement.idl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = HTMLAreaElement.idl; sourceTree = "<group>"; };
1AE2A9F10A1CDA5700B42B25 /* HTMLBaseFontElement.idl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = HTMLBaseFontElement.idl; sourceTree = "<group>"; };
1AE2A9F20A1CDA5700B42B25 /* HTMLBodyElement.idl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = HTMLBodyElement.idl; sourceTree = "<group>"; };
......@@ -20049,11 +20051,9 @@
D6FDAEF2149C06190037B1E1 /* HistogramSupport.cpp */,
D630E2AB149BF344005B2F93 /* HistogramSupport.h */,
BC3BC29B0E91AB0F00835588 /* HostWindow.h */,
1AE00D57182DAC8D00087DD7 /* KeyedCoding.h */,
521D46F711AEC9B100514613 /* KillRing.h */,
4306E4E514955543007F17AC /* KillRingNone.cpp */,
6593923509AE4346002C531F /* URL.cpp */,
6593923609AE4346002C531F /* URL.h */,
BCBD21AA0E417AD400A070F2 /* URLHash.h */,
E18772F0126E2629003DD586 /* Language.cpp */,
85EC9AF90A71A2C600EEEAED /* Language.h */,
141DC0471648348F00371E5A /* LayoutUnit.h */,
......@@ -20150,6 +20150,9 @@
93309EA1099EB78C0056E581 /* Timer.cpp */,
9305B24C098F1B6B00C28855 /* Timer.h */,
1419D2C40CEA6F6100FF507A /* TreeShared.h */,
6593923509AE4346002C531F /* URL.cpp */,
6593923609AE4346002C531F /* URL.h */,
BCBD21AA0E417AD400A070F2 /* URLHash.h */,
2E3BBF051162DA1100B9409A /* UUID.cpp */,
2E3BBF061162DA1100B9409A /* UUID.h */,
515788C01207852C00A37C4A /* VisitedLinkStrategy.h */,
......@@ -23442,6 +23445,7 @@
7A0E771F10C00DB100A0276E /* JSInspectorFrontendHost.h in Headers */,
1C5FAED20DCFD90100D58F78 /* JSJavaScriptCallFrame.h in Headers */,
A86629D309DA2B48009633A5 /* JSKeyboardEvent.h in Headers */,
1AE00D59182DAC8D00087DD7 /* KeyedCoding.h in Headers */,
935F45430F7C3B5F00D7C1FB /* JSLazyEventListener.h in Headers */,
BCE1C43C0D9830D3003B02F2 /* JSLocation.h in Headers */,
FD23A12613F5FA5900F67001 /* JSMediaElementAudioSourceNode.h in Headers */,
......@@ -29,6 +29,7 @@
#include "CachedPage.h"
#include "Document.h"
#include "IconDatabase.h"
#include "KeyedCoding.h"
#include "PageCache.h"
#include "ResourceRequest.h"
#include "SerializedScriptValue.h"
......@@ -682,6 +683,13 @@ void HistoryItem::encodeBackForwardTree(Encoder& encoder) const
encodeBackForwardTreeNode(encoder);
}
void HistoryItem::encodeBackForwardTree(KeyedEncoder& encoder) const
{
encoder.encodeUInt32("version", backForwardTreeEncodingVersion);
// FIXME: Encode the tree.
}
void HistoryItem::encodeBackForwardTreeNode(Encoder& encoder) const
{
size_t size = m_children.size();
......
......@@ -50,8 +50,9 @@ class Document;
class FormData;
class HistoryItem;
class Image;
class URL;
class KeyedEncoder;
class ResourceRequest;
class URL;
typedef Vector<RefPtr<HistoryItem>> HistoryItemVector;
......@@ -88,6 +89,7 @@ public:
void reset();
void encodeBackForwardTree(Encoder&) const;
void encodeBackForwardTree(KeyedEncoder&) const;
static PassRefPtr<HistoryItem> decodeBackForwardTree(const String& urlString, const String& title, const String& originalURLString, Decoder&);
const String& originalURLString() const;
......
......@@ -23,16 +23,21 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef KeyedCodingValueCF_h
#define KeyedCodingValueCF_h
#ifndef KeyedCoding_h
#define KeyedCoding_h
#include "KeyedCodingValue.h"
#include <wtf/RetainPtr.h>
#include <wtf/Forward.h>
namespace WebKit {
namespace WebCore {
RetainPtr<CFTypeRef> toCFType(const KeyedCodingValue&);
class KeyedEncoder {
protected:
virtual ~KeyedEncoder() { }
} // namespace WebKit
public:
virtual void encodeUInt32(const String& key, uint32_t) = 0;
};
#endif // KeyedCodingValueCF_h
} // namespace WebCore
#endif // KeyedCoding_h
2013-11-08 Anders Carlsson <andersca@apple.com>
Begin stubbing out a KeyedEncoder class in WebCore
https://bugs.webkit.org/show_bug.cgi?id=124079
Reviewed by Sam Weinig.
* Shared/KeyedEncoder.h: Removed.
* Shared/cf/KeyedCodingValueCF.cpp: Removed.
* Shared/cf/KeyedEncoder.cpp: Added.
Remove old keyed encoders.
(WebKit::createDictionary):
Helper function to create a mutable dictionary.
(WebKit::KeyedEncoder::KeyedEncoder):
Create the root dictionary.
(WebKit::KeyedEncoder::encodeUInt32):
Create a CFNumberRef and add it to the dictionary.
* Shared/cf/KeyedEncoder.h: Added.
* WebKit2.xcodeproj/project.pbxproj:
Add new files.
* WebProcess/WebPage/WebBackForwardListProxy.cpp:
(WebKit::updateBackForwardItem):
Create a KeyedEncoder and encode the history tree.
2013-11-08 Brady Eidson <beidson@apple.com>
Merge IDBTransactionBackendInterface and IDBTransactionBackendImpl
......
/*
* Copyright (C) 2013 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef KeyedEncoder_h
#define KeyedEncoder_h
#include <wtf/Forward.h>
#include <wtf/HashMap.h>
#include <wtf/text/WTFString.h>
// FIXME: I believe this class can be moved to either WTF or WebCore
// and replace the Encoder/Decoder classes there. Currently the Encoder/Decoder
// classes are used to serialize history trees and using a keyed encoder would be
// less fragile from a binary compatibility perspective.
namespace WebKit {
struct KeyedCodingValue;
class KeyedEncoder {
public:
KeyedEncoder();
~KeyedEncoder();
void encode(const String& key, const String& value);
private:
#if 0
struct Value {
enum Type {
StringValue,
ObjectValue,
};
String string;
HashMap<String, Value> object;
};
HashMap<String, Value> root;
#endif
HashMap<String, KeyedCodingValue> m_rootObject;
HashMap<String, KeyedCodingValue>* m_currentObject;
};
} // namespace WebKit
#endif // KeyedEncoder_h
/*
* Copyright (C) 2013 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "config.h"
#include "KeyedCodingValueCF.h"
namespace WebKit {
static RetainPtr<CFMutableDictionaryRef> toCFDictionary(const HashMap<String, KeyedCodingValue>& object)
{
RetainPtr<CFMutableDictionaryRef> dictionary = adoptCF(CFDictionaryCreateMutable(kCFAllocatorDefault, object.size(), &kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks));
for (auto it = object.begin(), end = object.end(); it != end; ++it)
CFDictionarySetValue(dictionary.get(), it->key.createCFString().get(), toCFType(it->value).get());
return dictionary;
}
RetainPtr<CFTypeRef> toCFType(const KeyedCodingValue& value)
{
switch (value.type) {
case KeyedCodingValue::StringValue:
return value.string.createCFString();
case KeyedCodingValue::ObjectValue:
return toCFDictionary(value.object);
}
ASSERT_NOT_REACHED();
return nullptr;
}
} // namespace WebKit
......@@ -26,30 +26,29 @@
#include "config.h"
#include "KeyedEncoder.h"
#include "KeyedCodingValue.h"
#include <wtf/text/StringHash.h>
#include <CoreFoundation/CoreFoundation.h>
#include <wtf/text/WTFString.h>
namespace WebKit {
KeyedEncoder::KeyedEncoder()
: m_currentObject(&m_rootObject)
static RetainPtr<CFMutableDictionaryRef> createDictionary()
{
return adoptCF(CFDictionaryCreateMutable(kCFAllocatorDefault, 0, &kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks));
}
KeyedEncoder::KeyedEncoder()
: m_rootDictionary(createDictionary())
{
}
KeyedEncoder::~KeyedEncoder()
{
ASSERT(m_currentObject == &m_rootObject);
}
void KeyedEncoder::encode(const String& key, const String& value)
void KeyedEncoder::encodeUInt32(const String& key, uint32_t value)
{
ASSERT(!m_currentObject->contains(key));
KeyedCodingValue keyedCodingValue;
keyedCodingValue.type = KeyedCodingValue::StringValue;
keyedCodingValue.string = value;
m_currentObject->set(key, std::move(keyedCodingValue));
RetainPtr<CFNumberRef> number = adoptCF(CFNumberCreate(kCFAllocatorDefault, kCFNumberSInt32Type, &value));
CFDictionarySetValue(m_rootDictionary.get(), key.createCFString().get(), number.get());
}
} // namespace WebKit
......@@ -23,25 +23,25 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef KeyedCodingValue_h
#define KeyedCodingValue_h
#ifndef KeyedEncoder_h
#define KeyedEncoder_h
#include <wtf/HashMap.h>
#include <wtf/text/WTFString.h>
#include <WebCore/KeyedCoding.h>
#include <wtf/RetainPtr.h>
namespace WebKit {
struct KeyedCodingValue {
enum Type {
StringValue,
ObjectValue
};
class KeyedEncoder : public WebCore::KeyedEncoder {
public:
KeyedEncoder();
~KeyedEncoder();
Type type;
String string;
HashMap<String, KeyedCodingValue> object;
private:
virtual void encodeUInt32(const String& key, uint32_t) OVERRIDE;
RetainPtr<CFMutableDictionaryRef> m_rootDictionary;
};
} // namespace WebKit
#endif // KeyedCodingValue_h
#endif // KeyedEncoder_h
......@@ -148,11 +148,6 @@
1A4A9C9A12B821CD008FE984 /* NetscapePluginModuleMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1A4A9C9912B821CD008FE984 /* NetscapePluginModuleMac.mm */; };
1A4A9F3312B844E2008FE984 /* PluginQuirks.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A4A9F3112B844E2008FE984 /* PluginQuirks.h */; };
1A50DB66110A3D57000D3FE5 /* WebProcess.app in Copy Files */ = {isa = PBXBuildFile; fileRef = 1A50DB1E110A3BDC000D3FE5 /* WebProcess.app */; };
1A588B30174AAC7100ACF472 /* KeyedEncoder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A588B2E174AAC7100ACF472 /* KeyedEncoder.cpp */; };
1A588B31174AAC7100ACF472 /* KeyedEncoder.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A588B2F174AAC7100ACF472 /* KeyedEncoder.h */; };
1A588B33174AAE0B00ACF472 /* KeyedCodingValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A588B32174AAE0B00ACF472 /* KeyedCodingValue.h */; };
1A588B36174AB77000ACF472 /* KeyedCodingValueCF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A588B34174AB77000ACF472 /* KeyedCodingValueCF.cpp */; };
1A588B37174AB77000ACF472 /* KeyedCodingValueCF.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A588B35174AB77000ACF472 /* KeyedCodingValueCF.h */; };
1A594ABA112A1FB6009DE7C7 /* WebUIClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A594AB8112A1FB6009DE7C7 /* WebUIClient.cpp */; };
1A594ABB112A1FB6009DE7C7 /* WebUIClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A594AB9112A1FB6009DE7C7 /* WebUIClient.h */; };
1A5E4DA412D3BD3D0099A2BB /* TextCheckerState.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A5E4DA312D3BD3D0099A2BB /* TextCheckerState.h */; };
......@@ -269,6 +264,8 @@
1AE00D4C182D6EB000087DD7 /* WKBrowsingContextHandle.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1AE00D4A182D6EB000087DD7 /* WKBrowsingContextHandle.mm */; };
1AE00D4D182D6EB000087DD7 /* WKBrowsingContextHandle.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AE00D4B182D6EB000087DD7 /* WKBrowsingContextHandle.h */; };
1AE00D4F182D6F5000087DD7 /* WKBrowsingContextHandleInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AE00D4E182D6F5000087DD7 /* WKBrowsingContextHandleInternal.h */; };
1AE00D5C182DADE100087DD7 /* KeyedEncoder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE00D5A182DADE100087DD7 /* KeyedEncoder.cpp */; };
1AE00D5D182DADE100087DD7 /* KeyedEncoder.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AE00D5B182DADE100087DD7 /* KeyedEncoder.h */; };
1AE117F611DBB30900981615 /* ProcessLauncher.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE117F511DBB30900981615 /* ProcessLauncher.cpp */; };
1AE4976811FF658E0048B464 /* NPJSObject.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AE4976611FF658E0048B464 /* NPJSObject.h */; };
1AE4976911FF658E0048B464 /* NPJSObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE4976711FF658E0048B464 /* NPJSObject.cpp */; };
......@@ -1618,11 +1615,6 @@
1A4F976C100E7B6600637A18 /* FeatureDefines.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = FeatureDefines.xcconfig; sourceTree = "<group>"; };
1A4F976E100E7B6600637A18 /* Version.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Version.xcconfig; sourceTree = "<group>"; };
1A50DB1E110A3BDC000D3FE5 /* WebProcess.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = WebProcess.app; sourceTree = BUILT_PRODUCTS_DIR; };
1A588B2E174AAC7100ACF472 /* KeyedEncoder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KeyedEncoder.cpp; sourceTree = "<group>"; };
1A588B2F174AAC7100ACF472 /* KeyedEncoder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KeyedEncoder.h; sourceTree = "<group>"; };
1A588B32174AAE0B00ACF472 /* KeyedCodingValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KeyedCodingValue.h; sourceTree = "<group>"; };
1A588B34174AB77000ACF472 /* KeyedCodingValueCF.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KeyedCodingValueCF.cpp; sourceTree = "<group>"; };
1A588B35174AB77000ACF472 /* KeyedCodingValueCF.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KeyedCodingValueCF.h; sourceTree = "<group>"; };
1A594AB8112A1FB6009DE7C7 /* WebUIClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebUIClient.cpp; sourceTree = "<group>"; };
1A594AB9112A1FB6009DE7C7 /* WebUIClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebUIClient.h; sourceTree = "<group>"; };
1A5E4DA312D3BD3D0099A2BB /* TextCheckerState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextCheckerState.h; sourceTree = "<group>"; };
......@@ -1756,6 +1748,8 @@
1AE00D4A182D6EB000087DD7 /* WKBrowsingContextHandle.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WKBrowsingContextHandle.mm; sourceTree = "<group>"; };
1AE00D4B182D6EB000087DD7 /* WKBrowsingContextHandle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKBrowsingContextHandle.h; sourceTree = "<group>"; };
1AE00D4E182D6F5000087DD7 /* WKBrowsingContextHandleInternal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKBrowsingContextHandleInternal.h; sourceTree = "<group>"; };
1AE00D5A182DADE100087DD7 /* KeyedEncoder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KeyedEncoder.cpp; sourceTree = "<group>"; };
1AE00D5B182DADE100087DD7 /* KeyedEncoder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KeyedEncoder.h; sourceTree = "<group>"; };
1AE117F511DBB30900981615 /* ProcessLauncher.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ProcessLauncher.cpp; sourceTree = "<group>"; };
1AE4976611FF658E0048B464 /* NPJSObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NPJSObject.h; sourceTree = "<group>"; };
1AE4976711FF658E0048B464 /* NPJSObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = NPJSObject.cpp; sourceTree = "<group>"; };
......@@ -3361,9 +3355,6 @@
BC64696E11DBE603006455B0 /* ImmutableArray.h */,
BCBCB0CC1215E33A00DE59CA /* ImmutableDictionary.cpp */,
BCBCB0CA1215E32100DE59CA /* ImmutableDictionary.h */,
1A588B32174AAE0B00ACF472 /* KeyedCodingValue.h */,
1A588B2E174AAC7100ACF472 /* KeyedEncoder.cpp */,
1A588B2F174AAC7100ACF472 /* KeyedEncoder.h */,
1A92DC1012F8BA460017AF65 /* LayerTreeContext.h */,
BCC8049D122F0D6B00103529 /* MutableArray.cpp */,
BCC8049E122F0D6B00103529 /* MutableArray.h */,
......@@ -3509,8 +3500,8 @@
children = (
1AAF0C4912B16334008E49E2 /* ArgumentCodersCF.cpp */,
1AAF0C4812B16334008E49E2 /* ArgumentCodersCF.h */,
1A588B34174AB77000ACF472 /* KeyedCodingValueCF.cpp */,
1A588B35174AB77000ACF472 /* KeyedCodingValueCF.h */,
1AE00D5A182DADE100087DD7 /* KeyedEncoder.cpp */,
1AE00D5B182DADE100087DD7 /* KeyedEncoder.h */,
);
path = cf;
sourceTree = "<group>";
......@@ -5560,9 +5551,6 @@
BCB0B0DE12305A8C00B1341E /* InjectedBundleUserMessageCoders.h in Headers */,
1AE49A4911FFA8CE0048B464 /* JSNPMethod.h in Headers */,
1AE4987811FF7FAA0048B464 /* JSNPObject.h in Headers */,
1A588B33174AAE0B00ACF472 /* KeyedCodingValue.h in Headers */,
1A588B37174AB77000ACF472 /* KeyedCodingValueCF.h in Headers */,
1A588B31174AAC7100ACF472 /* KeyedEncoder.h in Headers */,
BCE0937814FB128C001138D9 /* LayerHostingContext.h in Headers */,
1A92DC1112F8BA460017AF65 /* LayerTreeContext.h in Headers */,
1A186EEA12EF7618008E5F37 /* LayerTreeHost.h in Headers */,
......@@ -5926,6 +5914,7 @@
51A55601128C6D92009ABCEC /* WKContextMenuItemTypes.h in Headers */,
BCC938E11180DE440085E5FE /* WKContextPrivate.h in Headers */,
9FB5F395169E6A80002C25BF /* WKContextPrivateMac.h in Headers */,
1AE00D5D182DADE100087DD7 /* KeyedEncoder.h in Headers */,
3309345B1315B9980097A7BC /* WKCookieManager.h in Headers */,
512F58FA12A88A5400629530 /* WKCredential.h in Headers */,
518ACF1112B015F800B04B83 /* WKCredentialTypes.h in Headers */,
......@@ -6860,8 +6849,6 @@
BC14DF78120B5B7900826C0C /* InjectedBundleScriptWorld.cpp in Sources */,
1AE49A4A11FFA8CE0048B464 /* JSNPMethod.cpp in Sources */,
1AE4987911FF7FAA0048B464 /* JSNPObject.cpp in Sources */,
1A588B36174AB77000ACF472 /* KeyedCodingValueCF.cpp in Sources */,
1A588B30174AAC7100ACF472 /* KeyedEncoder.cpp in Sources */,
BCE0937714FB128C001138D9 /* LayerHostingContext.mm in Sources */,
1A92DC1312F8BAB90017AF65 /* LayerTreeContextMac.mm in Sources */,
1A186EEB12EF7618008E5F37 /* LayerTreeHost.cpp in Sources */,
......@@ -7166,6 +7153,7 @@
1A3E736211CC2659007BD539 /* WebPlatformStrategies.cpp in Sources */,
C0337DDD127A521C008FF4F4 /* WebPlatformTouchPoint.cpp in Sources */,
31D5929E166E060000E6BF02 /* WebPlugInClient.cpp in Sources */,
1AE00D5C182DADE100087DD7 /* KeyedEncoder.cpp in Sources */,
1AC8702E130B49A2002C1257 /* WebPluginSiteDataManager.cpp in Sources */,
BCB9F8AF1124E07700A137E0 /* WebPolicyClient.cpp in Sources */,
BC5744EF12638FB3006F0F12 /* WebPopupItem.cpp in Sources */,
......
......@@ -28,6 +28,7 @@
#include "DataReference.h"
#include "EncoderAdapter.h"
#include "KeyedEncoder.h"
#include "WebCoreArgumentCoders.h"
#include "WebPage.h"
#include "WebPageProxyMessages.h"
......@@ -83,6 +84,9 @@ void WebBackForwardListProxy::setHighestItemIDFromUIProcess(uint64_t itemID)
static void updateBackForwardItem(uint64_t itemID, HistoryItem* item)
{
KeyedEncoder keyedEncoder;
item->encodeBackForwardTree(keyedEncoder);
EncoderAdapter encoder;
item->encodeBackForwardTree(encoder);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment