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

Side by Side Diff: chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.h

Issue 2107603002: Makes the pinned tab title change indicator hide correctly (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: feedback Created 4 years, 5 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/ui/views/tabs/tab.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 (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 #ifndef CHROME_BROWSER_UI_VIEWS_TABS_FAKE_BASE_TAB_STRIP_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_TABS_FAKE_BASE_TAB_STRIP_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_VIEWS_TABS_FAKE_BASE_TAB_STRIP_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_VIEWS_TABS_FAKE_BASE_TAB_STRIP_CONTROLLER_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "chrome/browser/ui/views/tabs/tab_strip_controller.h" 10 #include "chrome/browser/ui/views/tabs/tab_strip_controller.h"
11 #include "ui/base/models/list_selection_model.h" 11 #include "ui/base/models/list_selection_model.h"
12 12
13 class TabStrip; 13 class TabStrip;
14 14
15 class FakeBaseTabStripController : public TabStripController { 15 class FakeBaseTabStripController : public TabStripController {
16 public: 16 public:
17 FakeBaseTabStripController(); 17 FakeBaseTabStripController();
18 ~FakeBaseTabStripController() override; 18 ~FakeBaseTabStripController() override;
19 19
20 void AddTab(int index, bool is_active); 20 void AddTab(int index, bool is_active);
21 void AddPinnedTab(int index, bool is_active); 21 void AddPinnedTab(int index, bool is_active);
22 void RemoveTab(int index); 22 void RemoveTab(int index);
23 23
24 ui::ListSelectionModel* selection_model() { return &selection_model_; }
25
24 void set_tab_strip(TabStrip* tab_strip) { tab_strip_ = tab_strip; } 26 void set_tab_strip(TabStrip* tab_strip) { tab_strip_ = tab_strip; }
25 27
26 // TabStripController overrides: 28 // TabStripController overrides:
27 const ui::ListSelectionModel& GetSelectionModel() const override; 29 const ui::ListSelectionModel& GetSelectionModel() const override;
28 int GetCount() const override; 30 int GetCount() const override;
29 bool IsValidIndex(int index) const override; 31 bool IsValidIndex(int index) const override;
30 bool IsActiveTab(int index) const override; 32 bool IsActiveTab(int index) const override;
31 int GetActiveIndex() const override; 33 int GetActiveIndex() const override;
32 bool IsTabSelected(int index) const override; 34 bool IsTabSelected(int index) const override;
33 bool IsTabPinned(int index) const override; 35 bool IsTabPinned(int index) const override;
(...skipping 25 matching lines...) Expand all
59 61
60 int num_tabs_; 62 int num_tabs_;
61 int active_index_; 63 int active_index_;
62 64
63 ui::ListSelectionModel selection_model_; 65 ui::ListSelectionModel selection_model_;
64 66
65 DISALLOW_COPY_AND_ASSIGN(FakeBaseTabStripController); 67 DISALLOW_COPY_AND_ASSIGN(FakeBaseTabStripController);
66 }; 68 };
67 69
68 #endif // CHROME_BROWSER_UI_VIEWS_TABS_FAKE_BASE_TAB_STRIP_CONTROLLER_H_ 70 #endif // CHROME_BROWSER_UI_VIEWS_TABS_FAKE_BASE_TAB_STRIP_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/tabs/tab.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698