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

Unified Diff: chrome/browser/ui/android/tab_model/tab_model_list.h

Issue 10701030: Refactor SyncedWindowDelegateAndroid into TabModel (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Nit fixes Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/android/tab_model/tab_model_list.h
diff --git a/chrome/browser/ui/android/tab_model/tab_model_list.h b/chrome/browser/ui/android/tab_model/tab_model_list.h
new file mode 100644
index 0000000000000000000000000000000000000000..0d8e0df9ab6910889bae156c1d4af89de7607d25
--- /dev/null
+++ b/chrome/browser/ui/android/tab_model/tab_model_list.h
@@ -0,0 +1,38 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_LIST_H_
+#define CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_LIST_H_
+
+#include <vector>
+
+#include "chrome/browser/sessions/session_id.h"
+
+class Profile;
+class TabModel;
+
+// Stores a list of all TabModel objects.
+class TabModelList {
+ public:
+ typedef std::vector<TabModel*> TabModelVector;
+ typedef TabModelVector::iterator iterator;
+ typedef TabModelVector::const_iterator const_iterator;
+
+ static void AddTabModel(TabModel* tab_model);
+ static void RemoveTabModel(TabModel* tab_model);
+
+ static TabModel* GetTabModelWithProfile(Profile* profile);
+ static TabModel* FindTabModelWithId(SessionID::id_type desired_id);
+ static bool IsOffTheRecordSessionActive();
+
+ static const_iterator begin();
+ static const_iterator end();
+ static bool empty();
+ static size_t size();
+
+ private:
+ DISALLOW_IMPLICIT_CONSTRUCTORS(TabModelList);
+};
+
+#endif // CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_LIST_H_
« no previous file with comments | « chrome/browser/ui/android/tab_model/tab_model.cc ('k') | chrome/browser/ui/android/tab_model/tab_model_list.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698