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

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

Issue 107163005: [ash] Add TYPE_DIALOG and its item's LauncherContextMenu (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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 #include "ash/shelf/shelf_view.h" 5 #include "ash/shelf/shelf_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/ash_switches.h" 10 #include "ash/ash_switches.h"
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 virtual void UnpinAppWithID(const std::string& app_id) OVERRIDE { 240 virtual void UnpinAppWithID(const std::string& app_id) OVERRIDE {
241 LauncherID id = 0; 241 LauncherID id = 0;
242 EXPECT_TRUE(base::StringToInt(app_id, &id)); 242 EXPECT_TRUE(base::StringToInt(app_id, &id));
243 ASSERT_GT(id, 0); 243 ASSERT_GT(id, 0);
244 int index = model_->ItemIndexByID(id); 244 int index = model_->ItemIndexByID(id);
245 ASSERT_GE(index, 0); 245 ASSERT_GE(index, 0);
246 246
247 model_->RemoveItemAt(index); 247 model_->RemoveItemAt(index);
248 } 248 }
249 249
250 virtual bool CanUserModifyShelfAutoHideBehavior(
251 aura::Window* root_window) const OVERRIDE {
252 return true;
253 }
254
250 private: 255 private:
251 ShelfModel* model_; 256 ShelfModel* model_;
252 257
253 // Temp member variable for returning a value. See the comment in the 258 // Temp member variable for returning a value. See the comment in the
254 // GetAppIDForLauncherID(). 259 // GetAppIDForLauncherID().
255 std::string app_id_; 260 std::string app_id_;
256 261
257 DISALLOW_COPY_AND_ASSIGN(TestShelfDelegateForShelfView); 262 DISALLOW_COPY_AND_ASSIGN(TestShelfDelegateForShelfView);
258 }; 263 };
259 264
(...skipping 1471 matching lines...) Expand 10 before | Expand all | Expand 10 after
1731 test_api_->RunMessageLoopUntilAnimationsDone(); 1736 test_api_->RunMessageLoopUntilAnimationsDone();
1732 CheckAllItemsAreInBounds(); 1737 CheckAllItemsAreInBounds();
1733 } 1738 }
1734 1739
1735 INSTANTIATE_TEST_CASE_P(LtrRtl, ShelfViewTextDirectionTest, testing::Bool()); 1740 INSTANTIATE_TEST_CASE_P(LtrRtl, ShelfViewTextDirectionTest, testing::Bool());
1736 INSTANTIATE_TEST_CASE_P(VisibleBounds, ShelfViewVisibleBoundsTest, 1741 INSTANTIATE_TEST_CASE_P(VisibleBounds, ShelfViewVisibleBoundsTest,
1737 testing::Bool()); 1742 testing::Bool());
1738 1743
1739 } // namespace test 1744 } // namespace test
1740 } // namespace ash 1745 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698