diff options
author | Patrick Scott <phanna@android.com> | 2009-07-14 10:49:22 -0400 |
---|---|---|
committer | Patrick Scott <phanna@android.com> | 2009-07-14 10:53:30 -0400 |
commit | b0e4fc7b8efc66b20cf83a8d5f8dc9110d67da4f (patch) | |
tree | 710f62ce2b9875648e62d0e9d1771bf400c9c3f3 /src/com/android/browser/TabControl.java | |
parent | 14ab4478b0805629686a33a14621a5e68692f6d3 (diff) | |
download | packages_apps_Browser-b0e4fc7b8efc66b20cf83a8d5f8dc9110d67da4f.zip packages_apps_Browser-b0e4fc7b8efc66b20cf83a8d5f8dc9110d67da4f.tar.gz packages_apps_Browser-b0e4fc7b8efc66b20cf83a8d5f8dc9110d67da4f.tar.bz2 |
Show the new tab when creating it from the bookmarks/history.
When we are in the tab picker and a new tab is created from bookmarks/history,
show the new tab in the picker and then animate to it. Only do this for the
"open tabs in background" setting since openTab() will show the tab if that
setting is false.
We animate to the new tab because we currently don't have a way to show the new
tab in the tab picker with updated picker data (title and url in particular).
So instead of showing a blank tab, animate to the tab. Once the animations have
been redesigned and the code refactored, this will hopefully get better.
Diffstat (limited to 'src/com/android/browser/TabControl.java')
-rw-r--r-- | src/com/android/browser/TabControl.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/com/android/browser/TabControl.java b/src/com/android/browser/TabControl.java index bdb57fa..274598a 100644 --- a/src/com/android/browser/TabControl.java +++ b/src/com/android/browser/TabControl.java @@ -1066,6 +1066,11 @@ class TabControl { data.mScale = w.getScale(); data.mScrollX = w.getScrollX(); data.mScrollY = w.getScrollY(); + + // Remember the old picture if possible. + if (t.mPickerData != null) { + data.mPicture = t.mPickerData.mPicture; + } t.mPickerData = data; } |