大家好
在这种情况下有许多线程可用...我尝试了一切,但没有运气.我是android背景的新手.我是c#家伙,现在iam与xamarin机器人合作......所以任何人都可以解释什么是错误.这个解决方案不起作用**PRE lolipop devices**.
我的布局
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/quickreturn_coordinator"
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.design.widget.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
app:layout_scrollFlags="scroll|enterAlways"
app:popupTheme="@style/ThemeOverlay.AppCompat.Light" />
</android.support.design.widget.AppBarLayout>
<android.support.v7.widget.RecyclerView
android:id="@+id/masonry_grid"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
</android.support.design.widget.CoordinatorLayout>
Run Code Online (Sandbox Code Playgroud)
我是使用appcompact主题
值/ Style.xml
<?xml version="1.0" encoding="utf-8" ?>
<resources>
<style name="Theme.Splash"
parent="@android:style/Theme.Holo.Light">
<item name="android:windowBackground">@drawable/splashscreen</item>
<item name="android:windowNoTitle">true</item>
<item name="android:windowIsTranslucent">false</item>
<item name="android:windowIsFloating">false</item>
<item name="android:backgroundDimEnabled">true</item>
</style>
<style name="AppTheme" parent="Base.Theme">
</style>
<style name="Base.Theme" parent="Theme.AppCompat.Light.DarkActionBar">
<item name="colorPrimary">@color/DarkOrangeLight</item>
<item name="colorPrimaryDark">@color/DarkOrange</item>
<item name="colorAccent">@color/DarkOrangeAcent</item>
<item name="windowActionBarOverlay">true</item>
<item name="android:windowBackground">@color/bg</item>
<item name="windowActionBar">false</item>
<item name="windowActionBarOverlay">false</item>
<item name="windowNoTitle">true</item>
<!-- Customize …Run Code Online (Sandbox Code Playgroud)