| Index: chrome/browser/ui/panels/panel.cc
|
| diff --git a/chrome/browser/ui/panels/panel.cc b/chrome/browser/ui/panels/panel.cc
|
| index 35900ca68d4845adbbeb4120fc7f36f96116905f..bb4e4b3cc0c1208c39a783a18c9b91325231f437 100644
|
| --- a/chrome/browser/ui/panels/panel.cc
|
| +++ b/chrome/browser/ui/panels/panel.cc
|
| @@ -25,6 +25,7 @@
|
| #include "chrome/browser/ui/panels/panel_collection.h"
|
| #include "chrome/browser/ui/panels/panel_host.h"
|
| #include "chrome/browser/ui/panels/panel_manager.h"
|
| +#include "chrome/browser/ui/panels/stacked_panel_collection.h"
|
| #include "chrome/browser/web_applications/web_app.h"
|
| #include "chrome/common/chrome_notification_types.h"
|
| #include "chrome/common/extensions/extension.h"
|
| @@ -245,6 +246,11 @@ const std::string Panel::extension_id() const {
|
| return web_app::GetExtensionIdFromApplicationName(app_name_);
|
| }
|
|
|
| +StackedPanelCollection* Panel::stack() const {
|
| + return collection_->type() == PanelCollection::STACKED ?
|
| + static_cast<StackedPanelCollection*>(collection_) : NULL;
|
| +}
|
| +
|
| content::WebContents* Panel::GetWebContents() const {
|
| return panel_host_.get() ? panel_host_->web_contents() : NULL;
|
| }
|
| @@ -775,7 +781,7 @@ string16 Panel::GetWindowTitle() const {
|
| FormatTitleForDisplay(&title);
|
| }
|
|
|
| - if (title.empty())
|
| + if (!title.empty())
|
| title = UTF8ToUTF16(app_name());
|
|
|
| return title;
|
| @@ -809,6 +815,16 @@ void Panel::WebContentsFocused(content::WebContents* contents) {
|
| native_panel_->PanelWebContentsFocused(contents);
|
| }
|
|
|
| +void Panel::UpdateStackingProperty() {
|
| + native_panel_->UpdatePanelStackingProperty();
|
| +}
|
| +
|
| +void Panel::MoveByInstantly(const gfx::Vector2d& delta_origin) {
|
| + gfx::Rect bounds = GetBounds();
|
| + bounds.Offset(delta_origin);
|
| + SetPanelBoundsInstantly(bounds);
|
| +}
|
| +
|
| const extensions::Extension* Panel::GetExtension() const {
|
| ExtensionService* extension_service =
|
| extensions::ExtensionSystem::Get(profile())->extension_service();
|
|
|