Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(277)

Unified Diff: chrome/browser/gtk/options/content_page_gtk.cc

Issue 2881021: Revert 52740 - Always show the 'Control sync from Google Dashboard' link on t... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/gtk/options/content_page_gtk.cc
===================================================================
--- chrome/browser/gtk/options/content_page_gtk.cc (revision 52868)
+++ chrome/browser/gtk/options/content_page_gtk.cc (working copy)
@@ -371,23 +371,26 @@
gtk_box_pack_start(GTK_BOX(button_hbox), sync_customize_button_, FALSE,
FALSE, 0);
- // Add the privacy dashboard link.
- GtkWidget* dashboard_link_hbox =
- gtk_hbox_new(FALSE, gtk_util::kLabelSpacing);
- GtkWidget* dashboard_link_background = gtk_event_box_new();
- std::string dashboard_link_label =
- l10n_util::GetStringUTF8(IDS_SYNC_PRIVACY_DASHBOARD_LINK_LABEL);
- privacy_dashboard_link_ =
- gtk_chrome_link_button_new(dashboard_link_label.c_str());
- g_signal_connect(privacy_dashboard_link_, "clicked",
- G_CALLBACK(OnPrivacyDashboardLinkClickedThunk), this);
- gtk_box_pack_start(GTK_BOX(vbox), dashboard_link_hbox, FALSE, FALSE, 0);
- gtk_box_pack_start(GTK_BOX(dashboard_link_hbox),
- dashboard_link_background, FALSE, FALSE, 0);
- gtk_container_add(GTK_CONTAINER(dashboard_link_background),
- privacy_dashboard_link_);
+ // Add the privacy dashboard link. Only show it if the command line
+ // switch has been provided.
+ if (CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kShowPrivacyDashboardLink)) {
+ GtkWidget* dashboard_link_hbox =
+ gtk_hbox_new(FALSE, gtk_util::kLabelSpacing);
+ GtkWidget* dashboard_link_background = gtk_event_box_new();
+ std::string dashboard_link_label =
+ l10n_util::GetStringUTF8(IDS_SYNC_PRIVACY_DASHBOARD_LINK_LABEL);
+ privacy_dashboard_link_ =
+ gtk_chrome_link_button_new(dashboard_link_label.c_str());
+ g_signal_connect(privacy_dashboard_link_, "clicked",
+ G_CALLBACK(OnPrivacyDashboardLinkClickedThunk), this);
+ gtk_box_pack_start(GTK_BOX(vbox), dashboard_link_hbox, FALSE, FALSE, 0);
+ gtk_box_pack_start(GTK_BOX(dashboard_link_hbox),
+ dashboard_link_background, FALSE, FALSE, 0);
+ gtk_container_add(GTK_CONTAINER(dashboard_link_background),
+ privacy_dashboard_link_);
+ }
-
return vbox;
}
« no previous file with comments | « chrome/browser/cocoa/preferences_window_controller.mm ('k') | chrome/browser/views/options/content_page_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698