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

Side by Side Diff: ash/shelf/shelf_navigator.cc

Issue 2095193002: clang-format all of //ash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 | « ash/shelf/shelf_layout_manager_unittest.cc ('k') | ash/shelf/shelf_navigator_unittest.cc » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "ash/shelf/shelf_navigator.h" 5 #include "ash/shelf/shelf_navigator.h"
6 6
7 #include "ash/common/shelf/shelf_model.h" 7 #include "ash/common/shelf/shelf_model.h"
8 8
9 namespace ash { 9 namespace ash {
10 10
11 namespace { 11 namespace {
12 12
13 // Returns true if accelerator processing should skip the shelf item with the 13 // Returns true if accelerator processing should skip the shelf item with the
14 // specified type. 14 // specified type.
15 bool ShouldSkip(ShelfItemType type) { 15 bool ShouldSkip(ShelfItemType type) {
16 return type == TYPE_APP_LIST || 16 return type == TYPE_APP_LIST || type == TYPE_BROWSER_SHORTCUT ||
17 type == TYPE_BROWSER_SHORTCUT || 17 type == TYPE_APP_SHORTCUT || type == TYPE_WINDOWED_APP;
18 type == TYPE_APP_SHORTCUT ||
19 type == TYPE_WINDOWED_APP;
20 } 18 }
21 19
22 } // namespace 20 } // namespace
23 21
24 int GetNextActivatedItemIndex(const ShelfModel& model, 22 int GetNextActivatedItemIndex(const ShelfModel& model,
25 CycleDirection direction) { 23 CycleDirection direction) {
26 const ShelfItems& items = model.items(); 24 const ShelfItems& items = model.items();
27 int item_count = model.item_count(); 25 int item_count = model.item_count();
28 int current_index = -1; 26 int current_index = -1;
29 int first_running = -1; 27 int first_running = -1;
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 if (item.status == STATUS_ACTIVE) 61 if (item.status == STATUS_ACTIVE)
64 continue; 62 continue;
65 63
66 return i; 64 return i;
67 } 65 }
68 66
69 return -1; 67 return -1;
70 } 68 }
71 69
72 } // namespace ash 70 } // namespace ash
OLDNEW
« no previous file with comments | « ash/shelf/shelf_layout_manager_unittest.cc ('k') | ash/shelf/shelf_navigator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698