├── .gitignore ├── .idea ├── .name ├── compiler.xml ├── copyright │ └── profiles_settings.xml ├── dictionaries │ └── Chandru_MacBook.xml ├── gradle.xml ├── misc.xml ├── modules.xml └── vcs.xml ├── LICENSE.txt ├── MaterialDialogBottomSheet.iml ├── README.md ├── app ├── .gitignore ├── app.iml ├── build.gradle ├── proguard-rules.pro └── src │ ├── androidTest │ └── java │ │ └── takeoffandroid │ │ └── materialdialogbottomsheet │ │ └── ApplicationTest.java │ └── main │ ├── AndroidManifest.xml │ ├── java │ └── takeoffandroid │ │ └── materialdialogbottomsheet │ │ └── MainActivity.java │ └── res │ ├── anim │ ├── popup_hide.xml │ └── popup_show.xml │ ├── drawable-hdpi │ ├── details.png │ ├── export.png │ ├── open.png │ └── uninstall.png │ ├── drawable-mdpi │ ├── details.png │ ├── export.png │ ├── open.png │ └── uninstall.png │ ├── drawable-xhdpi │ ├── details.png │ ├── export.png │ ├── open.png │ └── uninstall.png │ ├── drawable-xxhdpi │ ├── details.png │ ├── export.png │ ├── open.png │ └── uninstall.png │ ├── drawable-xxxhdpi │ ├── details.png │ ├── export.png │ ├── open.png │ └── uninstall.png │ ├── layout │ ├── activity_main.xml │ └── bottom_sheet.xml │ ├── menu │ └── menu_main.xml │ ├── mipmap-hdpi │ └── ic_launcher.png │ ├── mipmap-mdpi │ └── ic_launcher.png │ ├── mipmap-xhdpi │ └── ic_launcher.png │ ├── mipmap-xxhdpi │ └── ic_launcher.png │ ├── values-w820dp │ └── dimens.xml │ └── values │ ├── dimens.xml │ ├── strings.xml │ └── styles.xml ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle /.gitignore: -------------------------------------------------------------------------------- 1 | .gradle 2 | /local.properties 3 | /.idea/workspace.xml 4 | /.idea/libraries 5 | .DS_Store 6 | /build 7 | /captures 8 | -------------------------------------------------------------------------------- /.idea/.name: -------------------------------------------------------------------------------- 1 | MaterialDialogBottomSheet -------------------------------------------------------------------------------- /.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/Chandru_MacBook.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | Android 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 38 | 39 | 40 | 41 | 42 | 1.6 43 | 44 | 49 | 50 | 51 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2015 Chandrasekar K 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining 4 | a copy of this software and associated documentation files (the 5 | "Software"), to deal in the Software without restriction, including 6 | without limitation the rights to use, copy, modify, merge, publish, 7 | distribute, sublicense, and/or sell copies of the Software, and to 8 | permit persons to whom the Software is furnished to do so without any conditions and terms. 9 | -------------------------------------------------------------------------------- /MaterialDialogBottomSheet.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-MaterialDialogBottomSheet-green.svg?style=flat)](https://android-arsenal.com/details/1/2057) 2 | # MaterialDialogBottomSheet 3 | 4 | Buy Me a Coffee at ko-fi.com 5 | 6 | MaterialDialogBottomSheet is a custom dialog implementation to use BottomSheet MaterialView feature in pre Lollipop and latest versions of android 7 | 8 | It can be used with an ease by simply enabling dialog as a BottomSheet without using any library integration. 9 | 10 | 11 | 12 | 13 | 14 | 15 | **Applications using MaterialDialogBottomSheet** 16 | 17 | 18 | Logo | Application 19 | -------- | --- 20 | ZappShare | ZappShare 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /app/app.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 8 | 9 | 10 | 11 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 22 5 | buildToolsVersion "22.0.1" 6 | 7 | defaultConfig { 8 | applicationId "takeoffandroid.materialdialogbottomsheet" 9 | minSdkVersion 11 10 | targetSdkVersion 22 11 | versionCode 1 12 | versionName "1.0" 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 | compile 'com.android.support:appcompat-v7:22.2.0' 25 | } 26 | -------------------------------------------------------------------------------- /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/Chandru-MacBook/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 | -------------------------------------------------------------------------------- /app/src/androidTest/java/takeoffandroid/materialdialogbottomsheet/ApplicationTest.java: -------------------------------------------------------------------------------- 1 | package takeoffandroid.materialdialogbottomsheet; 2 | 3 | import android.app.Application; 4 | import android.test.ApplicationTestCase; 5 | 6 | /** 7 | * Testing Fundamentals 8 | */ 9 | public class ApplicationTest extends ApplicationTestCase { 10 | public ApplicationTest() { 11 | super(Application.class); 12 | } 13 | } -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 10 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/src/main/java/takeoffandroid/materialdialogbottomsheet/MainActivity.java: -------------------------------------------------------------------------------- 1 | package takeoffandroid.materialdialogbottomsheet; 2 | 3 | import android.app.Dialog; 4 | import android.content.pm.ResolveInfo; 5 | import android.os.Build; 6 | import android.support.v7.app.ActionBarActivity; 7 | import android.os.Bundle; 8 | import android.support.v7.app.AppCompatActivity; 9 | import android.view.Gravity; 10 | import android.view.Menu; 11 | import android.view.MenuItem; 12 | import android.view.View; 13 | import android.widget.LinearLayout; 14 | import android.widget.TextView; 15 | import android.widget.Toast; 16 | 17 | import java.io.File; 18 | 19 | 20 | public class MainActivity extends AppCompatActivity { 21 | 22 | @Override 23 | protected void onCreate(Bundle savedInstanceState) { 24 | super.onCreate(savedInstanceState); 25 | setContentView(R.layout.activity_main); 26 | } 27 | 28 | public void openBottomSheet (View v) { 29 | 30 | View view = getLayoutInflater ().inflate (R.layout.bottom_sheet, null); 31 | TextView txtBackup = (TextView)view.findViewById( R.id.txt_backup); 32 | TextView txtDetail = (TextView)view.findViewById( R.id.txt_detail); 33 | TextView txtOpen = (TextView)view.findViewById( R.id.txt_open); 34 | final TextView txtUninstall = (TextView)view.findViewById( R.id.txt_uninstall); 35 | 36 | final Dialog mBottomSheetDialog = new Dialog (MainActivity.this, R.style.MaterialDialogSheet); 37 | mBottomSheetDialog.setContentView (view); 38 | mBottomSheetDialog.setCancelable (true); 39 | mBottomSheetDialog.getWindow ().setLayout (LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT); 40 | mBottomSheetDialog.getWindow ().setGravity (Gravity.BOTTOM); 41 | mBottomSheetDialog.show (); 42 | 43 | 44 | txtBackup.setOnClickListener(new View.OnClickListener() { 45 | 46 | @Override 47 | public void onClick(View v) { 48 | Toast.makeText(MainActivity.this,"Clicked Backup",Toast.LENGTH_SHORT).show(); 49 | mBottomSheetDialog.dismiss(); 50 | } 51 | }); 52 | 53 | txtDetail.setOnClickListener(new View.OnClickListener() { 54 | 55 | @Override 56 | public void onClick(View v) { 57 | Toast.makeText(MainActivity.this,"Clicked Detail",Toast.LENGTH_SHORT).show(); 58 | mBottomSheetDialog.dismiss(); 59 | } 60 | }); 61 | 62 | txtOpen.setOnClickListener(new View.OnClickListener() { 63 | 64 | @Override 65 | public void onClick(View v) { 66 | Toast.makeText(MainActivity.this,"Clicked Open",Toast.LENGTH_SHORT).show(); 67 | mBottomSheetDialog.dismiss(); 68 | } 69 | }); 70 | 71 | txtUninstall.setOnClickListener(new View.OnClickListener() { 72 | 73 | @Override 74 | public void onClick(View v) { 75 | Toast.makeText(MainActivity.this,"Clicked Uninstall",Toast.LENGTH_SHORT).show(); 76 | mBottomSheetDialog.dismiss(); 77 | } 78 | }); 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /app/src/main/res/anim/popup_hide.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/anim/popup_show.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/details.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-hdpi/details.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/export.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-hdpi/export.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-hdpi/open.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/uninstall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-hdpi/uninstall.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/details.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-mdpi/details.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/export.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-mdpi/export.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-mdpi/open.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/uninstall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-mdpi/uninstall.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/details.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xhdpi/details.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/export.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xhdpi/export.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xhdpi/open.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/uninstall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xhdpi/uninstall.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/details.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxhdpi/details.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/export.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxhdpi/export.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxhdpi/open.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/uninstall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxhdpi/uninstall.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/details.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxxhdpi/details.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/export.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxxhdpi/export.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxxhdpi/open.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/uninstall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ckdevrel/MaterialDialogBottomSheet/415409e3744bb2eefde9cc6768b188d8ad6b010a/app/src/main/res/drawable-xxxhdpi/uninstall.png -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 9 | 10 |