Skip to content

Commit ad05eed

Browse files
Document Android.Window APIs (#554)
* Document Android.Window APIs Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Restrict Android.Window docs to source-backed APIs Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Correct Android.Window callback docs Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: ce92d4c9-4603-4d9d-9d0f-9b92d4314552 * Correct Android.Window contract docs Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: ce92d4c9-4603-4d9d-9d0f-9b92d4314552 * Clarify Android.Window completion contracts Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: ce92d4c9-4603-4d9d-9d0f-9b92d4314552 --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: ce92d4c9-4603-4d9d-9d0f-9b92d4314552
1 parent 52a9b8b commit ad05eed

7 files changed

Lines changed: 56 additions & 50 deletions

docs/xml/Android.Window/InputTransferToken.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,8 @@
123123
</ReturnValue>
124124
<Parameters />
125125
<Docs>
126-
<summary>To be added.</summary>
127-
<returns>To be added.</returns>
126+
<summary>Describes the special objects in this token's marshaled representation.</summary>
127+
<returns>A bitmask of special object types in the marshaled representation.</returns>
128128
<remarks>
129129
<para>
130130
<format type="text/html">
@@ -267,9 +267,9 @@
267267
</Parameter>
268268
</Parameters>
269269
<Docs>
270-
<param name="dest">To be added.</param>
271-
<param name="flags">To be added.</param>
272-
<summary>To be added.</summary>
270+
<param name="dest">The parcel that receives the token.</param>
271+
<param name="flags">Additional flags describing how the token is written.</param>
272+
<summary>Flattens this token into a parcel.</summary>
273273
<remarks>
274274
<para>
275275
<format type="text/html">

docs/xml/Android.Window/SplashScreenStyle.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
<BaseTypeName>System.Enum</BaseTypeName>
1212
</Base>
1313
<Docs>
14-
<summary>To be added.</summary>
15-
<remarks>To be added.</remarks>
14+
<summary>Specifies the visual style of a launched activity's splash screen.</summary>
15+
<remarks>Use these values with the splash screen style APIs on <c>ActivityOptions</c>.</remarks>
1616
</Docs>
1717
<Members>
1818
<Member MemberName="Icon">
@@ -40,7 +40,7 @@
4040
</ReturnValue>
4141
<MemberValue>1</MemberValue>
4242
<Docs>
43-
<summary>To be added.</summary>
43+
<summary>Shows the launched activity's splash screen icon.</summary>
4444
</Docs>
4545
</Member>
4646
<Member MemberName="SolidColor">
@@ -68,7 +68,7 @@
6868
</ReturnValue>
6969
<MemberValue>0</MemberValue>
7070
<Docs>
71-
<summary>To be added.</summary>
71+
<summary>Uses a solid-color splash screen without showing the launched activity's icon.</summary>
7272
</Docs>
7373
</Member>
7474
</Members>

docs/xml/Android.Window/SplashScreenView.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676
</ReturnValue>
7777
<Docs>
7878
<summary>Returns the duration of the icon animation if icon is animatable.</summary>
79-
<value>To be added.</value>
79+
<value>The icon animation duration, or <see langword="null" /> or a non-null zero duration when the icon is not animatable.</value>
8080
<remarks>
8181
<para>Returns the duration of the icon animation if icon is animatable.
8282

@@ -122,7 +122,7 @@
122122
</ReturnValue>
123123
<Docs>
124124
<summary>If the replaced icon is animatable, return the animation start time based on system clock.</summary>
125-
<value>To be added.</value>
125+
<value>The icon animation start time, or <see langword="null" /> when no animatable icon is available.</value>
126126
<remarks>
127127
<para>If the replaced icon is animatable, return the animation start time based on system clock.</para>
128128
<para>
@@ -163,7 +163,7 @@
163163
</ReturnValue>
164164
<Docs>
165165
<summary>Get the view containing the Splash Screen icon and its background.</summary>
166-
<value>To be added.</value>
166+
<value>The view containing the splash screen icon and its background, or <see langword="null" /> when no icon view exists.</value>
167167
<remarks>
168168
<para>Get the view containing the Splash Screen icon and its background.</para>
169169
<para>

docs/xml/Android.Window/SurfaceSyncGroup.xml

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,9 @@
120120
<Docs>
121121
<param name="attachedSurfaceControl">The AttachedSurfaceControl that will be add to this
122122
SurfaceSyncGroup.</param>
123-
<param name="runnable">This is run on the same thread that the call was made on, but
124-
after the rendering is paused and before continuing to render
125-
the next frame. This method will not return until the
126-
execution of the runnable completes. This can be used to make
127-
changes to the AttachedSurfaceControl, ensuring that the
128-
changes are included in the sync.</param>
123+
<param name="runnable">Runs synchronously on the calling thread after rendering is paused
124+
and before the next frame is rendered. This method blocks until the runnable completes.
125+
Use it to make changes to the AttachedSurfaceControl that are included in the sync.</param>
129126
<summary>Add an AttachedSurfaceControl to the SurfaceSyncGroup.</summary>
130127
<returns>true if the AttachedSurfaceControl was successfully added to the SurfaceSyncGroup,
131128
false otherwise.</returns>
@@ -181,11 +178,14 @@
181178
</Parameter>
182179
</Parameters>
183180
<Docs>
184-
<param name="surfacePackage">To be added.</param>
185-
<param name="runnable">To be added.</param>
186-
<summary>To be added.</summary>
187-
<returns>To be added.</returns>
188-
<remarks>To be added.</remarks>
181+
<param name="surfacePackage">The surface package to add to this synchronization group.</param>
182+
<param name="runnable">An optional operation that runs synchronously on the calling thread
183+
after rendering is paused and before the next frame is rendered. This method blocks
184+
until the operation completes, allowing its changes to the hosted surface to be
185+
included in the sync.</param>
186+
<summary>Adds a surface package to this synchronization group.</summary>
187+
<returns><see langword="true" /> if the surface package was added; otherwise, <see langword="false" />.</returns>
188+
<remarks>Rendering is paused while the optional operation executes so its changes can be included in the synchronized frame.</remarks>
189189
</Docs>
190190
</Member>
191191
<Member MemberName="AddTransaction">
@@ -215,9 +215,14 @@
215215
<Parameter Name="transaction" Type="Android.Views.SurfaceControl+Transaction" />
216216
</Parameters>
217217
<Docs>
218-
<param name="transaction">To be added.</param>
219-
<summary>To be added.</summary>
220-
<remarks>To be added.</remarks>
218+
<param name="transaction">The transaction to synchronize with the group's other
219+
transactions while the group is active. If the group has completed, the transaction
220+
is applied immediately.</param>
221+
<summary>Adds a transaction to an active synchronization group; applies it immediately
222+
when the group has completed.</summary>
223+
<remarks>The transaction is synchronized with the group's other transactions only while
224+
the group is active. Once the group has completed, Android applies the transaction
225+
immediately.</remarks>
221226
</Docs>
222227
</Member>
223228
<Member MemberName="JniPeerMembers">

docs/xml/Android.Window/SystemOnBackInvokedCallbacks.xml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,10 @@
8181
</Parameters>
8282
<Docs>
8383
<param name="activity">The associated <c>Activity</c></param>
84-
<summary>Get a callback to triggers <c>Activity#finishAndRemoveTask()</c> on the associated
85-
<c>Activity</c>.</summary>
86-
<returns>To be added.</returns>
84+
<summary>Get a callback that finishes the associated <c>Activity</c>, removing its task from
85+
Recents when the activity is the task root.</summary>
86+
<returns>A callback that finishes the activity when back is invoked and removes its task from
87+
Recents only when the activity is the task root.</returns>
8788
<remarks>
8889
<para>Get a callback to triggers <c>Activity#finishAndRemoveTask()</c> on the associated
8990
<c>Activity</c>. If the activity is the root activity of its task, the entire task
@@ -161,7 +162,7 @@
161162
<param name="activity">The associated <c>Activity</c></param>
162163
<summary>Get a callback to triggers <c>Activity#moveTaskToBack(boolean)</c> on the associated
163164
<c>Activity</c>, moving the task containing the activity to the background.</summary>
164-
<returns>To be added.</returns>
165+
<returns>A callback that moves the activity's task to the background when back is invoked.</returns>
165166
<remarks>
166167
<para>Get a callback to triggers <c>Activity#moveTaskToBack(boolean)</c> on the associated
167168
<c>Activity</c>, moving the task containing the activity to the background. The system

docs/xml/Android.Window/TrustedPresentationThresholds.xml

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -85,14 +85,14 @@
8585
<Parameter Name="stabilityRequirementMs" Type="System.Int32" />
8686
</Parameters>
8787
<Docs>
88-
<param name="minAlpha">The min alpha the Window is required to
89-
have to be considered inside the
90-
threshold.</param>
91-
<param name="minFractionRendered">The min fraction of the Window that was presented
92-
to the user to be considered
93-
inside the threshold.</param>
94-
<param name="stabilityRequirementMs">The time in milliseconds required for the
95-
Window to be in the threshold.</param>
88+
<param name="minAlpha">The minimum alpha the Window must have to be considered inside the
89+
threshold. Must be greater than 0.0 and no greater than 1.0.</param>
90+
<param name="minFractionRendered">The minimum fraction of the Window presented to the
91+
user to be considered inside the threshold. Must be greater than 0.0 and no greater
92+
than 1.0.</param>
93+
<param name="stabilityRequirementMs">The time in milliseconds required for the Window to
94+
be in the threshold. Must be at least 1 millisecond; zero or negative values cause
95+
this constructor to throw <c>IllegalArgumentException</c>.</param>
9696
<summary>Creates a new TrustedPresentationThresholds.</summary>
9797
<remarks>
9898
<para>Creates a new TrustedPresentationThresholds.</para>
@@ -166,9 +166,9 @@
166166
</ReturnValue>
167167
<Parameters />
168168
<Docs>
169-
<summary>To be added.</summary>
170-
<returns>To be added.</returns>
171-
<remarks>To be added.</remarks>
169+
<summary>Describes the special objects in this threshold object's marshaled representation.</summary>
170+
<returns>A bitmask of special object types in the marshaled representation.</returns>
171+
<remarks>The bitmask indicates whether the parcel representation contains special objects such as file descriptors.</remarks>
172172
</Docs>
173173
</Member>
174174
<Member MemberName="JniPeerMembers">
@@ -229,7 +229,7 @@
229229
<Docs>
230230
<summary>The min alpha the Window is required to have to be considered inside the
231231
threshold.</summary>
232-
<value>To be added.</value>
232+
<value>A value greater than 0.0 and no greater than 1.0.</value>
233233
<remarks>
234234
<para>The min alpha the Window is required to have to be considered inside the
235235
threshold.</para>
@@ -272,7 +272,7 @@
272272
<Docs>
273273
<summary>The min fraction of the Window that was presented to the user to be considered
274274
inside the threshold.</summary>
275-
<value>To be added.</value>
275+
<value>A value greater than 0.0 and no greater than 1.0.</value>
276276
<remarks>
277277
<para>The min fraction of the Window that was presented to the user to be considered
278278
inside the threshold.</para>
@@ -314,7 +314,7 @@
314314
</ReturnValue>
315315
<Docs>
316316
<summary>The time in milliseconds required for the Window to be in the threshold.</summary>
317-
<value>To be added.</value>
317+
<value>A value of at least 1 millisecond.</value>
318318
<remarks>
319319
<para>The time in milliseconds required for the Window to be in the threshold.</para>
320320
<para>
@@ -426,10 +426,10 @@
426426
</Parameter>
427427
</Parameters>
428428
<Docs>
429-
<param name="dest">To be added.</param>
430-
<param name="flags">To be added.</param>
431-
<summary>To be added.</summary>
432-
<remarks>To be added.</remarks>
429+
<param name="dest">The parcel that receives the threshold values.</param>
430+
<param name="flags">Additional flags describing how the threshold values are written.</param>
431+
<summary>Flattens these threshold values into a parcel.</summary>
432+
<remarks>The parcel representation can be used to transfer threshold values across process boundaries.</remarks>
433433
</Docs>
434434
</Member>
435435
</Members>

docs/xml/ns-Android.Window.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Namespace Name="Android.Window">
22
<Docs>
3-
<summary>To be added.</summary>
4-
<remarks>To be added.</remarks>
3+
<summary>Provides APIs for predictive back navigation, splash screens, surface synchronization, input transfer, and trusted presentation thresholds.</summary>
4+
<remarks>These APIs support Android window behavior that is coordinated with the system.</remarks>
55
</Docs>
66
</Namespace>

0 commit comments

Comments
 (0)