Update V8 to version 4.7.52.
[chromium-blink-merge.git] / chrome / test / base / test_browser_window_aura.h
blobbb2e169755bbe31695eae8a4177dac4e0ea39d49
1 // Copyright 2015 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.
5 #ifndef CHROME_TEST_BASE_TEST_BROWSER_WINDOW_AURA_H_
6 #define CHROME_TEST_BASE_TEST_BROWSER_WINDOW_AURA_H_
8 #include "chrome/test/base/test_browser_window.h"
9 #include "ui/aura/window.h"
11 // A browser window proxy with an associated Aura native window.
12 class TestBrowserWindowAura : public TestBrowserWindow {
13 public:
14 explicit TestBrowserWindowAura(scoped_ptr<aura::Window> native_window);
15 ~TestBrowserWindowAura() override;
17 // TestBrowserWindow overrides:
18 gfx::NativeWindow GetNativeWindow() const override;
19 void Show() override;
20 void Hide() override;
21 gfx::Rect GetBounds() const override;
23 scoped_ptr<Browser> CreateBrowser(Browser::CreateParams* params);
25 private:
26 Browser* browser_; // not owned
27 scoped_ptr<aura::Window> native_window_;
29 DISALLOW_COPY_AND_ASSIGN(TestBrowserWindowAura);
32 namespace chrome {
34 // Helper that creates a browser with a native Aura |window|. If |window| is
35 // nullptr, it will create an Aura window to associate with the browser. It also
36 // handles the lifetime of TestBrowserWindowAura.
37 scoped_ptr<Browser> CreateBrowserWithAuraTestWindowForParams(
38 scoped_ptr<aura::Window> window,
39 Browser::CreateParams* params);
41 } // namespace chrome
43 #endif // CHROME_TEST_BASE_TEST_BROWSER_WINDOW_AURA_H_