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

Side by Side Diff: ash/wm/overview/window_grid.cc

Issue 2899253002: chromeos: Rename ash::WmShelf to Shelf (Closed)
Patch Set: rebase Created 3 years, 7 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "ash/wm/overview/window_grid.h" 5 #include "ash/wm/overview/window_grid.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional> 8 #include <functional>
9 #include <set> 9 #include <set>
10 #include <utility> 10 #include <utility>
11 #include <vector> 11 #include <vector>
12 12
13 #include "ash/ash_switches.h" 13 #include "ash/ash_switches.h"
14 #include "ash/public/cpp/shelf_types.h" 14 #include "ash/public/cpp/shelf_types.h"
15 #include "ash/public/cpp/shell_window_ids.h" 15 #include "ash/public/cpp/shell_window_ids.h"
16 #include "ash/root_window_controller.h" 16 #include "ash/root_window_controller.h"
17 #include "ash/screen_util.h" 17 #include "ash/screen_util.h"
18 #include "ash/shelf/wm_shelf.h" 18 #include "ash/shelf/shelf.h"
19 #include "ash/wm/overview/cleanup_animation_observer.h" 19 #include "ash/wm/overview/cleanup_animation_observer.h"
20 #include "ash/wm/overview/scoped_overview_animation_settings.h" 20 #include "ash/wm/overview/scoped_overview_animation_settings.h"
21 #include "ash/wm/overview/scoped_overview_animation_settings_factory.h" 21 #include "ash/wm/overview/scoped_overview_animation_settings_factory.h"
22 #include "ash/wm/overview/window_selector.h" 22 #include "ash/wm/overview/window_selector.h"
23 #include "ash/wm/overview/window_selector_delegate.h" 23 #include "ash/wm/overview/window_selector_delegate.h"
24 #include "ash/wm/overview/window_selector_item.h" 24 #include "ash/wm/overview/window_selector_item.h"
25 #include "ash/wm/window_state.h" 25 #include "ash/wm/window_state.h"
26 #include "ash/wm_window.h" 26 #include "ash/wm_window.h"
27 #include "base/command_line.h" 27 #include "base/command_line.h"
28 #include "base/i18n/string_search.h" 28 #include "base/i18n/string_search.h"
(...skipping 605 matching lines...) Expand 10 before | Expand all | Expand 10 after
634 (*iter)->OnMinimizedStateChanged(); 634 (*iter)->OnMinimizedStateChanged();
635 PositionWindows(false); 635 PositionWindows(false);
636 } 636 }
637 } 637 }
638 638
639 void WindowGrid::InitShieldWidget() { 639 void WindowGrid::InitShieldWidget() {
640 // TODO(varkha): The code assumes that SHELF_BACKGROUND_MAXIMIZED is 640 // TODO(varkha): The code assumes that SHELF_BACKGROUND_MAXIMIZED is
641 // synonymous with a black shelf background. Update this code if that 641 // synonymous with a black shelf background. Update this code if that
642 // assumption is no longer valid. 642 // assumption is no longer valid.
643 const float initial_opacity = 643 const float initial_opacity =
644 (WmShelf::ForWindow(root_window_)->GetBackgroundType() == 644 (Shelf::ForWindow(root_window_)->GetBackgroundType() ==
645 SHELF_BACKGROUND_MAXIMIZED) 645 SHELF_BACKGROUND_MAXIMIZED)
646 ? 1.f 646 ? 1.f
647 : 0.f; 647 : 0.f;
648 shield_widget_.reset( 648 shield_widget_.reset(
649 CreateBackgroundWidget(root_window_, ui::LAYER_SOLID_COLOR, kShieldColor, 649 CreateBackgroundWidget(root_window_, ui::LAYER_SOLID_COLOR, kShieldColor,
650 0, 0, SK_ColorTRANSPARENT, initial_opacity)); 650 0, 0, SK_ColorTRANSPARENT, initial_opacity));
651 aura::Window* widget_window = shield_widget_->GetNativeWindow(); 651 aura::Window* widget_window = shield_widget_->GetNativeWindow();
652 const gfx::Rect bounds = widget_window->parent()->bounds(); 652 const gfx::Rect bounds = widget_window->parent()->bounds();
653 widget_window->SetBounds(bounds); 653 widget_window->SetBounds(bounds);
654 widget_window->SetName("OverviewModeShield"); 654 widget_window->SetName("OverviewModeShield");
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
833 *min_right = left; 833 *min_right = left;
834 if (*max_right < left) 834 if (*max_right < left)
835 *max_right = left; 835 *max_right = left;
836 } 836 }
837 *max_bottom = top + height; 837 *max_bottom = top + height;
838 } 838 }
839 return windows_fit; 839 return windows_fit;
840 } 840 }
841 841
842 } // namespace ash 842 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc ('k') | ash/wm/overview/window_selector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698