aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-main.c
diff options
context:
space:
mode:
authorGustavo Noronha Silva <gns@gnome.org>2013-05-04 00:37:11 +0800
committerGustavo Noronha Silva <gns@gnome.org>2013-05-04 03:28:13 +0800
commit5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d (patch)
treec4261b260af1955eb6dc51a148f00a99e80b5a03 /src/ephy-main.c
parent1f6c4b033e5ff7a21a96abde2e804585e4f234f9 (diff)
downloadgsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.tar
gsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.tar.gz
gsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.tar.bz2
gsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.tar.lz
gsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.tar.xz
gsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.tar.zst
gsoc2013-epiphany-5ee94f4954f6e4b49eabeafd6a9bd6ee925f395d.zip
Allow running a regular standalone instance with a different profile
Adds a new standalone shell mode and removes restrictions on using --profile in a non-private, non-incognito instance of the browser. Useful for debugging or improving features that rely on being in a regular session, such as password and session saving/restoring. https://bugzilla.gnome.org/show_bug.cgi?id=699602
Diffstat (limited to 'src/ephy-main.c')
-rw-r--r--src/ephy-main.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/ephy-main.c b/src/ephy-main.c
index 80d076bad..665739bc3 100644
--- a/src/ephy-main.c
+++ b/src/ephy-main.c
@@ -334,11 +334,6 @@ main (int argc,
exit (1);
}
- if (profile_directory != NULL && private_instance == FALSE && application_mode == FALSE && incognito_mode == FALSE) {
- g_print ("--profile can only be used in combination with --private-instance, --incognito-mode or --application-mode\n");
- exit (1);
- }
-
if (application_mode && profile_directory == NULL) {
g_print ("--profile must be used when --application-mode is requested\n");
exit (1);
@@ -417,7 +412,13 @@ main (int argc,
/* Now create the shell */
if (private_instance)
mode = EPHY_EMBED_SHELL_MODE_PRIVATE;
- else if (incognito_mode) {
+ else if (profile_directory) {
+ /* This mode exists purely for letting EphyShell know it should
+ * not consider this instance part of the unique application
+ * represented by the BROWSER mode.
+ */
+ mode = EPHY_EMBED_SHELL_MODE_STANDALONE;
+ } else if (incognito_mode) {
mode = EPHY_EMBED_SHELL_MODE_INCOGNITO;
/* Use the right theming. */