1

I've read this question and watch the video clip from Bitspin, however I'm still unable to figure out the techtique they used on ActionBar.

You can observe the ActionBar layout transition inside Timely, when navigating from the settings Fragment to the about Fragment (and navigating back), the up caret and the title is animated by zooming and fading. So how is this made possible?

Settings

Or can you let me know if there is some techtique on crossfading ActionBar layout changes? My main purpose is to smooth the transition when user opens the navigational drawer and the title changes, aciton buttons disappears.

Thanks in advance.

EDIT:

I turned on the dev options for showing layout borders and found that Timely is using custom layouts to achieve this. However this is not possible for other applications heavily relying on other ActionBar features such as ActionMenu.

So are there any alternative ways to achieve layout transitions on ActionBar and its ActionMenus?

Community
  • 1
  • 1
Hai Zhang
  • 5,574
  • 1
  • 44
  • 51
  • They put a lot of work into Timely to make it look so good. I don't know how they did it, but I think you can reproduce the effect by animating the `View` which makes up `ActionBar`. Fading and scaling it while a new dummy `View` slides in its place. – Xaver Kapeller Jun 02 '14 at 04:41
  • @XaverKapeller Thanks for the information. I had layout borders shown in my dev options, and I found that Timely is having two separate views for animation. It could be a custom layout, or maybe they are not using ActionBar at all. So it becomes impossible for applications with ActionMenus or other widgets to achieve this simply. However, I still wonder if I can achieve this effect natively. – Hai Zhang Jun 02 '14 at 05:10
  • I've been thinking about it and a custom view is probably the simplest solution. Anything else becomes complicated very quickly, especially when you want your app to run on Gingerbread or before. If I find the time today I will write an answer with an example. – Xaver Kapeller Jun 02 '14 at 06:51

0 Answers0