multiselect


Source link: https://github.com/karanvs/multiselect

multiselect

This is a sample repository for demonstrating the use of multiselect library. Multiselect library is a powerful library to select multiple images and videos efficiently.

Getting Started

  • Add this to build.gradle
repositories {

jcenter()
maven  {
  url “https://jitpack.io”  
}
 
}
 
  • Add dependency for library
dependencies {
 compile 'com.github.karanvs:multiselect:v1.2' 
}
 

Usage

  • Define a theme in styles.xml
<style name="AppTheme.NoActionBar" parent="Theme.AppCompat.Light.NoActionBar">
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item> </style> 

Use the colors of your choice, it will reflect in multiselect activity.

  • Add multiselect activity under application tag and permission to your manifest
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"></uses-permission>  <activity
  android:name="com.veer.multiselect.MultiSelectActivity"
  android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
  <action android:name="com.veer.multiselect.MultiSelectActivity" />
  <category android:name="android.intent.category.DEFAULT" />
</intent-filter> </activity> 
  • For selecting multiple images , use
Intent intent = new Intent(context, MultiSelectActivity.class);
 intent.putExtra(com.veer.multiselect.Util.Constants.LIMIT, limit);
 intent.putExtra(com.veer.multiselect.Util.Constants.SELECT_TYPE, Constants. PATH_IMAGE);
 startActivityForResult(intent,
  com.veer.multiselect.Util.Constants.REQUEST_CODE_MULTISELECT);

  ```  * For selecting multiple videos , use 

Intent intent = new Intent(context, MultiSelectActivity.class); intent.putExtra(com.veer.multiselect.Util.Constants.LIMIT, limit); intent.putExtra(com.veer.multiselect.Util.Constants.SELECT_TYPE, Constants.PATH_VIDEO); startActivityForResult(intent, com.veer.multiselect.Util.Constants.REQUEST_CODE_MULTISELECT); ```

  • Override onActivityResult and use as
@Override public void onActivityResult(int requestCode, int resultCode, Intent data) {

super.onActivityResult(requestCode, resultCode, data);

if (requestCode == com.veer.multiselect.Util.Constants.REQUEST_CODE_MULTISELECT

 && resultCode == RESULT_OK) {

  paths = data.getStringArrayListExtra(com.veer.multiselect.Util.Constants.GET_PATHS);

 
}
 
}
 

//here paths is the arraylist containing paths of items selected.

License

This project is licensed under the Apache 2.0 License - see the LICENSE.txt file for details

Resources

ChartProgressBar is an android library to build a bar chart with progress bar style.

Country gives a list of countries with all their flags.

A circular seekbar for Android, with a control knob! (for the lack of a better word).

A customizable number picker based on Material guidelines.

It is a recycler view adapter that supports multiview holders, filters, and child view click events.

CFAlertDialog is a library that helps you display super awesome dialogs on Android. It offers an adaptive UI support with tons of customisation options. This will save a lot of time for you.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes