| Index: chrome/common/extensions/api/experimental_wm.idl
|
| diff --git a/chrome/common/extensions/api/experimental_wm.idl b/chrome/common/extensions/api/experimental_wm.idl
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..033ecab8aa4fd21eaf5903b1a66bcc80a79cfd30
|
| --- /dev/null
|
| +++ b/chrome/common/extensions/api/experimental_wm.idl
|
| @@ -0,0 +1,66 @@
|
| +// Copyright (c) 2012 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.
|
| +
|
| +// Window management API.
|
| +
|
| +namespace experimental.wm {
|
| + enum WindowType {
|
| + modal,
|
| + normal,
|
| + panel
|
| + };
|
| +
|
| + enum WindowState {
|
| + normal,
|
| + minimized,
|
| + maximized,
|
| + fullscreen
|
| + };
|
| +
|
| + // The position and size of windows in screen coordinates.
|
| + dictionary Bounds {
|
| + long x;
|
| + long y;
|
| + long width;
|
| + long height;
|
| + };
|
| +
|
| + dictionary AshWindow {
|
| + // A unique identifier for the window during the lifetime of the session.
|
| + long id;
|
| +
|
| + // Window type and state.
|
| + WindowType type;
|
| + WindowState state;
|
| +
|
| + // The user-visible title of the window. This can be empty.
|
| + DOMString title;
|
| +
|
| + // The location and size of the window. The location is in screen
|
| + // coordinates.
|
| + Bounds bounds;
|
| +
|
| + // At most one window can be active at a time.
|
| + boolean active;
|
| + };
|
| +
|
| + interface Events {
|
| + // This is triggered immediately after a window is created, but before it is
|
| + // displayed.
|
| + static void onWindowCreated(AshWindow window);
|
| +
|
| + // This is triggered whenever the window is closed (i.e. by the user, by
|
| + // the web-page, or by the WM app from the close API call).
|
| + static void onWindowClosed(AshWindow window);
|
| +
|
| + // This is triggered when a window is hidden.
|
| + static void onWindowHidden(AshWindow window);
|
| +
|
| + // This is triggered when a window is made visible.
|
| + static void onWindowShown(AshWindow window);
|
| +
|
| + // This is triggered when a new window becomes active.
|
| + static void onActiveWindowChanged(AshWindow window);
|
| + };
|
| +};
|
|
|