java.lang.UnsupportedOperationException: Can't convert to dimension: type=0x12

StackOverflow https://stackoverflow.com/questions/22927655

  •  29-06-2023
  •  | 
  •  

Вопрос

I am getting this error, java.lang.UnsupportedOperationException: Can't convert to dimension: type=0x12, from the following lines in my override of the @android:style/Theme.Holo.Light theme below using Android API 4.1.2. It works fine in an older API and the newest. What is the issue here?

<item name="android:windowTranslucentStatus">true</item>
<item name="android:windowTranslucentNavigation">true</item>

I am using this users-sdk line:

<uses-sdk android:minSdkVersion="10" android:targetSdkVersion="19"></uses-sdk>
Это было полезно?

Решение

windowTranslucentNavigation and windowTranslucentNavigation

Works Only for Api level 19 or above.Your setting the minSdkversion to 10.

check the api level in the programmatically and set the

if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT){
windowTranslucentNavigation=true;

}
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top