[epiphany] ephy-navigation-history-action: fix overview title



commit 4e9047e324c443b666f07cc356f38a21702c9268
Author: Xan Lopez <xan igalia com>
Date:   Wed Aug 29 02:26:26 2012 +0200

    ephy-navigation-history-action: fix overview title
    
    The overview is not an actual web page, so it won't have a title as
    far as WebKit is concerned. Hardcode "Most Visited" as its title.

 src/ephy-navigation-history-action.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/ephy-navigation-history-action.c b/src/ephy-navigation-history-action.c
index f8892bf..6898001 100644
--- a/src/ephy-navigation-history-action.c
+++ b/src/ephy-navigation-history-action.c
@@ -37,6 +37,7 @@
 #include "ephy-type-builtins.h"
 #include "ephy-window.h"
 
+#include <glib/gi18n.h>
 #include <gtk/gtk.h>
 #ifdef HAVE_WEBKIT2
 #include <webkit2/webkit2.h>
@@ -540,6 +541,10 @@ build_dropdown_menu (EphyNavigationHistoryAction *action)
 
     title = g_strdup (webkit_web_history_item_get_title (hitem));
 #endif
+    /* The overview is not actually a webpage, so we need to hardcode
+     * this here. */
+    if (g_strcmp0 (uri, "ephy-about:overview") == 0)
+      title = g_strdup (_("Most Visited"));
 
     if (title == NULL || g_strstrip (title)[0] == '\0')
       item = new_history_menu_item (EPHY_WEB_VIEW (web_view), uri, uri);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]