Title: [181850] trunk/Source/WebKit2
- Revision
- 181850
- Author
- [email protected]
- Date
- 2015-03-23 03:02:08 -0700 (Mon, 23 Mar 2015)
Log Message
[GTK][WK2] webkitBackForwardListChanged() should operate on a Vector reference
https://bugs.webkit.org/show_bug.cgi?id=142963
Reviewed by Carlos Garcia Campos.
* UIProcess/API/gtk/WebKitBackForwardList.cpp:
(webkitBackForwardListChanged): This function only reads from the passed-in
Vector of removed items, so only a const lvalue reference to the Vector
is needed.
* UIProcess/API/gtk/WebKitBackForwardListPrivate.h:
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (181849 => 181850)
--- trunk/Source/WebKit2/ChangeLog 2015-03-23 09:14:19 UTC (rev 181849)
+++ trunk/Source/WebKit2/ChangeLog 2015-03-23 10:02:08 UTC (rev 181850)
@@ -1,3 +1,16 @@
+2015-03-23 Zan Dobersek <[email protected]>
+
+ [GTK][WK2] webkitBackForwardListChanged() should operate on a Vector reference
+ https://bugs.webkit.org/show_bug.cgi?id=142963
+
+ Reviewed by Carlos Garcia Campos.
+
+ * UIProcess/API/gtk/WebKitBackForwardList.cpp:
+ (webkitBackForwardListChanged): This function only reads from the passed-in
+ Vector of removed items, so only a const lvalue reference to the Vector
+ is needed.
+ * UIProcess/API/gtk/WebKitBackForwardListPrivate.h:
+
2015-03-23 Carlos Garcia Campos <[email protected]>
[GTK] Add a configure option to build without Redirected XComposite Window
Modified: trunk/Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardList.cpp (181849 => 181850)
--- trunk/Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardList.cpp 2015-03-23 09:14:19 UTC (rev 181849)
+++ trunk/Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardList.cpp 2015-03-23 10:02:08 UTC (rev 181850)
@@ -128,13 +128,13 @@
return list;
}
-void webkitBackForwardListChanged(WebKitBackForwardList* backForwardList, WebBackForwardListItem* webAddedItem, Vector<RefPtr<WebBackForwardListItem>> webRemovedItems)
+void webkitBackForwardListChanged(WebKitBackForwardList* backForwardList, WebBackForwardListItem* webAddedItem, const Vector<RefPtr<WebBackForwardListItem>>& webRemovedItems)
{
WebKitBackForwardListItem* addedItem = webkitBackForwardListGetOrCreateItem(backForwardList, webAddedItem);
GList* removedItems = nullptr;
WebKitBackForwardListPrivate* priv = backForwardList->priv;
- for (const auto& webItem : webRemovedItems) {
+ for (auto& webItem : webRemovedItems) {
removedItems = g_list_prepend(removedItems, g_object_ref(priv->itemsMap.get(webItem.get()).get()));
priv->itemsMap.remove(webItem.get());
}
Modified: trunk/Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardListPrivate.h (181849 => 181850)
--- trunk/Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardListPrivate.h 2015-03-23 09:14:19 UTC (rev 181849)
+++ trunk/Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardListPrivate.h 2015-03-23 10:02:08 UTC (rev 181850)
@@ -32,6 +32,6 @@
WebKitBackForwardList* webkitBackForwardListCreate(WebKit::WebBackForwardList*);
WebKitBackForwardListItem* webkitBackForwardListItemGetOrCreate(WebKit::WebBackForwardListItem*);
WebKit::WebBackForwardListItem* webkitBackForwardListItemGetItem(WebKitBackForwardListItem*);
-void webkitBackForwardListChanged(WebKitBackForwardList*, WebKit::WebBackForwardListItem* webAddedItem, Vector<RefPtr<WebKit::WebBackForwardListItem>>);
+void webkitBackForwardListChanged(WebKitBackForwardList*, WebKit::WebBackForwardListItem* webAddedItem, const Vector<RefPtr<WebKit::WebBackForwardListItem>>&);
#endif // WebKitBackForwardListPrivate_h
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes