diff --git a/.gitignore b/.gitignore index 415d566c7..12a398578 100644 --- a/.gitignore +++ b/.gitignore @@ -12,9 +12,12 @@ bin/ gen/ target/ +build/ # Local configuration file (sdk path, etc) local.properties +gradle.properties +.gradle build.xml # Backup files @@ -27,6 +30,7 @@ build.xml .idea *.iml gen-external-apklibs +out #transifex downloads changelog description @@ -37,3 +41,4 @@ proguard libs *.DS_Store src/de/danoeh/antennapod/util/flattr/FlattrConfig.java +gradle.properties diff --git a/.gitmodules b/.gitmodules index cd43a243e..17dac28b0 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,9 +1,3 @@ -[submodule "submodules/ActionBarSherlock"] - path = submodules/ActionBarSherlock - url = git://github.com/JakeWharton/ActionBarSherlock.git -[submodule "submodules/ViewPagerIndicator"] - path = submodules/ViewPagerIndicator - url = git://github.com/JakeWharton/Android-ViewPagerIndicator.git [submodule "submodules/dslv"] path = submodules/dslv - url = git://github.com/bauerca/drag-sort-listview.git + url = git://github.com/danieloeh/drag-sort-listview.git diff --git a/.tx/config b/.tx/config index 3a05b8725..145e12a23 100644 --- a/.tx/config +++ b/.tx/config @@ -21,6 +21,7 @@ trans.ru-RU = res/values-ru/strings.xml trans.ru_RU = res/values-ru/strings.xml trans.uk_UA = res/values-uk-rUA/strings.xml trans.zh_CN = res/values-zh-rCN/strings.xml +trans.sv_SE = res/values-sv-rSE/strings.xml [antennapod.description] file_filter = description/.txt diff --git a/AndroidManifest.xml b/AndroidManifest.xml index 38441a520..5d33f2957 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -1,15 +1,15 @@ + android:versionCode="32" + android:versionName="0.9.7.5" > + android:targetSdkVersion="18" /> @@ -40,15 +40,16 @@ android:name=".activity.MainActivity" android:configChanges="keyboardHidden|orientation" android:label="@string/app_name" > - - - - - - + android:value="de.danoeh.antennapod.activity.SearchActivity" /> + + + + + + @@ -70,6 +72,7 @@ + @@ -81,6 +84,7 @@ + @@ -99,7 +103,10 @@ android:configChanges="orientation|screenSize" > + android:value="de.danoeh.antennapod.activity.SearchActivity" /> + - + android:value="de.danoeh.antennapod.activity.MiroGuideSearchActivity" /> + - - - - - About AntennaPod - - - -

Used libraries

-

ActionBarSherlock (Link)

- by Jake Wharton, licensed under the Apache 2.0 license - -

Android-ViewPagerIndicator (Link)

- by Jake Wharton, licensed under the Apache 2.0 license - -

Apache Commons (Link)

- by The Apache Software Foundation, licensed under the Apache 2.0 license -

flattr4j (Link)

- licensed under the Apache 2.0 license -

drag-sort-listview (Link)

- licensed under the Apache 2.0 license - + + } + + versiontag { + color: gray; + } + + h1 { + font-size: 15pt; + } + + h2 { + font-size: 13pt; + } + + a { + font-size: 14px; + color: #00A8DF; + text-decoration: none; + } + + + About AntennaPod + + + +

Used libraries

+ +

NineOldAndroids (Link)

+by Jake Wharton, licensed under the Apache 2.0 license + +

Apache Commons (Link)

+by The Apache Software Foundation, licensed under the Apache 2.0 license +

flattr4j (Link)

+licensed under the Apache 2.0 license +

drag-sort-listview (Link)

+licensed under the Apache 2.0 license +

Presto Client (Link)

+licensed under the Apache 2.0 license + diff --git a/build.gradle b/build.gradle new file mode 100644 index 000000000..92f15b779 --- /dev/null +++ b/build.gradle @@ -0,0 +1,97 @@ +buildscript { + repositories { + mavenCentral() + } + dependencies { + classpath 'com.android.tools.build:gradle:0.5.6' + } +} +apply plugin: 'android' + +repositories { + mavenCentral() +} +dependencies { + def libsdir = new File('libs'); + if (!libsdir.exists()) { + println "Creating libs directory" + libsdir.mkdir() + } + def prestoLib = new File('libs/presto_client-0.8.5.jar') + if (!prestoLib.exists()) { + println "Downloading presto library into libs folder" + new URL('http://www.aocate.com/presto/client/presto_client-0.8.5.jar').withInputStream{ i -> prestoLib.withOutputStream{ it << i }} + } + + compile 'com.android.support:appcompat-v7:18.0.+' + compile 'org.apache.commons:commons-lang3:3.1' + compile ('org.shredzone.flattr4j:flattr4j-core:2.7') { + exclude group: 'org.apache.httpcomponents', module: 'httpcore' + exclude group: 'org.apache.httpcomponents', module: 'httpclient' + exclude group: 'org.json', module: 'json' + } + compile 'commons-io:commons-io:2.4' + compile 'com.nineoldandroids:library:2.4.0' + compile project(':submodules:dslv:library') + compile files('libs/presto_client-0.8.5.jar') +} + +android { + compileSdkVersion 18 + buildToolsVersion "17" + + defaultConfig { + minSdkVersion 10 + targetSdkVersion 18 + testPackageName "de.test.antennapod" + testInstrumentationRunner "instrumentationTest.de.test.antennapod.AntennaPodTestRunner" + } + + signingConfigs { + releaseConfig { + if (project.hasProperty('releaseStoreFile')) { + storeFile file(releaseStoreFile) + } else { + storeFile file('keystore') + } + if (project.hasProperty('releaseStorePassword')) { + storePassword releaseStorePassword + } else { + storePassword "password" + } + if (project.hasProperty('releaseKeyAlias')) { + keyAlias releaseKeyAlias + } else { + keyAlias "alias" + } + if (project.hasProperty('releaseKeyPassword')) { + keyPassword releaseKeyPassword + } else { + keyPassword "password" + } + } + } + + sourceSets { + main { + manifest.srcFile 'AndroidManifest.xml' + java.srcDirs = ['src'] + resources.srcDirs = ['src'] + aidl.srcDirs = ['src'] + renderscript.srcDirs = ['src'] + res.srcDirs = ['res'] + assets.srcDirs = ['assets'] + } + } + + buildTypes { + debug { + packageNameSuffix ".debug" + } + release { + runProguard true + proguardFile 'proguard.cfg' + signingConfig signingConfigs.releaseConfig + } + } +} diff --git a/pom.xml b/pom.xml index f7935a0d3..c195a6789 100644 --- a/pom.xml +++ b/pom.xml @@ -1,246 +1,268 @@ - 4.0.0 - de.danoeh - antennapod - apk - 0.9.7.4 - AntennaPod + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> + 4.0.0 + de.danoeh + antennapod + apk + 0.9.7.5 + AntennaPod + + + android.support + compatibility-v4 + 18 + + + android.support + compatibility-v7-appcompat + 18 + apklib + + + android.support + compatibility-v7-appcompat + 18 + jar + + + com.google.android + android-test + 2.2.1 + + + org.apache.commons + commons-lang3 + 3.1 + + + org.shredzone.flattr4j + flattr4j-core + 2.7 + compile + + + org.apache.httpcomponents + httpcore + + + org.apache.httpcomponents + httpclient + + + org.json + json + + + + + com.google.android + android + provided + 4.1.1.4 + + + com.google.android + annotations + 4.1.1.4 + + + commons-io + commons-io + 2.4 + + + com.mobeta.android.dslv + drag-sort-listview + 0.6.1-SNAPSHOT + apklib + + + com.nineoldandroids + library + 2.4.0 + + + com.aocate + presto_client + 0.8.5 + jar + system + ${project.basedir}/libs/presto_client-0.8.5.jar + + - - - org.apache.commons - commons-lang3 - 3.1 - - - org.shredzone.flattr4j - flattr4j-core - 2.4 - compile - - - org.apache.httpcomponents - httpcore - - - org.apache.httpcomponents - httpclient - - - org.json - json - - - - - com.google.android - android - provided - 4.1.1.4 - - - com.actionbarsherlock - library - 4.1.0 - apklib - - - com.viewpagerindicator - library - 2.3.1 - apklib - - - com.google.android - annotations - 4.1.1.4 - - - commons-io - commons-io - 2.4 - - - com.mobeta.android.dslv - drag-sort-listview - 0.6.1-SNAPSHOT - apklib - - + + src + + + org.apache.maven.plugins + maven-compiler-plugin + 2.3.2 + + 1.6 + 1.6 + + + + com.jayway.maven.plugins.android.generation2 + android-maven-plugin + 3.6.1 + + + ${env.ANDROID_HOME} + 18 + + + true + + + true + + + alignApk + package + + zipalign + + + + + + - - src - - - org.apache.maven.plugins - maven-compiler-plugin - 2.3.2 - - 1.6 - 1.6 - - - - com.jayway.maven.plugins.android.generation2 - android-maven-plugin - 3.6.0 - - - ${env.ANDROID_HOME} - 17 - - - true - - - true - - - alignApk - package - - zipalign - - - - - - - - - - development - - - - environment - !production - - - - In Development - - - - production - - In Production - - - - release - - - - performRelease - true - - - - - - org.apache.maven.plugins - maven-jarsigner-plugin - - - signing - - sign - verify - - package - true - - true - - - ${project.build.directory}/${project.artifactId}-${project.version}.apk - - ${sign.keystore} - ${sign.alias} - ${sign.storepass} - ${sign.keypass} - true + + + development + + + + environment + !production + + + + In Development + + + + production + + In Production + + + + release + + + + performRelease + true + + + + + + org.apache.maven.plugins + maven-jarsigner-plugin + + + signing + + sign + verify + + package + true + + true + + + ${project.build.directory}/${project.artifactId}-${project.version}.apk + + ${sign.keystore} + ${sign.alias} + ${sign.storepass} + ${sign.keypass} + true -sigalgMD5withRSA -digestalgSHA1 - - - - - - - com.jayway.maven.plugins.android.generation2 - android-maven-plugin - true - - - false - - - false - true - ${project.build.directory}/${project.artifactId}-${project.version}.apk - ${project.build.directory}/${project.artifactId}-${project.version}-signed-aligned.apk - - - - false - false - - + + + + + + + com.jayway.maven.plugins.android.generation2 + android-maven-plugin + true + + + false + + false - proguard.cfg - - - - - alignApk - package - - zipalign - - - - - - org.codehaus.mojo - build-helper-maven-plugin - - - - ${project.build.directory}/${project.artifactId}-${project.version}-signed-aligned.apk - apk - signed-aligned - - - ${project.build.directory}/proguard/mapping.txt - map - release - - - - - - attach-signed-aligned - package - - attach-artifact - - - - - - - - + true + ${project.build.directory}/${project.artifactId}-${project.version}.apk + ${project.build.directory}/${project.artifactId}-${project.version}-signed-aligned.apk + + + + false + false + + + false + proguard-mvn.cfg + + + + + alignApk + package + + zipalign + + + + + + org.codehaus.mojo + build-helper-maven-plugin + + + + ${project.build.directory}/${project.artifactId}-${project.version}-signed-aligned.apk + apk + signed-aligned + + + ${project.build.directory}/proguard/mapping.txt + map + release + + + + + + attach-signed-aligned + package + + attach-artifact + + + + + + + + diff --git a/proguard-mvn.cfg b/proguard-mvn.cfg new file mode 100644 index 000000000..70019bfcb --- /dev/null +++ b/proguard-mvn.cfg @@ -0,0 +1,66 @@ +-printmapping out.map +-renamesourcefileattribute SourceFile +-keepattributes SourceFile,LineNumberTable + +-dontpreverify +-repackageclasses '' +-allowaccessmodification +-optimizations !code/simplification/arithmetic +-keepattributes *Annotation* + +-injars libs/presto_client-0.8.5.jar + +-keep public class * extends android.app.Activity +-keep public class * extends android.app.Application +-keep public class * extends android.app.Service +-keep public class * extends android.content.BroadcastReceiver +-keep public class * extends android.content.ContentProvider + +-keep public class * extends android.view.View { + public (android.content.Context); + public (android.content.Context, android.util.AttributeSet); + public (android.content.Context, android.util.AttributeSet, int); + public void set*(...); +} + +-keepclassmembers enum * { + public static **[] values(); + public static ** valueOf(java.lang.String); +} + +-keepclasseswithmembers class * { + public (android.content.Context, android.util.AttributeSet); +} + +-keepclasseswithmembers class * { + public (android.content.Context, android.util.AttributeSet, int); +} + +-keepclassmembers class * extends android.content.Context { + public void *(android.view.View); + public void *(android.view.MenuItem); +} + +-keepclassmembers class * implements android.os.Parcelable { + static android.os.Parcelable$Creator CREATOR; +} + +-keepclassmembers class **.R$* { + public static ; +} + +-keep class android.support.v4.** { *; } +-keep interface android.support.v4.** { *; } +-keep class android.support.v7.** { *; } +-keep interface android.support.v7.** { *; } +-dontwarn android.support.v4.** +-dontwarn android.support.v7.** + +-keepattributes *Annotation* + +-keep class org.shredzone.flattr4j.** { *; } +-dontwarn org.shredzone.flattr4j.** + +-keep class org.apache.commons.** { *; } + +-dontskipnonpubliclibraryclassmembers diff --git a/proguard.cfg b/proguard.cfg index 3e5ad54e4..96111d41f 100644 --- a/proguard.cfg +++ b/proguard.cfg @@ -8,10 +8,7 @@ -optimizations !code/simplification/arithmetic -keepattributes *Annotation* -#-libraryjars libs/android-support-v4.jar -#-libraryjars libs/commons-lang3-3.1.jar -#-libraryjars libs/flattr4j-core-2.4.jar -#-libraryjars libs/commons-io-2.4.jar +#-injars libs/presto_client-0.8.5.jar -keep public class * extends android.app.Activity -keep public class * extends android.app.Application @@ -52,10 +49,12 @@ public static ; } --keep class android.support.v4.app.** { *; } --keep interface android.support.v4.app.** { *; } --keep class com.actionbarsherlock.** { *; } --keep interface com.actionbarsherlock.** { *; } +-keep class android.support.v4.** { *; } +-keep interface android.support.v4.** { *; } +-keep class android.support.v7.** { *; } +-keep interface android.support.v7.** { *; } +-dontwarn android.support.v4.** +-dontwarn android.support.v7.** -keepattributes *Annotation* diff --git a/project.properties b/project.properties index 2706f89b9..75f295e31 100644 --- a/project.properties +++ b/project.properties @@ -9,7 +9,7 @@ # Project target. proguard.config=proguard.cfg -target=android-17 +target=android-18 android.library.reference.1=submodules/ActionBarSherlock/library android.library.reference.2=submodules/ViewPagerIndicator/library android.library.reference.3=submodules/dslv/library diff --git a/res/layout-land/audioplayer_activity.xml b/res/layout-land/audioplayer_activity.xml index 521dbc68a..1e671c745 100644 --- a/res/layout-land/audioplayer_activity.xml +++ b/res/layout-land/audioplayer_activity.xml @@ -92,14 +92,12 @@ android:layout_width="80dp" android:layout_height="match_parent" android:layout_centerHorizontal="true" - android:layout_marginLeft="8dp" - android:layout_marginRight="8dp" android:background="?attr/borderless_button" android:src="?attr/av_pause" /> + +