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

Side by Side Diff: chrome/common/extensions/api/app_window.idl

Issue 11147037: Add a 'hidden' option to chrome.app.window.create() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix ash tests Created 8 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 namespace app.window { 5 namespace app.window {
6 dictionary CreateWindowOptions { 6 dictionary CreateWindowOptions {
7 // Id to identify the window. This will be used to remember the size 7 // Id to identify the window. This will be used to remember the size
8 // and position of the window and restore that geometry when a window 8 // and position of the window and restore that geometry when a window
9 // with the same id (and no explicit size or position) is later opened. 9 // with the same id (and no explicit size or position) is later opened.
10 DOMString? id; 10 DOMString? id;
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 long? maxWidth; 43 long? maxWidth;
44 44
45 // Maximum height of the window. 45 // Maximum height of the window.
46 long? maxHeight; 46 long? maxHeight;
47 47
48 // Window type: 'shell' (the default) is the only currently supported value. 48 // Window type: 'shell' (the default) is the only currently supported value.
49 DOMString? type; 49 DOMString? type;
50 50
51 // Frame type: 'none' or 'chrome' (defaults to 'chrome'). 51 // Frame type: 'none' or 'chrome' (defaults to 'chrome').
52 DOMString? frame; 52 DOMString? frame;
53
54 // If true, the window will be created in a hidden state. Call show() on
55 // the window to show it once it has been created. Defaults to false.
56 boolean? hidden;
53 }; 57 };
54 58
55 callback CreateWindowCallback = 59 callback CreateWindowCallback =
56 void ([instanceOf=AppWindow] object created_window); 60 void ([instanceOf=AppWindow] object created_window);
57 61
58 dictionary AppWindow { 62 dictionary AppWindow {
59 // Focus the window. 63 // Focus the window.
60 static void focus(); 64 static void focus();
61 65
62 // Minimize the window. 66 // Minimize the window.
(...skipping 13 matching lines...) Expand all
76 80
77 // Draw attention to the window. 81 // Draw attention to the window.
78 static void drawAttention(); 82 static void drawAttention();
79 83
80 // Clear attention to the window. 84 // Clear attention to the window.
81 static void clearAttention(); 85 static void clearAttention();
82 86
83 // Close the window. 87 // Close the window.
84 static void close(); 88 static void close();
85 89
90 // Show the window. Does nothing if the window is already visible.
91 static void show();
92
93 // Hide the window. Does nothing if the window is already hidden.
94 static void hide();
95
86 // The JavaScript 'window' object for the created child. 96 // The JavaScript 'window' object for the created child.
87 [instanceOf=global] object contentWindow; 97 [instanceOf=global] object contentWindow;
88 }; 98 };
89 99
90 interface Functions { 100 interface Functions {
91 // The size and position of a window can be specified in a number of 101 // The size and position of a window can be specified in a number of
92 // different ways. The most simple option is not specifying anything at 102 // different ways. The most simple option is not specifying anything at
93 // all, in which case a default size and platform dependent position will 103 // all, in which case a default size and platform dependent position will
94 // be used. 104 // be used.
95 // 105 //
(...skipping 18 matching lines...) Expand all
114 // If you specify both a regular and a default value for the same option 124 // If you specify both a regular and a default value for the same option
115 // the regular value is the only one that takes effect. 125 // the regular value is the only one that takes effect.
116 static void create(DOMString url, 126 static void create(DOMString url,
117 optional CreateWindowOptions options, 127 optional CreateWindowOptions options,
118 optional CreateWindowCallback callback); 128 optional CreateWindowCallback callback);
119 129
120 [nocompile] static AppWindow current(); 130 [nocompile] static AppWindow current();
121 [nocompile, nodoc] static void initializeAppWindow(object state); 131 [nocompile, nodoc] static void initializeAppWindow(object state);
122 }; 132 };
123 }; 133 };
OLDNEW
« no previous file with comments | « chrome/common/extensions/api/app_current_window_internal.idl ('k') | chrome/test/base/test_browser_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698