Get rid of more WebHistoryItem cruft
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 18 Oct 2016 22:28:31 +0000 (22:28 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 18 Oct 2016 22:28:31 +0000 (22:28 +0000)
https://bugs.webkit.org/show_bug.cgi?id=163623

Reviewed by Tim Horton.

Source/WebCore:

* history/HistoryItem.cpp:
(WebCore::HistoryItem::HistoryItem):
* history/HistoryItem.h:
(WebCore::HistoryItem::setViewportArguments):
(WebCore::HistoryItem::bookmarkID): Deleted.
(WebCore::HistoryItem::setBookmarkID): Deleted.
(WebCore::HistoryItem::sharedLinkUniqueIdentifier): Deleted.
(WebCore::HistoryItem::setSharedLinkUniqueIdentifier): Deleted.

Source/WebKit/mac:

* History/WebHistoryItem.mm:
(-[WebHistoryItem initFromDictionaryRepresentation:]):
* History/WebHistoryItemPrivate.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207493 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/history/HistoryItem.cpp
Source/WebCore/history/HistoryItem.h
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/History/WebHistoryItem.mm
Source/WebKit/mac/History/WebHistoryItemPrivate.h

index 3e99450..c1a010c 100644 (file)
@@ -1,3 +1,19 @@
+2016-10-18  Anders Carlsson  <andersca@apple.com>
+
+        Get rid of more WebHistoryItem cruft
+        https://bugs.webkit.org/show_bug.cgi?id=163623
+
+        Reviewed by Tim Horton.
+
+        * history/HistoryItem.cpp:
+        (WebCore::HistoryItem::HistoryItem):
+        * history/HistoryItem.h:
+        (WebCore::HistoryItem::setViewportArguments):
+        (WebCore::HistoryItem::bookmarkID): Deleted.
+        (WebCore::HistoryItem::setBookmarkID): Deleted.
+        (WebCore::HistoryItem::sharedLinkUniqueIdentifier): Deleted.
+        (WebCore::HistoryItem::setSharedLinkUniqueIdentifier): Deleted.
+
 2016-10-18  Dave Hyatt  <hyatt@apple.com>
 
         Fix Windows build.
index 9118f8a..320798e 100644 (file)
@@ -120,8 +120,6 @@ inline HistoryItem::HistoryItem(const HistoryItem& item)
     , m_obscuredInset(item.m_obscuredInset)
     , m_scale(item.m_scale)
     , m_scaleIsInitial(item.m_scaleIsInitial)
-    , m_bookmarkID(item.m_bookmarkID)
-    , m_sharedLinkUniqueIdentifier(item.m_sharedLinkUniqueIdentifier)
 #endif
 {
     if (item.m_formData)
index 9b42d88..344d536 100644 (file)
@@ -192,11 +192,6 @@ public:
 
     const ViewportArguments& viewportArguments() const { return m_viewportArguments; }
     void setViewportArguments(const ViewportArguments& viewportArguments) { m_viewportArguments = viewportArguments; }
-
-    uint32_t bookmarkID() const { return m_bookmarkID; }
-    void setBookmarkID(uint32_t bookmarkID) { m_bookmarkID = bookmarkID; }
-    String sharedLinkUniqueIdentifier() const { return m_sharedLinkUniqueIdentifier; }
-    void setSharedLinkUniqueIdentifier(const String& sharedLinkUniqueidentifier) { m_sharedLinkUniqueIdentifier = sharedLinkUniqueidentifier; }
 #endif
 
     void notifyChanged();
@@ -265,9 +260,6 @@ private:
     float m_scale { 0 }; // Note that UIWebView looks for a non-zero value, so this has to start as 0.
     bool m_scaleIsInitial { false };
     ViewportArguments m_viewportArguments;
-
-    uint32_t m_bookmarkID { 0 };
-    String m_sharedLinkUniqueIdentifier;
 #endif
 
 #if PLATFORM(COCOA)
index c80c8e9..1fac1c8 100644 (file)
@@ -1,3 +1,14 @@
+2016-10-18  Anders Carlsson  <andersca@apple.com>
+
+        Get rid of more WebHistoryItem cruft
+        https://bugs.webkit.org/show_bug.cgi?id=163623
+
+        Reviewed by Tim Horton.
+
+        * History/WebHistoryItem.mm:
+        (-[WebHistoryItem initFromDictionaryRepresentation:]):
+        * History/WebHistoryItemPrivate.h:
+
 2016-10-18  Wenson Hsieh  <wenson_hsieh@apple.com>
 
         Showing and hiding candidates list is very distracting after selecting word
index 3df7dfe..25a4332 100644 (file)
@@ -71,9 +71,6 @@ static NSString *scaleKey = @"scale";
 static NSString *scaleIsInitialKey = @"scaleIsInitial";
 static NSString *scrollPointXKey = @"scrollPointX";
 static NSString *scrollPointYKey = @"scrollPointY";
-
-static NSString * const bookmarkIDKey = @"bookmarkID";
-static NSString * const sharedLinkUniqueIdentifierKey = @"sharedLinkUniqueIdentifier";
 #endif
 
 // Private keys used in the WebHistoryItem's dictionary representation.
@@ -379,14 +376,6 @@ WebHistoryItem *kit(HistoryItem* item)
     NSNumber *scrollPointYValue = [dict objectForKey:scrollPointYKey];
     if (scrollPointXValue && scrollPointYValue)
         core(_private)->setScrollPosition(IntPoint([scrollPointXValue intValue], [scrollPointYValue intValue]));
-
-    uint32_t bookmarkIDValue = [[dict objectForKey:bookmarkIDKey] unsignedIntValue];
-    if (bookmarkIDValue)
-        core(_private)->setBookmarkID(bookmarkIDValue);
-
-    NSString *sharedLinkUniqueIdentifierValue = [dict objectForKey:sharedLinkUniqueIdentifierKey];
-    if (sharedLinkUniqueIdentifierValue)
-        core(_private)->setSharedLinkUniqueIdentifier(sharedLinkUniqueIdentifierValue);
 #endif
 
     return self;
@@ -475,14 +464,6 @@ WebHistoryItem *kit(HistoryItem* item)
     IntPoint scrollPosition = core(_private)->scrollPosition();
     [dict setObject:[NSNumber numberWithInt:scrollPosition.x()] forKey:scrollPointXKey];
     [dict setObject:[NSNumber numberWithInt:scrollPosition.y()] forKey:scrollPointYKey];
-
-    uint32_t bookmarkID = core(_private)->bookmarkID();
-    if (bookmarkID)
-        [dict setObject:[NSNumber numberWithUnsignedInt:bookmarkID] forKey:bookmarkIDKey];
-
-    NSString *sharedLinkUniqueIdentifier = [self _sharedLinkUniqueIdentifier];
-    if (sharedLinkUniqueIdentifier)
-        [dict setObject:sharedLinkUniqueIdentifier forKey:sharedLinkUniqueIdentifierKey];
 #endif
 
     return dict;
@@ -619,25 +600,6 @@ WebHistoryItem *kit(HistoryItem* item)
     core(_private)->setScrollPosition(IntPoint(scrollPoint));
 }
 
-- (uint32_t)_bookmarkID
-{
-    return core(_private)->bookmarkID();
-}
-
-- (void)_setBookmarkID:(uint32_t)bookmarkID
-{
-    core(_private)->setBookmarkID(bookmarkID);
-}
-
-- (NSString *)_sharedLinkUniqueIdentifier
-{
-    return nsStringNilIfEmpty(core(_private)->sharedLinkUniqueIdentifier());
-}
-
-- (void)_setSharedLinkUniqueIdentifier:(NSString *)identifier
-{
-    core(_private)->setSharedLinkUniqueIdentifier(identifier);
-}
 #endif // PLATFORM(IOS)
 
 - (BOOL)_isInPageCache
index b4fbf6c..f8e6331 100644 (file)
@@ -75,11 +75,6 @@ extern NSString *WebViewportHeightKey;
 - (void)_setViewportArguments:(NSDictionary *)arguments;
 - (CGPoint)_scrollPoint;
 - (void)_setScrollPoint:(CGPoint)scrollPoint;
-
-- (uint32_t)_bookmarkID;
-- (void)_setBookmarkID:(uint32_t)bookmarkID;
-- (NSString *)_sharedLinkUniqueIdentifier;
-- (void)_setSharedLinkUniqueIdentifier:(NSString *)identifier;
 #endif
 
 - (BOOL)_isInPageCache;