Chrome API for recently closed tabs

1,090 views
Skip to first unread message

Hans

unread,
Feb 12, 2013, 3:18:42 PM2/12/13
to chromium-...@chromium.org
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

Benjamin Kalman

unread,
Feb 12, 2013, 3:38:40 PM2/12/13
to Hans, chromium-...@chromium.org
We're actually working on this API right now, a subset is available in dev channel: http://developer.chrome.com/dev/extensions/sessionRestore.html


--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To post to this group, send email to chromium-...@chromium.org.
Visit this group at http://groups.google.com/a/chromium.org/group/chromium-extensions/?hl=en.
For more options, visit https://groups.google.com/a/chromium.org/groups/opt_out.
 
 

Vladyslav Volovyk

unread,
Feb 12, 2013, 3:45:10 PM2/12/13
to chromium-...@chromium.org
Very similar issue with the tabs and windows restored after Chrome restart after crash or because user has enabled the option "continue from where i leave"

There is actually no easy ways to reassociate all of this tabs with older tabIds, as far as know, i investigate this topic a lot.

Vladyslav Volovyk

unread,
Feb 12, 2013, 3:48:24 PM2/12/13
to chromium-...@chromium.org, Hans
Cool! Please also give an ability to reassociate tabs created after Chrome restart after undo or after restore the crashed session with the ids of the tabs/windows which was open in previous session.


On Tuesday, February 12, 2013 10:38:40 PM UTC+2, kalman wrote:
We're actually working on this API right now, a subset is available in dev channel: http://developer.chrome.com/dev/extensions/sessionRestore.html
On Tue, Feb 12, 2013 at 12:18 PM, Hans <hans...@gmail.com> wrote:
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.

Benjamin Kalman

unread,
Feb 12, 2013, 3:48:36 PM2/12/13
to Vladyslav Volovyk, chromium-...@chromium.org
yeah, I'm not sure how easy that would be to do reliably. It's something that would be useful to track in a bug.


--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.

Vladyslav Volovyk

unread,
Feb 12, 2013, 3:51:46 PM2/12/13
to chromium-...@chromium.org, Hans
By the way, please note that it will astonishingly cool to somehow mention all such novations in the What's New page, at least in the dev chanel version of documentation.
Thanks anyway. Best.


On Tuesday, February 12, 2013 10:38:40 PM UTC+2, kalman wrote:
We're actually working on this API right now, a subset is available in dev channel: http://developer.chrome.com/dev/extensions/sessionRestore.html
On Tue, Feb 12, 2013 at 12:18 PM, Hans <hans...@gmail.com> wrote:
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.

Benjamin Kalman

unread,
Feb 12, 2013, 3:54:20 PM2/12/13
to Vladyslav Volovyk, chromium-...@chromium.org, Hans
Noted. The what's new page is updated by hand and sometimes we forget, but we hope to change that soon.


To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.

Vladyslav Volovyk

unread,
Feb 12, 2013, 3:55:40 PM2/12/13
to chromium-...@chromium.org, Vladyslav Volovyk
We just need the field in the tab or the window objects which will just mention the previous Id from the previous life of this tab or window, from the previous Chrome session.
Just that. This will allow to reassociate everything back in the extension which track the sessions.


On Tuesday, February 12, 2013 10:48:36 PM UTC+2, kalman wrote:
yeah, I'm not sure how easy that would be to do reliably. It's something that would be useful to track in a bug.
On Tue, Feb 12, 2013 at 12:45 PM, Vladyslav Volovyk <omn...@gmail.com> wrote:
Very similar issue with the tabs and windows restored after Chrome restart after crash or because user has enabled the option "continue from where i leave"

There is actually no easy ways to reassociate all of this tabs with older tabIds, as far as know, i investigate this topic a lot.



On Tuesday, February 12, 2013 10:18:42 PM UTC+2, Hans wrote:
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.

Vladyslav Volovyk

unread,
Feb 12, 2013, 3:56:29 PM2/12/13
to chromium-...@chromium.org, Vladyslav Volovyk
This is VERY needed feature.

Benjamin Kalman

unread,
Feb 12, 2013, 3:58:34 PM2/12/13
to Vladyslav Volovyk, chromium-...@chromium.org
Cool, file a bug and I'll assign it to the right person.


To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.

Hans

unread,
Feb 12, 2013, 5:22:42 PM2/12/13
to chromium-...@chromium.org, Hans
Nice! Thanks.

Can you add an Event that is triggered when a previously-closed tab is re-opened?


On Tuesday, February 12, 2013 8:38:40 PM UTC, kalman wrote:
We're actually working on this API right now, a subset is available in dev channel: http://developer.chrome.com/dev/extensions/sessionRestore.html
On Tue, Feb 12, 2013 at 12:18 PM, Hans <hans...@gmail.com> wrote:
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.

Benjamin Kalman

unread,
Feb 12, 2013, 5:28:13 PM2/12/13
to Hans, chromium-...@chromium.org
Sounds reasonable, but unless it's tracked in a bug it will be forgotten about.


To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.

Omnray

