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

Side by Side Diff: chrome/browser/ui/views/browser_actions_container.cc

Issue 10834079: views: Extract Widget observer into its own header file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/browser_actions_container.h" 5 #include "chrome/browser/ui/views/browser_actions_container.h"
6 6
7 #include "base/stl_util.h" 7 #include "base/stl_util.h"
8 #include "chrome/browser/extensions/extension_service.h" 8 #include "chrome/browser/extensions/extension_service.h"
9 #include "chrome/browser/prefs/pref_service.h" 9 #include "chrome/browser/prefs/pref_service.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 12 matching lines...) Expand all
23 #include "grit/ui_resources.h" 23 #include "grit/ui_resources.h"
24 #include "ui/base/accessibility/accessible_view_state.h" 24 #include "ui/base/accessibility/accessible_view_state.h"
25 #include "ui/base/animation/slide_animation.h" 25 #include "ui/base/animation/slide_animation.h"
26 #include "ui/base/dragdrop/drag_utils.h" 26 #include "ui/base/dragdrop/drag_utils.h"
27 #include "ui/base/l10n/l10n_util.h" 27 #include "ui/base/l10n/l10n_util.h"
28 #include "ui/base/resource/resource_bundle.h" 28 #include "ui/base/resource/resource_bundle.h"
29 #include "ui/base/theme_provider.h" 29 #include "ui/base/theme_provider.h"
30 #include "ui/gfx/canvas.h" 30 #include "ui/gfx/canvas.h"
31 #include "ui/views/controls/resize_area.h" 31 #include "ui/views/controls/resize_area.h"
32 #include "ui/views/metrics.h" 32 #include "ui/views/metrics.h"
33 #include "ui/views/widget/widget.h"
33 34
34 using extensions::Extension; 35 using extensions::Extension;
35 36
36 namespace { 37 namespace {
37 38
38 // Horizontal spacing between most items in the container, as well as after the 39 // Horizontal spacing between most items in the container, as well as after the
39 // last item or chevron (if visible). 40 // last item or chevron (if visible).
40 const int kItemSpacing = ToolbarView::kStandardSpacing; 41 const int kItemSpacing = ToolbarView::kStandardSpacing;
41 42
42 // Horizontal spacing before the chevron (if visible). 43 // Horizontal spacing before the chevron (if visible).
(...skipping 763 matching lines...) Expand 10 before | Expand all | Expand 10 after
806 views::BubbleBorder::ArrowLocation arrow_location = base::i18n::IsRTL() ? 807 views::BubbleBorder::ArrowLocation arrow_location = base::i18n::IsRTL() ?
807 views::BubbleBorder::TOP_LEFT : views::BubbleBorder::TOP_RIGHT; 808 views::BubbleBorder::TOP_LEFT : views::BubbleBorder::TOP_RIGHT;
808 popup_ = ExtensionPopup::ShowPopup(popup_url, 809 popup_ = ExtensionPopup::ShowPopup(popup_url,
809 browser_, 810 browser_,
810 reference_view, 811 reference_view,
811 arrow_location); 812 arrow_location);
812 popup_->GetWidget()->AddObserver(this); 813 popup_->GetWidget()->AddObserver(this);
813 popup_button_ = button; 814 popup_button_ = button;
814 popup_button_->SetButtonPushed(); 815 popup_button_->SetButtonPushed();
815 } 816 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/browser_actions_container.h ('k') | chrome/browser/ui/views/chrome_to_mobile_bubble_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698