OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/views/location_bar/location_bar_view.h" | 5 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <map> | 8 #include <map> |
9 | 9 |
10 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
(...skipping 1098 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1109 view->SetBounds( | 1109 view->SetBounds( |
1110 leading ? bounds->x() : (bounds->right() - view_size.width()), | 1110 leading ? bounds->x() : (bounds->right() - view_size.width()), |
1111 view->y(), view_size.width(), view->height()); | 1111 view->y(), view_size.width(), view->height()); |
1112 bounds->set_width(bounds->width() - desired_width); | 1112 bounds->set_width(bounds->width() - desired_width); |
1113 } | 1113 } |
1114 } | 1114 } |
1115 | 1115 |
1116 void LocationBarView::RefreshContentSettingViews() { | 1116 void LocationBarView::RefreshContentSettingViews() { |
1117 for (ContentSettingViews::const_iterator i(content_setting_views_.begin()); | 1117 for (ContentSettingViews::const_iterator i(content_setting_views_.begin()); |
1118 i != content_setting_views_.end(); ++i) { | 1118 i != content_setting_views_.end(); ++i) { |
1119 (*i)->UpdateFromWebContents(model_->input_in_progress() ? NULL : | 1119 (*i)->Update(model_->input_in_progress() ? NULL : GetTabContents()); |
1120 GetWebContentsFromDelegate(delegate_)); | |
1121 } | 1120 } |
1122 } | 1121 } |
1123 | 1122 |
1124 void LocationBarView::DeletePageActionViews() { | 1123 void LocationBarView::DeletePageActionViews() { |
1125 for (PageActionViews::const_iterator i(page_action_views_.begin()); | 1124 for (PageActionViews::const_iterator i(page_action_views_.begin()); |
1126 i != page_action_views_.end(); ++i) | 1125 i != page_action_views_.end(); ++i) |
1127 RemoveChildView(*i); | 1126 RemoveChildView(*i); |
1128 STLDeleteElements(&page_action_views_); | 1127 STLDeleteElements(&page_action_views_); |
1129 } | 1128 } |
1130 | 1129 |
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1529 } | 1528 } |
1530 | 1529 |
1531 void LocationBarView::CleanupFadeAnimation() { | 1530 void LocationBarView::CleanupFadeAnimation() { |
1532 // Since we're no longer animating we don't need our layer. | 1531 // Since we're no longer animating we don't need our layer. |
1533 SetPaintToLayer(false); | 1532 SetPaintToLayer(false); |
1534 // Bubble labels don't need a transparent background anymore. | 1533 // Bubble labels don't need a transparent background anymore. |
1535 ev_bubble_view_->SetLabelBackgroundColor(SK_ColorWHITE); | 1534 ev_bubble_view_->SetLabelBackgroundColor(SK_ColorWHITE); |
1536 selected_keyword_view_->SetLabelBackgroundColor(SK_ColorWHITE); | 1535 selected_keyword_view_->SetLabelBackgroundColor(SK_ColorWHITE); |
1537 } | 1536 } |
1538 #endif // USE_AURA | 1537 #endif // USE_AURA |
OLD | NEW |