1 // Copyright 2016 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #include "ui/views/test/test_layout_manager.h" 6 7 namespace views { 8 namespace test { 9 10 TestLayoutManager::TestLayoutManager() = default; 11 12 TestLayoutManager::~TestLayoutManager() = default; 13 Layout(View * host)14void TestLayoutManager::Layout(View* host) {} 15 GetPreferredSize(const View * host) const16gfx::Size TestLayoutManager::GetPreferredSize(const View* host) const { 17 return preferred_size_; 18 } 19 GetPreferredHeightForWidth(const View * host,int width) const20int TestLayoutManager::GetPreferredHeightForWidth(const View* host, 21 int width) const { 22 return preferred_height_for_width_; 23 } 24 InvalidateLayout()25void TestLayoutManager::InvalidateLayout() { 26 ++invalidate_count_; 27 } 28 29 } // namespace test 30 } // namespace views 31