-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
757b1bf
commit 2f1070f
Showing
72 changed files
with
558 additions
and
1,051 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 |
---|---|---|
|
@@ -53,3 +53,4 @@ google-services.json | |
freeline.py | ||
freeline/ | ||
freeline_project_description.json | ||
.idea/ |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
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,25 @@ | ||
apply plugin: 'com.android.library' | ||
|
||
android { | ||
compileSdkVersion 29 | ||
buildToolsVersion "29.0.0" | ||
|
||
defaultConfig { | ||
minSdkVersion 16 | ||
targetSdkVersion 29 | ||
versionCode 12 | ||
versionName "1.2.1" | ||
} | ||
buildTypes { | ||
release { | ||
minifyEnabled false | ||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' | ||
} | ||
} | ||
} | ||
|
||
dependencies { | ||
implementation fileTree(dir: 'libs', include: ['*.jar']) | ||
implementation 'androidx.appcompat:appcompat:1.2.0' | ||
implementation 'androidx.annotation:annotation:1.1.0' | ||
} |
File renamed without changes.
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,11 @@ | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
package="com.yc.shadow"> | ||
|
||
<application | ||
android:allowBackup="true" | ||
android:label="@string/app_name" | ||
android:supportsRtl="true"> | ||
|
||
</application> | ||
|
||
</manifest> |
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
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
4 changes: 2 additions & 2 deletions
4
...s/yc/yccardviewlib/shadow/ShapeUtils.java → ...c/main/java/com/yc/shadow/ShapeUtils.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
8 changes: 0 additions & 8 deletions
8
YCCardViewLib/src/main/res/values/attrs.xml → CardViewLib/src/main/res/values/attrs.xml
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
File renamed without changes.
File renamed without changes.
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
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,2 @@ | ||
/build | ||
.idea/ |
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 @@ | ||
apply plugin: 'com.android.library' | ||
|
||
android { | ||
compileSdkVersion 29 | ||
|
||
defaultConfig { | ||
minSdkVersion 16 | ||
targetSdkVersion 29 | ||
versionCode 1 | ||
versionName "1.0" | ||
} | ||
|
||
buildTypes { | ||
release { | ||
minifyEnabled false | ||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' | ||
} | ||
} | ||
|
||
} | ||
|
||
dependencies { | ||
implementation fileTree(dir: 'libs', include: ['*.jar']) | ||
implementation 'androidx.appcompat:appcompat:1.2.0' | ||
implementation 'androidx.annotation:annotation:1.1.0' | ||
} |
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,21 @@ | ||
# Add project specific ProGuard rules here. | ||
# You can control the set of applied configuration files using the | ||
# proguardFiles setting in build.gradle. | ||
# | ||
# For more details, see | ||
# http://developer.android.com/guide/developing/tools/proguard.html | ||
|
||
# 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 *; | ||
#} | ||
|
||
# Uncomment this to preserve the line number information for | ||
# debugging stack traces. | ||
#-keepattributes SourceFile,LineNumberTable | ||
|
||
# If you keep the line number information, uncomment this to | ||
# hide the original source file name. | ||
#-renamesourcefileattribute SourceFile |
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,2 @@ | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
package="com.yc.library" /> |
89 changes: 89 additions & 0 deletions
89
ShadowConfig/src/main/java/com/yc/library/ShadowConfig.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,89 @@ | ||
package com.yc.library; | ||
|
||
import android.graphics.LinearGradient; | ||
import androidx.annotation.ColorInt; | ||
import androidx.annotation.Nullable; | ||
|
||
/** | ||
* <pre> | ||
* @author yangchong | ||
* blog : https://github.com/yangchong211 | ||
* time : 2019/3/20 | ||
* desc : 自定义带阴影Drawable背景 | ||
* revise: 阴影参数配置 | ||
* </pre> | ||
*/ | ||
public final class ShadowConfig { | ||
|
||
private int mColor; | ||
private int mShadowColor; | ||
private int[] mGradientColorArray; | ||
private float[] mGradientPositions; | ||
private LinearGradient mLinearGradient; | ||
private int mRadius; | ||
private int mShadowRadius; | ||
private int mOffsetX; | ||
private int mOffsetY; | ||
|
||
public ShadowConfig() { | ||
//初始化默认值 | ||
mColor = R.color.primary_material_dark; | ||
mShadowColor = R.color.primary_text_disabled_material_dark; | ||
mRadius = 5; | ||
mShadowRadius = 10; | ||
mOffsetX = 0; | ||
mOffsetY = 0; | ||
} | ||
|
||
public ShadowConfig setColor(@ColorInt int color) { | ||
this.mColor = color; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setShadowColor(@ColorInt int shadowColor) { | ||
this.mShadowColor = shadowColor; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setGradientColorArray(@Nullable int[] colorArray) { | ||
this.mGradientColorArray = colorArray; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setGradientPositions(@Nullable float[] positions) { | ||
this.mGradientPositions = positions; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setLinearGradient(@Nullable LinearGradient linearGradient) { | ||
this.mLinearGradient = linearGradient; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setRadius(int radius) { | ||
this.mRadius = radius; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setShadowRadius(int shadowRadius) { | ||
this.mShadowRadius = shadowRadius; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setOffsetX(int offsetX) { | ||
this.mOffsetX = offsetX; | ||
return this; | ||
} | ||
|
||
public ShadowConfig setOffsetY(int offsetY) { | ||
this.mOffsetY = offsetY; | ||
return this; | ||
} | ||
|
||
|
||
public ShadowDrawable builder() { | ||
return new ShadowDrawable(mColor, mGradientColorArray, mGradientPositions, | ||
mShadowColor, mLinearGradient, mRadius, mShadowRadius, | ||
mOffsetX, mOffsetY); | ||
} | ||
} |
Oops, something went wrong.