Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6219)

Unified Diff: chrome/common/extensions/api/windows.json

Issue 1015123003: Extension window.create API accepts state. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Make manually minimized if initial_state == minizized Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/api/windows.json
diff --git a/chrome/common/extensions/api/windows.json b/chrome/common/extensions/api/windows.json
index 9d8bab2f369680113db50e20653404cefc68f6f5..b7a48b319a77f042a63a11c2fcd5ff739905bba5 100644
--- a/chrome/common/extensions/api/windows.json
+++ b/chrome/common/extensions/api/windows.json
@@ -11,6 +11,12 @@
},
"types": [
{
+ "id": "State",
+ "type": "string",
+ "enum": ["normal", "minimized", "maximized", "fullscreen"],
+ "description": "The state of this browser window. Under some circumstances a Window may not be assigned state property, for example when querying closed windows from the $(ref:sessions) API."
+ },
+ {
"id": "Window",
"type": "object",
"properties": {
@@ -29,10 +35,9 @@
"enum": ["normal", "popup", "panel", "app"]
},
"state": {
- "type": "string",
+ "$ref": "State",
"optional": true,
- "description": "The state of this browser window. Under some circumstances a Window may not be assigned state property, for example when querying closed windows from the $(ref:sessions) API.",
- "enum": ["normal", "minimized", "maximized", "fullscreen"]
+ "description": "The state of this browser window. Under some circumstances a Window may not be assigned state property, for example when querying closed windows from the $(ref:sessions) API."
},
"alwaysOnTop": {"type": "boolean", "description": "Whether the window is set to be always on top."},
"sessionId": {"type": "string", "optional": true, "description": "The session ID used to uniquely identify a Window obtained from the $(ref:sessions) API."}
@@ -180,6 +185,11 @@
"optional": true,
"description": "Specifies what type of browser window to create. The 'panel' and 'detached_panel' types create a popup unless the '--enable-panels' flag is set.",
"enum": ["normal", "popup", "panel", "detached_panel"]
+ },
+ "state": {
+ "$ref": "State",
+ "optional": true,
+ "description": "The initial state of the window. The 'minimized', 'maximized' and 'fullscreen' states cannot be combined with 'left', 'top', 'width' or 'height'."
}
},
"optional": true
@@ -214,10 +224,9 @@
"focused": {"type": "boolean", "optional": true, "description": "If true, brings the window to the front. If false, brings the next window in the z-order to the front."},
"drawAttention": {"type": "boolean", "optional": true, "description": "If true, causes the window to be displayed in a manner that draws the user's attention to the window, without changing the focused window. The effect lasts until the user changes focus to the window. This option has no effect if the window already has focus. Set to false to cancel a previous draw attention request."},
"state": {
- "type": "string",
+ "$ref": "State",
"optional": true,
- "description": "The new state of the window. The 'minimized', 'maximized' and 'fullscreen' states cannot be combined with 'left', 'top', 'width' or 'height'.",
- "enum": ["normal", "minimized", "maximized", "fullscreen"]
+ "description": "The new state of the window. The 'minimized', 'maximized' and 'fullscreen' states cannot be combined with 'left', 'top', 'width' or 'height'."
}
}
},

Powered by Google App Engine
This is Rietveld 408576698