forked from tome34/frameDemoMo2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1,重新上传
- Loading branch information
Showing
45 changed files
with
1,253 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
|
||
apply plugin: 'com.android.library' | ||
|
||
|
||
android { | ||
compileSdkVersion rootProject.ext.android.compileSdkVersion | ||
buildToolsVersion rootProject.ext.android.buildToolsVersion | ||
|
||
defaultConfig { | ||
minSdkVersion rootProject.ext.android.minSdkVersion | ||
targetSdkVersion rootProject.ext.android.targetSdkVersion | ||
versionCode rootProject.ext.android.versionCode | ||
versionName rootProject.ext.android.versionName | ||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" | ||
|
||
|
||
} | ||
|
||
compileOptions { | ||
sourceCompatibility JavaVersion.VERSION_1_8 | ||
targetCompatibility JavaVersion.VERSION_1_8 | ||
} | ||
|
||
buildTypes { | ||
release { | ||
minifyEnabled false | ||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' | ||
} | ||
} | ||
|
||
/*java插件引入了一个概念叫做SourceSets,通过修改SourceSets中的属性,可以指定哪些源文件(或文件夹下的源文件)要被编译,哪些源文件要被排除。*/ | ||
// sourceSets { | ||
// main { | ||
// if (rootProject.ext.moduleWelfare) { | ||
// manifest.srcFile 'src/main/module/AndroidManifest.xml' | ||
// } else { | ||
// manifest.srcFile 'src/main/AndroidManifest.xml' | ||
// java { | ||
// //排除java/debug文件夹下的所有文件 | ||
// exclude '*debug' | ||
// } | ||
// } | ||
// | ||
// } | ||
// } | ||
|
||
} | ||
|
||
dependencies { | ||
implementation fileTree(dir: 'libs', include: ['*.jar']) | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Add project specific ProGuard rules here. | ||
# By default, the flags in this file are appended to flags specified | ||
# in /Users/Sai/Documents/software/sdk/tools/proguard/proguard-android.txt | ||
# You can edit the include path and order by changing the proguardFiles | ||
# directive in build.gradle. | ||
# | ||
# For more details, see | ||
# http://developer.android.com/guide/developing/tools/proguard.html | ||
|
||
# Add any project specific keep options here: | ||
|
||
# If your project uses WebView with JS, uncomment the following | ||
# and specify the fully qualified class name to the JavaScript interface | ||
# class: | ||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview { | ||
# public *; | ||
#} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.bigkoo.alertview"> | ||
|
||
</manifest> |
26 changes: 26 additions & 0 deletions
26
baseLib/alertview/src/main/java/com/bigkoo/alertview/AlertAnimateUtil.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package com.bigkoo.alertview; | ||
|
||
import android.view.Gravity; | ||
|
||
/** | ||
* Created by Sai on 15/8/9. | ||
*/ | ||
public class AlertAnimateUtil { | ||
private static final int INVALID = -1; | ||
/** | ||
* Get default animation resource when not defined by the user | ||
* | ||
* @param gravity the gravity of the dialog | ||
* @param isInAnimation determine if is in or out animation. true when is is | ||
* @return the id of the animation resource | ||
*/ | ||
static int getAnimationResource(int gravity, boolean isInAnimation) { | ||
switch (gravity ) { | ||
case Gravity.BOTTOM: | ||
return isInAnimation ? R.anim.slide_in_bottom : R.anim.slide_out_bottom; | ||
case Gravity.CENTER: | ||
return isInAnimation ? R.anim.fade_in_center : R.anim.fade_out_center; | ||
} | ||
return INVALID; | ||
} | ||
} |
Oops, something went wrong.