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

Unified Diff: chrome/browser/sessions/session_utils.h

Issue 7931027: Refactoring recently closed tab filtering (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Long live the STL Created 9 years, 3 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/sessions/session_utils.h
diff --git a/chrome/browser/sessions/session_utils.h b/chrome/browser/sessions/session_utils.h
new file mode 100644
index 0000000000000000000000000000000000000000..c148487e8d56e29073aa9808050e2726a65fc424
--- /dev/null
+++ b/chrome/browser/sessions/session_utils.h
@@ -0,0 +1,26 @@
+// Copyright (c) 2011 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_SESSIONS_SESSION_UTILS_H_
+#define CHROME_BROWSER_SESSIONS_SESSION_UTILS_H_
+#pragma once
+
+#include "chrome/browser/sessions/tab_restore_service.h"
+
+class SessionUtils {
+ public:
+ // Fill the passed list from the entries passed as argument filtering out the
+ // ones with the same title and URL as a previous entry. This avoid filling
+ // the list with things that look like duplicates.
+ //
+ // The |filtering_entries| returned are simply references to the one passed in
+ // without copy: There is no transfer of ownership.
+ static void FilteredEntries(const TabRestoreService::Entries& entries,
+ TabRestoreService::Entries* filtered_entries);
+
+ private:
+ DISALLOW_IMPLICIT_CONSTRUCTORS(SessionUtils);
+};
+
+#endif // CHROME_BROWSER_SESSIONS_SESSION_UTILS_H_
« no previous file with comments | « chrome/browser/automation/automation_provider_observers.cc ('k') | chrome/browser/sessions/session_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698