k0shk0sh / RetainedDateTimePickers

Android Library to help you with your date & time pickers while retaining the instance of the pickers on orientation change.
Apache License 2.0
106 stars 20 forks source link
android-library datepickerdialog orientation-changes picker timepickerdialog

RetainedDateTimePickers

Android Library to help you with your date & time pickers while retaining the instance of the pickers on orientation change.

Installation

Gradle

compile 'com.github.k0shk0sh:RetainedDateTimePickers:1.0.2'

Maven

<dependency>
  <groupId>com.github.k0shk0sh</groupId>
  <artifactId>RetainedDateTimePickers</artifactId>
  <version>1.0.2</version>
  <type>aar</type>
</dependency>

Usage

Your Activity or Fragment must implement DatePickerCallback and or TimePickerCallback to receive the selected date & selected time if applicable.

RetainedDateTimePickers should be treated as any normal DialogFragment:

To understand more how the library works, please take a look at the sample app.

Screenshots

Why this library?

Dependency

Android Support Fragment Library v24.2.1

Pull requests are welcomed.

Copyright Notice

Copyright (C) 2016 Kosh. Licensed under the Apache 2.0 license (see the LICENSE file).