| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/ui/gtk/options/general_page_gtk.h" | 5 #include "chrome/browser/ui/gtk/options/general_page_gtk.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 #include "chrome/browser/ui/gtk/accessible_widget_helper_gtk.h" | 23 #include "chrome/browser/ui/gtk/accessible_widget_helper_gtk.h" |
| 24 #include "chrome/browser/ui/gtk/gtk_chrome_link_button.h" | 24 #include "chrome/browser/ui/gtk/gtk_chrome_link_button.h" |
| 25 #include "chrome/browser/ui/gtk/gtk_util.h" | 25 #include "chrome/browser/ui/gtk/gtk_util.h" |
| 26 #include "chrome/browser/ui/gtk/keyword_editor_view.h" | 26 #include "chrome/browser/ui/gtk/keyword_editor_view.h" |
| 27 #include "chrome/browser/ui/gtk/options/managed_prefs_banner_gtk.h" | 27 #include "chrome/browser/ui/gtk/options/managed_prefs_banner_gtk.h" |
| 28 #include "chrome/browser/ui/gtk/options/options_layout_gtk.h" | 28 #include "chrome/browser/ui/gtk/options/options_layout_gtk.h" |
| 29 #include "chrome/browser/ui/gtk/options/url_picker_dialog_gtk.h" | 29 #include "chrome/browser/ui/gtk/options/url_picker_dialog_gtk.h" |
| 30 #include "chrome/browser/ui/options/show_options_url.h" | 30 #include "chrome/browser/ui/options/show_options_url.h" |
| 31 #include "chrome/common/pref_names.h" | 31 #include "chrome/common/pref_names.h" |
| 32 #include "chrome/common/url_constants.h" | 32 #include "chrome/common/url_constants.h" |
| 33 #include "gfx/gtk_util.h" | |
| 34 #include "grit/chromium_strings.h" | 33 #include "grit/chromium_strings.h" |
| 35 #include "grit/generated_resources.h" | 34 #include "grit/generated_resources.h" |
| 36 #include "ui/base/l10n/l10n_util.h" | 35 #include "ui/base/l10n/l10n_util.h" |
| 36 #include "ui/gfx/gtk_util.h" |
| 37 | 37 |
| 38 namespace { | 38 namespace { |
| 39 | 39 |
| 40 // Markup for the text showing the current state of the default browser | 40 // Markup for the text showing the current state of the default browser |
| 41 const char kDefaultBrowserLabelMarkup[] = "<span color='#%s'>%s</span>"; | 41 const char kDefaultBrowserLabelMarkup[] = "<span color='#%s'>%s</span>"; |
| 42 | 42 |
| 43 // Color of the default browser text when Chromium is the default browser | 43 // Color of the default browser text when Chromium is the default browser |
| 44 const char kDefaultBrowserLabelColor[] = "008700"; | 44 const char kDefaultBrowserLabelColor[] = "008700"; |
| 45 | 45 |
| 46 // Color of the default browser text when Chromium is not the default browser | 46 // Color of the default browser text when Chromium is not the default browser |
| (...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 811 int desired_width = allocation->x - sender->parent->allocation.x; | 811 int desired_width = allocation->x - sender->parent->allocation.x; |
| 812 GtkRequisition req; | 812 GtkRequisition req; |
| 813 gtk_widget_size_request(instant_indent_, &req); | 813 gtk_widget_size_request(instant_indent_, &req); |
| 814 if (req.width != desired_width) | 814 if (req.width != desired_width) |
| 815 gtk_widget_set_size_request(instant_indent_, desired_width, -1); | 815 gtk_widget_set_size_request(instant_indent_, desired_width, -1); |
| 816 } | 816 } |
| 817 | 817 |
| 818 void GeneralPageGtk::OnSearchLearnMoreClicked(GtkWidget* sender) { | 818 void GeneralPageGtk::OnSearchLearnMoreClicked(GtkWidget* sender) { |
| 819 browser::ShowOptionsURL(profile(), browser::InstantLearnMoreURL()); | 819 browser::ShowOptionsURL(profile(), browser::InstantLearnMoreURL()); |
| 820 } | 820 } |
| OLD | NEW |