#include "ash/ash_switches.h"
#include "ash/focus_cycler.h"
#include "ash/root_window_controller.h"
-#include "ash/session_state_delegate.h"
+#include "ash/session/session_state_delegate.h"
#include "ash/shelf/shelf_constants.h"
#include "ash/shelf/shelf_delegate.h"
#include "ash/shelf/shelf_layout_manager.h"
// Class used to slightly dim shelf items when maximized and visible.
class DimmerView : public views::View,
public views::WidgetDelegate,
- ash::internal::BackgroundAnimatorDelegate {
+ ash::BackgroundAnimatorDelegate {
public:
// If |disable_dimming_animations_for_test| is set, all alpha animations will
// be performed instantly.
return View::GetWidget();
}
- // ash::internal::BackgroundAnimatorDelegate overrides:
+ // ash::BackgroundAnimatorDelegate overrides:
virtual void UpdateBackground(int alpha) OVERRIDE {
alpha_ = alpha;
SchedulePaint();
bool disable_dimming_animations_for_test_;
// The animator for the background transitions.
- ash::internal::BackgroundAnimator background_animator_;
+ ash::BackgroundAnimator background_animator_;
// Notification of entering / exiting of the shelf area by mouse.
scoped_ptr<DimmerEventFilter> event_filter_;
void DimmerView::OnPaintBackground(gfx::Canvas* canvas) {
SkPaint paint;
- ResourceBundle& rb = ResourceBundle::GetSharedInstance();
+ ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
gfx::ImageSkia shelf_background =
- *rb.GetImageNamed(IDR_AURA_LAUNCHER_DIMMING).ToImageSkia();
+ *rb.GetImageNamed(IDR_ASH_SHELF_DIMMING).ToImageSkia();
if (shelf_->GetAlignment() != ash::SHELF_ALIGNMENT_BOTTOM) {
shelf_background = gfx::ImageSkiaOperations::CreateRotatedImage(
touch_inside_ = touch_inside;
}
-using ash::internal::ShelfLayoutManager;
+using ash::ShelfLayoutManager;
// ShelfWindowTargeter makes it easier to resize windows with the mouse when the
// window-edge slightly overlaps with the shelf edge. The targeter also makes it
// sizes it to the width of the shelf minus the size of the status area.
class ShelfWidget::DelegateView : public views::WidgetDelegate,
public views::AccessiblePaneView,
- public internal::BackgroundAnimatorDelegate,
+ public BackgroundAnimatorDelegate,
public aura::WindowObserver {
public:
explicit DelegateView(ShelfWidget* shelf);
virtual ~DelegateView();
- void set_focus_cycler(internal::FocusCycler* focus_cycler) {
+ void set_focus_cycler(FocusCycler* focus_cycler) {
focus_cycler_ = focus_cycler;
}
- internal::FocusCycler* focus_cycler() {
- return focus_cycler_;
- }
+ FocusCycler* focus_cycler() { return focus_cycler_; }
ui::Layer* opaque_background() { return &opaque_background_; }
private:
ShelfWidget* shelf_;
scoped_ptr<views::Widget> dimmer_;
- internal::FocusCycler* focus_cycler_;
+ FocusCycler* focus_cycler_;
int alpha_;
ui::Layer opaque_background_;
}
void ShelfWidget::DelegateView::OnPaintBackground(gfx::Canvas* canvas) {
- ResourceBundle& rb = ResourceBundle::GetSharedInstance();
+ ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
gfx::ImageSkia shelf_background =
- *rb.GetImageSkiaNamed(IDR_AURA_LAUNCHER_BACKGROUND);
+ *rb.GetImageSkiaNamed(IDR_ASH_SHELF_BACKGROUND);
if (SHELF_ALIGNMENT_BOTTOM != shelf_->GetAlignment())
shelf_background = gfx::ImageSkiaOperations::CreateRotatedImage(
shelf_background,
// The part of the shelf background that is in the corner below the docked
// windows close to the work area is an arched gradient that blends
// vertically oriented docked background and horizontal shelf.
- gfx::ImageSkia shelf_corner =
- *rb.GetImageSkiaNamed(IDR_AURA_LAUNCHER_CORNER);
+ gfx::ImageSkia shelf_corner = *rb.GetImageSkiaNamed(IDR_ASH_SHELF_CORNER);
if (dock_bounds.x() == 0) {
shelf_corner = gfx::ImageSkiaOperations::CreateRotatedImage(
shelf_corner, SkBitmapOperations::ROTATION_90_CW);
ShelfWidget::ShelfWidget(aura::Window* shelf_container,
aura::Window* status_container,
- internal::WorkspaceController* workspace_controller)
+ WorkspaceController* workspace_controller)
: delegate_view_(new DelegateView(this)),
background_animator_(delegate_view_, 0, kShelfBackgroundAlpha),
activating_as_fallback_(false),
SetContentsView(delegate_view_);
delegate_view_->SetParentLayer(GetLayer());
- status_area_widget_ = new internal::StatusAreaWidget(status_container);
+ status_area_widget_ = new StatusAreaWidget(status_container);
status_area_widget_->CreateTrayViews();
if (Shell::GetInstance()->session_state_delegate()->
IsActiveUserSessionStarted()) {
}
Shell::GetInstance()->focus_cycler()->AddWidget(status_area_widget_);
- shelf_layout_manager_ = new internal::ShelfLayoutManager(this);
+ shelf_layout_manager_ = new ShelfLayoutManager(this);
shelf_layout_manager_->AddObserver(this);
shelf_container->SetLayoutManager(shelf_layout_manager_);
shelf_layout_manager_->set_workspace_controller(workspace_controller);
workspace_controller->SetShelf(shelf_layout_manager_);
- status_container->SetLayoutManager(
- new internal::StatusAreaLayoutManager(this));
+ status_container->SetLayoutManager(new StatusAreaLayoutManager(this));
shelf_container->SetEventTargeter(scoped_ptr<ui::EventTargeter>(new
ShelfWindowTargeter(shelf_container, shelf_layout_manager_)));
SetFocusCycler(shell->focus_cycler());
// Inform the root window controller.
- internal::RootWindowController::ForWindow(window_container_)
- ->OnShelfCreated();
+ RootWindowController::ForWindow(window_container_)->OnShelfCreated();
shelf_->SetVisible(
shell->session_state_delegate()->IsActiveUserSessionStarted());
shelf_->SetVisible(visible);
}
-void ShelfWidget::SetFocusCycler(internal::FocusCycler* focus_cycler) {
+void ShelfWidget::SetFocusCycler(FocusCycler* focus_cycler) {
delegate_view_->set_focus_cycler(focus_cycler);
if (focus_cycler)
focus_cycler->AddWidget(this);
}
-internal::FocusCycler* ShelfWidget::GetFocusCycler() {
+FocusCycler* ShelfWidget::GetFocusCycler() {
return delegate_view_->focus_cycler();
}