Mavenized (almost) everything - Transcode feature removed

This commit is contained in:
YuviPanda 2013-01-25 03:00:36 +05:30
parent 0a493dc8a1
commit 3a313f3fb3
444 changed files with 1703 additions and 34416 deletions

16
.gitignore vendored
View file

@ -1,16 +0,0 @@
# built application files
*.apk
*.ap_
# files for the dex VM
*.dex
# Java class files
*.class
# generated files
bin/
gen/
# Local configuration file (sdk path, etc)
local.properties

View file

@ -1,35 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>commons</name>
<comment></comment>
<projects>
<project>ActionBarSherlock</project>
<project>java-mwapi</project>
</projects>
<buildSpec>
<buildCommand>
<name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.android.ide.eclipse.adt.PreCompilerBuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.android.ide.eclipse.adt.ApkBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>com.android.ide.eclipse.adt.AndroidNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

View file

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.wikimedia.commons.test" android:versionCode="1" android:versionName="1.0-SNAPSHOT">
<application android:icon="@drawable/icon" android:label="@string/app_name">
<uses-library android:name="android.test.runner" />
</application>
<instrumentation android:targetPackage="org.wikimedia.commons"
android:name="android.test.InstrumentationTestRunner" />
</manifest>

71
commons-it/commons-it.iml Normal file
View file

@ -0,0 +1,71 @@
<?xml version="1.0" encoding="UTF-8"?>
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="android" name="Android">
<configuration>
<option name="GEN_FOLDER_RELATIVE_PATH_APT" value="/target/generated-sources/r" />
<option name="GEN_FOLDER_RELATIVE_PATH_AIDL" value="/target/generated-sources/aidl" />
<option name="MANIFEST_FILE_RELATIVE_PATH" value="/AndroidManifest.xml" />
<option name="RES_FOLDER_RELATIVE_PATH" value="/res" />
<option name="ASSETS_FOLDER_RELATIVE_PATH" value="/assets" />
<option name="LIBS_FOLDER_RELATIVE_PATH" value="/src/main/native" />
<option name="USE_CUSTOM_APK_RESOURCE_FOLDER" value="false" />
<option name="CUSTOM_APK_RESOURCE_FOLDER" value="/target/generated-sources/combined-resources/res" />
<option name="USE_CUSTOM_COMPILER_MANIFEST" value="false" />
<option name="CUSTOM_COMPILER_MANIFEST" value="" />
<option name="APK_PATH" value="/target/commons-it.apk" />
<option name="LIBRARY_PROJECT" value="false" />
<option name="RUN_PROCESS_RESOURCES_MAVEN_TASK" value="false" />
<option name="GENERATE_UNSIGNED_APK" value="false" />
<option name="CUSTOM_DEBUG_KEYSTORE_PATH" value="" />
<option name="PACK_TEST_CODE" value="false" />
<option name="RUN_PROGUARD" value="false" />
<option name="PROGUARD_CFG_PATH" value="/proguard-project.txt" />
<resOverlayFolders>
<path>/res-overlay</path>
</resOverlayFolders>
<includeSystemProguardFile>true</includeSystemProguardFile>
<includeAssetsFromLibraries>true</includeAssetsFromLibraries>
<additionalNativeLibs />
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_5" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/target/idea-classes" />
<output-test url="file://$MODULE_DIR$/target/idea-test-classes" />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/target/generated-sources/r" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
<excludeFolder url="file://$MODULE_DIR$/target/classes" />
<excludeFolder url="file://$MODULE_DIR$/target/generated-sources/combined-assets" />
<excludeFolder url="file://$MODULE_DIR$/target/generated-sources/combined-resources" />
<excludeFolder url="file://$MODULE_DIR$/target/generated-sources/extracted-dependencies" />
<excludeFolder url="file://$MODULE_DIR$/target/unpack" />
</content>
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" scope="PROVIDED" name="Maven: android:android:4.1_r2" level="project" />
<orderEntry type="library" name="Maven: com.google.android:android-test:4.0.1.2" level="project" />
<orderEntry type="library" name="Maven: com.google.android:android:4.0.1.2" level="project" />
<orderEntry type="library" name="Maven: commons-logging:commons-logging:1.1.1" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpclient:4.0.1" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpcore:4.0.1" level="project" />
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.3" level="project" />
<orderEntry type="library" name="Maven: org.khronos:opengl-api:gl1.1-android-2.1_r1" level="project" />
<orderEntry type="library" name="Maven: xerces:xmlParserAPIs:2.6.2" level="project" />
<orderEntry type="library" name="Maven: xpp3:xpp3:1.1.4c" level="project" />
<orderEntry type="library" name="Maven: org.json:json:20080701" level="project" />
<orderEntry type="library" scope="PROVIDED" name="Maven: junit:junit:4.10" level="project" />
<orderEntry type="library" scope="PROVIDED" name="Maven: org.hamcrest:hamcrest-core:1.1" level="project" />
<orderEntry type="library" name="Maven: org.mediawiki:api:1.0" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:fluent-hc:4.2.2" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpmime:4.2.2" level="project" />
<orderEntry type="library" name="Maven: in.yuvi:http.fluent:1.0" level="project" />
<orderEntry type="library" name="Maven: com.actionbarsherlock:actionbarsherlock:apklib:4.2.0" level="project" />
<orderEntry type="library" name="Maven: com.google.android:support-v4:r7" level="project" />
<orderEntry type="library" name="Maven: de.akquinet.android.androlog:androlog:1.0.5" level="project" />
<orderEntry type="module" module-name="commons" />
<orderEntry type="jdk" jdkName="Android 4.0.3 Platform" jdkType="Android SDK" />
<orderEntry type="module" module-name="~apklib-com.actionbarsherlock_actionbarsherlock_4.2.0" />
</component>
</module>

102
commons-it/pom.xml Normal file
View file

@ -0,0 +1,102 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.wikimedia</groupId>
<artifactId>commons-parent</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.wikimedia</groupId>
<artifactId>commons-it</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>apk</packaging>
<name>commons-it - Integration tests</name>
<properties>
<!--
When not running a release, we are deploying the plain artifact (so no classifier)
This is overridden during the release.
-->
<zipaligned-classifier></zipaligned-classifier>
</properties>
<dependencies>
<dependency>
<groupId>android</groupId>
<artifactId>android</artifactId>
</dependency>
<dependency>
<groupId>com.google.android</groupId>
<artifactId>android-test</artifactId>
<version>4.0.1.2</version>
</dependency>
<dependency>
<groupId>org.wikimedia</groupId>
<artifactId>commons</artifactId>
<type>apk</type>
<version>1.0-SNAPSHOT</version>
<classifier>${zipaligned-classifier}</classifier> <!-- classifier set according to the ran profile -->
</dependency>
<dependency>
<groupId>org.wikimedia</groupId>
<artifactId>commons</artifactId>
<type>jar</type>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<extensions>true</extensions>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>release</id>
<properties>
<!--
When running a release, we must deployed the final artifact (signed and zipaligned).
-->
<zipaligned-classifier>aligned</zipaligned-classifier>
</properties>
<build>
<plugins>
<plugin>
<artifactId>maven-jarsigner-plugin</artifactId>
<executions>
<execution>
<id>sign-application-it-apk</id>
<phase>package</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<configuration>
<sign>
<debug>false</debug>
</sign>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>

Binary file not shown.

After

Width:  |  Height:  |  Size: 4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/hello"
/>
</LinearLayout>

View file

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="hello">Hello commons-it!</string>
<string name="app_name">commons-it - tests</string>
</resources>

14
commons-parent.iml Normal file
View file

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_5" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/target/classes" />
<output-test url="file://$MODULE_DIR$/target/test-classes" />
<exclude-output />
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/target" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

View file

@ -0,0 +1,19 @@
# Androlog configuration
# this file must be pushed to /sdcard/androlog.properties:
# adb push androlog.properties /sdcard/androlog.properties
# more detail on: https://github.com/akquinet/androlog/wiki/Androlog-configuration
androlog.active = true
#Configure the default log level:
#androlog.default.level=INFO
#Configure specific loggers
#Enable the reporting
#More info on: https://github.com/akquinet/androlog/wiki/Androlog-reporting
#androlog.report.active=true
#androlog.report.reporters=de.akquinet.android.androlog.reporter.MailReporter
#androlog.reporter.mail.address=me@my.company.com
#androlog.report.default.level=WARN
#androlog.report.log.items=40
#androlog.report.trigger.level=ERROR

