Bug 59656 - [API 26] Many new 'Android.Views.ViewStructure' autofill and other methods have uninformative parameter names
Summary: [API 26] Many new 'Android.Views.ViewStructure' autofill and other methods ha...
Status: VERIFIED FIXED
Alias: None
Product: Android
Classification: Xamarin
Component: Bindings ()
Version: 8.0 (15.4)
Hardware: Macintosh Mac OS
: Normal normal
Target Milestone: 15.4
Assignee: Atsushi Eno
URL:
Depends on:
Blocks:
 
Reported: 2017-09-21 17:30 UTC by Peter Collins
Modified: 2017-09-27 18:40 UTC (History)
4 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
VERIFIED FIXED

Description Peter Collins 2017-09-21 17:30:13 UTC
The following additions to Android.Views.ViewStructure in API 26 have generic parameter names, which could likely be improved.

> [Register ("newHtmlInfoBuilder", "(Ljava/lang/String;)Landroid/view/ViewStructure$HtmlInfo$Builder;", "GetNewHtmlInfoBuilder_Ljava_lang_String_Handler", ApiSince = 26)]
> public abstract ViewStructure.HtmlInfo.Builder NewHtmlInfoBuilder (string p0);
> 
> ...
> 
> [Register ("setAutofillHints", "([Ljava/lang/String;)V", "GetSetAutofillHints_arrayLjava_lang_String_Handler", ApiSince = 26)]
> public abstract void SetAutofillHints (string[] p0);
> 
> [Register ("setAutofillId", "(Landroid/view/autofill/AutofillId;I)V", "GetSetAutofillId_Landroid_view_autofill_AutofillId_IHandler", ApiSince = 26)]
> public abstract void SetAutofillId (AutofillId p0, int p1);
> 
> [Register ("setAutofillOptions", "([Ljava/lang/CharSequence;)V", "GetSetAutofillOptions_arrayLjava_lang_CharSequence_Handler", ApiSince = 26)]
> public abstract void SetAutofillOptions (ICharSequence[] p0);
> 
> public void SetAutofillOptions (string[] p0)
> {
>     ...
> }
> 
> [Register ("setAutofillType", "(I)V", "GetSetAutofillType_IHandler", ApiSince = 26)]
> public abstract void SetAutofillType (int p0);
> 
> [Register ("setAutofillValue", "(Landroid/view/autofill/AutofillValue;)V", "GetSetAutofillValue_Landroid_view_autofill_AutofillValue_Handler", ApiSince = 26)]
> public abstract void SetAutofillValue (AutofillValue p0);
> 
> ...
> 
> [Register ("setDataIsSensitive", "(Z)V", "GetSetDataIsSensitive_ZHandler", ApiSince = 26)]
> public abstract void SetDataIsSensitive (bool p0);
> 
> ...
>
> [Register ("setHtmlInfo", "(Landroid/view/ViewStructure$HtmlInfo;)V", "GetSetHtmlInfo_Landroid_view_ViewStructure_HtmlInfo_Handler", ApiSince = 26)]
> public abstract void SetHtmlInfo (ViewStructure.HtmlInfo p0);
> 
> ...
> 
> [Register ("setInputType", "(I)V", "GetSetInputType_IHandler", ApiSince = 26)]
> public abstract void SetInputType (int p0);
> 
> [Register ("setLocaleList", "(Landroid/os/LocaleList;)V", "GetSetLocaleList_Landroid_os_LocaleList_Handler", ApiSince = 26)]
> public abstract void SetLocaleList (LocaleList p0);
> 
> ...
> 
> [Register ("setOpaque", "(Z)V", "GetSetOpaque_ZHandler", ApiSince = 26)]
> public abstract void SetOpaque (bool p0);
> 
> ...
> 
> [Register ("setWebDomain", "(Ljava/lang/String;)V", "GetSetWebDomain_Ljava_lang_String_Handler", ApiSince = 26)]
> public abstract void SetWebDomain (string p0);
Comment 1 Atsushi Eno 2017-09-22 17:31:45 UTC
This PR most likely fixes this. https://github.com/xamarin/xamarin-android/pull/893
Comment 2 Peter Collins 2017-09-22 18:28:49 UTC
I'm going to milestone this improvement for 15.5.
Comment 3 Jon Douglas [MSFT] 2017-09-25 14:58:12 UTC
Marking as CONFIRMED as parameters should be improved and I am also seeing this for some APIs.
Comment 4 Peter Collins 2017-09-25 15:49:39 UTC
@JonDouglas do you have additional examples not mentioned above that we should be considering? This is now being considered for d15-4, and any additional related changes will need to be assessed as soon as possible.
Comment 5 Jon Douglas [MSFT] 2017-09-25 17:02:02 UTC
(In reply to Peter Collins from comment #4)
> @JonDouglas do you have additional examples not mentioned above that we
> should be considering? This is now being considered for d15-4, and any
> additional related changes will need to be assessed as soon as possible.

I do not have additional examples of Mono.Android.dll. At first I thought I did, but then I noticed that the SensorManager and other APIs have the same parameter naming on Google's API docs when I did a quick audit. Here is an example:

https://developer.android.com/reference/android/hardware/SensorManager.html#getAltitude(float, float)

So false alarm on additional items. I can CONFIRM the ones listed in this bug report however.
Comment 7 Cody Beyer (MSFT) 2017-09-27 03:23:45 UTC
Merged in 15.4
Comment 8 Peter Collins 2017-09-27 18:40:24 UTC
The parameter names mentioned above have been fixed in monodroid/d15-4/87269403:

https://gist.github.com/pjcollins/46f41eff4d7c86b38898f9bb7e5d4107