Repository: rongi/rotate-layout Branch: master Commit: 8ca8d6567c71 Files: 24 Total size: 27.7 KB Directory structure: gitextract_kr12uiru/ ├── .gitignore ├── LICENSE.md ├── README.md ├── build.gradle ├── examples/ │ ├── AndroidManifest.xml │ ├── build.gradle │ ├── proguard-rules.pro │ ├── project.properties │ ├── res/ │ │ ├── drawable/ │ │ │ └── border.xml │ │ ├── layout/ │ │ │ ├── activity_main.xml │ │ │ └── small_form.xml │ │ ├── values/ │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── values-v14/ │ │ └── styles.xml │ └── src/ │ └── com/ │ └── github/ │ └── rongi/ │ └── rotate_layout/ │ └── example/ │ └── MainActivity.java ├── gradle/ │ └── wrapper/ │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── rotate-layout/ │ ├── AndroidManifest.xml │ ├── build.gradle │ ├── res/ │ │ └── values/ │ │ └── attrs.xml │ └── src/ │ └── com/ │ └── github/ │ └── rongi/ │ └── rotate_layout/ │ └── layout/ │ └── RotateLayout.java └── settings.gradle ================================================ FILE CONTENTS ================================================ ================================================ FILE: .gitignore ================================================ # Local configuration file (sdk path, etc) local.properties # Intellij project files *.iml .idea/ .DS_Store build .gradle projectFilesBackup ================================================ FILE: LICENSE.md ================================================ The MIT License (MIT) Copyright (c) 2015 rongi Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: README.md ================================================ Rotate Layout ============= A custom layout that can rotate it's view [![Example](https://github.com/rongi/rotate-layout/raw/master/docs/screenshot5.png)](#Example) Usage ===== In your layout file add ```xml ``` Voila! Your layout will be rotated 90 degrees. Download ======== ```groovy implementation 'rongi.rotate-layout:rotate-layout:3.0.0' ``` Features ======== 1. The rotated view receives correct touch events. 2. The bounding box is also rotated. This means that if the view was 100x50px before the rotation, then after 90 degrees rotation it will be 50x100px and can fit into another layout with this dimensions. ================================================ FILE: build.gradle ================================================ // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } allprojects { repositories { jcenter() } } ================================================ FILE: examples/AndroidManifest.xml ================================================ ================================================ FILE: examples/build.gradle ================================================ apply plugin: 'com.android.application' android { compileSdkVersion 22 buildToolsVersion '22.0.1' sourceSets { main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] // resources.srcDirs = ['src'] // aidl.srcDirs = ['src'] // renderscript.srcDirs = ['src'] res.srcDirs = ['res'] assets.srcDirs = ['assets'] } // Move the tests to tests/java, tests/res, etc... instrumentTest.setRoot('tests') // Move the build types to build-types/ // For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ... // This moves them out of them default location under src//... which would // conflict with src/ being used by the main source set. // Adding new build types or product flavors should be accompanied // by a similar customization. debug.setRoot('build-types/debug') release.setRoot('build-types/release') } compileOptions { sourceCompatibility JavaVersion.VERSION_1_7 targetCompatibility JavaVersion.VERSION_1_7 } defaultConfig { applicationId "com.github.rongi.rotate_layout.example" minSdkVersion 19 targetSdkVersion 22 versionCode 1 versionName "1" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } } dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) compile project(':rotate-layout') compile 'com.jakewharton:butterknife:7.0.1' } ================================================ FILE: examples/proguard-rules.pro ================================================ # Add project specific ProGuard rules here. # By default, the flags in this file are appended to flags specified # in /Users/dmitry/dev/android-sdk/tools/proguard/proguard-android.txt # You can edit the include path and order by changing the proguardFiles # directive in build.gradle. # # 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 *; #} ================================================ FILE: examples/project.properties ================================================ # 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 edit # "ant.properties", and override values to adapt the script to your # project structure. # # To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): #proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt # Project target. target=android-19 android.library.reference.1=../../../git/rotate-layout/library ================================================ FILE: examples/res/drawable/border.xml ================================================ ================================================ FILE: examples/res/layout/activity_main.xml ================================================ ================================================ FILE: examples/res/layout/small_form.xml ================================================