[PATCH] location with homepage URL at startup & New tab is blank



Hi!

I am just using epiphany for a few hours and I really like it.
However, I found a few stuffs annoying.
So I made this little patch in order to fix two of them:
1) The location wasn't set at startup
2) A new tab always loaded the homepage

I wanted to add the fact that, when you create a new tab, the keyboard
focus is on the location, but I didn't manage to.

Greetings,
Nicolas

p.s: The location is highlighted at startup (but doesn't have keyboard
focus), I don't know how to fix that :(

-- 
+-----------------------------------+
| Nicolas BENOIT                    |
| http://nbenoit.tuxfamily.org      |
|                                   |
|   .~.                             |
|   /V\          Gnu - Linux        |
|  // \\   http://www.slackware.com |
| /(   )\                           |
|  ^^-^^                            |
+-----------------------------------+
Only in epiphany-1.2.3: patch.diff
diff -c -r epiphany-1.2.3/src/ephy-shell.c epiphany-1.2.3-patched/src/ephy-shell.c
*** epiphany-1.2.3/src/ephy-shell.c	2004-02-24 18:43:48.000000000 +0100
--- epiphany-1.2.3-patched/src/ephy-shell.c	2004-04-23 18:04:35.000000000 +0200
***************
*** 515,521 ****
  }
  
  static void
! load_homepage (EphyEmbed *embed)
  {
  	char *home;
  
--- 515,521 ----
  }
  
  static void
! load_homepage (EphyEmbed *embed, EphyTab *tab)
  {
  	char *home;
  
***************
*** 530,535 ****
--- 530,538 ----
  
  	ephy_embed_load_url (embed, home);
  
+   if (tab != NULL)
+     ephy_tab_set_location (tab, home, TAB_ADDRESS_EXPIRE_NEXT);
+ 
  	g_free (home);
  }
  
***************
*** 608,620 ****
  			     jump_to);
  	gtk_widget_show (GTK_WIDGET(window));
  
! 	if (flags & EPHY_NEW_TAB_HOME_PAGE ||
! 	    flags & EPHY_NEW_TAB_NEW_PAGE)
  	{
! 		ephy_tab_set_location (tab, "", TAB_ADDRESS_EXPIRE_NEXT);
! 		toolbar_activate_location (toolbar);
! 		load_homepage (embed);
  	}
  	else if (flags & EPHY_NEW_TAB_OPEN_PAGE)
  	{
  		g_assert (url != NULL);
--- 611,626 ----
  			     jump_to);
  	gtk_widget_show (GTK_WIDGET(window));
  
! 	if (flags & EPHY_NEW_TAB_HOME_PAGE)
  	{
! 		load_homepage (embed, tab);
!     toolbar_activate_location (toolbar);
  	}
+   else if (flags & EPHY_NEW_TAB_NEW_PAGE)
+   {
+     ephy_embed_load_url (embed, "about:blank");
+     toolbar_activate_location (toolbar);
+   }
  	else if (flags & EPHY_NEW_TAB_OPEN_PAGE)
  	{
  		g_assert (url != NULL);


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