Skip to content

Commit 3fe1411

Browse files
committed
change: Migrate the project from Eclipse/ant to Android Studio/Gradle
1 parent 9447d46 commit 3fe1411

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+357
-179
lines changed

.gitignore

+13-10
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,32 @@
1-
# built application files
1+
# Built application files
22
*.apk
33
*.ap_
44

5-
# files for the dex VM
5+
# Files for the Dalvik VM
66
*.dex
77

88
# Java class files
99
*.class
1010

11-
# generated files
11+
# Generated files
1212
bin/
1313
gen/
1414

15+
# Gradle files
16+
.gradle/
17+
build/
18+
1519
# Local configuration file (sdk path, etc)
1620
local.properties
1721

22+
# Proguard folder generated by Eclipse
23+
proguard/
24+
1825
# Eclipse project files
1926
.classpath
2027
.project
2128

22-
# Proguard folder generated by Eclipse
23-
proguard/
24-
25-
# Intellij project files
26-
*.iml
27-
*.ipr
28-
*.iws
29+
# Android Studio files
2930
.idea/
31+
*.iml
32+

.gitmodules

-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
11
[submodule "submodules/AndroidLib"]
22
path = submodules/AndroidLib
33
url = https://github.com/yongce/AndroidLib.git
4-
[submodule "submodules/android-support-v7"]
5-
path = submodules/android-support-v7
6-
url = https://github.com/yongce/android-support-v7.git

ant.properties

-17
This file was deleted.

app/build.gradle

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
apply plugin: 'com.android.application'
2+
3+
android {
4+
compileSdkVersion rootProject.ext.compileSdkVersion
5+
buildToolsVersion rootProject.ext.buildToolsVersion
6+
7+
defaultConfig {
8+
applicationId "me.ycdev.android.uidemo"
9+
versionCode 1
10+
versionName "1.0"
11+
12+
minSdkVersion 8
13+
targetSdkVersion 21
14+
}
15+
16+
buildTypes {
17+
release {
18+
minifyEnabled false
19+
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
20+
}
21+
}
22+
}
23+
24+
dependencies {
25+
compile project(':androidLib')
26+
compile 'com.android.support:appcompat-v7:21.0.3'
27+
}

AndroidManifest.xml renamed to app/src/main/AndroidManifest.xml

+2-6
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3-
package="me.ycdev.android.uidemo"
4-
android:versionCode="1"
5-
android:versionName="1.0" >
6-
7-
<uses-sdk android:minSdkVersion="7" android:targetSdkVersion="19" />
3+
package="me.ycdev.android.uidemo">
84

95
<application
106
android:icon="@drawable/ic_launcher"
@@ -32,4 +28,4 @@
3228
android:label="@string/module_transitions_title" />
3329
</application>
3430

35-
</manifest>
31+
</manifest>

src/me/ycdev/android/uidemo/base/GridEntriesActivity.java renamed to app/src/main/java/me/ycdev/android/uidemo/base/GridEntriesActivity.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
import java.util.List;
44

5+
import me.ycdev.android.lib.common.utils.IntentUtils;
56
import me.ycdev.android.uidemo.R;
6-
import me.ycdev.androidlib.utils.IntentUtils;
77

88
import android.app.Activity;
99
import android.content.Context;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<shape xmlns:android="http://schemas.android.com/apk/res/android"
3+
android:shape="oval" >
4+
<gradient
5+
android:centerX="0.5"
6+
android:centerY="0.5"
7+
android:startColor="#ff0000"
8+
android:endColor="#aa330000"
9+
android:gradientRadius="100"
10+
android:type="radial"
11+
android:useLevel="false" /> <!-- useLevel must be "false" when type is "radial" -->
12+
</shape>
+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<shape xmlns:android="http://schemas.android.com/apk/res/android"
3+
android:shape="ring"
4+
android:innerRadiusRatio="6"
5+
android:thicknessRatio="6"
6+
android:useLevel="false" >
7+
<gradient
8+
android:centerX="0.5"
9+
android:centerY="0.5"
10+
android:startColor="#ff00ffff"
11+
android:endColor="#0000ffff"
12+
android:gradientRadius="200"
13+
android:type="radial"
14+
android:useLevel="false" /> <!-- useLevel must be "false" when type is "radial" -->
15+
</shape>

res/layout/drawables_shapes.xml renamed to app/src/main/res/layout/drawables_shapes.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,16 @@
4444
android:layout_height="100dp"
4545
android:layout_margin="10dp"
4646
android:text="@string/drawables_shape_oval"
47-
android:background="@drawable/shape_oval" />
47+
android:background="@drawable/shape_oval_radial" />
4848
<Button
4949
android:layout_width="200dp"
5050
android:layout_height="100dp"
5151
android:layout_margin="10dp"
5252
android:text="@string/drawables_shape_oval"
53-
android:background="@drawable/shape_oval" />
53+
android:background="@drawable/shape_oval_sweep" />
5454
<Button
5555
android:layout_width="200dp"
56-
android:layout_height="100dp"
56+
android:layout_height="200dp"
5757
android:layout_margin="10dp"
5858
android:text="@string/drawables_shape_ring"
5959
android:background="@drawable/shape_ring" />
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

build.gradle

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
buildscript {
2+
repositories {
3+
jcenter()
4+
}
5+
dependencies {
6+
classpath 'com.android.tools.build:gradle:1.0.0'
7+
}
8+
}
9+
10+
ext {
11+
compileSdkVersion = 21
12+
buildToolsVersion = "21.1.1"
13+
}
14+
15+
allprojects {
16+
repositories {
17+
jcenter()
18+
}
19+
}

build.xml

-92
This file was deleted.

gradle/wrapper/gradle-wrapper.jar

48.7 KB
Binary file not shown.
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#Wed Apr 10 15:27:10 PDT 2013
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.2.1-all.zip

0 commit comments

Comments
 (0)