unread,
Feb 12, 2013, 5:49:09 PM2/12/13
to chromium-...@chromium.org, Hans
I think already existed event for new tabs is sufficient, what we need is just the new field in the tab/window object which will allow us to track it back to the previous instance, just the id will be sufficient i think.
Id is never repeated in same sessions.

Benjamin Kalman

unread,
Feb 12, 2013, 6:01:14 PM2/12/13
to Omnray, chromium-...@chromium.org, Hans
That makes sense.


To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.

Omnray

unread,
Feb 12, 2013, 6:16:23 PM2/12/13
to chromium-...@chromium.org, Omnray, Hans
Well, actually the sessionId and the ability to get current sessionID is also needed, as the tab/window can be restored after several Chrome restarts.
As session-id the time-stamp of the restart will be well sufficient i think. Maybe it is already somehow possible to obtain this time-stamp.

...yeh, need file a feature request, just wait that maybe some other will do this  ; )


On Wednesday, February 13, 2013 1:01:14 AM UTC+2, kalman wrote:
That makes sense.


On Tue, Feb 12, 2013 at 2:49 PM, Omnray <omn...@gmail.com> wrote:
I think already existed event for new tabs is sufficient, what we need is just the new field in the tab/window object which will allow us to track it back to the previous instance, just the id will be sufficient i think.
Id is never repeated in same sessions.

On Wednesday, February 13, 2013 12:22:42 AM UTC+2, Hans wrote:
Nice! Thanks.

Can you add an Event that is triggered when a previously-closed tab is re-opened?


On Tuesday, February 12, 2013 8:38:40 PM UTC, kalman wrote:
We're actually working on this API right now, a subset is available in dev channel: http://developer.chrome.com/dev/extensions/sessionRestore.html
On Tue, Feb 12, 2013 at 12:18 PM, Hans <hans...@gmail.com> wrote:
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsubscribe...@chromium.org.

Omnray

unread,
Feb 12, 2013, 6:18:14 PM2/12/13
to chromium-...@chromium.org, Omnray, Hans
But even the partial solution without sessionId will be a huge step forward. 

Hans Meyer

unread,
Feb 13, 2013, 2:06:11 AM2/13/13
to Omnray, chromium-...@chromium.org
Good point about reusing the tab Created event, Omnray (as long as it includes a way to qualify the session in addition to the prev id, as you've subsequently pointed out)

Hans

unread,
Feb 13, 2013, 11:22:33 AM2/13/13
to chromium-...@chromium.org, Vladyslav Volovyk
Benjamin, can you post the link to bug reporting in this thread. I want to make sure I'm filing the bug in the right place.

Thanks,
Hans


On Tuesday, February 12, 2013 8:58:34 PM UTC, kalman wrote:
Cool, file a bug and I'll assign it to the right person.
On Tue, Feb 12, 2013 at 12:56 PM, Vladyslav Volovyk <omn...@gmail.com> wrote:
This is VERY needed feature.


On Tuesday, February 12, 2013 10:55:40 PM UTC+2, Vladyslav Volovyk wrote:
We just need the field in the tab or the window objects which will just mention the previous Id from the previous life of this tab or window, from the previous Chrome session.
Just that. This will allow to reassociate everything back in the extension which track the sessions.

On Tuesday, February 12, 2013 10:48:36 PM UTC+2, kalman wrote:
yeah, I'm not sure how easy that would be to do reliably. It's something that would be useful to track in a bug.
On Tue, Feb 12, 2013 at 12:45 PM, Vladyslav Volovyk <omn...@gmail.com> wrote:
Very similar issue with the tabs and windows restored after Chrome restart after crash or because user has enabled the option "continue from where i leave"

There is actually no easy ways to reassociate all of this tabs with older tabIds, as far as know, i investigate this topic a lot.



On Tuesday, February 12, 2013 10:18:42 PM UTC+2, Hans wrote:
Are recently-closed tabs surfaced in any manner in the Chrome API? I didn't find any references to such.

Fundamentally, I want to be able to either a) identify a freshly-created tab as a tab that was created as a direct result of the user requesting to reopen a recently closed tab or b) associate a created tab to a manually-maintained list of tabs that have been closed during the browser session. One issue that complicates this is that recently-closed tabs are regenerated (eg, on ctrl+shift+T) with a new tabId.

Any ideas?

Thanks,
Hans Meyer

--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsubscribe...@chromium.org.

Benjamin Kalman

unread,
Feb 13, 2013, 11:26:06 AM2/13/13
to Hans, chromium-...@chromium.org, Vladyslav Volovyk
Sure, go to https://code.google.com/p/chromium/issues and click New Issue, that will bring up a wizard.

Alternatively just go to http://crbug.com/new to get the non-wizard interface.


To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.

Hans

unread,
Feb 13, 2013, 12:22:52 PM2/13/13
to chromium-...@chromium.org, Hans, Vladyslav Volovyk
Thanks. Here is the bug I filed as per above discussion:


Let me know if I did any of this incorrectly. The process felt a bit klunky :)

Hans

Benjamin Kalman

unread,
Feb 13, 2013, 12:25:49 PM2/13/13
to Hans, chromium-...@chromium.org, Vladyslav Volovyk
Thanks.


To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
Reply all
Reply to author
Forward
0 new messages