aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-tab.c
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@gnome.org>2004-03-22 17:21:31 +0800
committerMarco Pesenti Gritti <marco@src.gnome.org>2004-03-22 17:21:31 +0800
commit3637d5f3ff787e028c00c8d552c555720896e5ba (patch)
tree3748e80731b2a806689ee01b6f42b51284475aa6 /src/ephy-tab.c
parentbcb9219590ac63ec2cb717e90ec9ef176947cdb6 (diff)
downloadgsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.tar
gsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.tar.gz
gsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.tar.bz2
gsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.tar.lz
gsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.tar.xz
gsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.tar.zst
gsoc2013-epiphany-3637d5f3ff787e028c00c8d552c555720896e5ba.zip
Cleanups chromes code and register a type for the enum.
2004-03-16 Marco Pesenti Gritti <marco@gnome.org> * embed/ephy-embed.c: (ephy_embed_chrome_get_type): * embed/ephy-embed.h: * embed/mozilla/Makefile.am: * embed/mozilla/mozilla-embed.cpp: Cleanups chromes code and register a type for the enum. * src/ephy-nautilus-view.c: (gnv_embed_new_window_cb): Adapt to the api changes * src/ephy-tab.c: (ephy_tab_new_window_cb): Move js chrome lockdown pref check here. * src/ephy-window.c: (get_chromes_visibility), (sync_chromes_visibility), (ephy_window_fullscreen), (ephy_window_unfullscreen), (update_chromes_actions), (update_actions_sensitivity), (show_embed_popup), (get_default_chrome), (ephy_window_set_property), (ephy_window_class_init), (actions_notifier), (navigation_notifier), (ephy_window_init), (ephy_window_finalize), (ephy_window_new_with_chrome), (ephy_window_set_print_preview), (ephy_window_show), (sync_prefs_with_chrome), (sync_chrome_with_view_toggle), (ephy_window_view_statusbar_cb), (ephy_window_view_toolbar_cb), (ephy_window_view_bookmarksbar_cb): Rework chrome handling so that it's not applied to all windows. Changes are now saved on the fly like for window size. * src/ephy-window.h: Use a construct property instead of a _set for chrome.
Diffstat (limited to 'src/ephy-tab.c')
-rw-r--r--src/ephy-tab.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/ephy-tab.c b/src/ephy-tab.c
index 35dd1122a..73668100b 100644
--- a/src/ephy-tab.c
+++ b/src/ephy-tab.c
@@ -60,6 +60,8 @@
#define EPHY_TAB_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), EPHY_TYPE_TAB, EphyTabPrivate))
+#define CONF_LOCKDOWN_DISABLE_JAVASCRIPT_CHROME "/apps/epiphany/lockdown/disable_javascript_chrome"
+
struct EphyTabPrivate
{
EphyWindow *window;
@@ -901,13 +903,19 @@ ephy_tab_net_state_cb (EphyEmbed *embed, const char *uri,
static void
ephy_tab_new_window_cb (EphyEmbed *embed, EphyEmbed **new_embed,
- EmbedChromeMask chromemask, EphyTab *tab)
+ EphyEmbedChrome chromemask, EphyTab *tab)
{
EphyTab *new_tab;
EphyWindow *window;
- window = ephy_window_new ();
- ephy_window_request_chrome (window, chromemask);
+ if (eel_gconf_get_boolean (CONF_LOCKDOWN_DISABLE_JAVASCRIPT_CHROME))
+ {
+ window = ephy_window_new ();
+ }
+ else
+ {
+ window = ephy_window_new_with_chrome (chromemask);
+ }
new_tab = ephy_tab_new ();
gtk_widget_show (GTK_WIDGET (new_tab));