| Index: chrome/browser/sessions/session_id.cc
|
| diff --git a/chrome/browser/sessions/session_id.cc b/chrome/browser/sessions/session_id.cc
|
| index 80f690a83f0197dbf4640348da200dbff3cb7530..a177736c9f83b4786f233ea5e26f346f5176eec9 100644
|
| --- a/chrome/browser/sessions/session_id.cc
|
| +++ b/chrome/browser/sessions/session_id.cc
|
| @@ -13,10 +13,17 @@ SessionID::SessionID() {
|
| id_ = next_id++;
|
| }
|
|
|
| -SessionID::id_type SessionID::IdForTab(const TabContents* tab) {
|
| - return tab ? tab->session_tab_helper()->session_id().id() : -1;
|
| +SessionID::id_type SessionID::IdForTab(const content::WebContents* tab) {
|
| + const TabContents* tab_contents = tab ? TabContents::FromWebContents(tab)
|
| + : NULL;
|
| + return tab_contents ? tab_contents->session_tab_helper()->session_id().id()
|
| + : -1;
|
| }
|
|
|
| -SessionID::id_type SessionID::IdForWindowContainingTab(const TabContents* tab) {
|
| - return tab ? tab->session_tab_helper()->window_id().id() : -1;
|
| +SessionID::id_type SessionID::IdForWindowContainingTab(
|
| + const content::WebContents* tab) {
|
| + const TabContents* tab_contents = tab ? TabContents::FromWebContents(tab)
|
| + : NULL;
|
| + return tab_contents ? tab_contents->session_tab_helper()->window_id().id()
|
| + : -1;
|
| }
|
|
|