Permalink
Browse files

initial commit

Signed-off-by: Issac <issac@imid.me>
  • Loading branch information...
0 parents commit 04ea3a958a4d11bb7e8211bb7f0f20f85cead02f Issac committed Aug 15, 2013
Showing with 3,958 additions and 0 deletions.
  1. +30 −0 .gitignore
  2. +1 −0 .gradle/1.6/taskArtifacts/cache.properties
  3. +1 −0 .gradle/1.6/taskArtifacts/cache.properties.lock
  4. BIN .gradle/1.6/taskArtifacts/fileHashes.bin
  5. BIN .gradle/1.6/taskArtifacts/fileSnapshots.bin
  6. BIN .gradle/1.6/taskArtifacts/outputFileStates.bin
  7. BIN .gradle/1.6/taskArtifacts/taskArtifacts.bin
  8. +28 −0 SwipeBackDemo/build.gradle
  9. BIN SwipeBackDemo/libs/android-support-v4.jar
  10. +30 −0 SwipeBackDemo/src/main/AndroidManifest.xml
  11. BIN SwipeBackDemo/src/main/ic_launcher-web.png
  12. +31 −0 SwipeBackDemo/src/main/java/me/imid/swipebacklayout/demo/MainActivity.java
  13. +25 −0 SwipeBackDemo/src/main/java/me/imid/swipebacklayout/demo/TestActivity.java
  14. BIN SwipeBackDemo/src/main/res/drawable-hdpi/ic_launcher.png
  15. BIN SwipeBackDemo/src/main/res/drawable-mdpi/ic_launcher.png
  16. BIN SwipeBackDemo/src/main/res/drawable-xhdpi/ic_launcher.png
  17. BIN SwipeBackDemo/src/main/res/drawable-xxhdpi/ic_launcher.png
  18. +17 −0 SwipeBackDemo/src/main/res/layout/activity_main.xml
  19. +16 −0 SwipeBackDemo/src/main/res/layout/activity_test.xml
  20. +6 −0 SwipeBackDemo/src/main/res/menu/main.xml
  21. +4 −0 SwipeBackDemo/src/main/res/values-sw600dp/dimens.xml
  22. +5 −0 SwipeBackDemo/src/main/res/values-sw720dp-land/dimens.xml
  23. +12 −0 SwipeBackDemo/src/main/res/values-v11/styles.xml
  24. +13 −0 SwipeBackDemo/src/main/res/values-v14/styles.xml
  25. +5 −0 SwipeBackDemo/src/main/res/values/dimens.xml
  26. +9 −0 SwipeBackDemo/src/main/res/values/strings.xml
  27. +20 −0 SwipeBackDemo/src/main/res/values/styles.xml
  28. +27 −0 SwipeBackLayout/build.gradle
  29. BIN SwipeBackLayout/libs/android-support-v4.jar
  30. +18 −0 SwipeBackLayout/src/main/AndroidManifest.xml
  31. BIN SwipeBackLayout/src/main/ic_launcher-web.png
  32. +1,556 −0 SwipeBackLayout/src/main/java/me/imid/swipebacklayout/lib/DrawerLayout.java
  33. +263 −0 SwipeBackLayout/src/main/java/me/imid/swipebacklayout/lib/SwipeBackLayout.java
  34. +1,451 −0 SwipeBackLayout/src/main/java/me/imid/swipebacklayout/lib/ViewDragHelper.java
  35. +40 −0 SwipeBackLayout/src/main/java/me/imid/swipebacklayout/lib/app/SwipeBackActivity.java
  36. BIN SwipeBackLayout/src/main/res/drawable-hdpi/ic_launcher.png
  37. BIN SwipeBackLayout/src/main/res/drawable-mdpi/ic_launcher.png
  38. BIN SwipeBackLayout/src/main/res/drawable-xhdpi/ic_launcher.png
  39. BIN SwipeBackLayout/src/main/res/drawable-xhdpi/shadow.9.png
  40. BIN SwipeBackLayout/src/main/res/drawable-xxhdpi/ic_launcher.png
  41. +16 −0 SwipeBackLayout/src/main/res/layout/activity_main2.xml
  42. +6 −0 SwipeBackLayout/src/main/res/menu/main.xml
  43. +4 −0 SwipeBackLayout/src/main/res/values-sw600dp/dimens.xml
  44. +5 −0 SwipeBackLayout/src/main/res/values-sw720dp-land/dimens.xml
  45. +11 −0 SwipeBackLayout/src/main/res/values-v11/styles.xml
  46. +12 −0 SwipeBackLayout/src/main/res/values-v14/styles.xml
  47. +5 −0 SwipeBackLayout/src/main/res/values/dimens.xml
  48. +8 −0 SwipeBackLayout/src/main/res/values/strings.xml
  49. +20 −0 SwipeBackLayout/src/main/res/values/styles.xml
  50. +1 −0 build.gradle
  51. BIN gradle/wrapper/gradle-wrapper.jar
  52. +7 −0 gradle/wrapper/gradle-wrapper.properties
  53. +164 −0 gradlew
  54. +90 −0 gradlew.bat
  55. +1 −0 settings.gradle
