| 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/views/extensions/extension_installed_bubble.h" | 5 #include "chrome/browser/ui/views/extensions/extension_installed_bubble.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 #include "grit/theme_resources_standard.h" | 29 #include "grit/theme_resources_standard.h" |
| 30 #include "ui/base/l10n/l10n_util.h" | 30 #include "ui/base/l10n/l10n_util.h" |
| 31 #include "ui/base/resource/resource_bundle.h" | 31 #include "ui/base/resource/resource_bundle.h" |
| 32 #include "ui/views/controls/button/image_button.h" | 32 #include "ui/views/controls/button/image_button.h" |
| 33 #include "ui/views/controls/image_view.h" | 33 #include "ui/views/controls/image_view.h" |
| 34 #include "ui/views/controls/label.h" | 34 #include "ui/views/controls/label.h" |
| 35 #include "ui/views/controls/link.h" | 35 #include "ui/views/controls/link.h" |
| 36 #include "ui/views/controls/link_listener.h" | 36 #include "ui/views/controls/link_listener.h" |
| 37 #include "ui/views/layout/fill_layout.h" | 37 #include "ui/views/layout/fill_layout.h" |
| 38 #include "ui/views/layout/layout_constants.h" | 38 #include "ui/views/layout/layout_constants.h" |
| 39 #include "views/view.h" | 39 #include "ui/views/view.h" |
| 40 | 40 |
| 41 namespace { | 41 namespace { |
| 42 | 42 |
| 43 const int kIconSize = 43; | 43 const int kIconSize = 43; |
| 44 | 44 |
| 45 const int kRightColumnWidth = 285; | 45 const int kRightColumnWidth = 285; |
| 46 | 46 |
| 47 // The Bubble uses a BubbleBorder which adds about 6 pixels of whitespace | 47 // The Bubble uses a BubbleBorder which adds about 6 pixels of whitespace |
| 48 // around the content view. We compensate by reducing our outer borders by this | 48 // around the content view. We compensate by reducing our outer borders by this |
| 49 // amount + 4px. | 49 // amount + 4px. |
| (...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 414 } | 414 } |
| 415 | 415 |
| 416 void ExtensionInstalledBubble::WindowClosing() { | 416 void ExtensionInstalledBubble::WindowClosing() { |
| 417 if (extension_ && type_ == PAGE_ACTION) { | 417 if (extension_ && type_ == PAGE_ACTION) { |
| 418 BrowserView* browser_view = BrowserView::GetBrowserViewForBrowser(browser_); | 418 BrowserView* browser_view = BrowserView::GetBrowserViewForBrowser(browser_); |
| 419 browser_view->GetLocationBarView()->SetPreviewEnabledPageAction( | 419 browser_view->GetLocationBarView()->SetPreviewEnabledPageAction( |
| 420 extension_->page_action(), | 420 extension_->page_action(), |
| 421 false); // preview_enabled | 421 false); // preview_enabled |
| 422 } | 422 } |
| 423 } | 423 } |
| OLD | NEW |