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

Side by Side Diff: chrome/browser/resources/md_bookmarks/actions.js

Issue 2902103002: MD Bookmarks: Disable 'Open in Incognito Window' when Incognito is disabled (Closed)
Patch Set: Review comment Created 3 years, 6 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
« no previous file with comments | « no previous file | chrome/browser/resources/md_bookmarks/api_listener.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 Module for functions which produce action objects. These are 6 * @fileoverview Module for functions which produce action objects. These are
7 * listed in one place to document available actions and their parameters. 7 * listed in one place to document available actions and their parameters.
8 */ 8 */
9 9
10 cr.define('bookmarks.actions', function() { 10 cr.define('bookmarks.actions', function() {
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
234 * @param {!Array<string>} ids 234 * @param {!Array<string>} ids
235 * @return {!Action} 235 * @return {!Action}
236 */ 236 */
237 function setSearchResults(ids) { 237 function setSearchResults(ids) {
238 return { 238 return {
239 name: 'finish-search', 239 name: 'finish-search',
240 results: ids, 240 results: ids,
241 }; 241 };
242 } 242 }
243 243
244 /**
245 * @param {IncognitoAvailability} availability
246 * @return {!Action}
247 */
248 function setIncognitoAvailability(availability) {
249 assert(availability != IncognitoAvailability.FORCED);
250 return {
251 name: 'set-incognito-availability',
252 value: availability,
253 };
254 }
255
244 return { 256 return {
245 changeFolderOpen: changeFolderOpen, 257 changeFolderOpen: changeFolderOpen,
246 clearSearch: clearSearch, 258 clearSearch: clearSearch,
247 createBookmark: createBookmark, 259 createBookmark: createBookmark,
248 deselectItems: deselectItems, 260 deselectItems: deselectItems,
249 editBookmark: editBookmark, 261 editBookmark: editBookmark,
250 moveBookmark: moveBookmark, 262 moveBookmark: moveBookmark,
251 refreshNodes: refreshNodes, 263 refreshNodes: refreshNodes,
252 removeBookmark: removeBookmark, 264 removeBookmark: removeBookmark,
253 reorderChildren: reorderChildren, 265 reorderChildren: reorderChildren,
254 selectAll: selectAll, 266 selectAll: selectAll,
255 selectFolder: selectFolder, 267 selectFolder: selectFolder,
256 selectItem: selectItem, 268 selectItem: selectItem,
269 setIncognitoAvailability: setIncognitoAvailability,
257 setSearchResults: setSearchResults, 270 setSearchResults: setSearchResults,
258 setSearchTerm: setSearchTerm, 271 setSearchTerm: setSearchTerm,
259 updateAnchor: updateAnchor, 272 updateAnchor: updateAnchor,
260 }; 273 };
261 }); 274 });
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/md_bookmarks/api_listener.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698