Title: [123821] trunk/Source/WebCore
Revision
123821
Author
[email protected]
Date
2012-07-26 17:41:55 -0700 (Thu, 26 Jul 2012)

Log Message

[GTK] avoid unneeded object creation when calling Vector::append
https://bugs.webkit.org/show_bug.cgi?id=88805

Patch by Arnaud Renevier <[email protected]> on 2012-07-26
Reviewed by Alexey Proskuryakov.

No new tests: no change in functionality.

* platform/gtk/ContextMenuGtk.cpp:
(WebCore::contextMenuItemVector):
* platform/gtk/KeyBindingTranslator.h:
(WebCore::KeyBindingTranslator::addPendingEditorCommand):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (123820 => 123821)


--- trunk/Source/WebCore/ChangeLog	2012-07-27 00:34:48 UTC (rev 123820)
+++ trunk/Source/WebCore/ChangeLog	2012-07-27 00:41:55 UTC (rev 123821)
@@ -1,3 +1,17 @@
+2012-07-26  Arnaud Renevier  <[email protected]>
+
+        [GTK] avoid unneeded object creation when calling Vector::append
+        https://bugs.webkit.org/show_bug.cgi?id=88805
+
+        Reviewed by Alexey Proskuryakov.
+
+        No new tests: no change in functionality.
+
+        * platform/gtk/ContextMenuGtk.cpp:
+        (WebCore::contextMenuItemVector):
+        * platform/gtk/KeyBindingTranslator.h:
+        (WebCore::KeyBindingTranslator::addPendingEditorCommand):
+
 2012-07-26  Benjamin Poulain  <[email protected]>
 
         Initialize the Event Names' strings from read only memory

Modified: trunk/Source/WebCore/platform/gtk/ContextMenuGtk.cpp (123820 => 123821)


--- trunk/Source/WebCore/platform/gtk/ContextMenuGtk.cpp	2012-07-27 00:34:48 UTC (rev 123820)
+++ trunk/Source/WebCore/platform/gtk/ContextMenuGtk.cpp	2012-07-27 00:41:55 UTC (rev 123821)
@@ -103,7 +103,7 @@
         GtkWidget* widget = static_cast<GtkWidget*>(item->data);
         if (!GTK_IS_MENU_ITEM(widget))
             continue;
-        menuItemVector.append(ContextMenuItem(GTK_MENU_ITEM(widget)));
+        menuItemVector.append(GTK_MENU_ITEM(widget));
     }
 
     return menuItemVector;

Modified: trunk/Source/WebCore/platform/gtk/KeyBindingTranslator.h (123820 => 123821)


--- trunk/Source/WebCore/platform/gtk/KeyBindingTranslator.h	2012-07-27 00:34:48 UTC (rev 123820)
+++ trunk/Source/WebCore/platform/gtk/KeyBindingTranslator.h	2012-07-27 00:41:55 UTC (rev 123821)
@@ -33,7 +33,7 @@
 
     enum EventType { KeyDown, KeyPress };
     void getEditorCommandsForKeyEvent(GdkEventKey*, EventType, Vector<WTF::String>&);
-    void addPendingEditorCommand(const char* command) { m_pendingEditorCommands.append(WTF::String(command)); }
+    void addPendingEditorCommand(const char* command) { m_pendingEditorCommands.append(command); }
 
 private:
     GRefPtr<GtkWidget> m_nativeWidget;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to