小编elu*_*uuu的帖子

错误:任务':app:packageDebug'的执行失败.> com.android.builder.packaging.PackagerException

我使用Android Studio 2.0 RC 1.今天android studio给自己一个错误.

错误:任务':app:packageDebug'的执行失败.com.android.builder.packaging.PackagerException:java.io.IOException:无法读取zip文件'D:\ Unimag\MyUnimax21042016\app\build\outputs\apk\app-debug.apk'.

我的gradle文件:

apply plugin: 'com.android.application'


android {
    compileSdkVersion 23
    buildToolsVersion "23.0.1"

    defaultConfig {
        applicationId "kz.dreamwings.unimax"
        minSdkVersion 15
        targetSdkVersion 23
        versionCode 2
        versionName "0.0.2"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }

        debug {
            debuggable true
        }
    }
}



dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:appcompat-v7:23.0.1'
    compile 'com.android.support:design:23.0.1'
    compile 'com.mcxiaoke.volley:library:1.0.19'
    compile 'com.android.support:cardview-v7:23.1.1'
    compile 'com.android.support:recyclerview-v7:23.2.1'
    compile 'com.joanzapata.iconify:android-iconify-fontawesome:2.2.2'
    compile 'com.squareup.picasso:picasso:2.5.2'
    compile 'com.github.rahatarmanahmed:circularprogressview:2.5.0'

}
Run Code Online (Sandbox Code Playgroud)

来自Messages Gradle Build的完整消息

Information:Gradle tasks [:app:assembleDebug]
:app:preBuild UP-TO-DATE …
Run Code Online (Sandbox Code Playgroud)

android android-studio-2.0

6
推荐指数
1
解决办法
6161
查看次数

断开默认背景,例如TabLayout和工具栏中的EditText或按下状态

我使用TabLayout作为ViewPager的标签.当我按下某个标签时,我会得到带有奇怪颜色标签的背景.并且独立于TabLayout的EditText背景也在奇怪的视图中.API 19中的结果.在API 22中,所有工作都很完美

AA

当我按下工具栏中的后退按钮时,我有类似的背景和奇怪的颜色

BB

有片段xml,我使用TabLayout和工具栏

    <android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:app="http://schemas.android.com/apk/res-auto"
        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:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar">

            <android.support.v7.widget.Toolbar
                android:id="@+id/toolbar"
                android:layout_width="match_parent"
                android:layout_height="?attr/actionBarSize"
                android:background="?attr/colorPrimary"
                app:popupTheme="@style/ThemeOverlay.AppCompat.Light">
                </android.support.v7.widget.Toolbar>


            <android.support.design.widget.TabLayout
                android:id="@+id/tabs"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                app:tabMode="fixed"
                app:tabGravity="fill"
                app:tabIndicatorHeight="0dp"
                android:layout_marginBottom="10dp"
                />
        </android.support.design.widget.AppBarLayout>

        <android.support.v4.view.ViewPager
            android:id="@+id/viewpager"
            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)



这是我使用EditText的片段xml

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="20dp"
            android:text="????????? ???? ????? ?????"
            android:textColor="@color/black"/>
         <EditText
                    android:id="@+id/edt_firstname"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:hint="?????*"
                    android:textSize="15sp"
                    android:textColorHighlight="#F14040"
                    android:layout_marginTop="10dp"
                    style="@style/Base"
                    android:backgroundTint="@color/colorPrimary"
                    android:inputType="phone"
                    android:maxLength="13"
                    />
        <EditText
            android:id="@+id/lastname"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:hint="??????"
            android:textSize="15sp"
            android:textColorHighlight="#F14040"
            android:layout_marginTop="10dp"
            style="@style/Base"
            android:backgroundTint="@color/colorPrimary"
            android:inputType="textPassword"
            />
Run Code Online (Sandbox Code Playgroud)



这是我的风格xml

<style name="MyMaterialTheme" parent="MyMaterialTheme.Base">
</style>

<style name="MyMaterialTheme.Base" …
Run Code Online (Sandbox Code Playgroud)

android nine-patch

5
推荐指数
1
解决办法
485
查看次数

标签 统计

android ×2

android-studio-2.0 ×1

nine-patch ×1