├── .idea
├── .name
├── copyright
│ └── profiles_settings.xml
├── encodings.xml
├── modules.xml
├── runConfigurations.xml
├── compiler.xml
├── gradle.xml
└── misc.xml
├── app
├── .gitignore
├── src
│ ├── main
│ │ ├── res
│ │ │ ├── values
│ │ │ │ ├── strings.xml
│ │ │ │ ├── colors.xml
│ │ │ │ ├── dimens.xml
│ │ │ │ └── styles.xml
│ │ │ ├── mipmap-hdpi
│ │ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-mdpi
│ │ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xhdpi
│ │ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxxhdpi
│ │ │ │ └── ic_launcher.png
│ │ │ ├── values-w820dp
│ │ │ │ └── dimens.xml
│ │ │ └── layout
│ │ │ │ └── activity_main.xml
│ │ ├── AndroidManifest.xml
│ │ └── java
│ │ │ └── me
│ │ │ └── wangyuwei
│ │ │ └── jikegallery
│ │ │ └── MainActivity.java
│ ├── test
│ │ └── java
│ │ │ └── me
│ │ │ └── wangyuwei
│ │ │ └── jikegallery
│ │ │ └── ExampleUnitTest.java
│ └── androidTest
│ │ └── java
│ │ └── me
│ │ └── wangyuwei
│ │ └── jikegallery
│ │ └── ApplicationTest.java
├── proguard-rules.pro
└── build.gradle
├── GalleryView
├── .gitignore
├── src
│ ├── main
│ │ ├── res
│ │ │ ├── values
│ │ │ │ └── strings.xml
│ │ │ ├── drawable-xhdpi
│ │ │ │ ├── logo.png
│ │ │ │ └── stock.png
│ │ │ └── layout
│ │ │ │ └── gallery_view.xml
│ │ ├── AndroidManifest.xml
│ │ └── java
│ │ │ └── me
│ │ │ └── wangyuwei
│ │ │ └── galleryview
│ │ │ ├── GalleryEntity.java
│ │ │ ├── GalleryView.java
│ │ │ ├── SmoothViewGroup.java
│ │ │ ├── TitleView.java
│ │ │ └── Gallery.java
│ ├── test
│ │ └── java
│ │ │ └── me
│ │ │ └── wangyuwei
│ │ │ └── galleryview
│ │ │ └── ExampleUnitTest.java
│ └── androidTest
│ │ └── java
│ │ └── me
│ │ └── wangyuwei
│ │ └── galleryview
│ │ └── ApplicationTest.java
├── proguard-rules.pro
└── build.gradle
├── settings.gradle
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── .gitignore
├── gradle.properties
├── README.md
├── gradlew.bat
├── checkstyle.xml
└── gradlew
/.idea/.name:
--------------------------------------------------------------------------------
1 | JiKeGallery
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/GalleryView/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app', ':GalleryView'
2 |
--------------------------------------------------------------------------------
/.idea/copyright/profiles_settings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | JiKeGallery
3 |
4 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/GalleryView/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | GalleryView
3 |
4 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | *.iml
2 | .gradle
3 | /local.properties
4 | /.idea/workspace.xml
5 | /.idea/libraries
6 | .DS_Store
7 | /build
8 | /captures
9 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/GalleryView/src/main/res/drawable-xhdpi/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/GalleryView/src/main/res/drawable-xhdpi/logo.png
--------------------------------------------------------------------------------
/GalleryView/src/main/res/drawable-xhdpi/stock.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JeasonWong/JikeGallery/HEAD/GalleryView/src/main/res/drawable-xhdpi/stock.png
--------------------------------------------------------------------------------
/.idea/encodings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/app/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #3F51B5
4 | #303F9F
5 | #FF4081
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/values/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 16dp
4 | 16dp
5 |
6 |
--------------------------------------------------------------------------------
/GalleryView/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Mon Dec 28 10:00:20 PST 2015
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
7 |
--------------------------------------------------------------------------------
/GalleryView/src/main/java/me/wangyuwei/galleryview/GalleryEntity.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | /**
4 | * 作者: 巴掌 on 16/8/5 07:55
5 | * Github: https://github.com/JeasonWong
6 | */
7 | public class GalleryEntity {
8 |
9 | public String imgUrl;
10 | public String title;
11 |
12 | }
13 |
--------------------------------------------------------------------------------
/app/src/main/res/values-w820dp/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 64dp
6 |
7 |
--------------------------------------------------------------------------------
/app/src/test/java/me/wangyuwei/jikegallery/ExampleUnitTest.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.jikegallery;
2 |
3 | import org.junit.Test;
4 |
5 | import static org.junit.Assert.*;
6 |
7 | /**
8 | * To work on unit tests, switch the Test Artifact in the Build Variants view.
9 | */
10 | public class ExampleUnitTest {
11 | @Test
12 | public void addition_isCorrect() throws Exception {
13 | assertEquals(4, 2 + 2);
14 | }
15 | }
--------------------------------------------------------------------------------
/GalleryView/src/test/java/me/wangyuwei/galleryview/ExampleUnitTest.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | import org.junit.Test;
4 |
5 | import static org.junit.Assert.*;
6 |
7 | /**
8 | * To work on unit tests, switch the Test Artifact in the Build Variants view.
9 | */
10 | public class ExampleUnitTest {
11 | @Test
12 | public void addition_isCorrect() throws Exception {
13 | assertEquals(4, 2 + 2);
14 | }
15 | }
--------------------------------------------------------------------------------
/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/app/src/androidTest/java/me/wangyuwei/jikegallery/ApplicationTest.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.jikegallery;
2 |
3 | import android.app.Application;
4 | import android.test.ApplicationTestCase;
5 |
6 | /**
7 | * Testing Fundamentals
8 | */
9 | public class ApplicationTest extends ApplicationTestCase {
10 | public ApplicationTest() {
11 | super(Application.class);
12 | }
13 | }
--------------------------------------------------------------------------------
/GalleryView/src/androidTest/java/me/wangyuwei/galleryview/ApplicationTest.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | import android.app.Application;
4 | import android.test.ApplicationTestCase;
5 |
6 | /**
7 | * Testing Fundamentals
8 | */
9 | public class ApplicationTest extends ApplicationTestCase {
10 | public ApplicationTest() {
11 | super(Application.class);
12 | }
13 | }
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/.idea/runConfigurations.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
11 |
12 |
--------------------------------------------------------------------------------
/GalleryView/src/main/res/layout/gallery_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
10 |
11 |
15 |
16 |
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/wscn/Documents/android-sdk-macosx/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/GalleryView/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/wscn/Documents/android-sdk-macosx/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/.idea/compiler.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/app/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | android {
4 | compileSdkVersion 23
5 | buildToolsVersion "24.0.1"
6 |
7 | defaultConfig {
8 | applicationId "me.wangyuwei.jikegallery"
9 | minSdkVersion 15
10 | targetSdkVersion 23
11 | versionCode 1
12 | versionName "1.0"
13 | }
14 | buildTypes {
15 | release {
16 | minifyEnabled false
17 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
18 | }
19 | }
20 | }
21 |
22 | dependencies {
23 | compile fileTree(dir: 'libs', include: ['*.jar'])
24 | testCompile 'junit:junit:4.12'
25 | compile 'com.android.support:appcompat-v7:23.4.0'
26 | compile project(':GalleryView')
27 | }
28 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 |
3 | # IDE (e.g. Android Studio) users:
4 | # Gradle settings configured through the IDE *will override*
5 | # any settings specified in this file.
6 |
7 | # For more details on how to configure your build environment visit
8 | # http://www.gradle.org/docs/current/userguide/build_environment.html
9 |
10 | # Specifies the JVM arguments used for the daemon process.
11 | # The setting is particularly useful for tweaking memory settings.
12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m
13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
14 |
15 | # When configured, Gradle will run in incubating parallel mode.
16 | # This option should only be used with decoupled projects. More details, visit
17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18 | # org.gradle.parallel=true
--------------------------------------------------------------------------------
/.idea/gradle.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ## What's JikeGallery ?
2 | A cool gallery view with vertical smooth animation which shows content more attractive.
3 |
4 | [](https://android-arsenal.com/details/1/4084)
5 |
6 | ## Demo
7 | 
8 |
9 | ## Arlticle
10 | [手摸手教你写炫酷控件](http://www.wangyuwei.me/2016/08/07/%E6%89%8B%E6%91%B8%E6%89%8B%E6%95%99%E4%BD%A0%E5%86%99%E7%82%AB%E9%85%B7%E6%8E%A7%E4%BB%B6/)
11 |
12 | ##Build
13 | #####Step 1
14 | ```build
15 | repositories {
16 | maven {
17 | url 'https://dl.bintray.com/wangyuwei/maven'
18 | }
19 | }
20 | ```
21 | #####Step 2
22 | ```java
23 | compile 'me.wangyuwei:GalleryView:1.0.0'
24 | ```
25 |
26 | ##**Lincense**
27 |
28 | ```lincense
29 | Copyright [2016] [JeasonWong of copyright owner]
30 |
31 | Licensed under the Apache License, Version 2.0 (the "License");
32 | you may not use this file except in compliance with the License.
33 | You may obtain a copy of the License at
34 |
35 | http://www.apache.org/licenses/LICENSE-2.0
36 |
37 | Unless required by applicable law or agreed to in writing, software
38 | distributed under the License is distributed on an "AS IS" BASIS,
39 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
40 | See the License for the specific language governing permissions and
41 | limitations under the License.
42 | ```
43 |
44 |
45 |
--------------------------------------------------------------------------------
/GalleryView/src/main/java/me/wangyuwei/galleryview/GalleryView.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | import android.content.Context;
4 | import android.util.AttributeSet;
5 | import android.view.View;
6 | import android.widget.FrameLayout;
7 |
8 | import java.util.ArrayList;
9 | import java.util.List;
10 |
11 |
12 | /**
13 | * 作者: 巴掌 on 16/8/6 11:15
14 | * Github: https://github.com/JeasonWong
15 | */
16 | public class GalleryView extends FrameLayout {
17 |
18 | private Gallery mGallery;
19 | private TitleView mTitleView;
20 |
21 | public GalleryView(Context context, AttributeSet attrs) {
22 | this(context, attrs, 0);
23 | }
24 |
25 | public GalleryView(Context context, AttributeSet attrs, int defStyleAttr) {
26 | super(context, attrs, defStyleAttr);
27 | initView();
28 | }
29 |
30 | private void initView() {
31 | View.inflate(getContext(), R.layout.gallery_view, this);
32 | mGallery = (Gallery) findViewById(R.id.gallery);
33 | mTitleView = (TitleView) findViewById(R.id.title_view);
34 | }
35 |
36 | public void startSmooth() {
37 | mGallery.startSmooth();
38 | mTitleView.startSmooth();
39 | }
40 |
41 | public void addGalleryData(List listEntities) {
42 | List imgList = new ArrayList<>();
43 | for (GalleryEntity entity : listEntities) {
44 | imgList.add(entity.imgUrl);
45 | }
46 | mGallery.setImgList(imgList);
47 |
48 | List titleList = new ArrayList<>();
49 | for (GalleryEntity entity : listEntities) {
50 | titleList.add(entity.title);
51 | }
52 | mTitleView.setTitleList(titleList);
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
11 |
12 |
18 |
19 |
25 |
26 |
32 |
33 |
34 |
35 |
36 |
45 |
46 |
47 |
--------------------------------------------------------------------------------
/app/src/main/java/me/wangyuwei/jikegallery/MainActivity.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.jikegallery;
2 |
3 | import android.app.Activity;
4 | import android.os.Bundle;
5 | import android.view.View;
6 |
7 | import java.util.ArrayList;
8 | import java.util.List;
9 |
10 | import me.wangyuwei.galleryview.GalleryEntity;
11 | import me.wangyuwei.galleryview.GalleryView;
12 |
13 | public class MainActivity extends Activity {
14 |
15 | private List mGalleryList = new ArrayList<>();
16 | private List mEntities = new ArrayList<>();
17 |
18 | private String[] mImgs = new String[]{"http://awb.img1.xmtbang.com/wechatmsg2015/article201505/20150525/thumb/9b65bb01da504a12807f50324fe01e3b.jpg",
19 | // "http://img.gaonengfun.com/attach/img/2015/12/11/1449820178464698.gif",
20 | "http://p3.gexing.com/G1/M00/B0/E2/rBACE1IaEE2iXDJcAAAY2UyOZcc821_200x200_3.jpg",
21 | "http://img4.imgtn.bdimg.com/it/u=665141257,1340555319&fm=21&gp=0.jpg"};
22 |
23 | private String[] mTitles = new String[]{"这是一个简单的测试",
24 | // "这是一个隐藏的福利",
25 | "必有小新",
26 | "Tracy McGrady"};
27 |
28 | @Override
29 | protected void onCreate(Bundle savedInstanceState) {
30 | super.onCreate(savedInstanceState);
31 | setContentView(R.layout.activity_main);
32 |
33 | mGalleryList.add((GalleryView) findViewById(R.id.gallery0));
34 | mGalleryList.add((GalleryView) findViewById(R.id.gallery1));
35 | mGalleryList.add((GalleryView) findViewById(R.id.gallery2));
36 |
37 | for (int i = 0; i < mGalleryList.size(); i++) {
38 | mEntities.clear();
39 | for (int j = 0; j < mImgs.length; j++) {
40 | GalleryEntity entity = new GalleryEntity();
41 | entity.imgUrl = mImgs[j];
42 | entity.title = mTitles[j];
43 | mEntities.add(entity);
44 | }
45 | mGalleryList.get(i).addGalleryData(mEntities);
46 | }
47 |
48 | }
49 |
50 | private void startSmooth() {
51 | for (int i = 0; i < mGalleryList.size(); i++) {
52 | final int index = i;
53 | mGalleryList.get(i).postDelayed(new Runnable() {
54 | @Override
55 | public void run() {
56 | mGalleryList.get(index).startSmooth();
57 | }
58 | }, 100 * i);
59 | }
60 |
61 | }
62 |
63 | public void onRefresh(View view) {
64 | startSmooth();
65 | }
66 |
67 | }
68 |
--------------------------------------------------------------------------------
/GalleryView/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.library'
2 | apply plugin: 'com.jfrog.bintray'
3 | apply plugin: 'com.github.dcendents.android-maven'
4 |
5 | group = 'me.wangyuwei' // Change this to match your package name
6 | version = '1.0.0' // Change this to match your version number
7 |
8 | android {
9 | compileSdkVersion 23
10 | buildToolsVersion "24.0.1"
11 |
12 | defaultConfig {
13 | minSdkVersion 15
14 | targetSdkVersion 23
15 | versionCode 1
16 | versionName "1.0"
17 | }
18 | buildTypes {
19 | release {
20 | minifyEnabled false
21 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
22 | }
23 | }
24 | }
25 |
26 | dependencies {
27 | compile fileTree(dir: 'libs', include: ['*.jar'])
28 | testCompile 'junit:junit:4.12'
29 | compile 'com.android.support:appcompat-v7:23.4.0'
30 | compile 'com.github.bumptech.glide:glide:3.7.0'
31 | }
32 |
33 | task generateSourcesJar(type: Jar) {
34 | from android.sourceSets.main.java.srcDirs
35 | classifier 'sources'
36 | }
37 |
38 | task generateJavadocs(type: Javadoc) {
39 | source = android.sourceSets.main.java.srcDirs
40 | classpath += project.files(android.getBootClasspath()
41 | .join(File.pathSeparator))
42 | }
43 |
44 | task generateJavadocsJar(type: Jar) {
45 | from generateJavadocs.destinationDir
46 | classifier 'javadoc'
47 | }
48 |
49 | artifacts {
50 | // archives generateJavaDocsJar
51 | archives generateSourcesJar
52 | }
53 |
54 | Properties properties = new Properties()
55 | properties.load(project.rootProject.file('local.properties').newDataInputStream())
56 | bintray {
57 | user = properties.getProperty("bintray.user")
58 | key = properties.getProperty("bintray.key")
59 | pkg {
60 | repo = 'maven'
61 | name = 'JikeGallery'
62 | desc = "A cool gallery view with vertical smooth animation which shows content more attractive."
63 |
64 | version {
65 | name = '1.0.0'
66 | desc = 'A cool gallery view with vertical smooth animation which shows content more attractive.'
67 | vcsTag = 'android, loadfing, view'
68 | }
69 |
70 | licenses = ['Apache-2.0']
71 | vcsUrl = 'https://github.com/JeasonWong/JikeGallery.git'
72 | websiteUrl = 'https://github.com/JeasonWong/JikeGallery'
73 |
74 | labels = ['android']
75 | publish = true
76 | publicDownloadNumbers = true
77 | }
78 | configurations = ['archives']
79 | }
80 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if "%DIRNAME%" == "" set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 | if "%@eval[2+2]" == "4" goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if "x%~1" == "x" goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if "%ERRORLEVEL%"=="0" goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if "%OS%"=="Windows_NT" endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 | 1.8
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
--------------------------------------------------------------------------------
/GalleryView/src/main/java/me/wangyuwei/galleryview/SmoothViewGroup.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | import android.animation.ValueAnimator;
4 | import android.content.Context;
5 | import android.util.AttributeSet;
6 | import android.view.ViewGroup;
7 | import android.view.animation.AccelerateDecelerateInterpolator;
8 |
9 | /**
10 | * 作者: 巴掌 on 16/8/6 23:58
11 | * Github: https://github.com/JeasonWong
12 | */
13 | public abstract class SmoothViewGroup extends ViewGroup {
14 |
15 | //滑动状态
16 | protected static final int STATUS_SMOOTHING = 0;
17 | //停止状态
18 | protected static final int STATUS_STOP = 1;
19 |
20 | //ViewGroup宽高
21 | protected int mWidth, mHeight;
22 | //变化的marginTop值
23 | protected int mSmoothMarginTop;
24 | //默认状态
25 | protected int mStatus = STATUS_STOP;
26 | //滚动时间间隔
27 | protected int mDuration = 500;
28 | //重复次数
29 | protected int mRepeatTimes = 0;
30 |
31 |
32 | public SmoothViewGroup(Context context, AttributeSet attrs) {
33 | this(context, attrs, 0);
34 | }
35 |
36 | public SmoothViewGroup(Context context, AttributeSet attrs, int defStyleAttr) {
37 | super(context, attrs, defStyleAttr);
38 | }
39 |
40 | @Override
41 | protected void onSizeChanged(int w, int h, int oldw, int oldh) {
42 | super.onSizeChanged(w, h, oldw, oldh);
43 | mWidth = w;
44 | mHeight = h;
45 | mSmoothMarginTop = -h;
46 | initView();
47 | }
48 |
49 | protected abstract void initView();
50 |
51 | /**
52 | * 开启滑动
53 | *
54 | */
55 | public void startSmooth() {
56 |
57 | if (mStatus != STATUS_STOP) {
58 | return;
59 | }
60 |
61 | ValueAnimator animator = ValueAnimator.ofFloat(-mHeight, 0);
62 | animator.setDuration(mDuration);
63 | animator.setInterpolator(new AccelerateDecelerateInterpolator());
64 | animator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
65 | @Override
66 | public void onAnimationUpdate(ValueAnimator animation) {
67 |
68 | float marginTop = (float) animation.getAnimatedValue();
69 | mSmoothMarginTop = (int) marginTop;
70 |
71 | if (marginTop == 0) {
72 |
73 | postDelayed(new Runnable() {
74 | @Override
75 | public void run() {
76 |
77 | mRepeatTimes++;
78 |
79 | mSmoothMarginTop = -mHeight;
80 |
81 | doAnimFinish();
82 |
83 | mStatus = STATUS_STOP;
84 |
85 | }
86 | }, 50);
87 |
88 | } else {
89 | doAnim();
90 | }
91 | }
92 | });
93 | animator.start();
94 | mStatus = STATUS_SMOOTHING;
95 | }
96 |
97 | //动画结束
98 | protected abstract void doAnimFinish();
99 |
100 | //动画进行时
101 | protected abstract void doAnim();
102 |
103 | /**
104 | * 是否是奇数圈
105 | *
106 | * @return 结果
107 | */
108 | protected boolean isOddCircle() {
109 | return mRepeatTimes % 2 == 1;
110 | }
111 |
112 | }
113 |
--------------------------------------------------------------------------------
/checkstyle.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
--------------------------------------------------------------------------------
/GalleryView/src/main/java/me/wangyuwei/galleryview/TitleView.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | import android.content.Context;
4 | import android.text.TextUtils;
5 | import android.util.AttributeSet;
6 | import android.view.View;
7 | import android.widget.TextView;
8 |
9 | import java.util.ArrayList;
10 | import java.util.List;
11 |
12 | /**
13 | * 作者: 巴掌 on 16/8/6 10:27
14 | * Github: https://github.com/JeasonWong
15 | */
16 | public class TitleView extends SmoothViewGroup {
17 |
18 |
19 | private List mTitleList = new ArrayList<>();
20 | private TextView[] mTexts = new TextView[2];
21 |
22 | private int mTextLineHeight = 0;
23 |
24 | public TitleView(Context context, AttributeSet attrs) {
25 | this(context, attrs, 0);
26 | }
27 |
28 | public TitleView(Context context, AttributeSet attrs, int defStyleAttr) {
29 | super(context, attrs, defStyleAttr);
30 | }
31 |
32 | @Override
33 | protected void initView() {
34 |
35 | //如果没有内容,则不进行初始化操作
36 | if (mTitleList.size() == 0) {
37 | return;
38 | }
39 |
40 | removeAllViews();
41 |
42 | MarginLayoutParams params = new MarginLayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT);
43 |
44 | for (int i = 0; i < mTexts.length; i++) {
45 | mTexts[i] = new TextView(getContext());
46 | mTexts[i].setText(getTitle(i));
47 | mTexts[i].setLines(2);
48 | mTexts[i].setEllipsize(TextUtils.TruncateAt.END);
49 | mTexts[i].setTextSize(14);
50 | if (mTextLineHeight < mTexts[i].getLineHeight()) {
51 | mTextLineHeight = mTexts[i].getLineHeight();
52 | }
53 | addViewInLayout(mTexts[i], -1, params, true);
54 | }
55 |
56 | }
57 |
58 | @Override
59 | protected void onLayout(boolean changed, int l, int t, int r, int b) {
60 | int cCount = getChildCount();
61 | MarginLayoutParams cParams;
62 |
63 | for (int i = 0; i < cCount; i++) {
64 | View childView = getChildAt(i);
65 | cParams = (MarginLayoutParams) childView.getLayoutParams();
66 |
67 | int cl = 0, ct = 0, cr, cb;
68 |
69 | if (isOddCircle()) {
70 | if (i == 1) {
71 | cl = cParams.leftMargin;
72 | ct = mHeight / 2 - mTextLineHeight + mSmoothMarginTop + mHeight;
73 | } else if (i == 0) {
74 | cl = cParams.leftMargin;
75 | ct = mHeight / 2 - mTextLineHeight + mSmoothMarginTop;
76 | }
77 | } else {
78 | if (i == 0) {
79 | cl = cParams.leftMargin;
80 | ct = mHeight / 2 - mTextLineHeight + mSmoothMarginTop + mHeight;
81 | } else if (i == 1) {
82 | cl = cParams.leftMargin;
83 | ct = mHeight / 2 - mTextLineHeight + mSmoothMarginTop;
84 | }
85 | }
86 |
87 | cr = cl + mWidth;
88 | cb = ct + mHeight;
89 | childView.layout(cl, ct, cr, cb);
90 | }
91 | }
92 |
93 | @Override
94 | protected void doAnimFinish() {
95 | if (isOddCircle()) {
96 | mTexts[0].setText(getTitle(mRepeatTimes + 1));
97 | } else {
98 | mTexts[1].setText(getTitle(mRepeatTimes + 1));
99 | }
100 |
101 | for (int i = 0; i < mTexts.length; i++) {
102 | mTexts[i].setAlpha(1);
103 | }
104 | }
105 |
106 | @Override
107 | protected void doAnim() {
108 | if (isOddCircle()) {
109 | mTexts[1].setAlpha(-mSmoothMarginTop / (float) mHeight);
110 | } else {
111 | mTexts[0].setAlpha(-mSmoothMarginTop / (float) mHeight);
112 | }
113 | requestLayout();
114 | }
115 |
116 | public void setTitleList(List titleList) {
117 | mTitleList = titleList;
118 | initView();
119 | }
120 |
121 | private String getTitle(int position) {
122 | position = position % mTitleList.size();
123 | return mTitleList.get(position);
124 | }
125 |
126 | }
127 |
--------------------------------------------------------------------------------
/GalleryView/src/main/java/me/wangyuwei/galleryview/Gallery.java:
--------------------------------------------------------------------------------
1 | package me.wangyuwei.galleryview;
2 |
3 | import android.content.Context;
4 | import android.graphics.Color;
5 | import android.util.AttributeSet;
6 | import android.view.View;
7 | import android.widget.ImageView;
8 |
9 | import com.bumptech.glide.Glide;
10 |
11 | import java.util.ArrayList;
12 | import java.util.List;
13 |
14 | /**
15 | * 作者: 巴掌 on 16/8/4 23:25
16 | * Github: https://github.com/JeasonWong
17 | */
18 | public class Gallery extends SmoothViewGroup {
19 |
20 | private List mImgList = new ArrayList<>();
21 | private ImageView[] mImgs = new ImageView[2];
22 | private View mShadowView;
23 |
24 | public Gallery(Context context, AttributeSet attrs) {
25 | this(context, attrs, 0);
26 | }
27 |
28 | public Gallery(Context context, AttributeSet attrs, int defStyleAttr) {
29 | super(context, attrs, defStyleAttr);
30 | }
31 |
32 | @Override
33 | protected void initView() {
34 |
35 | //如果没有内容,则不进行初始化操作
36 | if (mImgList.size() == 0) {
37 | return;
38 | }
39 |
40 | removeAllViews();
41 |
42 | MarginLayoutParams params = new MarginLayoutParams(mWidth, mHeight);
43 |
44 | //两个ImageView加载前两张图
45 | for (int i = 0; i < mImgs.length; i++) {
46 | mImgs[i] = new ImageView(getContext());
47 | addViewInLayout(mImgs[i], -1, params, true);
48 | Glide.with(getContext()).load(getImgPath(i)).centerCrop().into(mImgs[i]);
49 | }
50 |
51 | //创建阴影View
52 | mShadowView = new View(getContext());
53 | mShadowView.setBackgroundColor(Color.parseColor("#60000000"));
54 | mShadowView.setAlpha(0);
55 | addViewInLayout(mShadowView, -1, params, true);
56 | }
57 |
58 | @Override
59 | protected void onLayout(boolean changed, int l, int t, int r, int b) {
60 |
61 | int cCount = getChildCount();
62 | MarginLayoutParams cParams;
63 |
64 | for (int i = 0; i < cCount; i++) {
65 | View childView = getChildAt(i);
66 | cParams = (MarginLayoutParams) childView.getLayoutParams();
67 |
68 | int cl = 0, ct = 0, cr, cb;
69 |
70 | if (isOddCircle()) {
71 | if (i == 1) {
72 | cl = cParams.leftMargin;
73 | ct = mSmoothMarginTop + mHeight;
74 | } else if (i == 0) {
75 | cl = cParams.leftMargin;
76 | ct = mSmoothMarginTop;
77 | }
78 | } else {
79 | if (i == 0) {
80 | cl = cParams.leftMargin;
81 | ct = mSmoothMarginTop + mHeight;
82 | } else if (i == 1) {
83 | cl = cParams.leftMargin;
84 | ct = mSmoothMarginTop;
85 | }
86 | }
87 | //控制shadowView
88 | if (i == 2) {
89 | cl = cParams.leftMargin;
90 | ct = mSmoothMarginTop + mHeight;
91 | }
92 |
93 | cr = cl + mWidth;
94 | cb = ct + mHeight;
95 | childView.layout(cl, ct, cr, cb);
96 | }
97 |
98 | }
99 |
100 | @Override
101 | protected void doAnimFinish() {
102 | if (isOddCircle()) {
103 | Glide.with(getContext()).load(getImgPath(mRepeatTimes + 1)).centerCrop().into(mImgs[0]);
104 | } else {
105 | Glide.with(getContext()).load(getImgPath(mRepeatTimes + 1)).centerCrop().into(mImgs[1]);
106 | }
107 | mShadowView.setAlpha(0);
108 | }
109 |
110 | @Override
111 | protected void doAnim() {
112 | mShadowView.setAlpha(((1 - (-mSmoothMarginTop) / (float) mHeight)));
113 | requestLayout();
114 | }
115 |
116 | public void setImgList(List imgList) {
117 | mImgList = imgList;
118 | initView();
119 | }
120 |
121 | /**
122 | * 获取图片地址
123 | *
124 | * @param position 位置
125 | * @return 图片地址
126 | */
127 | private String getImgPath(int position) {
128 | position = position % mImgList.size();
129 | return mImgList.get(position);
130 | }
131 |
132 | }
133 |
--------------------------------------------------------------------------------
/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10 | DEFAULT_JVM_OPTS=""
11 |
12 | APP_NAME="Gradle"
13 | APP_BASE_NAME=`basename "$0"`
14 |
15 | # Use the maximum available, or set MAX_FD != -1 to use that value.
16 | MAX_FD="maximum"
17 |
18 | warn ( ) {
19 | echo "$*"
20 | }
21 |
22 | die ( ) {
23 | echo
24 | echo "$*"
25 | echo
26 | exit 1
27 | }
28 |
29 | # OS specific support (must be 'true' or 'false').
30 | cygwin=false
31 | msys=false
32 | darwin=false
33 | case "`uname`" in
34 | CYGWIN* )
35 | cygwin=true
36 | ;;
37 | Darwin* )
38 | darwin=true
39 | ;;
40 | MINGW* )
41 | msys=true
42 | ;;
43 | esac
44 |
45 | # Attempt to set APP_HOME
46 | # Resolve links: $0 may be a link
47 | PRG="$0"
48 | # Need this for relative symlinks.
49 | while [ -h "$PRG" ] ; do
50 | ls=`ls -ld "$PRG"`
51 | link=`expr "$ls" : '.*-> \(.*\)$'`
52 | if expr "$link" : '/.*' > /dev/null; then
53 | PRG="$link"
54 | else
55 | PRG=`dirname "$PRG"`"/$link"
56 | fi
57 | done
58 | SAVED="`pwd`"
59 | cd "`dirname \"$PRG\"`/" >/dev/null
60 | APP_HOME="`pwd -P`"
61 | cd "$SAVED" >/dev/null
62 |
63 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
64 |
65 | # Determine the Java command to use to start the JVM.
66 | if [ -n "$JAVA_HOME" ] ; then
67 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
68 | # IBM's JDK on AIX uses strange locations for the executables
69 | JAVACMD="$JAVA_HOME/jre/sh/java"
70 | else
71 | JAVACMD="$JAVA_HOME/bin/java"
72 | fi
73 | if [ ! -x "$JAVACMD" ] ; then
74 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
75 |
76 | Please set the JAVA_HOME variable in your environment to match the
77 | location of your Java installation."
78 | fi
79 | else
80 | JAVACMD="java"
81 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
82 |
83 | Please set the JAVA_HOME variable in your environment to match the
84 | location of your Java installation."
85 | fi
86 |
87 | # Increase the maximum file descriptors if we can.
88 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
89 | MAX_FD_LIMIT=`ulimit -H -n`
90 | if [ $? -eq 0 ] ; then
91 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
92 | MAX_FD="$MAX_FD_LIMIT"
93 | fi
94 | ulimit -n $MAX_FD
95 | if [ $? -ne 0 ] ; then
96 | warn "Could not set maximum file descriptor limit: $MAX_FD"
97 | fi
98 | else
99 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
100 | fi
101 | fi
102 |
103 | # For Darwin, add options to specify how the application appears in the dock
104 | if $darwin; then
105 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
106 | fi
107 |
108 | # For Cygwin, switch paths to Windows format before running java
109 | if $cygwin ; then
110 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
111 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
112 | JAVACMD=`cygpath --unix "$JAVACMD"`
113 |
114 | # We build the pattern for arguments to be converted via cygpath
115 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
116 | SEP=""
117 | for dir in $ROOTDIRSRAW ; do
118 | ROOTDIRS="$ROOTDIRS$SEP$dir"
119 | SEP="|"
120 | done
121 | OURCYGPATTERN="(^($ROOTDIRS))"
122 | # Add a user-defined pattern to the cygpath arguments
123 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
124 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
125 | fi
126 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
127 | i=0
128 | for arg in "$@" ; do
129 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
130 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
131 |
132 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
133 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
134 | else
135 | eval `echo args$i`="\"$arg\""
136 | fi
137 | i=$((i+1))
138 | done
139 | case $i in
140 | (0) set -- ;;
141 | (1) set -- "$args0" ;;
142 | (2) set -- "$args0" "$args1" ;;
143 | (3) set -- "$args0" "$args1" "$args2" ;;
144 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
145 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
146 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
147 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
148 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
149 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
150 | esac
151 | fi
152 |
153 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
154 | function splitJvmOpts() {
155 | JVM_OPTS=("$@")
156 | }
157 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
158 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
159 |
160 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
161 |
--------------------------------------------------------------------------------