diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-01-15 00:59:16 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-01-15 00:59:16 +0000 |
commit | f3ec774a2c177d3c6845553d3bf9735a7b8a5907 (patch) | |
tree | ed09ccf69300383bd4b2e8ac7c8b9d1bdeead07b /chrome/browser/tab_contents/tab_util.h | |
parent | bb515eda39129537a089a062c3db3152e63f24d9 (diff) | |
download | chromium_src-f3ec774a2c177d3c6845553d3bf9735a7b8a5907.zip chromium_src-f3ec774a2c177d3c6845553d3bf9735a7b8a5907.tar.gz chromium_src-f3ec774a2c177d3c6845553d3bf9735a7b8a5907.tar.bz2 |
Move a bunch of TabContents related files into a tab_contents subdir
Review URL: http://codereview.chromium.org/18250
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8058 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/tab_contents/tab_util.h')
-rw-r--r-- | chrome/browser/tab_contents/tab_util.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/chrome/browser/tab_contents/tab_util.h b/chrome/browser/tab_contents/tab_util.h new file mode 100644 index 0000000..6aa96f3 --- /dev/null +++ b/chrome/browser/tab_contents/tab_util.h @@ -0,0 +1,26 @@ +// Copyright (c) 2006-2008 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_TAB_UTIL_H__ +#define CHROME_BROWSER_TAB_UTIL_H__ + +class URLRequest; +class WebContents; + +namespace tab_util { + +// Helper to get the IDs necessary for looking up a TabContents. +// Should only be called from the IO thread, since it accesses an URLRequest. +bool GetTabContentsID(URLRequest* request, int* render_process_host_id, + int* routing_id); + +// Helper to find the WebContents that originated the given request. Can be +// NULL if the tab has been closed or some other error occurs. +// Should only be called from the UI thread, since it accesses TabContent. +WebContents* GetWebContentsByID(int render_process_host_id, int routing_id); + +} // namespace tab_util + +#endif // CHROME_BROWSER_TAB_UTIL_H__ + |