SharedElementCallback.OnCreateSnapshotView(Context, IParcelable) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Reconstitutes a snapshot View from a Parcelable returned in onCaptureSharedElementSnapshot(android.view.View, android.graphics.Matrix, android.graphics.RectF) to be used in onSharedElementStart(java.util.List, java.util.List, java.util.List) and onSharedElementEnd(java.util.List, java.util.List, java.util.List).
[Android.Runtime.Register("onCreateSnapshotView", "(Landroid/content/Context;Landroid/os/Parcelable;)Landroid/view/View;", "GetOnCreateSnapshotView_Landroid_content_Context_Landroid_os_Parcelable_Handler")]
public virtual Android.Views.View? OnCreateSnapshotView(Android.Content.Context? context, Android.OS.IParcelable? snapshot);
[<Android.Runtime.Register("onCreateSnapshotView", "(Landroid/content/Context;Landroid/os/Parcelable;)Landroid/view/View;", "GetOnCreateSnapshotView_Landroid_content_Context_Landroid_os_Parcelable_Handler")>]
abstract member OnCreateSnapshotView : Android.Content.Context * Android.OS.IParcelable -> Android.Views.View
override this.OnCreateSnapshotView : Android.Content.Context * Android.OS.IParcelable -> Android.Views.View
Parameters
- context
- Context
Context: The Context used to create the snapshot View.
- snapshot
- IParcelable
Parcelable: The Parcelable returned by onCaptureSharedElementSnapshot(android.view.View, android.graphics.Matrix, android.graphics.RectF).
Returns
A View to be sent in onSharedElementStart(java.util.List, java.util.List, java.util.List) and onSharedElementEnd(java.util.List, java.util.List, java.util.List). A null value will produce a null snapshot value for those two methods.
- Attributes
Remarks
Reconstitutes a snapshot View from a Parcelable returned in onCaptureSharedElementSnapshot(android.view.View, android.graphics.Matrix, android.graphics.RectF) to be used in onSharedElementStart(java.util.List, java.util.List, java.util.List) and onSharedElementEnd(java.util.List, java.util.List, java.util.List). The returned View will be sized and positioned after this call so that it is ready to be added to the decor View's overlay. This is not called for Fragment Transitions.
Android reference for android.app.SharedElementCallback.onCreateSnapshotView.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.