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

Side by Side Diff: chrome/common/extensions/docs/js/api_page_generator.js

Issue 9566007: Initial Managed Mode extension API, supporting querying the setting and a stub for enabling the mod… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Updated checkout again Created 8 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 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 /** 5 /**
6 * @fileoverview This file is the controller for generating extension 6 * @fileoverview This file is the controller for generating extension
7 * doc pages. 7 * doc pages.
8 * 8 *
9 * It expects to have available via XHR (relative path): 9 * It expects to have available via XHR (relative path):
10 * 1) API_TEMPLATE which is the main template for the api pages. 10 * 1) API_TEMPLATE which is the main template for the api pages.
(...skipping 23 matching lines...) Expand all
34 '../api/experimental.accessibility.json', 34 '../api/experimental.accessibility.json',
35 '../api/experimental.app.json', 35 '../api/experimental.app.json',
36 '../api/experimental.bookmarkManager.json', 36 '../api/experimental.bookmarkManager.json',
37 '../api/experimental.dns.json', 37 '../api/experimental.dns.json',
38 '../api/experimental.downloads.json', 38 '../api/experimental.downloads.json',
39 '../api/experimental.extension.json', 39 '../api/experimental.extension.json',
40 '../api/experimental.infobars.json', 40 '../api/experimental.infobars.json',
41 '../api/experimental.input.ui.json', 41 '../api/experimental.input.ui.json',
42 '../api/experimental.input.virtualKeyboard.json', 42 '../api/experimental.input.virtualKeyboard.json',
43 '../api/experimental.keybinding.json', 43 '../api/experimental.keybinding.json',
44 '../api/experimental.managedMode.json',
44 '../api/experimental.processes.json', 45 '../api/experimental.processes.json',
45 '../api/experimental.rlz.json', 46 '../api/experimental.rlz.json',
46 '../api/experimental.serial.json', 47 '../api/experimental.serial.json',
47 '../api/experimental.socket.json', 48 '../api/experimental.socket.json',
48 '../api/experimental.speechInput.json', 49 '../api/experimental.speechInput.json',
49 '../api/experimental.topSites.json', 50 '../api/experimental.topSites.json',
50 '../api/extension.json', 51 '../api/extension.json',
51 '../api/fileBrowserHandler.json', 52 '../api/fileBrowserHandler.json',
52 '../api/fileBrowserPrivate.json', 53 '../api/fileBrowserPrivate.json',
53 '../api/history.json', 54 '../api/history.json',
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 } 236 }
236 } 237 }
237 238
238 try { 239 try {
239 xhr.onreadystatechange = function(){ 240 xhr.onreadystatechange = function(){
240 if (xhr.readyState == 4) { 241 if (xhr.readyState == 4) {
241 if (xhr.status < 300 && xhr.responseText) { 242 if (xhr.status < 300 && xhr.responseText) {
242 window.clearTimeout(abortTimerId); 243 window.clearTimeout(abortTimerId);
243 onSuccess(xhr.responseText); 244 onSuccess(xhr.responseText);
244 } else { 245 } else {
245 handleError('Failure to fetch content'); 246 handleError('Failure to fetch content: ' + xhr.status);
246 } 247 }
247 } 248 }
248 } 249 }
249 250
250 xhr.onerror = handleError; 251 xhr.onerror = handleError;
251 252
252 xhr.open('GET', url, true); 253 xhr.open('GET', url, true);
253 xhr.send(null); 254 xhr.send(null);
254 } catch(e) { 255 } catch(e) {
255 console.log('ex: ' + e); 256 console.log('ex: ' + e);
(...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after
670 } 671 }
671 if (a.name > b.name) { 672 if (a.name > b.name) {
672 return 1; 673 return 1;
673 } 674 }
674 return 0; 675 return 0;
675 } 676 }
676 677
677 function disableDocs(obj) { 678 function disableDocs(obj) {
678 return !!obj.nodoc || !!obj.internal; 679 return !!obj.nodoc || !!obj.internal;
679 } 680 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698