View file

@ -0,0 +1,126 @@
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<!-- /etc/fonts/fonts.conf file to configure system font access -->
<fontconfig>
<!-- Font directory list -->
<dir prefix="xdg">fontconfig/fonts</dir>
<!-- Font cache directory list -->
<cachedir prefix="xdg">fontconfig</cachedir>
<!--
Accept deprecated 'mono' alias, replacing it with 'monospace'
-->
<match target="pattern">
<test qual="any" name="family">
<string>mono</string>
</test>
<edit name="family" mode="assign" binding="same">
<string>monospace</string>
</edit>
</match>
<!--
Accept alternate 'sans serif' spelling, replacing it with 'sans-serif'
-->
<match target="pattern">
<test qual="any" name="family">
<string>sans serif</string>
</test>
<edit name="family" mode="assign" binding="same">
<string>sans-serif</string>
</edit>
</match>
<!--
Accept deprecated 'sans' alias, replacing it with 'sans-serif'
-->
<match target="pattern">
<test qual="any" name="family">
<string>sans</string>
</test>
<edit name="family" mode="assign" binding="same">
<string>sans-serif</string>
</edit>
</match>
<config>
<!--
These are the default Unicode chars that are expected to be blank
in fonts. All other blank chars are assumed to be broken and
won't appear in the resulting charsets
-->
<blank>
<int>0x0020</int> <!-- SPACE -->
<int>0x00A0</int> <!-- NO-BREAK SPACE -->
<int>0x00AD</int> <!-- SOFT HYPHEN -->
<int>0x034F</int> <!-- COMBINING GRAPHEME JOINER -->
<int>0x0600</int> <!-- ARABIC NUMBER SIGN -->
<int>0x0601</int> <!-- ARABIC SIGN SANAH -->
<int>0x0602</int> <!-- ARABIC FOOTNOTE MARKER -->
<int>0x0603</int> <!-- ARABIC SIGN SAFHA -->
<int>0x06DD</int> <!-- ARABIC END OF AYAH -->
<int>0x070F</int> <!-- SYRIAC ABBREVIATION MARK -->
<int>0x115F</int> <!-- HANGUL CHOSEONG FILLER -->
<int>0x1160</int> <!-- HANGUL JUNGSEONG FILLER -->
<int>0x1680</int> <!-- OGHAM SPACE MARK -->
<int>0x17B4</int> <!-- KHMER VOWEL INHERENT AQ -->
<int>0x17B5</int> <!-- KHMER VOWEL INHERENT AA -->
<int>0x180E</int> <!-- MONGOLIAN VOWEL SEPARATOR -->
<int>0x2000</int> <!-- EN QUAD -->
<int>0x2001</int> <!-- EM QUAD -->
<int>0x2002</int> <!-- EN SPACE -->
<int>0x2003</int> <!-- EM SPACE -->
<int>0x2004</int> <!-- THREE-PER-EM SPACE -->
<int>0x2005</int> <!-- FOUR-PER-EM SPACE -->
<int>0x2006</int> <!-- SIX-PER-EM SPACE -->
<int>0x2007</int> <!-- FIGURE SPACE -->
<int>0x2008</int> <!-- PUNCTUATION SPACE -->
<int>0x2009</int> <!-- THIN SPACE -->
<int>0x200A</int> <!-- HAIR SPACE -->
<int>0x200B</int> <!-- ZERO WIDTH SPACE -->
<int>0x200C</int> <!-- ZERO WIDTH NON-JOINER -->
<int>0x200D</int> <!-- ZERO WIDTH JOINER -->
<int>0x200E</int> <!-- LEFT-TO-RIGHT MARK -->
<int>0x200F</int> <!-- RIGHT-TO-LEFT MARK -->
<int>0x2028</int> <!-- LINE SEPARATOR -->
<int>0x2029</int> <!-- PARAGRAPH SEPARATOR -->
<int>0x202A</int> <!-- LEFT-TO-RIGHT EMBEDDING -->
<int>0x202B</int> <!-- RIGHT-TO-LEFT EMBEDDING -->
<int>0x202C</int> <!-- POP DIRECTIONAL FORMATTING -->
<int>0x202D</int> <!-- LEFT-TO-RIGHT OVERRIDE -->
<int>0x202E</int> <!-- RIGHT-TO-LEFT OVERRIDE -->
<int>0x202F</int> <!-- NARROW NO-BREAK SPACE -->
<int>0x205F</int> <!-- MEDIUM MATHEMATICAL SPACE -->
<int>0x2060</int> <!-- WORD JOINER -->
<int>0x2061</int> <!-- FUNCTION APPLICATION -->
<int>0x2062</int> <!-- INVISIBLE TIMES -->
<int>0x2063</int> <!-- INVISIBLE SEPARATOR -->
<int>0x206A</int> <!-- INHIBIT SYMMETRIC SWAPPING -->
<int>0x206B</int> <!-- ACTIVATE SYMMETRIC SWAPPING -->
<int>0x206C</int> <!-- INHIBIT ARABIC FORM SHAPING -->
<int>0x206D</int> <!-- ACTIVATE ARABIC FORM SHAPING -->
<int>0x206E</int> <!-- NATIONAL DIGIT SHAPES -->
<int>0x206F</int> <!-- NOMINAL DIGIT SHAPES -->
<int>0x2800</int> <!-- BRAILLE PATTERN BLANK -->
<int>0x3000</int> <!-- IDEOGRAPHIC SPACE -->
<int>0x3164</int> <!-- HANGUL FILLER -->
<int>0xFEFF</int> <!-- ZERO WIDTH NO-BREAK SPACE -->
<int>0xFFA0</int> <!-- HALFWIDTH HANGUL FILLER -->
<int>0xFFF9</int> <!-- INTERLINEAR ANNOTATION ANCHOR -->
<int>0xFFFA</int> <!-- INTERLINEAR ANNOTATION SEPARATOR -->
<int>0xFFFB</int> <!-- INTERLINEAR ANNOTATION TERMINATOR -->
</blank>
<!--
Rescan configuration every 30 seconds when FcFontSetList is called
-->
<rescan>
<int>30</int>
</rescan>
</config>
</fontconfig>

Binary file not shown.

63
commons/commons.iml Normal file
View file

