Chromium Code Reviews| Index: mojo/services/native_viewport/platform_viewport_headless.h |
| diff --git a/mojo/services/native_viewport/platform_viewport_headless.h b/mojo/services/native_viewport/platform_viewport_headless.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..bd392da5bde06b812e68e91f6ee8dea1525b1ac2 |
| --- /dev/null |
| +++ b/mojo/services/native_viewport/platform_viewport_headless.h |
| @@ -0,0 +1,34 @@ |
| +// Copyright 2013 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#include "mojo/services/native_viewport/platform_viewport.h" |
| +#include "ui/gfx/rect.h" |
| + |
| +namespace mojo { |
| + |
| +class PlatformViewportHeadless : public PlatformViewport { |
| + public: |
| + explicit PlatformViewportHeadless(Delegate* delegate); |
| + virtual ~PlatformViewportHeadless(); |
| + |
| + static scoped_ptr<PlatformViewport> Create(Delegate* delegate); |
|
jamesr
2014/09/25 22:18:14
why are both the constructor and this factory func
abarth-chromium
2014/09/25 23:31:36
Made the constructor private.
|
| + |
| + private: |
| + // Overridden from PlatformViewport: |
| + virtual void Init(const gfx::Rect& bounds) OVERRIDE; |
| + virtual void Show() OVERRIDE; |
| + virtual void Hide() OVERRIDE; |
| + virtual void Close() OVERRIDE; |
| + virtual gfx::Size GetSize() OVERRIDE; |
| + virtual void SetBounds(const gfx::Rect& bounds) OVERRIDE; |
| + virtual void SetCapture() OVERRIDE; |
| + virtual void ReleaseCapture() OVERRIDE; |
| + |
| + Delegate* delegate_; |
| + gfx::Rect bounds_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(PlatformViewportHeadless); |
| +}; |
| + |
| +} // namespace mojo |