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/panels/panel.cc

Issue 8342048: Make NotificationService an interface in the content namespace, and switch callers to use it. Mov... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 2 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) 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/panels/panel.h" 5 #include "chrome/browser/ui/panels/panel.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/extensions/extension_prefs.h" 8 #include "chrome/browser/extensions/extension_prefs.h"
9 #include "chrome/browser/extensions/extension_service.h" 9 #include "chrome/browser/extensions/extension_service.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
11 #include "content/browser/renderer_host/render_view_host.h" 11 #include "content/browser/renderer_host/render_view_host.h"
12 #include "chrome/browser/ui/browser.h" 12 #include "chrome/browser/ui/browser.h"
13 #include "chrome/browser/ui/panels/native_panel.h" 13 #include "chrome/browser/ui/panels/native_panel.h"
14 #include "chrome/browser/ui/panels/panel_manager.h" 14 #include "chrome/browser/ui/panels/panel_manager.h"
15 #include "chrome/browser/ui/window_sizer.h" 15 #include "chrome/browser/ui/window_sizer.h"
16 #include "chrome/browser/web_applications/web_app.h" 16 #include "chrome/browser/web_applications/web_app.h"
17 #include "chrome/common/extensions/extension.h" 17 #include "chrome/common/extensions/extension.h"
18 #include "content/browser/tab_contents/tab_contents.h" 18 #include "content/browser/tab_contents/tab_contents.h"
19 #include "content/common/view_messages.h" 19 #include "content/common/view_messages.h"
20 #include "content/public/browser/notification_source.h"
20 #include "content/public/browser/notification_types.h" 21 #include "content/public/browser/notification_types.h"
21 #include "ui/gfx/rect.h" 22 #include "ui/gfx/rect.h"
22 23
23 // static 24 // static
24 const Extension* Panel::GetExtensionFromBrowser(Browser* browser) { 25 const Extension* Panel::GetExtensionFromBrowser(Browser* browser) {
25 // Find the extension. When we create a panel from an extension, the extension 26 // Find the extension. When we create a panel from an extension, the extension
26 // ID is passed as the app name to the Browser. 27 // ID is passed as the app name to the Browser.
27 ExtensionService* extension_service = 28 ExtensionService* extension_service =
28 browser->GetProfile()->GetExtensionService(); 29 browser->GetProfile()->GetExtensionService();
29 return extension_service->GetExtensionById( 30 return extension_service->GetExtensionById(
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 RequestRenderViewHostToDisableScrollbars(GetRenderViewHost()); 576 RequestRenderViewHostToDisableScrollbars(GetRenderViewHost());
576 } 577 }
577 578
578 Browser* Panel::browser() const { 579 Browser* Panel::browser() const {
579 return native_panel_->GetPanelBrowser(); 580 return native_panel_->GetPanelBrowser();
580 } 581 }
581 582
582 void Panel::DestroyBrowser() { 583 void Panel::DestroyBrowser() {
583 native_panel_->DestroyPanelBrowser(); 584 native_panel_->DestroyPanelBrowser();
584 } 585 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/panels/base_panel_browser_test.cc ('k') | chrome/browser/ui/panels/panel_browser_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698