@ -0,0 +1,63 @@
<?xml version="1.0" encoding="UTF-8"?>
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="android" name="Android">
<configuration>
<option name="GEN_FOLDER_RELATIVE_PATH_APT" value="/target/generated-sources/r" />
<option name="GEN_FOLDER_RELATIVE_PATH_AIDL" value="/target/generated-sources/aidl" />
<option name="MANIFEST_FILE_RELATIVE_PATH" value="/AndroidManifest.xml" />
<option name="RES_FOLDER_RELATIVE_PATH" value="/res" />
<option name="ASSETS_FOLDER_RELATIVE_PATH" value="/assets" />
<option name="LIBS_FOLDER_RELATIVE_PATH" value="/src/main/native" />
<option name="USE_CUSTOM_APK_RESOURCE_FOLDER" value="false" />
<option name="CUSTOM_APK_RESOURCE_FOLDER" value="/target/generated-sources/combined-resources/res" />
<option name="USE_CUSTOM_COMPILER_MANIFEST" value="false" />
<option name="CUSTOM_COMPILER_MANIFEST" value="" />
<option name="APK_PATH" value="/target/commons.apk" />
<option name="LIBRARY_PROJECT" value="false" />
<option name="RUN_PROCESS_RESOURCES_MAVEN_TASK" value="false" />
<option name="GENERATE_UNSIGNED_APK" value="false" />
<option name="CUSTOM_DEBUG_KEYSTORE_PATH" value="" />
<option name="PACK_TEST_CODE" value="false" />
<option name="RUN_PROGUARD" value="false" />
<option name="PROGUARD_CFG_PATH" value="/proguard-project.txt" />
<resOverlayFolders>
<path>/res-overlay</path>
</resOverlayFolders>
<includeSystemProguardFile>true</includeSystemProguardFile>
<includeAssetsFromLibraries>true</includeAssetsFromLibraries>
<additionalNativeLibs />
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_5" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/target/idea-classes" />
<output-test url="file://$MODULE_DIR$/target/idea-test-classes" />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/target/generated-sources/r" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
<excludeFolder url="file://$MODULE_DIR$/target/classes" />
<excludeFolder url="file://$MODULE_DIR$/target/generated-sources/combined-assets" />
<excludeFolder url="file://$MODULE_DIR$/target/generated-sources/combined-resources" />
<excludeFolder url="file://$MODULE_DIR$/target/generated-sources/extracted-dependencies" />
<excludeFolder url="file://$MODULE_DIR$/target/maven-archiver" />
<excludeFolder url="file://$MODULE_DIR$/target/unpack" />
</content>
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="Maven: org.mediawiki:api:1.0" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:fluent-hc:4.2.2" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpclient:4.2.2" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpcore:4.2.2" level="project" />
<orderEntry type="library" name="Maven: commons-logging:commons-logging:1.1.1" level="project" />
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.6" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpmime:4.2.2" level="project" />
<orderEntry type="library" name="Maven: in.yuvi:http.fluent:1.0" level="project" />
<orderEntry type="library" name="Maven: com.actionbarsherlock:actionbarsherlock:apklib:4.2.0" level="project" />
<orderEntry type="library" name="Maven: com.google.android:support-v4:r7" level="project" />
<orderEntry type="library" scope="PROVIDED" name="Maven: android:android:4.1_r2" level="project" />
<orderEntry type="library" name="Maven: de.akquinet.android.androlog:androlog:1.0.5" level="project" />
<orderEntry type="jdk" jdkName="Android 4.0.3 Platform" jdkType="Android SDK" />
<orderEntry type="module" module-name="~apklib-com.actionbarsherlock_actionbarsherlock_4.2.0" />
</component>
</module>

View file

@ -0,0 +1,3 @@
# File used by Eclipse to determine the target system
# Project target.
target=android-15

View file

