OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/location_bar_view_gtk.h" | 5 #include "chrome/browser/ui/gtk/location_bar_view_gtk.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1051 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1062 } else { | 1062 } else { |
1063 gtk_widget_modify_bg(tab_to_search_box_, GTK_STATE_NORMAL, | 1063 gtk_widget_modify_bg(tab_to_search_box_, GTK_STATE_NORMAL, |
1064 &kKeywordBackgroundColor); | 1064 &kKeywordBackgroundColor); |
1065 gtk_util::SetRoundedWindowBorderColor(tab_to_search_box_, | 1065 gtk_util::SetRoundedWindowBorderColor(tab_to_search_box_, |
1066 kKeywordBorderColor); | 1066 kKeywordBorderColor); |
1067 | 1067 |
1068 // Until we switch to vector graphics, force the font size of labels. | 1068 // Until we switch to vector graphics, force the font size of labels. |
1069 // 12.1px = 9pt @ 96dpi | 1069 // 12.1px = 9pt @ 96dpi |
1070 gtk_util::ForceFontSizePixels(security_info_label_, 12.1); | 1070 gtk_util::ForceFontSizePixels(security_info_label_, 12.1); |
1071 gtk_util::ForceFontSizePixels(tab_to_search_full_label_, | 1071 gtk_util::ForceFontSizePixels(tab_to_search_full_label_, |
1072 browser_defaults::kAutocompleteEditFontPixelSize); | 1072 browser_defaults::kOmniboxFontPixelSize); |
1073 gtk_util::ForceFontSizePixels(tab_to_search_partial_label_, | 1073 gtk_util::ForceFontSizePixels(tab_to_search_partial_label_, |
1074 browser_defaults::kAutocompleteEditFontPixelSize); | 1074 browser_defaults::kOmniboxFontPixelSize); |
1075 gtk_util::ForceFontSizePixels(tab_to_search_hint_leading_label_, | 1075 gtk_util::ForceFontSizePixels(tab_to_search_hint_leading_label_, |
1076 browser_defaults::kAutocompleteEditFontPixelSize); | 1076 browser_defaults::kOmniboxFontPixelSize); |
1077 gtk_util::ForceFontSizePixels(tab_to_search_hint_trailing_label_, | 1077 gtk_util::ForceFontSizePixels(tab_to_search_hint_trailing_label_, |
1078 browser_defaults::kAutocompleteEditFontPixelSize); | 1078 browser_defaults::kOmniboxFontPixelSize); |
1079 | 1079 |
1080 const int top_bottom = popup_window_mode_ ? kBorderThickness : 0; | 1080 const int top_bottom = popup_window_mode_ ? kBorderThickness : 0; |
1081 gtk_alignment_set_padding(GTK_ALIGNMENT(location_entry_alignment_), | 1081 gtk_alignment_set_padding(GTK_ALIGNMENT(location_entry_alignment_), |
1082 kTopMargin + kBorderThickness, | 1082 kTopMargin + kBorderThickness, |
1083 kBottomMargin + kBorderThickness, | 1083 kBottomMargin + kBorderThickness, |
1084 top_bottom, top_bottom); | 1084 top_bottom, top_bottom); |
1085 gtk_alignment_set_padding(GTK_ALIGNMENT(tab_to_search_alignment_), | 1085 gtk_alignment_set_padding(GTK_ALIGNMENT(tab_to_search_alignment_), |
1086 1, 1, 0, 0); | 1086 1, 1, 0, 0); |
1087 gtk_alignment_set_padding(GTK_ALIGNMENT(site_type_alignment_), | 1087 gtk_alignment_set_padding(GTK_ALIGNMENT(site_type_alignment_), |
1088 1, 1, 0, 0); | 1088 1, 1, 0, 0); |
(...skipping 1011 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2100 } | 2100 } |
2101 | 2101 |
2102 void LocationBarViewGtk::PageActionViewGtk::InspectPopup( | 2102 void LocationBarViewGtk::PageActionViewGtk::InspectPopup( |
2103 ExtensionAction* action) { | 2103 ExtensionAction* action) { |
2104 ExtensionPopupGtk::Show( | 2104 ExtensionPopupGtk::Show( |
2105 action->GetPopupUrl(current_tab_id_), | 2105 action->GetPopupUrl(current_tab_id_), |
2106 owner_->browser_, | 2106 owner_->browser_, |
2107 event_box_.get(), | 2107 event_box_.get(), |
2108 ExtensionPopupGtk::SHOW_AND_INSPECT); | 2108 ExtensionPopupGtk::SHOW_AND_INSPECT); |
2109 } | 2109 } |
OLD | NEW |