├── .gitignore ├── .idea ├── compiler.xml ├── copyright │ └── profiles_settings.xml ├── dictionaries │ └── apple.xml ├── encodings.xml ├── gradle.xml ├── misc.xml ├── modules.xml └── runConfigurations.xml ├── README.md ├── app ├── .gitignore ├── build.gradle ├── proguard-rules.pro └── src │ ├── androidTest │ └── java │ │ └── com │ │ └── jzp │ │ └── rotate3d │ │ └── sample │ │ └── ExampleInstrumentedTest.java │ ├── main │ ├── AndroidManifest.xml │ ├── java │ │ └── com │ │ │ └── jzp │ │ │ └── rotate3d │ │ │ └── sample │ │ │ └── MainActivity.java │ └── res │ │ ├── drawable-xxhdpi │ │ ├── btn_drop.png │ │ ├── btn_hide.png │ │ ├── btn_hide_blue.png │ │ ├── btn_shape.xml │ │ ├── home_bg.png │ │ ├── ic_account_iphone.png │ │ ├── ic_password.png │ │ ├── ic_third_login_qq.png │ │ ├── ic_third_wechat.png │ │ ├── ic_third_weibo.png │ │ ├── ic_username.png │ │ ├── icon_code.png │ │ └── icon_iphone.png │ │ ├── drawable │ │ └── logo.jpg │ │ ├── layout │ │ └── activity_main.xml │ │ ├── mipmap-hdpi │ │ ├── ic_launcher.png │ │ └── ic_launcher_round.png │ │ ├── mipmap-mdpi │ │ ├── ic_launcher.png │ │ └── ic_launcher_round.png │ │ ├── mipmap-xhdpi │ │ ├── ic_launcher.png │ │ └── ic_launcher_round.png │ │ ├── mipmap-xxhdpi │ │ ├── ic_launcher.png │ │ └── ic_launcher_round.png │ │ ├── mipmap-xxxhdpi │ │ ├── ic_launcher.png │ │ └── ic_launcher_round.png │ │ └── values │ │ ├── colors.xml │ │ ├── strings.xml │ │ └── styles.xml │ └── test │ └── java │ └── com │ └── jzp │ └── rotate3d │ └── sample │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── image ├── image.gif └── qrcode.png ├── library ├── .gitignore ├── build.gradle ├── proguard-rules.pro └── src │ ├── androidTest │ └── java │ │ └── com │ │ └── jzp │ │ └── rotate3d │ │ └── ExampleInstrumentedTest.java │ ├── main │ ├── AndroidManifest.xml │ ├── java │ │ └── com │ │ │ └── jzp │ │ │ └── rotate3d │ │ │ ├── Rotate3D.java │ │ │ └── Rotate3dAnimation.java │ └── res │ │ └── values │ │ └── strings.xml │ └── test │ └── java │ └── com │ └── jzp │ └── rotate3d │ └── ExampleUnitTest.java └── settings.gradle /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | .externalNativeBuild 10 | -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /.idea/dictionaries/apple.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 18 | 19 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 19 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | Android 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 62 | 63 | 64 | 65 | 66 | 67 | 72 | 73 | 74 | 75 | 76 | 77 | 1.8 78 | 79 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 95 | 96 | 97 | 98 | 99 | 100 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Rotate3D 2 | This is a 3D ratate library ,You can easy use it 3 | 4 | # Preview 5 | 6 | ![img](image/image.gif) 7 | 8 | # Demo Apk 9 | 10 | you can scan the qrcode for download demo apk 11 | 12 | ![](image/qrcode.png) 13 | 14 | # Feature 15 | - Light 16 | - Noninvasive,You don't need to make changes to existing code. 17 | - Wide applicability,It is available for all views 18 | 19 | # Getting started 20 | 21 | In your build.gradle: 22 | 23 | dependencies { 24 | compile 'com.jzp:rotate3D:1.0.0' 25 | } 26 | 27 | 28 | # Usage 29 | create Rotate3D 30 | 31 | Rotate3D anim = new Rotate3D.Builder(this) 32 | .bindParentView(parent_ll) 33 | .bindPositiveView(account_login_ll) 34 | .bindNegativeView(account_phone_ll) 35 | .create(); 36 | 37 | start the 3D animation 38 | 39 | anim.transform(); 40 | # Follow Me 41 | ![](http://upload-images.jianshu.io/upload_images/1750086-58e561db5db3a196.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240) 42 | 43 | # License 44 | 45 | Copyright 2017, Rotate3D , 1179537855@qq.com 46 | 47 | Licensed under the Apache License, Version 2.0 (the "License"); 48 | you may not use this file except in compliance with the License. 49 | You may obtain a copy of the License at 50 | 51 | http://www.apache.org/licenses/LICENSE-2.0 52 | 53 | Unless required by applicable law or agreed to in writing, software 54 | distributed under the License is distributed on an "AS IS" BASIS, 55 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 56 | See the License for the specific language governing permissions and 57 | limitations under the License. 58 | -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 25 5 | buildToolsVersion "25.0.3" 6 | defaultConfig { 7 | applicationId "com.jzp.rotate3d.sample" 8 | minSdkVersion 14 9 | targetSdkVersion 25 10 | versionCode 1 11 | versionName "1.0" 12 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 13 | } 14 | buildTypes { 15 | release { 16 | minifyEnabled false 17 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 18 | } 19 | } 20 | } 21 | 22 | dependencies { 23 | compile fileTree(dir: 'libs', include: ['*.jar']) 24 | androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', { 25 | exclude group: 'com.android.support', module: 'support-annotations' 26 | }) 27 | compile 'com.android.support:appcompat-v7:25.3.1' 28 | compile 'com.android.support.constraint:constraint-layout:1.0.2' 29 | testCompile 'junit:junit:4.12' 30 | compile project(":library") 31 | } 32 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/apple/Library/Android/sdk/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | 19 | # Uncomment this to preserve the line number information for 20 | # debugging stack traces. 21 | #-keepattributes SourceFile,LineNumberTable 22 | 23 | # If you keep the line number information, uncomment this to 24 | # hide the original source file name. 25 | #-renamesourcefileattribute SourceFile 26 | -------------------------------------------------------------------------------- /app/src/androidTest/java/com/jzp/rotate3d/sample/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.jzp.rotate3d.sample; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumentation test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() throws Exception { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.jzp.rotate3d.sample", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/src/main/java/com/jzp/rotate3d/sample/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.jzp.rotate3d.sample; 2 | 3 | import android.support.v7.app.AppCompatActivity; 4 | import android.os.Bundle; 5 | import android.view.View; 6 | import android.widget.LinearLayout; 7 | import android.widget.TextView; 8 | 9 | import com.jzp.rotate3d.Rotate3D; 10 | 11 | public class MainActivity extends AppCompatActivity { 12 | 13 | Rotate3D anim; 14 | private LinearLayout account_login_ll; 15 | private LinearLayout account_phone_ll; 16 | private LinearLayout parent_ll; 17 | private TextView no_pass_login; 18 | 19 | @Override 20 | protected void onCreate(Bundle savedInstanceState) { 21 | super.onCreate(savedInstanceState); 22 | setContentView(R.layout.activity_main); 23 | account_phone_ll = (LinearLayout) findViewById(R.id.account_phone_ll); 24 | account_login_ll = (LinearLayout) findViewById(R.id.account_login_ll); 25 | parent_ll = (LinearLayout) findViewById(R.id.parent_ll); 26 | no_pass_login = (TextView) findViewById(R.id.no_pass_login); 27 | 28 | anim = new Rotate3D.Builder(this) 29 | .bindParentView(parent_ll) 30 | .bindPositiveView(account_login_ll) 31 | .bindNegativeView(account_phone_ll) 32 | .create(); 33 | 34 | no_pass_login.setOnClickListener(new View.OnClickListener() { 35 | @Override 36 | public void onClick(View v) { 37 | anim.transform(); 38 | if (anim.isOpen()) { 39 | no_pass_login.setText("使用免密登录"); 40 | } else { 41 | no_pass_login.setText("使用账户登录"); 42 | } 43 | } 44 | }); 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/btn_drop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/btn_drop.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/btn_hide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/btn_hide.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/btn_hide_blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/btn_hide_blue.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/btn_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/home_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/home_bg.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_account_iphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/ic_account_iphone.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_password.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/ic_password.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_third_login_qq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/ic_third_login_qq.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_third_wechat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/ic_third_wechat.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_third_weibo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/ic_third_weibo.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_username.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/ic_username.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/icon_code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/icon_code.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/icon_iphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable-xxhdpi/icon_iphone.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiangzepeng/Rotate3DSample/fd5075db3d1a1aa3214582440de774507a7e2fc5/app/src/main/res/drawable/logo.jpg -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 15 | 16 | 25 | 26 | 27 | 28 | 35 | 36 | 43 | 51 | 52 | 61 | 62 | 69 | 70 | 83 | 84 | 93 | 94 | 95 | 103 | 104 | 110 | 111 | 118 | 119 | 132 | 133 | 140 | 141 | 142 | 143 | 151 | 152 | 153 | 160 | 161 | 169 | 170 | 180 | 181 | 187 | 188 | 195 | 196 | 209 | 210 | 219 | 220 | 221 | 229 | 230 | 236 | 237 | 243 | 244 | 257 | 258 | 265 | 266 | 274 | 275 | 276 | 277 | 285 | 286 | 287 | 288 |