| Index: mojo/services/native_viewport/native_viewport.h
|
| diff --git a/mojo/services/native_viewport/native_viewport.h b/mojo/services/native_viewport/native_viewport.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..78ae27d3e070f17f8a1971757310f1174b0069bf
|
| --- /dev/null
|
| +++ b/mojo/services/native_viewport/native_viewport.h
|
| @@ -0,0 +1,45 @@
|
| +// 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.
|
| +
|
| +#ifndef MOJO_SERVICES_NATIVE_VIEWPORT_NATIVE_VIEWPORT_H_
|
| +#define MOJO_SERVICES_NATIVE_VIEWPORT_NATIVE_VIEWPORT_H_
|
| +
|
| +#include "base/memory/scoped_ptr.h"
|
| +
|
| +namespace gfx {
|
| +class Size;
|
| +}
|
| +
|
| +namespace ui {
|
| +class Event;
|
| +}
|
| +
|
| +namespace mojo {
|
| +namespace services {
|
| +
|
| +class NativeViewportDelegate {
|
| + public:
|
| + virtual ~NativeViewportDelegate() {}
|
| +
|
| + virtual bool OnEvent(ui::Event* event) = 0;
|
| +
|
| + virtual void OnResized(const gfx::Size& size) = 0;
|
| +
|
| + virtual void OnDestroyed() = 0;
|
| +};
|
| +
|
| +// Encapsulation of platform-specific Viewport.
|
| +class NativeViewport {
|
| + public:
|
| + virtual ~NativeViewport() {}
|
| +
|
| + virtual void Close() = 0;
|
| +
|
| + static scoped_ptr<NativeViewport> Create(NativeViewportDelegate* delegate);
|
| +};
|
| +
|
| +} // namespace services
|
| +} // namespace mojo
|
| +
|
| +#endif // MOJO_SERVICES_NATIVE_VIEWPORT_NATIVE_VIEWPORT_H_
|
|
|