Gut ash::MaterialDesignController, and remove the about:flags entry.

It's not removed completely because IsXXXMaterial() is still used in
many places and serves as a good marker for code cleanup, but it no
longer does anything useful.

A bunch of tests are updated as well to remove parameterization. The
amount of overlap with bug 685837 was not originally intended, but at a
certain point it became easier to keep removing code than to carefully
determine dependencies.

BUG=690048,685837

Review-Url: https://codereview.chromium.org/2692663002
Cr-Commit-Position: refs/heads/master@{#450531}
diff --git a/ash/root_window_controller_unittest.cc b/ash/root_window_controller_unittest.cc
index d6369dd0..4d33dee0 100644
--- a/ash/root_window_controller_unittest.cc
+++ b/ash/root_window_controller_unittest.cc
@@ -6,7 +6,6 @@
 
 #include <memory>
 
-#include "ash/common/material_design/material_design_controller.h"
 #include "ash/common/session/session_controller.h"
 #include "ash/common/session/session_state_delegate.h"
 #include "ash/common/system/tray/system_tray_delegate.h"
@@ -17,7 +16,6 @@
 #include "ash/common/wm_window.h"
 #include "ash/public/cpp/shell_window_ids.h"
 #include "ash/shell.h"
-#include "ash/test/ash_md_test_base.h"
 #include "ash/test/ash_test_base.h"
 #include "ash/wm/window_properties.h"
 #include "ash/wm/window_state_aura.h"
@@ -106,7 +104,7 @@
 
 namespace test {
 
-class RootWindowControllerTest : public AshMDTestBase {
+class RootWindowControllerTest : public AshTestBase {
  public:
   views::Widget* CreateTestWidget(const gfx::Rect& bounds) {
     views::Widget* widget = views::Widget::CreateWindowWithContextAndBounds(
@@ -136,16 +134,7 @@
   }
 };
 
-INSTANTIATE_TEST_CASE_P(
-    /* prefix intentionally left blank due to only one parameterization */,
-    RootWindowControllerTest,
-    testing::Values(MaterialDesignController::NON_MATERIAL,
-                    MaterialDesignController::MATERIAL_NORMAL,
-                    MaterialDesignController::MATERIAL_EXPERIMENTAL));
-
-TEST_P(RootWindowControllerTest, MoveWindows_Basic) {
-  const int height_offset = GetMdMaximizedWindowHeightOffset();
-
+TEST_F(RootWindowControllerTest, MoveWindows_Basic) {
   // Windows origin should be doubled when moved to the 1st display.
   UpdateDisplay("600x600,300x300");
   aura::Window::Windows root_windows = Shell::GetAllRootWindows();
@@ -159,9 +148,9 @@
   views::Widget* maximized = CreateTestWidget(gfx::Rect(700, 10, 100, 100));
   maximized->Maximize();
   EXPECT_EQ(root_windows[1], maximized->GetNativeView()->GetRootWindow());
-  EXPECT_EQ(gfx::Rect(600, 0, 300, 253 + height_offset).ToString(),
+  EXPECT_EQ(gfx::Rect(600, 0, 300, 252).ToString(),
             maximized->GetWindowBoundsInScreen().ToString());
-  EXPECT_EQ(gfx::Rect(0, 0, 300, 253 + height_offset).ToString(),
+  EXPECT_EQ(gfx::Rect(0, 0, 300, 252).ToString(),
             maximized->GetNativeView()->GetBoundsInRootWindow().ToString());
 
   views::Widget* minimized = CreateTestWidget(gfx::Rect(800, 10, 100, 100));
@@ -220,18 +209,18 @@
   // share the same desktop workspace, which cancels the shelf status.
   fullscreen->SetFullscreen(false);
   EXPECT_EQ(root_windows[0], maximized->GetNativeView()->GetRootWindow());
-  EXPECT_EQ(gfx::Rect(0, 0, 600, 553 + height_offset).ToString(),
+  EXPECT_EQ(gfx::Rect(0, 0, 600, 552).ToString(),
             maximized->GetWindowBoundsInScreen().ToString());
-  EXPECT_EQ(gfx::Rect(0, 0, 600, 553 + height_offset).ToString(),
+  EXPECT_EQ(gfx::Rect(0, 0, 600, 552).ToString(),
             maximized->GetNativeView()->GetBoundsInRootWindow().ToString());
 
   // Set fullscreen to true, but maximized window's size won't change because
   // it's not visible. see crbug.com/504299.
   fullscreen->SetFullscreen(true);
   EXPECT_EQ(root_windows[0], maximized->GetNativeView()->GetRootWindow());
-  EXPECT_EQ(gfx::Rect(0, 0, 600, 553 + height_offset).ToString(),
+  EXPECT_EQ(gfx::Rect(0, 0, 600, 552).ToString(),
             maximized->GetWindowBoundsInScreen().ToString());
-  EXPECT_EQ(gfx::Rect(0, 0, 600, 553 + height_offset).ToString(),
+  EXPECT_EQ(gfx::Rect(0, 0, 600, 552).ToString(),
             maximized->GetNativeView()->GetBoundsInRootWindow().ToString());
 
   EXPECT_EQ(root_windows[0], minimized->GetNativeView()->GetRootWindow());
@@ -265,7 +254,7 @@
   EXPECT_EQ(kShellWindowId_PanelContainer, panel->parent()->id());
 }
 
-TEST_P(RootWindowControllerTest, MoveWindows_Modal) {
+TEST_F(RootWindowControllerTest, MoveWindows_Modal) {
   UpdateDisplay("500x500,500x500");
 
   aura::Window::Windows root_windows = Shell::GetAllRootWindows();
@@ -295,7 +284,7 @@
 }
 
 // Make sure lock related windows moves.
-TEST_P(RootWindowControllerTest, MoveWindows_LockWindowsInUnified) {
+TEST_F(RootWindowControllerTest, MoveWindows_LockWindowsInUnified) {
   display_manager()->SetUnifiedDesktopEnabled(true);
 
   UpdateDisplay("500x500");
@@ -373,7 +362,7 @@
   EXPECT_EQ("0,0 600x500", lock_screen->GetNativeWindow()->bounds().ToString());
 }
 
-TEST_P(RootWindowControllerTest, ModalContainer) {
+TEST_F(RootWindowControllerTest, ModalContainer) {
   UpdateDisplay("600x600");
   WmShell* wm_shell = WmShell::Get();
   RootWindowController* controller = wm_shell->GetPrimaryRootWindowController();
@@ -410,7 +399,7 @@
   wm_shell->GetSessionStateDelegate()->UnlockScreen();
 }
 
-TEST_P(RootWindowControllerTest, ModalContainerNotLoggedInLoggedIn) {
+TEST_F(RootWindowControllerTest, ModalContainerNotLoggedInLoggedIn) {
   UpdateDisplay("600x600");
 
   // Configure login screen environment.
@@ -455,7 +444,7 @@
                 WmLookup::Get()->GetWindowForWidget(session_modal_widget)));
 }
 
-TEST_P(RootWindowControllerTest, ModalContainerBlockedSession) {
+TEST_F(RootWindowControllerTest, ModalContainerBlockedSession) {
   UpdateDisplay("600x600");
   RootWindowController* controller =
       WmShell::Get()->GetPrimaryRootWindowController();
@@ -496,7 +485,7 @@
   }
 }
 
-TEST_P(RootWindowControllerTest, GetWindowForFullscreenMode) {
+TEST_F(RootWindowControllerTest, GetWindowForFullscreenMode) {
   UpdateDisplay("600x600");
   RootWindowController* controller = Shell::GetPrimaryRootWindowController();
 
@@ -527,7 +516,7 @@
   EXPECT_EQ(NULL, controller->GetWindowForFullscreenMode());
 }
 
-TEST_P(RootWindowControllerTest, MultipleDisplaysGetWindowForFullscreenMode) {
+TEST_F(RootWindowControllerTest, MultipleDisplaysGetWindowForFullscreenMode) {
   UpdateDisplay("600x600,600x600");
   Shell::RootWindowControllerList controllers =
       Shell::GetInstance()->GetAllRootWindowControllers();
@@ -564,7 +553,7 @@
 
 // Test that GetRootWindowController() works with multiple displays and
 // child widgets.
-TEST_P(RootWindowControllerTest, GetRootWindowController) {
+TEST_F(RootWindowControllerTest, GetRootWindowController) {
   UpdateDisplay("600x600,600x600");
   Shell::RootWindowControllerList controllers =
       Shell::GetInstance()->GetAllRootWindowControllers();
@@ -592,7 +581,7 @@
 
 // Test that user session window can't be focused if user session blocked by
 // some overlapping UI.
-TEST_P(RootWindowControllerTest, FocusBlockedWindow) {
+TEST_F(RootWindowControllerTest, FocusBlockedWindow) {
   UpdateDisplay("600x600");
   RootWindowController* controller = Shell::GetPrimaryRootWindowController();
   aura::Window* lock_container =
@@ -651,7 +640,7 @@
 };
 
 // Verifies shutdown doesn't delete windows that are not owned by the parent.
-TEST_P(RootWindowControllerTest, DontDeleteWindowsNotOwnedByParent) {
+TEST_F(RootWindowControllerTest, DontDeleteWindowsNotOwnedByParent) {
   DestroyedWindowObserver observer1;
   aura::test::TestWindowDelegate delegate1;
   aura::Window* window1 = new aura::Window(&delegate1);