summaryrefslogtreecommitdiff
path: root/src/ephy-main.c
diff options
context:
space:
mode:
authorMichael Catanzaro <mcatanzaro@igalia.com>2019-01-03 15:26:21 -0600
committerMichael Catanzaro <mcatanzaro@igalia.com>2019-01-04 09:01:58 -0600
commitd381ce22ac742671fc4c0e06abd24a42204535b7 (patch)
treea233e9e0875fc63f128aaf78c6d8c0b2f032b92f /src/ephy-main.c
parent1dbf87ed9f7f2651121273430d41a5b953bc6304 (diff)
downloadepiphany-d381ce22ac742671fc4c0e06abd24a42204535b7.tar.gz
Remove --new-tab flag
This doesn't do anything, because new tabs are already created by default. Well, almost. Currently, when a primary instance already exists and a secondary instance is launched, that actually does open a new window in the primary instance. But we'll clean that up in the next commit.
Diffstat (limited to 'src/ephy-main.c')
-rw-r--r--src/ephy-main.c21
1 files changed, 1 insertions, 20 deletions
diff --git a/src/ephy-main.c b/src/ephy-main.c
index 72c7de3a4..cd48216d7 100644
--- a/src/ephy-main.c
+++ b/src/ephy-main.c
@@ -45,7 +45,6 @@
#include <string.h>
#include <stdlib.h>
-static gboolean open_in_new_tab = FALSE;
static gboolean open_in_new_window = FALSE;
static char *session_filename = NULL;
@@ -110,8 +109,6 @@ option_version_cb (const gchar *option_name,
/* If you're modifying this array then you need to update the manpage. */
static const GOptionEntry option_entries[] =
{
- { "new-tab", 'n', 0, G_OPTION_ARG_NONE, &open_in_new_tab,
- N_("Open a new tab in an existing browser window"), NULL },
{ "new-window", 0, 0, G_OPTION_ARG_NONE, &open_in_new_window,
N_("Open a new browser window"), NULL },
{ "load-session", 'l', 0, G_OPTION_ARG_FILENAME, &session_filename,
@@ -167,19 +164,6 @@ get_startup_id (void)
return retval;
}
-static EphyStartupFlags
-get_startup_flags (void)
-{
- EphyStartupFlags flags = 0;
-
- if (open_in_new_tab)
- flags |= EPHY_STARTUP_NEW_TAB;
- if (open_in_new_window)
- flags |= EPHY_STARTUP_NEW_WINDOW;
-
- return flags;
-}
-
int
main (int argc,
char *argv[])
@@ -393,14 +377,11 @@ main (int argc,
exit (0);
}
- startup_flags = get_startup_flags ();
+ startup_flags = open_in_new_window ? EPHY_STARTUP_NEW_WINDOW : 0;
/* Now create the shell */
if (private_instance) {
mode = EPHY_EMBED_SHELL_MODE_PRIVATE;
- /* In private mode the session autoresume will always open an empty window.
- * If there are arguments, we want the URIs to be opened in thet existing window. */
- startup_flags |= EPHY_STARTUP_NEW_TAB;
} else if (incognito_mode) {
mode = EPHY_EMBED_SHELL_MODE_INCOGNITO;
} else if (automation_mode) {