我添加this library以支持Lollipop前设备上的循环显示。 我已阅读设置指南,一切实际上都很棒!它编译时没有错误,并且正如预期的那样在应用程序中工作。但是,我正面临一些“渲染问题”的警告,我无法摆脱。它说:
Rendering Problems
The following classes could not be found:
- io.codetail.widget.RevealLinearLayout (Fix Build Path, Create Class)
Tip: Try to build the project.
我的.xml文件:
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".SingleGameActivity"
android:paddingTop="@dimen/activity_vertical_margin"
android:id="@+id/mainLayout"
android:background="@color/game_background">
<!-- Some other stuff -->
<io.codetail.widget.RevealLinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_centerHorizontal="true">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/newPlaceWrapper"
android:background="#95000000"
android:orientation="vertical"
android:visibility="invisible">
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:id="@+id/textNewPlace"
android:text=""
android:textColor="#ffffffff"
android:textSize="30sp"
android:gravity="center"
android:paddingTop="20dp"
android:paddingBottom="20dp"/>
</LinearLayout>
</io.codetail.widget.RevealLinearLayout>
<!-- Some other stuff -->
</RelativeLayout>
我的build.gradle(模块:app)
apply plugin: 'com.android.application'
android {
compileSdkVersion 22
buildToolsVersion "22.0.1"
defaultConfig {
applicationId "//"
minSdkVersion 16
targetSdkVersion 22
versionCode 1
versionName "1.0"
}
}
repositories {
maven { url 'https://jitpack.io' }
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:support-v4:22.2.0'
compile 'com.android.support:support-v13:21.0.2'
compile 'com.github.ozodrukh:CircularReveal:1.1.1'
}