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

Unified Diff: ui/file_manager/file_manager/foreground/js/ui/list_container.js

Issue 1408533002: Turn on verbose flag for compiling file_manager. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added verbose option for foregrounds. Created 5 years, 2 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: ui/file_manager/file_manager/foreground/js/ui/list_container.js
diff --git a/ui/file_manager/file_manager/foreground/js/ui/list_container.js b/ui/file_manager/file_manager/foreground/js/ui/list_container.js
index 9d7fb65c4d0d4ad0d5b857b0ae98f64c1170eaaa..c5a4292a73069783abdfcc67c9d6208a7e7509b7 100644
--- a/ui/file_manager/file_manager/foreground/js/ui/list_container.js
+++ b/ui/file_manager/file_manager/foreground/js/ui/list_container.js
@@ -154,26 +154,18 @@ ListContainer.prototype = /** @struct */ {
* @return {!FileTable|!FileGrid}
*/
get currentView() {
- switch (this.currentListType) {
- case ListContainer.ListType.DETAIL:
- return this.table;
- case ListContainer.ListType.THUMBNAIL:
- return this.grid;
- }
- assertNotReached();
+ assert(this.currentListType !== ListContainer.ListType.UNINITIALIZED);
+ return this.currentListType === ListContainer.ListType.DETAIL ?
+ this.table : this.grid;
},
/**
* @return {!cr.ui.List}
*/
get currentList() {
- switch (this.currentListType) {
- case ListContainer.ListType.DETAIL:
- return this.table.list;
- case ListContainer.ListType.THUMBNAIL:
- return this.grid;
- }
- assertNotReached();
+ assert(this.currentListType !== ListContainer.ListType.UNINITIALIZED);
+ return this.currentListType === ListContainer.ListType.DETAIL ?
+ this.table.list : this.grid;
}
};

Powered by Google App Engine
This is Rietveld 408576698