-
Notifications
You must be signed in to change notification settings - Fork 430
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
移除 Library 中的 BGABadgeXxxxView,改为 annotationProcessor 的形式
- Loading branch information
1 parent
05a14a2
commit 02db075
Showing
40 changed files
with
616 additions
and
810 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 |
---|---|---|
|
@@ -41,4 +41,6 @@ proguard/ | |
# Mac system files | ||
.DS_Store | ||
|
||
*.keystore | ||
*.keystore | ||
|
||
repo/ |
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
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,14 @@ | ||
apply plugin: 'java-library' | ||
|
||
sourceCompatibility = JavaVersion.VERSION_1_7 | ||
targetCompatibility = JavaVersion.VERSION_1_7 | ||
|
||
|
||
// gradle clean build uploadArchives -PpublishAar | ||
if (hasProperty("publishAar")) { | ||
apply from: 'https://raw.githubusercontent.com/bingoogolapple/PublishAar/master/local-release.gradle' | ||
} | ||
// gradle clean build bintrayUpload -PpublishAar | ||
if (hasProperty("publishAar")) { | ||
apply from: 'https://raw.githubusercontent.com/bingoogolapple/PublishAar/master/jcenter-release.gradle' | ||
} |
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 @@ | ||
PUBLISH_AAR_ARTIFACT_ID=bga-badgeview-annotation | ||
PUBLISH_AAR_DESCRIPTION=Android BadgeView Annotation |
33 changes: 33 additions & 0 deletions
33
annotation/src/main/java/cn/bingoogolapple/badgeview/annotation/BGABadge.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,33 @@ | ||
/** | ||
* Copyright 2018 bingoogolapple | ||
* <p/> | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* <p/> | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* <p/> | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package cn.bingoogolapple.badgeview.annotation; | ||
|
||
import java.lang.annotation.ElementType; | ||
import java.lang.annotation.Retention; | ||
import java.lang.annotation.RetentionPolicy; | ||
import java.lang.annotation.Target; | ||
|
||
/** | ||
* 作者:王浩 邮件:bingoogolapple@gmail.com | ||
* 创建时间:2018/1/14 | ||
* 描述: | ||
*/ | ||
@Retention(RetentionPolicy.CLASS) | ||
@Target(ElementType.TYPE) | ||
public @interface BGABadge { | ||
String[] value() default {}; | ||
} |
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,35 @@ | ||
apply plugin: 'com.android.library' | ||
|
||
android { | ||
compileSdkVersion ANDROID_BUILD_SDK_VERSION as int | ||
|
||
defaultConfig { | ||
minSdkVersion ANDROID_BUILD_MIN_SDK_VERSION as int | ||
targetSdkVersion ANDROID_BUILD_TARGET_SDK_VERSION as int | ||
} | ||
|
||
android { | ||
lintOptions { | ||
abortOnError false | ||
} | ||
} | ||
} | ||
|
||
dependencies { | ||
compileOnly 'com.android.support:appcompat-v7:27.0.2' | ||
|
||
// 发布到 jcenter 时 | ||
// api 中用 compile 传递依赖,用 api 不会传递依赖 | ||
// api project(':annotation') | ||
// 发布完 annotation 后,改用依赖仓库里的 annotation 后再发布 api | ||
compile "cn.bingoogolapple:bga-badgeview-annotation:${VERSION_NAME}" | ||
} | ||
|
||
// gradle clean build uploadArchives -PpublishAar | ||
if (hasProperty("publishAar")) { | ||
apply from: 'https://raw.githubusercontent.com/bingoogolapple/PublishAar/master/local-release.gradle' | ||
} | ||
// gradle clean build bintrayUpload -PpublishAar | ||
if (hasProperty("publishAar")) { | ||
apply from: 'https://raw.githubusercontent.com/bingoogolapple/PublishAar/master/jcenter-release.gradle' | ||
} |
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 @@ | ||
PUBLISH_AAR_ARTIFACT_ID=bga-badgeview-api | ||
PUBLISH_AAR_DESCRIPTION=Android BadgeView Api |
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
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,23 @@ | ||
apply plugin: 'java-library' | ||
|
||
dependencies { | ||
// compiler 中用 implementation | ||
// implementation project(':annotation') | ||
// 发布完 annotation 后,改用依赖仓库里的 annotation 后再发布 compiler | ||
implementation "cn.bingoogolapple:bga-badgeview-annotation:${VERSION_NAME}" | ||
|
||
implementation 'com.google.auto.service:auto-service:1.0-rc4' | ||
implementation 'com.squareup:javapoet:1.9.0' | ||
} | ||
|
||
sourceCompatibility = JavaVersion.VERSION_1_7 | ||
targetCompatibility = JavaVersion.VERSION_1_7 | ||
|
||
// gradle clean build uploadArchives -PpublishAar | ||
if (hasProperty("publishAar")) { | ||
apply from: 'https://raw.githubusercontent.com/bingoogolapple/PublishAar/master/local-release.gradle' | ||
} | ||
// gradle clean build bintrayUpload -PpublishAar | ||
if (hasProperty("publishAar")) { | ||
apply from: 'https://raw.githubusercontent.com/bingoogolapple/PublishAar/master/jcenter-release.gradle' | ||
} |
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 @@ | ||
PUBLISH_AAR_ARTIFACT_ID=bga-badgeview-compiler | ||
PUBLISH_AAR_DESCRIPTION=Android BadgeView Compiler |
Oops, something went wrong.