[epiphany/mcatanzaro/cli: 4/8] shell: Open new tab in primary instance when activated without args



commit fb8e57bbe83dff65d0ad27dbcfe736a682b60c86
Author: Michael Catanzaro <mcatanzaro igalia com>
Date:   Thu Jan 3 15:27:52 2019 -0600

    shell: Open new tab in primary instance when activated without args
    
    This makes more sense. When a secondary instance is activated without
    any arguments, previously we would open a new window by default. Now
    we'll open a new tab in the current window instead, matching gedit's
    behavior. Get the old behavior by passing --new-window.

 src/ephy-shell.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
---
diff --git a/src/ephy-shell.c b/src/ephy-shell.c
index 624c0f513..034efce31 100644
--- a/src/ephy-shell.c
+++ b/src/ephy-shell.c
@@ -1044,7 +1044,6 @@ open_uris_data_new (EphyShell       *shell,
 {
   OpenURIsData *data;
   gboolean fullscreen_lockdown;
-  gboolean have_uris;
   EphySession *session = ephy_shell_get_session (shell);
 
   data = g_new0 (OpenURIsData, 1);
@@ -1056,9 +1055,7 @@ open_uris_data_new (EphyShell       *shell,
   fullscreen_lockdown = g_settings_get_boolean (EPHY_SETTINGS_LOCKDOWN,
                                                 EPHY_PREFS_LOCKDOWN_FULLSCREEN);
 
-  have_uris = uris && !(g_strv_length ((char **)uris) == 1 && !g_strcmp0 (uris[0], ""));
-
-  if (((startup_flags & EPHY_STARTUP_NEW_WINDOW) && !fullscreen_lockdown) || !have_uris) {
+  if ((startup_flags & EPHY_STARTUP_NEW_WINDOW) && !fullscreen_lockdown) {
     data->window = ephy_window_new ();
   } else {
     data->flags |= EPHY_NEW_TAB_JUMP;


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