Fragment animation as in Honeycomb Gmail app - how to do that?

by Scythe » Fri, 20 May 2011 00:14:57 GMT


Sponsored Links
 I'd like to achieve similar fragment behaviour as in the Honeycomb
Gmail app. So I have three fragment next to each other: A, B and C.
Initially, A and B is displayed, and when the user selects something
from B, it triggers an sliding-animation/fragment-transaction so that
B and C are visible. B showing the selected item, C showing the
desired content.

Any ideas how the Gmail app does this?

-- 



Re: Fragment animation as in Honeycomb Gmail app - how to do that?

by Ed Burnette » Fri, 20 May 2011 02:33:46 GMT


 There's probably using FragmentTransaction.setTransition() or
setCustomAnimations().




-- 


Sponsored Links


Other Threads

1. How to handle tall dialogs

Hi group.

I have a standard dialog with a headline, a label, a text field,
another label and a DatePicker. They are laid out using a vertical
LinearLayout. When the user slides the keyboard open, the dialog is
rotated. Now, the dialog does no longer fit on the screen, it is to
tall. ...DatePicker has some height... :-)

I wonder what is the preferred way to handle this. I need to do
something, as the DatePicker is not fully visiable. One solution
surely is to put the LinearLayout inside a ScrollView. Do you have
further suggestions?

Thank you very much in advance.

Regards
Thomas

--~--~---------~--~----~------------~-------~--~----~

2. TabWidget problem

Hi,
I have implemented a tabWidget layout but when I launch it, I obtain those
errors :

ActivityManager: Warning: Activity not started, its current task has been
brought to the front
java.lang.NullPointerException
    at android.widget.TabWidget.dispatchDraw(TabWidget.java:105)
    at android.view.ViewGroup.drawChild(ViewGroup.java:1434)
    at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1208)
    at android.view.ViewGroup.drawChild(ViewGroup.java:1434)
    at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1208)
    at android.view.ViewGroup.drawChild(ViewGroup.java:1434)
    at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1208)
    at android.view.View.draw(View.java:5465)
    at android.widget.FrameLayout.draw(FrameLayout.java:324)
    at com.android.layoutlib.bridge.Bridge.computeLayout(Bridge.java:338)
    at
com.android.ide.eclipse.editors.layout.GraphicalLayoutEditor.computeLayout(Unknown
Source)
    at
com.android.ide.eclipse.editors.layout.GraphicalLayoutEditor.recomputeLayout(Unknown
Source)
    at
com.android.ide.eclipse.editors.layout.GraphicalLayoutEditor.activated(Unknown
Source)
    at
com.android.ide.eclipse.editors.layout.LayoutEditor.pageChange(Unknown
Source)
    at
org.eclipse.ui.part.MultiPageEditorPart.setActivePage(MultiPageEditorPart.java:973)
    at
org.eclipse.ui.forms.editor.FormEditor.setActivePage(FormEditor.java:627)
    at
org.eclipse.ui.part.MultiPageEditorPart.createPartControl(MultiPageEditorPart.java:314)
    at
org.eclipse.ui.internal.EditorReference.createPartHelper(EditorReference.java:661)
    at
org.eclipse.ui.internal.EditorReference.createPart(EditorReference.java:428)
    at
org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:594)
    at
org.eclipse.ui.internal.EditorReference.getEditor(EditorReference.java:266)
    at
org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched(WorkbenchPage.java:2820)
    at
org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:2729)
    at
org.eclipse.ui.internal.WorkbenchPage.access$11(WorkbenchPage.java:2721)
    at org.eclipse.ui.internal.WorkbenchPage$10.run(WorkbenchPage.java:2673)
    at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
    at
org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2668)
    at
org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2652)
    at
org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2643)
    at org.eclipse.ui.ide.IDE.openEditor(IDE.java:646)
    at org.eclipse.ui.ide.IDE.openEditor(IDE.java:605)
    at
org.eclipse.jdt.internal.ui.javaeditor.EditorUtility.openInEditor(EditorUtility.java:318)
    at
org.eclipse.jdt.internal.ui.javaeditor.EditorUtility.openInEditor(EditorUtility.java:160)
    at org.eclipse.jdt.ui.actions.OpenAction.run(OpenAction.java:228)
    at org.eclipse.jdt.ui.actions.OpenAction.run(OpenAction.java:207)
    at
org.eclipse.jdt.ui.actions.SelectionDispatchAction.dispatchRun(SelectionDispatchAction.java:274)
    at
org.eclipse.jdt.ui.actions.SelectionDispatchAction.run(SelectionDispatchAction.java:250)
    at
org.eclipse.jdt.internal.ui.packageview.PackageExplorerActionGroup.handleOpen(PackageExplorerActionGroup.java:363)
    at
org.eclipse.jdt.internal.ui.packageview.PackageExplorerPart$5.open(PackageExplorerPart.java:603)
    at
org.eclipse.jface.viewers.StructuredViewer$2.run(StructuredViewer.java:820)
    at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
    at org.eclipse.core.runtime.Platform.run(Platform.java:880)
    at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:48)
    at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:175)
    at
org.eclipse.jface.viewers.StructuredViewer.fireOpen(StructuredViewer.java:818)
    at
org.eclipse.jface.viewers.StructuredViewer.handleOpen(StructuredViewer.java:1079)
    at
org.eclipse.jface.viewers.StructuredViewer$6.handleOpen(StructuredViewer.java:1183)
    at
org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrategy.java:263)
    at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.java:257)
    at
org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrategy.java:297)
    at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
    at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3823)
    at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3422)
    at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2384)
    at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2348)
    at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2200)
    at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:495)
    at
org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:288)
    at
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:490)
    at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
    at
org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:113)
    at
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:193)
    at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
    at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
    at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:386)
    at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)
    at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
    at org.eclipse.equinox.launcher.Main.run(Main.java:1236)

I don't know what is wrong with tabWidget?!
Thanks for your help.
Michal

--~--~---------~--~----~------------~-------~--~----~

3. Drawing on the incoming call screen

4. android emulator window hangs when closing window

5. Geo command

6. import an existing project

7. Running Android applications on Linux