@ -0,0 +1,308 @@
#include <jni.h>
#include <gst/gst.h>
#include <gio/gio.h>
#include <android/log.h>
#define CAT_FMT "%s:%d:%s"
static GstClockTime _priv_gst_info_start_time;
/* Declaration of static plugins */
GST_PLUGIN_STATIC_DECLARE(coreelements);
GST_PLUGIN_STATIC_DECLARE(coreindexers);
GST_PLUGIN_STATIC_DECLARE(adder);
GST_PLUGIN_STATIC_DECLARE(app);
GST_PLUGIN_STATIC_DECLARE(audioconvert);
GST_PLUGIN_STATIC_DECLARE(audiorate);
GST_PLUGIN_STATIC_DECLARE(audioresample);
GST_PLUGIN_STATIC_DECLARE(audiotestsrc);
GST_PLUGIN_STATIC_DECLARE(ffmpegcolorspace);
GST_PLUGIN_STATIC_DECLARE(gdp);
GST_PLUGIN_STATIC_DECLARE(gio);
GST_PLUGIN_STATIC_DECLARE(pango);
GST_PLUGIN_STATIC_DECLARE(typefindfunctions);
GST_PLUGIN_STATIC_DECLARE(videorate);
GST_PLUGIN_STATIC_DECLARE(videoscale);
GST_PLUGIN_STATIC_DECLARE(videotestsrc);
GST_PLUGIN_STATIC_DECLARE(volume);
GST_PLUGIN_STATIC_DECLARE(autodetect);
GST_PLUGIN_STATIC_DECLARE(videofilter);
GST_PLUGIN_STATIC_DECLARE(uridecodebin);
GST_PLUGIN_STATIC_DECLARE(playback);
GST_PLUGIN_STATIC_DECLARE(debug);
GST_PLUGIN_STATIC_DECLARE(audioparsers);
GST_PLUGIN_STATIC_DECLARE(id3demux);
GST_PLUGIN_STATIC_DECLARE(isomp4);
GST_PLUGIN_STATIC_DECLARE(ogg);
GST_PLUGIN_STATIC_DECLARE(vorbis);
GST_PLUGIN_STATIC_DECLARE(wavparse);
GST_PLUGIN_STATIC_DECLARE(amrnb);
GST_PLUGIN_STATIC_DECLARE(amrwbdec);
GST_PLUGIN_STATIC_DECLARE(faad);
GST_PLUGIN_STATIC_DECLARE(mad);
GST_PLUGIN_STATIC_DECLARE(mpegaudioparse);
/* Declaration of static gio modules */
/* Call this function to register static plugins */
void
gst_android_register_static_plugins (void)
{
GST_PLUGIN_STATIC_REGISTER(coreelements);
GST_PLUGIN_STATIC_REGISTER(coreindexers);
GST_PLUGIN_STATIC_REGISTER(adder);
GST_PLUGIN_STATIC_REGISTER(app);
GST_PLUGIN_STATIC_REGISTER(audioconvert);
GST_PLUGIN_STATIC_REGISTER(audiorate);
GST_PLUGIN_STATIC_REGISTER(audioresample);
GST_PLUGIN_STATIC_REGISTER(audiotestsrc);
GST_PLUGIN_STATIC_REGISTER(ffmpegcolorspace);
GST_PLUGIN_STATIC_REGISTER(gdp);
GST_PLUGIN_STATIC_REGISTER(gio);
GST_PLUGIN_STATIC_REGISTER(pango);
GST_PLUGIN_STATIC_REGISTER(typefindfunctions);
GST_PLUGIN_STATIC_REGISTER(videorate);
GST_PLUGIN_STATIC_REGISTER(videoscale);
GST_PLUGIN_STATIC_REGISTER(videotestsrc);
GST_PLUGIN_STATIC_REGISTER(volume);
GST_PLUGIN_STATIC_REGISTER(autodetect);
GST_PLUGIN_STATIC_REGISTER(videofilter);
GST_PLUGIN_STATIC_REGISTER(uridecodebin);
GST_PLUGIN_STATIC_REGISTER(playback);
GST_PLUGIN_STATIC_REGISTER(debug);
GST_PLUGIN_STATIC_REGISTER(audioparsers);
GST_PLUGIN_STATIC_REGISTER(id3demux);
GST_PLUGIN_STATIC_REGISTER(isomp4);
GST_PLUGIN_STATIC_REGISTER(ogg);
GST_PLUGIN_STATIC_REGISTER(vorbis);
GST_PLUGIN_STATIC_REGISTER(wavparse);
GST_PLUGIN_STATIC_REGISTER(amrnb);
GST_PLUGIN_STATIC_REGISTER(amrwbdec);
GST_PLUGIN_STATIC_REGISTER(faad);
GST_PLUGIN_STATIC_REGISTER(mad);
GST_PLUGIN_STATIC_REGISTER(mpegaudioparse);
}
/* Call this function to load GIO modules */
void
gst_android_load_gio_modules (void)
{
}
void
gst_debug_logcat (GstDebugCategory * category, GstDebugLevel level,
const gchar * file, const gchar * function, gint line,
GObject * object, GstDebugMessage * message, gpointer unused)
{
GstClockTime elapsed;
gint android_log_level;
gchar *tag;
if (level > gst_debug_category_get_threshold (category))
return;
elapsed = GST_CLOCK_DIFF (_priv_gst_info_start_time,
gst_util_get_timestamp ());
switch (level) {
case GST_LEVEL_ERROR:
android_log_level = ANDROID_LOG_ERROR;
break;
case GST_LEVEL_WARNING:
android_log_level = ANDROID_LOG_WARN;
break;
case GST_LEVEL_INFO:
android_log_level = ANDROID_LOG_INFO;
break;
case GST_LEVEL_DEBUG:
android_log_level = ANDROID_LOG_DEBUG;
break;
default:
android_log_level = ANDROID_LOG_VERBOSE;
break;
}
tag = g_strdup_printf ("GStreamer+%s",
gst_debug_category_get_name (category));
__android_log_print (android_log_level, tag,
"%" GST_TIME_FORMAT " " CAT_FMT " %s\n", GST_TIME_ARGS (elapsed),
file, line, function, gst_debug_message_get (message));
g_free (tag);
}
static gboolean
get_application_dirs (JNIEnv * env, jobject context, gchar ** cache_dir,
gchar ** files_dir)
{
jclass context_class;
jmethodID get_cache_dir_id, get_files_dir_id;
jclass file_class;
jmethodID get_absolute_path_id;
jobject dir;
jstring abs_path;
const gchar *abs_path_str;
*cache_dir = *files_dir = NULL;
context_class = (*env)->GetObjectClass (env, context);
if (!context_class) {
return FALSE;
}
get_cache_dir_id =
(*env)->GetMethodID (env, context_class, "getCacheDir",
"()Ljava/io/File;");
get_files_dir_id =
(*env)->GetMethodID (env, context_class, "getFilesDir",
"()Ljava/io/File;");
if (!get_cache_dir_id || !get_files_dir_id) {
return FALSE;
}
file_class = (*env)->FindClass (env, "java/io/File");
get_absolute_path_id =
(*env)->GetMethodID (env, file_class, "getAbsolutePath",
"()Ljava/lang/String;");
if (!get_absolute_path_id) {
return FALSE;
}
dir = (*env)->CallObjectMethod (env, context, get_cache_dir_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
if (dir) {
abs_path = (*env)->CallObjectMethod (env, dir, get_absolute_path_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
abs_path_str = (*env)->GetStringUTFChars (env, abs_path, NULL);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
*cache_dir = abs_path ? g_strdup (abs_path_str) : NULL;
(*env)->ReleaseStringUTFChars (env, abs_path, abs_path_str);
(*env)->DeleteLocalRef (env, abs_path);
(*env)->DeleteLocalRef (env, dir);
}
dir = (*env)->CallObjectMethod (env, context, get_files_dir_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
if (dir) {
abs_path = (*env)->CallObjectMethod (env, dir, get_absolute_path_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
abs_path_str = (*env)->GetStringUTFChars (env, abs_path, NULL);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
*files_dir = files_dir ? g_strdup (abs_path_str) : NULL;
(*env)->ReleaseStringUTFChars (env, abs_path, abs_path_str);
(*env)->DeleteLocalRef (env, abs_path);
(*env)->DeleteLocalRef (env, dir);
}
(*env)->DeleteLocalRef (env, file_class);
(*env)->DeleteLocalRef (env, context_class);
return TRUE;
}
static void
gst_android_init (JNIEnv * env, jclass klass, jobject context)
{
gchar *cache_dir;
gchar *files_dir;
gchar *registry;
GError *error = NULL;
if (gst_is_initialized ()) {
__android_log_print (ANDROID_LOG_INFO, "GStreamer",
"GStreamer already initialized");
return;
}
if (!get_application_dirs (env, context, &cache_dir, &files_dir))
return;
if (cache_dir) {
g_setenv ("TMP", cache_dir, TRUE);
g_setenv ("TMPDIR", cache_dir, TRUE);
g_setenv ("XDG_RUNTIME_DIR", cache_dir, TRUE);
g_setenv ("XDG_CACHE_DIR", cache_dir, TRUE);
registry = g_build_filename (cache_dir, "registry.bin", NULL);
g_setenv ("GST_REGISTRY", registry, TRUE);
g_free (registry);
g_setenv ("GST_REUSE_PLUGIN_SCANNER", "no", TRUE);
/* FIXME: Should probably also set GST_PLUGIN_SCANNER and GST_PLUGIN_SYSTEM_PATH */
}
if (files_dir) {
g_setenv ("HOME", files_dir, TRUE);
g_setenv ("XDG_DATA_DIRS", files_dir, TRUE);
g_setenv ("XDG_CONFIG_DIRS", files_dir, TRUE);
}
g_free (cache_dir);
g_free (files_dir);
/* Disable this for releases if performance is important
* or increase the threshold to get more information */
gst_debug_set_active (TRUE);
gst_debug_set_default_threshold (GST_LEVEL_WARNING);
gst_debug_remove_log_function (gst_debug_log_default);
gst_debug_add_log_function ((GstLogFunction) gst_debug_logcat, NULL);
/* get time we started for debugging messages */
_priv_gst_info_start_time = gst_util_get_timestamp ();
if (!gst_init_check (NULL, NULL, &error)) {
gchar *message = g_strdup_printf ("GStreamer initialization failed: %s",
error && error->message ? error->message : "(no message)");
jclass exception_class = (*env)->FindClass (env, "java/lang/Exception");
__android_log_print (ANDROID_LOG_ERROR, "GStreamer", message);
(*env)->ThrowNew (env, exception_class, message);
g_free (message);
return;
}
gst_android_register_static_plugins ();
gst_android_load_gio_modules();
__android_log_print (ANDROID_LOG_INFO, "GStreamer",
"GStreamer initialization complete");
}
static JNINativeMethod native_methods[] = {
{"init", "(Landroid/content/Context;)V", (void *) gst_android_init}
};
jint
JNI_OnLoad (JavaVM * vm, void *reserved)
{
JNIEnv *env = NULL;
if ((*vm)->GetEnv (vm, (void **) &env, JNI_VERSION_1_4) != JNI_OK) {
__android_log_print (ANDROID_LOG_ERROR, "GStreamer",
"Could not retrieve JNIEnv");
return 0;
}
jclass klass = (*env)->FindClass (env, "com/gst_sdk/GStreamer");
if (!klass) {
__android_log_print (ANDROID_LOG_ERROR, "GStreamer",
"Could not retrieve class com.gst_sdk.GStreamer");
return 0;
}
if ((*env)->RegisterNatives (env, klass, native_methods,
G_N_ELEMENTS (native_methods))) {
__android_log_print (ANDROID_LOG_ERROR, "GStreamer",
"Could not register native methods for com.gst_sdk_GStreamer");
return 0;
}
return JNI_VERSION_1_4;
}

Binary file not shown.

View file

@ -0,0 +1,7 @@
package com.gst_sdk;
import android.content.Context;
public class GStreamer {
public static native void init(Context context) throws Exception;
}

182
commons/pom.xml Normal file
View file

@ -0,0 +1,182 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.wikimedia</groupId>
<artifactId>commons-parent</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.wikimedia</groupId>
<artifactId>commons</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>apk</packaging>
<name>commons - Application</name>
<dependencies>
<dependency>
<groupId>org.mediawiki</groupId>
<artifactId>api</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>com.actionbarsherlock</groupId>
<artifactId>actionbarsherlock</artifactId>
<version>4.2.0</version>
<type>apklib</type>
</dependency>
<dependency>
<groupId>android</groupId>
<artifactId>android</artifactId>
</dependency>
<dependency>
<groupId>de.akquinet.android.androlog</groupId>
<artifactId>androlog</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<extensions>true</extensions>
</plugin>
<!-- Commenting out Native stuff for now
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<goals>
<goal>ndk-build</goal>
</goals>
<configuration>
<ndk>
<path>${env.ANDROID_NDK_HOME}</path>
</ndk>
<target>all</target>
</configuration>
<extensions>true</extensions>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>libs</directory>
</fileset>
<fileset>
<directory>obj</directory>
</fileset>
</filesets>
</configuration>
</plugin>
-->
</plugins>
</build>
<profiles>
<profile>
<id>release</id>
<build>
<plugins>
<plugin>
<groupId>com.pyx4me</groupId>
<artifactId>proguard-maven-plugin</artifactId>
<executions>
<execution>
<id>process-classes-with-proguard</id>
<phase>process-classes</phase>
<goals>
<goal>proguard</goal>
</goals>
<configuration>
<proguardVersion>4.4</proguardVersion>
<maxMemory>256m</maxMemory>
<injar>android-classes</injar>
<libs>
<lib>${rt.jar.path}</lib>
<lib>${jsse.jar.path}</lib>
</libs>
<obfuscate>true</obfuscate>
<addMavenDescriptor>false</addMavenDescriptor>
<proguardInclude>${project.basedir}/proguard.conf</proguardInclude>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>net.sf.proguard</groupId>
<artifactId>proguard</artifactId>
<version>4.4</version>
<scope>runtime</scope>
</dependency>
</dependencies>
</plugin>
<plugin>
<artifactId>maven-jarsigner-plugin</artifactId>
<executions>
<execution>
<id>sign-application-apk</id>
<phase>package</phase>
<goals>
<goal>sign</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<executions>
<execution>
<id>zipalign-application-apk</id>
<phase>package</phase>
<goals>
<goal>zipalign</goal>
</goals>
</execution>
</executions>
<configuration>
<zipalign>
<verbose>true</verbose>
<inputApk>${project.build.directory}/${project.artifactId}-${project.version}.apk</inputApk>
<outputApk>${project.build.directory}/${project.artifactId}-${project.version}-signed-aligned.apk</outputApk>
</zipalign>
<sign>
<debug>false</debug>
</sign>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<configuration>
<artifacts>
<artifact>
<file>${project.build.directory}/proguard_map.txt</file>
<type>map</type>
<classifier>release</classifier>
</artifact>
</artifacts>
</configuration>
<executions>
<execution>
<id>attach-signed-aligned</id>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>

View file

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 3 KiB

After

Width:  |  Height:  |  Size: 3 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 3 KiB

After

Width:  |  Height:  |  Size: 3 KiB

Before After
Before After

Binary file not shown.

After

Width:  |  Height:  |  Size: 6 KiB

View file

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Before After
Before After

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

View file

Before

Width:  |  Height:  |  Size: 3 KiB

After

Width:  |  Height:  |  Size: 3 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Before After
Before After

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

View file

Before

Width:  |  Height:  |  Size: 3.1 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 4 KiB

After

Width:  |  Height:  |  Size: 4 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 3.1 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Before After
Before After

View file

@ -0,0 +1,60 @@
package com.gstreamer;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import android.content.Context;
import android.content.res.AssetManager;
public class GStreamer {
private static native void nativeInit(Context context) throws Exception;
public static void init(Context context) throws Exception {
nativeInit(context);
copyFonts(context);
}
private static void copyFonts(Context context) {
AssetManager assetManager = context.getAssets();
File filesDir = context.getFilesDir();
File fontsFCDir = new File (filesDir, "fontconfig");
File fontsDir = new File (fontsFCDir, "fonts");
File fontsCfg = new File (fontsFCDir, "fonts.conf");
fontsDir.mkdirs();
try {
/* Copy the config file */
copyFile (assetManager, "fontconfig/fonts.conf", fontsCfg);
/* Copy the fonts */
for(String filename : assetManager.list("fontconfig/fonts/truetype")) {
File font = new File(fontsDir, filename);
copyFile (assetManager, "fontconfig/fonts/truetype/" + filename, font);
}
} catch (IOException e) {
e.printStackTrace();
}
}
private static void copyFile(AssetManager assetManager, String assetPath, File outFile) throws IOException {
InputStream in;
OutputStream out;
byte[] buffer = new byte[1024];
int read;
if (outFile.exists())
return;
in = assetManager.open(assetPath);
out = new FileOutputStream (outFile);
while((read = in.read(buffer)) != -1){
out.write(buffer, 0, read);
}
in.close();
out.flush();
out.close();
}
}

View file

@ -1,7 +1,6 @@
package org.wikimedia.commons;
import java.io.IOException;
import com.gst_sdk.GStreamer;
import java.io.StringWriter;
import javax.xml.transform.*;
@ -40,13 +39,6 @@ public class CommonsApplication extends Application {
public void onCreate() {
// TODO Auto-generated method stub
super.onCreate();
System.loadLibrary("gstreamer_android");
try {
GStreamer.init(this);
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
api = createMWApi();
}

View file

@ -4,10 +4,9 @@ import java.io.*;
import java.util.Date;
import org.mediawiki.api.*;
import org.wikimedia.commons.Transcoder.TranscoderProgressCallback;
import org.wikimedia.commons.media.Media;
import de.mastacode.http.ProgressListener;
import in.yuvi.http.fluent.ProgressListener;
import android.app.*;
import android.content.*;
@ -47,24 +46,7 @@ public class UploadService extends IntentService {
public static final int NOTIFICATION_DOWNLOAD_IN_PROGRESS = 1;
public static final int NOTIFICATION_DOWNLOAD_COMPLETE = 2;
public static final int NOTIFICATION_UPLOAD_FAILED = 3;
public static final int NOTIFICATION_TRANSCODING_IN_PROGRESS = 4;
public static final int NOTIFICATION_TRANSCODING_FAILED = 5;
private class TranscodeProgressListener implements TranscoderProgressCallback {
private Notification curNotification;
public TranscodeProgressListener(Notification curNotification) {
this.curNotification = curNotification;
}
@Override
public void transcodeProgressCb(int percent) {
curNotification.contentView.setProgressBar(R.id.uploadNotificationProgress, 100, percent, false);
startForeground(NOTIFICATION_TRANSCODING_IN_PROGRESS, curNotification);
Log.d("Commons", "Percentage: " + percent);
}
}
private class NotificationUpdateProgressListener implements ProgressListener {
Notification curNotification;
@ -155,47 +137,7 @@ public class UploadService extends IntentService {
dateCreated = new Date(cursor.getLong(0));
}
} else if (mimeType.startsWith("audio/")) {
String srcPath = this.getRealPathFromURI(mediaUri);
File destFile = File.createTempFile("org.wikimedia.commons", ".ogg");
filename = filename + ".ogg";
Log.d("Commons", "Path is " + srcPath);
Log.d("Commons", "Dest is " + destFile.getAbsolutePath());
RemoteViews transcodeNotificationView = new RemoteViews(getPackageName(), R.layout.layout_upload_progress);
transcodeNotificationView.setTextViewText(R.id.uploadNotificationTitle, String.format(getString(R.string.transcoding_progress_title_in_progress), filename));
transcodeNotificationView.setProgressBar(R.id.uploadNotificationProgress, 100, 0, false);
Notification transcodeNotification = new NotificationCompat.Builder(this).setAutoCancel(true)
.setSmallIcon(R.drawable.ic_launcher)
.setAutoCancel(true)
.setOngoing(true)
.setContent(transcodeNotificationView)
.setContentIntent(PendingIntent.getActivity(getApplicationContext(), 0, new Intent(), 0))
.setTicker(String.format(getString(R.string.transcoding_progress_title_in_progress), filename))
.getNotification();
startForeground(NOTIFICATION_TRANSCODING_IN_PROGRESS, transcodeNotification);
int transcodeResult = Transcoder.transcode(srcPath, destFile.getAbsolutePath(), null, new TranscodeProgressListener(transcodeNotification));
stopForeground(true);
if(transcodeResult != 0) {
Notification failureNotification = new NotificationCompat.Builder(this).setAutoCancel(true)
.setSmallIcon(R.drawable.ic_launcher)
.setAutoCancel(true)
.setContentIntent(PendingIntent.getService(getApplicationContext(), 0, intent, 0))
.setTicker(String.format(getString(R.string.transcoding_failed_notification_title), filename))
.setContentTitle(String.format(getString(R.string.transcoding_failed_notification_title), filename))
.setContentText(getString(R.string.transcoding_failed_notification_subtitle))
.getNotification();
notificationManager.notify(NOTIFICATION_TRANSCODING_FAILED, failureNotification);
return;
}
file = new FileInputStream(destFile);
length = destFile.length();
dateCreated = new Date(destFile.lastModified());
Log.d("Commons", "Transcode doen!");
/* Removed Audio implementationf or now */
}
} catch (FileNotFoundException e) {
throw new RuntimeException(e);

View file

@ -0,0 +1,22 @@
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := libtranscode
LOCAL_SRC_FILES := transcode.c
LOCAL_SHARED_LIBRARIES := gstreamer_android
LOCAL_LDLIBS := -landroid -llog
include $(BUILD_SHARED_LIBRARY)
GSTREAMER_SDK_ROOT := $(GSTREAMER_SDK_ROOT_ANDROID)
GSTREAMER_NDK_BUILD_PATH := $(GSTREAMER_SDK_ROOT)/share/gst-android/ndk-build/
include $(GSTREAMER_NDK_BUILD_PATH)/plugins.mk
GSTREAMER_PLUGINS := \
$(GSTREAMER_PLUGINS_CORE) \
$(GSTREAMER_PLUGINS_PLAYBACK) \
debug \
audioparsers id3demux isomp4 ogg vorbis wavparse \
amrnb amrwbdec faad mad mpegaudioparse
include $(GSTREAMER_NDK_BUILD_PATH)/gstreamer.mk

View file

@ -0,0 +1,8 @@
* Get the GStreamer SDK for Android
- http://docs.gstreamer.com/display/GstSDK/Installing+for+Android+development
- user: test, pass: Jo6eem7e (these will go away once the SDK gets out of the
beta stage)
* Get the NDK
* export GSTREAMER_SDK_ROOT_ANDROID=/path/to/unpacked/gstreamer/sdk
* (in top-level source dir) <NDK path>/ndk-build
* Continue building as usual

View file

@ -0,0 +1,308 @@
#include <jni.h>
#include <gst/gst.h>
#include <gio/gio.h>
#include <android/log.h>
#define CAT_FMT "%s:%d:%s"
static GstClockTime _priv_gst_info_start_time;
/* Declaration of static plugins */
GST_PLUGIN_STATIC_DECLARE(coreelements);
GST_PLUGIN_STATIC_DECLARE(coreindexers);
GST_PLUGIN_STATIC_DECLARE(adder);
GST_PLUGIN_STATIC_DECLARE(app);
GST_PLUGIN_STATIC_DECLARE(audioconvert);
GST_PLUGIN_STATIC_DECLARE(audiorate);
GST_PLUGIN_STATIC_DECLARE(audioresample);
GST_PLUGIN_STATIC_DECLARE(audiotestsrc);
GST_PLUGIN_STATIC_DECLARE(ffmpegcolorspace);
GST_PLUGIN_STATIC_DECLARE(gdp);
GST_PLUGIN_STATIC_DECLARE(gio);
GST_PLUGIN_STATIC_DECLARE(pango);
GST_PLUGIN_STATIC_DECLARE(typefindfunctions);
GST_PLUGIN_STATIC_DECLARE(videorate);
GST_PLUGIN_STATIC_DECLARE(videoscale);
GST_PLUGIN_STATIC_DECLARE(videotestsrc);
GST_PLUGIN_STATIC_DECLARE(volume);
GST_PLUGIN_STATIC_DECLARE(autodetect);
GST_PLUGIN_STATIC_DECLARE(videofilter);
GST_PLUGIN_STATIC_DECLARE(uridecodebin);
GST_PLUGIN_STATIC_DECLARE(playback);
GST_PLUGIN_STATIC_DECLARE(debug);
GST_PLUGIN_STATIC_DECLARE(audioparsers);
GST_PLUGIN_STATIC_DECLARE(id3demux);
GST_PLUGIN_STATIC_DECLARE(isomp4);
GST_PLUGIN_STATIC_DECLARE(ogg);
GST_PLUGIN_STATIC_DECLARE(vorbis);
GST_PLUGIN_STATIC_DECLARE(wavparse);
GST_PLUGIN_STATIC_DECLARE(amrnb);
GST_PLUGIN_STATIC_DECLARE(amrwbdec);
GST_PLUGIN_STATIC_DECLARE(faad);
GST_PLUGIN_STATIC_DECLARE(mad);
GST_PLUGIN_STATIC_DECLARE(mpegaudioparse);
/* Declaration of static gio modules */
/* Call this function to register static plugins */
void
gst_android_register_static_plugins (void)
{
GST_PLUGIN_STATIC_REGISTER(coreelements);
GST_PLUGIN_STATIC_REGISTER(coreindexers);
GST_PLUGIN_STATIC_REGISTER(adder);
GST_PLUGIN_STATIC_REGISTER(app);
GST_PLUGIN_STATIC_REGISTER(audioconvert);
GST_PLUGIN_STATIC_REGISTER(audiorate);
GST_PLUGIN_STATIC_REGISTER(audioresample);
GST_PLUGIN_STATIC_REGISTER(audiotestsrc);
GST_PLUGIN_STATIC_REGISTER(ffmpegcolorspace);
GST_PLUGIN_STATIC_REGISTER(gdp);
GST_PLUGIN_STATIC_REGISTER(gio);
GST_PLUGIN_STATIC_REGISTER(pango);
GST_PLUGIN_STATIC_REGISTER(typefindfunctions);
GST_PLUGIN_STATIC_REGISTER(videorate);
GST_PLUGIN_STATIC_REGISTER(videoscale);
GST_PLUGIN_STATIC_REGISTER(videotestsrc);
GST_PLUGIN_STATIC_REGISTER(volume);
GST_PLUGIN_STATIC_REGISTER(autodetect);
GST_PLUGIN_STATIC_REGISTER(videofilter);
GST_PLUGIN_STATIC_REGISTER(uridecodebin);
GST_PLUGIN_STATIC_REGISTER(playback);
GST_PLUGIN_STATIC_REGISTER(debug);
GST_PLUGIN_STATIC_REGISTER(audioparsers);
GST_PLUGIN_STATIC_REGISTER(id3demux);
GST_PLUGIN_STATIC_REGISTER(isomp4);
GST_PLUGIN_STATIC_REGISTER(ogg);
GST_PLUGIN_STATIC_REGISTER(vorbis);
GST_PLUGIN_STATIC_REGISTER(wavparse);
GST_PLUGIN_STATIC_REGISTER(amrnb);
GST_PLUGIN_STATIC_REGISTER(amrwbdec);
GST_PLUGIN_STATIC_REGISTER(faad);
GST_PLUGIN_STATIC_REGISTER(mad);
GST_PLUGIN_STATIC_REGISTER(mpegaudioparse);
}
/* Call this function to load GIO modules */
void
gst_android_load_gio_modules (void)
{
}
void
gst_debug_logcat (GstDebugCategory * category, GstDebugLevel level,
const gchar * file, const gchar * function, gint line,
GObject * object, GstDebugMessage * message, gpointer unused)
{
GstClockTime elapsed;
gint android_log_level;
gchar *tag;
if (level > gst_debug_category_get_threshold (category))
return;
elapsed = GST_CLOCK_DIFF (_priv_gst_info_start_time,
gst_util_get_timestamp ());
switch (level) {
case GST_LEVEL_ERROR:
android_log_level = ANDROID_LOG_ERROR;
break;
case GST_LEVEL_WARNING:
android_log_level = ANDROID_LOG_WARN;
break;
case GST_LEVEL_INFO:
android_log_level = ANDROID_LOG_INFO;
break;
case GST_LEVEL_DEBUG:
android_log_level = ANDROID_LOG_DEBUG;
break;
default:
android_log_level = ANDROID_LOG_VERBOSE;
break;
}
tag = g_strdup_printf ("GStreamer+%s",
gst_debug_category_get_name (category));
__android_log_print (android_log_level, tag,
"%" GST_TIME_FORMAT " " CAT_FMT " %s\n", GST_TIME_ARGS (elapsed),
file, line, function, gst_debug_message_get (message));
g_free (tag);
}
static gboolean
get_application_dirs (JNIEnv * env, jobject context, gchar ** cache_dir,
gchar ** files_dir)
{
jclass context_class;
jmethodID get_cache_dir_id, get_files_dir_id;
jclass file_class;
jmethodID get_absolute_path_id;
jobject dir;
jstring abs_path;
const gchar *abs_path_str;
*cache_dir = *files_dir = NULL;
context_class = (*env)->GetObjectClass (env, context);
if (!context_class) {
return FALSE;
}
get_cache_dir_id =
(*env)->GetMethodID (env, context_class, "getCacheDir",
"()Ljava/io/File;");
get_files_dir_id =
(*env)->GetMethodID (env, context_class, "getFilesDir",
"()Ljava/io/File;");
if (!get_cache_dir_id || !get_files_dir_id) {
return FALSE;
}
file_class = (*env)->FindClass (env, "java/io/File");
get_absolute_path_id =
(*env)->GetMethodID (env, file_class, "getAbsolutePath",
"()Ljava/lang/String;");
if (!get_absolute_path_id) {
return FALSE;
}
dir = (*env)->CallObjectMethod (env, context, get_cache_dir_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
if (dir) {
abs_path = (*env)->CallObjectMethod (env, dir, get_absolute_path_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
abs_path_str = (*env)->GetStringUTFChars (env, abs_path, NULL);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
*cache_dir = abs_path ? g_strdup (abs_path_str) : NULL;
(*env)->ReleaseStringUTFChars (env, abs_path, abs_path_str);
(*env)->DeleteLocalRef (env, abs_path);
(*env)->DeleteLocalRef (env, dir);
}
dir = (*env)->CallObjectMethod (env, context, get_files_dir_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
if (dir) {
abs_path = (*env)->CallObjectMethod (env, dir, get_absolute_path_id);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
abs_path_str = (*env)->GetStringUTFChars (env, abs_path, NULL);
if ((*env)->ExceptionCheck (env)) {
return FALSE;
}
*files_dir = files_dir ? g_strdup (abs_path_str) : NULL;
(*env)->ReleaseStringUTFChars (env, abs_path, abs_path_str);
(*env)->DeleteLocalRef (env, abs_path);
(*env)->DeleteLocalRef (env, dir);
}
(*env)->DeleteLocalRef (env, file_class);
(*env)->DeleteLocalRef (env, context_class);
return TRUE;
}
static void
gst_android_init (JNIEnv * env, jclass klass, jobject context)
{
gchar *cache_dir;
gchar *files_dir;
gchar *registry;
GError *error = NULL;
if (gst_is_initialized ()) {
__android_log_print (ANDROID_LOG_INFO, "GStreamer",
"GStreamer already initialized");
return;
}
if (!get_application_dirs (env, context, &cache_dir, &files_dir))
return;
if (cache_dir) {
g_setenv ("TMP", cache_dir, TRUE);
g_setenv ("TMPDIR", cache_dir, TRUE);
g_setenv ("XDG_RUNTIME_DIR", cache_dir, TRUE);
g_setenv ("XDG_CACHE_DIR", cache_dir, TRUE);
registry = g_build_filename (cache_dir, "registry.bin", NULL);
g_setenv ("GST_REGISTRY", registry, TRUE);
g_free (registry);
g_setenv ("GST_REUSE_PLUGIN_SCANNER", "no", TRUE);
/* FIXME: Should probably also set GST_PLUGIN_SCANNER and GST_PLUGIN_SYSTEM_PATH */
}
if (files_dir) {
g_setenv ("HOME", files_dir, TRUE);
g_setenv ("XDG_DATA_DIRS", files_dir, TRUE);
g_setenv ("XDG_CONFIG_DIRS", files_dir, TRUE);
}
g_free (cache_dir);
g_free (files_dir);
/* Disable this for releases if performance is important
* or increase the threshold to get more information */
gst_debug_set_active (TRUE);
gst_debug_set_default_threshold (GST_LEVEL_WARNING);
gst_debug_remove_log_function (gst_debug_log_default);
gst_debug_add_log_function ((GstLogFunction) gst_debug_logcat, NULL);
/* get time we started for debugging messages */
_priv_gst_info_start_time = gst_util_get_timestamp ();
if (!gst_init_check (NULL, NULL, &error)) {
gchar *message = g_strdup_printf ("GStreamer initialization failed: %s",
error && error->message ? error->message : "(no message)");
jclass exception_class = (*env)->FindClass (env, "java/lang/Exception");
__android_log_print (ANDROID_LOG_ERROR, "GStreamer", message);
(*env)->ThrowNew (env, exception_class, message);
g_free (message);
return;
}
gst_android_register_static_plugins ();
gst_android_load_gio_modules();
__android_log_print (ANDROID_LOG_INFO, "GStreamer",
"GStreamer initialization complete");
}
static JNINativeMethod native_methods[] = {
{"init", "(Landroid/content/Context;)V", (void *) gst_android_init}
};
jint
JNI_OnLoad (JavaVM * vm, void *reserved)
{
JNIEnv *env = NULL;
if ((*vm)->GetEnv (vm, (void **) &env, JNI_VERSION_1_4) != JNI_OK) {
__android_log_print (ANDROID_LOG_ERROR, "GStreamer",
"Could not retrieve JNIEnv");
return 0;
}
jclass klass = (*env)->FindClass (env, "com/gst_sdk/GStreamer");
if (!klass) {
__android_log_print (ANDROID_LOG_ERROR, "GStreamer",
"Could not retrieve class com.gst_sdk.GStreamer");
return 0;
}
if ((*env)->RegisterNatives (env, klass, native_methods,
G_N_ELEMENTS (native_methods))) {
__android_log_print (ANDROID_LOG_ERROR, "GStreamer",
"Could not register native methods for com.gst_sdk_GStreamer");
return 0;
}
return JNI_VERSION_1_4;
}

Binary file not shown.

View file

@ -0,0 +1,7 @@
package com.gst_sdk;
import android.content.Context;
public class GStreamer {
public static native void init(Context context) throws Exception;
}

View file

@ -0,0 +1,148 @@
#include <gst/gst.h>
#include <jni.h>
#include <android/log.h>
static int init(void)
{
/* XXX: ZERO thread-safety guarantees here */
static gboolean inited = 0;
if (inited)
return 0;
gst_init(NULL, NULL);
return 0;
}
static int transcode(const char *infile, const char *outfile,
const char *profile, jobject cb_obj, JNIEnv *env)
{
GstElement *pipeline;
GstBus *bus;
GstMessage *msg;
gchar pipeline_str[1024];
int ret = 0;
init();
snprintf(pipeline_str, 1024,
"filesrc location=\"%s\" ! "
"progressreport silent=true format=percent update-freq=1 ! "
"decodebin2 ! audioconvert ! vorbisenc ! oggmux ! "
"filesink location=\"%s\"",
infile, outfile);
pipeline = gst_parse_launch(pipeline_str, NULL);
gst_element_set_state (pipeline, GST_STATE_PLAYING);
bus = gst_element_get_bus(pipeline);
for (;;) {
msg = gst_bus_timed_pop_filtered(bus, GST_CLOCK_TIME_NONE,
GST_MESSAGE_ERROR | GST_MESSAGE_EOS | GST_MESSAGE_ELEMENT);
switch (GST_MESSAGE_TYPE(msg)) {
case GST_MESSAGE_ELEMENT: {
const GstStructure *s = gst_message_get_structure(msg);
int percent;
jclass cb_class;
jmethodID cb_id;
if (!cb_obj)
break;
if (!g_str_equal(gst_structure_get_name(s), "progress"))
break;
gst_structure_get_int(s, "percent", &percent);
cb_class = (*env)->FindClass(env, "org/wikimedia/commons/Transcoder$TranscoderProgressCallback");
if ((*env)->ExceptionCheck(env)) {
__android_log_print(ANDROID_LOG_ERROR, "GStreamer", "Class not found");
break;
}
cb_id = (*env)->GetMethodID(env, cb_class, "transcodeProgressCb", "(I)V");
if ((*env)->ExceptionCheck(env)) {
__android_log_print(ANDROID_LOG_ERROR, "GStreamer", "Method not found");
break;
}
(*env)->CallVoidMethod(env, cb_obj, cb_id, percent);
if ((*env)->ExceptionCheck(env)) {
__android_log_print(ANDROID_LOG_ERROR, "GStreamer", "Method call failed");
break;
}
break;
}
case GST_MESSAGE_ERROR: {
GError *err = NULL;
gchar *debug_info = NULL;
gst_message_parse_error(msg, &err, &debug_info);
GST_ERROR_OBJECT(pipeline, "%s -- %s", err->message,
debug_info ? debug_info : "no debug info");
g_error_free(err);
g_free(debug_info);
ret = -1;
goto done;
}
case GST_MESSAGE_EOS:
goto done;
default:
break;
}
}
done:
if (msg != NULL)
gst_message_unref (msg);
gst_object_unref (bus);
gst_element_set_state (pipeline, GST_STATE_NULL);
gst_object_unref (pipeline);
return ret;
}
jint Java_org_wikimedia_commons_Transcoder_transcode(JNIEnv* env,
jclass *klass, jstring infile, jstring outfile, jstring profile,
jobject cb_obj)
{
const char *in;
const char *out;
const char *prof = NULL;
if (!infile || !outfile)
return -1;
in = (*env)->GetStringUTFChars(env, infile, 0);
out = (*env)->GetStringUTFChars(env, outfile, 0);
if (profile)
prof = (*env)->GetStringUTFChars(env, profile, 0);
return transcode(in, out, prof, cb_obj, env);
}
#ifdef TEST
int main(int argc, char **argv)
{
if (argc != 3)
return -1;
transcode(argv[1], argv[2], NULL);
return 0;
}
#endif

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

View file

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
<classpathentry kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="gen"/>
<classpathentry kind="output" path="bin/classes"/>
</classpath>

View file

@ -1,33 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>ActionBarSherlock</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.android.ide.eclipse.adt.PreCompilerBuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.android.ide.eclipse.adt.ApkBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>com.android.ide.eclipse.adt.AndroidNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

View file

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="90" android:versionName="4.1.0" package="com.actionbarsherlock">
<uses-sdk android:minSdkVersion="7" android:targetSdkVersion="15"/>
</manifest>

View file

@ -1,15 +0,0 @@
ActionBarSherlock Library
=========================
This folder contains the main library which should be linked against as an
Android library project in your application.
For more information see the "Including In Your Project" section of the
[usage page][1].
[1]: http://actionbarsherlock.com/usage.html

View file

@ -1,92 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="ActionBarSherlock" default="help">
<!-- The local.properties file is created and updated by the 'android' tool.
It contains the path to the SDK. It should *NOT* be checked into
Version Control Systems. -->
<property file="local.properties" />
<!-- The ant.properties file can be created by you. It is only edited by the
'android' tool to add properties to it.
This is the place to change some Ant specific build properties.
Here are some properties you may want to change/update:
source.dir
The name of the source directory. Default is 'src'.
out.dir
The name of the output directory. Default is 'bin'.
For other overridable properties, look at the beginning of the rules
files in the SDK, at tools/ant/build.xml
Properties related to the SDK location or the project target should
be updated using the 'android' tool with the 'update' action.
This file is an integral part of the build system for your
application and should be checked into Version Control Systems.
-->
<property file="ant.properties" />
<!-- if sdk.dir was not set from one of the property file, then
get it from the ANDROID_HOME env var.
This must be done before we load project.properties since
the proguard config can use sdk.dir -->
<property environment="env" />
<condition property="sdk.dir" value="${env.ANDROID_HOME}">
<isset property="env.ANDROID_HOME" />
</condition>
<!-- The project.properties file is created and updated by the 'android'
tool, as well as ADT.
This contains project specific properties such as project target, and library
dependencies. Lower level build properties are stored in ant.properties
(or in .classpath for Eclipse projects).
This file is an integral part of the build system for your
application and should be checked into Version Control Systems. -->
<loadproperties srcFile="project.properties" />
<!-- quick check on sdk.dir -->
<fail
message="sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through the ANDROID_HOME environment variable."
unless="sdk.dir"
/>
<!--
Import per project custom build rules if present at the root of the project.
This is the place to put custom intermediary targets such as:
-pre-build
-pre-compile
-post-compile (This is typically used for code obfuscation.
Compiled code location: ${out.classes.absolute.dir}
If this is not done in place, override ${out.dex.input.absolute.dir})
-post-package
-post-build
-pre-clean
-->
<import file="custom_rules.xml" optional="true" />
<!-- Import the actual build file.
To customize existing targets, there are two options:
- Customize only one target:
- copy/paste the target into this file, *before* the
<import> task.
- customize it to your needs.
- Customize the whole content of build.xml
- copy/paste the content of the rules files (minus the top node)
into this file, replacing the <import> task.
- customize to your needs.
***********************
****** IMPORTANT ******
***********************
In all cases you must update the value of version-tag below to read 'custom' instead of an integer,
in order to avoid having your file be overridden by tools such as "android update project"
-->
<!-- version-tag: 1 -->
<import file="${sdk.dir}/tools/ant/build.xml" />
</project>

View file

@ -1,151 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.actionbarsherlock</groupId>
<artifactId>library</artifactId>
<name>ActionBarSherlock</name>
<packaging>apklib</packaging>
<parent>
<groupId>com.actionbarsherlock</groupId>
<artifactId>parent</artifactId>
<version>4.1.0</version>
<relativePath>../pom.xml</relativePath>
</parent>
<dependencies>
<dependency>
<groupId>com.google.android</groupId>
<artifactId>android</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.android</groupId>
<artifactId>support-v4</artifactId>
</dependency>
<dependency>
<groupId>com.pivotallabs</groupId>
<artifactId>robolectric</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<sourceDirectory>src</sourceDirectory>
<testSourceDirectory>test</testSourceDirectory>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>maven-replacer-plugin</artifactId>
<version>1.4.0</version>
<executions>
<execution>
<phase>process-sources</phase>
<goals>
<goal>replace</goal>
</goals>
</execution>
</executions>
<configuration>
<ignoreMissingFile>false</ignoreMissingFile>
<file>target/generated-sources/r/com/actionbarsherlock/R.java</file>
<outputFile>target/generated-sources/r/com/actionbarsherlock/R.java</outputFile>
<regex>false</regex>
<token>static final int</token>
<value>static int</value>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<configuration>
<configLocation>../checkstyle.xml</configLocation>
</configuration>
<executions>
<execution>
<phase>verify</phase>
<goals>
<goal>checkstyle</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<type>jar</type>
<file>${project.build.directory}/${project.build.finalName}.jar</file>
</artifact>
</artifacts>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>maven-replacer-plugin</artifactId>
<versionRange>[1.4.1,)</versionRange>
<goals>
<goal>replace</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</project>

View file

@ -1,20 +0,0 @@
# To enable ProGuard in your project, edit project.properties
# to define the proguard.config property as described in that file.
#
# Add project specific ProGuard rules here.
# By default, the flags in this file are appended to flags specified
# in ${sdk.dir}/tools/proguard/proguard-android.txt
# You can edit the include path and order by changing the ProGuard
# include property in project.properties.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
# Add any project specific keep options here:
# 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 *;
#}

View file

@ -1,12 +0,0 @@
# This file is automatically generated by Android Tools.
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
#
# This file must be checked in Version Control Systems.
#
# To customize properties used by the Ant build system use,
# "ant.properties", and override values to adapt the script to your
# project structure.
android.library=true
# Project target.
target=android-15

View file

@ -1,20 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2010 The Android Open Source Project
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
http://www.apache.org/licenses/LICENSE-2.0
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.
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_enabled="false" android:color="@color/abs__bright_foreground_disabled_holo_dark"/>
<item android:color="@color/abs__bright_foreground_holo_dark"/> <!-- not selected -->
</selector>

View file

@ -1,21 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2010 The Android Open Source Project
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
http://www.apache.org/licenses/LICENSE-2.0
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.
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_enabled="false" android:color="@color/abs__bright_foreground_disabled_holo_light"/>
<item android:color="@color/abs__bright_foreground_holo_light"/> <!-- not selected -->
</selector>

View file

@ -1,24 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2010 The Android Open Source Project
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
http://www.apache.org/licenses/LICENSE-2.0
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.
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_enabled="false" android:color="@color/abs__bright_foreground_disabled_holo_dark"/>
<item android:state_window_focused="false" android:color="@color/abs__bright_foreground_holo_dark"/>
<item android:state_pressed="true" android:color="@color/abs__bright_foreground_holo_dark"/>
<item android:state_selected="true" android:color="@color/abs__bright_foreground_holo_dark"/>
<item android:state_activated="true" android:color="@color/abs__bright_foreground_holo_dark"/>
<item android:color="@color/abs__bright_foreground_holo_dark"/> <!-- not selected -->
</selector>

View file

@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2010 The Android Open Source Project
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
http://www.apache.org/licenses/LICENSE-2.0
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.
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_enabled="false" android:color="@color/abs__bright_foreground_disabled_holo_light"/>
<item android:state_window_focused="false" android:color="@color/abs__bright_foreground_holo_light"/>
<item android:state_pressed="true" android:color="@color/abs__bright_foreground_holo_light"/>
<item android:state_selected="true" android:color="@color/abs__bright_foreground_holo_light"/>
<item android:state_activated="true" android:color="@color/abs__bright_foreground_holo_light"/>
<item android:color="@color/abs__bright_foreground_holo_light"/> <!-- not selected -->
</selector>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 144 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 138 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 144 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 135 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 134 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 156 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 156 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 145 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 192 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 139 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 133 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 145 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 104 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 102 B

Some files were not shown because too many files have changed in this diff Show more