Android 视图旋转Y 不适用于带有牛轧糖的华为

Tra*_*col 5 xml android android-layout android-7.0-nougat huawei-mobile-services

我不知道我是否应该在这里问这个问题,但有没有人遇到过这个问题,即搭载 Android 7.0 的华为设备有一个错误,如果您将 rotationY 属性设置为 XML 中的视图,则该视图将不会在运行时呈现?

XML 代码:

<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".MainActivity"
    android:rotationY="180">

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Hello World!"
        android:textSize="33sp"
        android:textColor="#000"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintLeft_toLeftOf="parent"
        app:layout_constraintRight_toRightOf="parent"
        app:layout_constraintTop_toTopOf="parent" />

</android.support.constraint.ConstraintLayout>
Run Code Online (Sandbox Code Playgroud)

搭载Android 6.0的小米手机 搭载Android 6.0的小米手机

搭载 Android 7.0 的华为荣耀 6X 搭载 Android 7.0 的华为荣耀 6X

我没有配备 Android 6.0 的华为设备的屏幕截图,因为那是在升级之前,但我可以向您保证它运行良好。根据我收到的反馈,使用 Android 7.0 的不同华为设备也存在此问题。我还使用属性 rotationX 进行了测试,但它仍然相同。有谁知道如何解决这个问题?