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

Unified Diff: chrome/browser/task_management/task_manager_interface.h

Issue 2146273002: TaskManager: when shown or activated, select the last active tab. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@triple_click_tm
Patch Set: Fix compile. 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/task_management/task_manager_interface.h
diff --git a/chrome/browser/task_management/task_manager_interface.h b/chrome/browser/task_management/task_manager_interface.h
index e021bd6f7bfb0092a6fe09ea8366bf37ba3e0f5e..9b62f0ba7aad3005e412f43cab816baaa239c3c1 100644
--- a/chrome/browser/task_management/task_manager_interface.h
+++ b/chrome/browser/task_management/task_manager_interface.h
@@ -24,6 +24,10 @@
class PrefRegistrySimple;
+namespace content {
+class WebContents;
+} // namespace content
+
namespace net {
class URLRequest;
} // namespace net
@@ -205,6 +209,12 @@ class TaskManagerInterface {
// the Task with |task_id| is running.
virtual size_t GetNumberOfTasksOnSameProcess(TaskId task_id) const = 0;
+ // Returns the TaskId associated with the main task for |web_contents|.
+ // Returns -1 if |web_contents| is nullptr or does not currently have an
+ // associated Task.
+ virtual TaskId GetTaskIdForWebContents(
+ content::WebContents* web_contents) const = 0;
+
// Returns true if the resource |type| usage calculation is enabled and
// the implementation should refresh its value (this means that at least one
// of the observers require this value). False otherwise.
« no previous file with comments | « chrome/browser/task_management/sampling/task_manager_impl.cc ('k') | chrome/browser/task_management/test_task_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698