@@ -0,0 +1,30 @@
+#Android generated
+bin
+gen
+gen*
+
+#Eclipse
+.project
+.classpath
+.settings
+
+#IntelliJ IDEA
+.idea
+*.iml
+*.ipr
+*.iws
+out
+build
+
+#Maven
+target
+release.properties
+pom.xml.*
+
+#Ant
+build.xml
+local.properties
+proguard.cfg
+
+#OSX
+.DS_Store
@@ -0,0 +1 @@
+#Sun Aug 11 22:27:11 CST 2013
@@ -0,0 +1 @@
+
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,28 @@
+buildscript {
+ repositories {
+ mavenCentral()
+ }
+ dependencies {
+ classpath 'com.android.tools.build:gradle:0.5.+'
+ }
+}
+apply plugin: 'android'
+
+repositories {
+ mavenCentral()
+}
+
+dependencies {
+ compile 'com.android.support:support-v4:13.0.+'
+ compile project(':SwipeBackLayout')
+}
+
+android {
+ compileSdkVersion 17
+ buildToolsVersion "17.0.0"
+
+ defaultConfig {
+ minSdkVersion 14
+ targetSdkVersion 14
+ }
+}
Binary file not shown.
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+ package="me.imid.swipebacklayout.demo"
+ android:versionCode="1"
+ android:versionName="1.0" >
+
+ <uses-sdk
+ android:minSdkVersion="14"
+ android:targetSdkVersion="14" />
+
+ <application
+ android:allowBackup="true"
+ android:icon="@drawable/ic_launcher"
+ android:label="@string/app_name"
+ android:theme="@style/AppTheme" >
+ <activity
+ android:name="me.imid.swipebacklayout.demo.MainActivity"
+ android:label="@string/app_name" >
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+
+ <category android:name="android.intent.category.LAUNCHER" />
+ </intent-filter>
+ </activity>
+ <activity
+ android:name="me.imid.swipebacklayout.demo.TestActivity"
+ android:label="@string/app_name" />
+ </application>
+
+</manifest>
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -0,0 +1,31 @@
+
+package me.imid.swipebacklayout.demo;
+
+import android.app.Activity;
+import android.content.Intent;
+import android.os.Bundle;
+import android.view.Menu;
+import android.view.View;
+
+public class MainActivity extends Activity {
+
+ @Override
+ protected void onCreate(Bundle savedInstanceState) {
+ super.onCreate(savedInstanceState);
+ setContentView(R.layout.activity_main);
+ findViewById(R.id.btn).setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ startActivity(new Intent(MainActivity.this, TestActivity.class));
+ }
+ });
+ }
+
+ @Override
+ public boolean onCreateOptionsMenu(Menu menu) {
+ // Inflate the menu; this adds items to the action bar if it is present.
+ getMenuInflater().inflate(R.menu.main, menu);
+ return true;
+ }
+
+}
@@ -0,0 +1,25 @@
+
+package me.imid.swipebacklayout.demo;
+
+import android.content.Intent;
+import android.os.Bundle;
+import android.view.View;
+
+import me.imid.swipebacklayout.lib.app.SwipeBackActivity;
+
+/**
+ * Created by Issac on 8/11/13.
+ */
+public class TestActivity extends SwipeBackActivity {
+ @Override
+ protected void onCreate(Bundle savedInstanceState) {
+ super.onCreate(savedInstanceState);
+ setContentView(R.layout.activity_test);
+ findViewById(R.id.btn).setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ startActivity(new Intent(TestActivity.this, TestActivity.class));
+ }
+ });
+ }
+}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -0,0 +1,17 @@
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:tools="http://schemas.android.com/tools"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:paddingLeft="@dimen/activity_horizontal_margin"
+ android:paddingRight="@dimen/activity_horizontal_margin"
+ android:paddingTop="@dimen/activity_vertical_margin"
+ android:paddingBottom="@dimen/activity_vertical_margin"
+ tools:context=".MainActivity">
+
+ <Button
+ android:id="@+id/btn"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/start_activity" />
+
+</RelativeLayout>
@@ -0,0 +1,16 @@
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:paddingLeft="@dimen/activity_horizontal_margin"
+ android:paddingRight="@dimen/activity_horizontal_margin"
+ android:paddingTop="@dimen/activity_vertical_margin"
+ android:paddingBottom="@dimen/activity_vertical_margin"
+ >
+
+ <Button
+ android:id="@+id/btn"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/start_activity"/>
+
+</RelativeLayout>
@@ -0,0 +1,6 @@
+<menu xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:id="@+id/action_settings"
+ android:title="@string/action_settings"
+ android:orderInCategory="100"
+ android:showAsAction="never" />
+</menu>
@@ -0,0 +1,4 @@
+<resources>
+ <!-- Customize dimensions originally defined in res/values/dimens.xml (such as
+ screen margins) for sw600dp devices (e.g. 7" tablets) here. -->
+</resources>
@@ -0,0 +1,5 @@
+<resources>
+ <!-- Customize dimensions originally defined in res/values/dimens.xml (such as
+ screen margins) for sw720dp devices (e.g. 10" tablets) in landscape here. -->
+ <dimen name="activity_horizontal_margin">128dp</dimen>
+</resources>
@@ -0,0 +1,12 @@
+<resources>
+
+ <!--
+ Base application theme for API 11+. This theme completely replaces
+ AppBaseTheme from res/values/styles.xml on API 11+ devices.
+ -->
+ <style name="AppBaseTheme" parent="android:Theme.Holo.Light">
+ <!-- API 11 theme customizations can go here. -->
+ <item name="android:windowIsTranslucent">true</item>
+ </style>
+
+</resources>
@@ -0,0 +1,13 @@
+<resources>
+
+ <!--
+ Base application theme for API 14+. This theme completely replaces
+ AppBaseTheme from BOTH res/values/styles.xml and
+ res/values-v11/styles.xml on API 14+ devices.
+ -->
+ <style name="AppBaseTheme" parent="android:Theme.Holo.Light.DarkActionBar">
+ <!-- API 14 theme customizations can go here. -->
+ <item name="android:windowIsTranslucent">true</item>
+ </style>
+
+</resources>
@@ -0,0 +1,5 @@
+<resources>
+ <!-- Default screen margins, per the Android Design guidelines. -->
+ <dimen name="activity_horizontal_margin">16dp</dimen>
+ <dimen name="activity_vertical_margin">16dp</dimen>
+</resources>
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+
+ <string name="app_name">SwipeBackDemo</string>
+ <string name="action_settings">Settings</string>
+ <string name="hello_world">Hello world!</string>
+ <string name="start_activity">Start new activity!</string>
+
+</resources>
@@ -0,0 +1,20 @@
+<resources>
+
+ <!--
+ Base application theme, dependent on API level. This theme is replaced
+ by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
+ -->
+ <style name="AppBaseTheme" parent="android:Theme.Light">
+ <!--
+ Theme customizations available in newer API levels can go in
+ res/values-vXX/styles.xml, while customizations related to
+ backward-compatibility can go here.
+ -->
+ </style>
+
+ <!-- Application theme. -->
+ <style name="AppTheme" parent="AppBaseTheme">
+ <!-- All customizations that are NOT specific to a particular API-level can go here. -->
+ </style>
+
+</resources>
@@ -0,0 +1,27 @@
+buildscript {
+ repositories {
+ mavenCentral()
+ }
+ dependencies {
+ classpath 'com.android.tools.build:gradle:0.5.+'
+ }
+}
+apply plugin: 'android-library'
+
+repositories {
+ mavenCentral()
+}
+
+dependencies {
+ compile 'com.android.support:support-v4:13.0.+'
+}
+
+android {
+ compileSdkVersion 17
+ buildToolsVersion "17.0.0"
+
+ defaultConfig {
+ minSdkVersion 14
+ targetSdkVersion 14
+ }
+}
Binary file not shown.
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+ package="me.imid.swipebacklayout.lib"
+ android:versionCode="1"
+ android:versionName="1.0" >
+
+ <uses-sdk
+ android:minSdkVersion="8"
+ android:targetSdkVersion="14" />
+
+ <application
+ android:allowBackup="true"
+ android:icon="@drawable/ic_launcher"
+ android:label="@string/app_name"
+ android:theme="@style/AppTheme" >
+ </application>
+
+</manifest>
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.

0 comments on commit 04ea3a9

Please sign in to comment.