Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: mutualmobile/CardStackUI
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.3
Choose a base ref
...
head repository: mutualmobile/CardStackUI
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref

Commits on Apr 5, 2016

  1. Bintray Issue fix

    Tushar Acharya committed Apr 5, 2016
    Copy the full SHA
    b4fc298 View commit details
  2. New Version 0.4.4

    Tushar-Acharya committed Apr 5, 2016
    Copy the full SHA
    8553af2 View commit details

Commits on Apr 6, 2016

  1. Bumped up the build tools versions in Travis config

    Mustafa Ali committed Apr 6, 2016
    Copy the full SHA
    b38a76c View commit details
  2. Commented code that is not required in CI

    Mustafa Ali committed Apr 6, 2016
    Copy the full SHA
    3b907b4 View commit details

Commits on Apr 7, 2016

  1. Merge pull request #16 from mutualmobile/fix-build

    Build failure fix
    Tushar-Acharya committed Apr 7, 2016
    Copy the full SHA
    0c3f64f View commit details
  2. Added method to override animation behavior for each card. Added reve…

    …rse animation option in demo app
    Tushar Acharya committed Apr 7, 2016
    Copy the full SHA
    97844bb View commit details
  3. New version release

    Tushar Acharya committed Apr 7, 2016
    Copy the full SHA
    d9fb923 View commit details
  4. Update README.md

    Tushar-Acharya committed Apr 7, 2016
    Copy the full SHA
    c11ebcd View commit details

Commits on Jul 18, 2016

  1. Added scrolling facility

    Tushar Acharya committed Jul 18, 2016
    Copy the full SHA
    95705a0 View commit details
  2. Merge remote-tracking branch 'origin/master'

    Tushar Acharya committed Jul 18, 2016
    Copy the full SHA
    76be00d View commit details
  3. Version Update

    Tushar Acharya committed Jul 18, 2016
    Copy the full SHA
    7a8b854 View commit details
  4. Update README.md

    Tushar-Acharya authored Jul 18, 2016
    Copy the full SHA
    9ad8b25 View commit details

Commits on Jul 19, 2016

  1. Version Update to 0.5.1

    Tushar Acharya committed Jul 19, 2016
    Copy the full SHA
    2922993 View commit details
  2. Version Update to 0.5.2

    Tushar Acharya committed Jul 19, 2016
    Copy the full SHA
    fbc57be View commit details

Commits on Feb 27, 2017

  1. Lib Updates

    tushar-nallan committed Feb 27, 2017
    Copy the full SHA
    434ad49 View commit details

Commits on Feb 28, 2017

  1. travis update

    tushar-nallan committed Feb 28, 2017
    Copy the full SHA
    85b4441 View commit details
  2. Use java8 compiler

    tushar-nallan committed Feb 28, 2017
    Copy the full SHA
    dbc7f46 View commit details
  3. Version Bump to 0.5.3

    tushar-nallan committed Feb 28, 2017
    Copy the full SHA
    ea255ac View commit details
  4. Add mavenCentral

    tushar-nallan committed Feb 28, 2017
    Copy the full SHA
    d89cfae View commit details

Commits on Apr 11, 2017

  1. Update README.md

    Tushar-Acharya authored Apr 11, 2017
    Copy the full SHA
    a43be85 View commit details

Commits on Apr 4, 2019

  1. 1. Updated gradle-plugin to 3.3.2

    2. Targeting latest SDK (28)
    3. compile changed to implementation
    VivekBhalodiyaMM committed Apr 4, 2019
    Copy the full SHA
    1544912 View commit details

Commits on Aug 9, 2019

  1. - Bumped up version to 0.6.0

    - Migrated Library and Sample App to Kotlin
    - Updated card's colours in the Sample App
    - Reformatted Code using Square code style
    - Removed Logger.java and Config.java in the Sample App
    - Added Timber in the Sample App
    - Refactored Application Class name in the Sample App
    - Refactored Prefs Class to PrefsUtils in the Sample App
    - Refactored packages in the Sample App
    VivekBhalodiyaMM committed Aug 9, 2019
    Copy the full SHA
    2a0bcfc View commit details
  2. Copy the full SHA
    ca946c4 View commit details
  3. Merge pull request #1 from Vivek65/enhancement/updated_library_versions

    Enhancement/updated library versions
    VivekBhalodiya authored Aug 9, 2019
    Copy the full SHA
    08390d9 View commit details
  4. Update README.md

    VivekBhalodiya authored Aug 9, 2019
    Copy the full SHA
    abce2e7 View commit details
  5. Copy the full SHA
    b93017b View commit details
  6. Copy the full SHA
    20612c6 View commit details
  7. - Updated Permissions for build-tools 28.0.3 in gradlew

    - Updated travis.yml
    VivekBhalodiyaMM committed Aug 9, 2019
    Copy the full SHA
    83da99f View commit details
  8. Merge pull request #2 from Vivek65/enhancement/updated_library_versions

    Enhancement/updated library versions
    VivekBhalodiya authored Aug 9, 2019
    Copy the full SHA
    360b783 View commit details

Commits on Jan 10, 2020

  1. Merge pull request #37 from Vivek65/master

    Library Versions Updated and migrated to Kotlin
    phanirajabhandari authored Jan 10, 2020
    Copy the full SHA
    e1a9f6c View commit details
Showing with 1,341 additions and 1,227 deletions.
  1. +4 −3 .travis.yml
  2. +11 −9 README.md
  3. +31 −17 app/build.gradle
  4. +20 −18 app/src/main/AndroidManifest.xml
  5. +0 −11 app/src/main/java/com/mutualmobile/cardstack/sample/Application.java
  6. +0 −59 app/src/main/java/com/mutualmobile/cardstack/sample/MainActivity.java
  7. +57 −0 app/src/main/java/com/mutualmobile/cardstack/sample/MainActivity.kt
  8. +0 −158 app/src/main/java/com/mutualmobile/cardstack/sample/MyCardStackAdapter.java
  9. +0 −48 app/src/main/java/com/mutualmobile/cardstack/sample/Prefs.java
  10. +18 −0 app/src/main/java/com/mutualmobile/cardstack/sample/SampleApplication.kt
  11. +178 −0 app/src/main/java/com/mutualmobile/cardstack/sample/adapters/MyCardStackAdapter.kt
  12. +0 −5 app/src/main/java/com/mutualmobile/cardstack/sample/interfaces/OnRestartRequest.java
  13. +5 −0 app/src/main/java/com/mutualmobile/cardstack/sample/interfaces/OnRestartRequest.kt
  14. +0 −17 app/src/main/java/com/mutualmobile/cardstack/sample/utils/Config.java
  15. +0 −58 app/src/main/java/com/mutualmobile/cardstack/sample/utils/Logger.java
  16. +58 −0 app/src/main/java/com/mutualmobile/cardstack/sample/utils/PrefsUtil.kt
  17. +20 −7 app/src/main/res/layout/activity_main.xml
  18. +14 −18 app/src/main/res/layout/card.xml
  19. +133 −125 app/src/main/res/layout/settings_card.xml
  20. +17 −26 app/src/main/res/values/colors.xml
  21. +4 −4 app/src/main/res/values/dimens.xml
  22. +12 −11 app/src/main/res/values/strings.xml
  23. +17 −21 app/src/main/res/values/styles.xml
  24. +35 −12 build.gradle
  25. +83 −64 cardstack/build.gradle
  26. +1 −4 cardstack/src/main/AndroidManifest.xml
  27. +26 −0 cardstack/src/main/java/com/mutualmobile/cardstack/CardFrameLayout.kt
  28. +0 −313 cardstack/src/main/java/com/mutualmobile/cardstack/CardStackAdapter.java
  29. +349 −0 cardstack/src/main/java/com/mutualmobile/cardstack/CardStackAdapter.kt
  30. +0 −207 cardstack/src/main/java/com/mutualmobile/cardstack/CardStackLayout.java
  31. +223 −0 cardstack/src/main/java/com/mutualmobile/cardstack/CardStackLayout.kt
  32. +0 −10 cardstack/src/main/java/com/mutualmobile/cardstack/utils/Units.java
  33. +21 −0 cardstack/src/main/java/com/mutualmobile/cardstack/utils/Units.kt
  34. +2 −2 gradle/wrapper/gradle-wrapper.properties
  35. +2 −0 gradlew
  36. BIN images/showcase/CardClick0.0.6.gif
  37. BIN images/showcase/InitAnimation0.0.6.gif
7 changes: 4 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
language: android
jdk: oraclejdk8
android:
components:
- tools
- build-tools-23.0.2
- android-23
- build-tools-28.0.3
- android-28
- extra-android-m2repository
script:
- ./gradlew assemble
- ./gradlew assemble
20 changes: 11 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,17 @@
# CardStack
An iOS Passbook-like highly customisable stack of cards implementation for Android.

[![Build Status](https://travis-ci.org/mutualmobile/CardStackUI.svg?branch=master)](https://travis-ci.org/mutualmobile/CardStackUI) [![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-CardStackUI-green.svg?style=true)](https://android-arsenal.com/details/1/3096)
[![Build Status](https://travis-ci.org/mutualmobile/CardStackUI.svg?branch=master)](https://travis-ci.org/mutualmobile/CardStackUI) [![Version](https://api.bintray.com/packages/mutualmobile/Android/card-stack-ui/images/download.svg)](https://bintray.com/mutualmobile/Android/card-stack-ui)
[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-CardStackUI-green.svg?style=true)](https://android-arsenal.com/details/1/3096)

<table>
<tr>
<td><h4>Init Animation</h4></td>
<td><h4>Card Click</h4></td>
<td><h4>Basic Drag</h4></td>
<td><h4>Parallax Drag</h4></td>
</tr>
<tr>
<td><img src="https://raw.githubusercontent.com/mutualmobile/CardStackUI/development/images/showcase/InitAnimation.gif?token=ABCt5p-LPvIgv6lQmwPhcs01L7i6s1RNks5WsjhMwA%3D%3D"></td>
<td><img src="https://raw.githubusercontent.com/mutualmobile/CardStackUI/development/images/showcase/Card%20Click.gif?token=ABCt5vutFKLG17UfTjwuNP7Wch6_e0a5ks5Wsi1HwA%3D%3D"></td>
<td><img src="https://raw.githubusercontent.com/mutualmobile/CardStackUI/development/images/showcase/BasicDrag.gif?token=ABCt5uiVA9iKifP5YX9ta6nI_t0KsxVMks5Wsi0GwA%3D%3D"></td>
<td><img src="https://raw.githubusercontent.com/mutualmobile/CardStackUI/development/images/showcase/PrallaxDrag.gif?token=ABCt5t4-uywQ20Kw489R1_5AQ7GXdx07ks5Wsi2QwA%3D%3D"></td>
<td><img src="https://github.com/Vivek65/CardStackUI/blob/master/images/showcase/InitAnimation0.0.6.gif"></td>
<td><img src="https://github.com/Vivek65/CardStackUI/blob/master/images/showcase/CardClick0.0.6.gif"></td>
</tr>
</table>

@@ -26,7 +23,7 @@ Sample app APK - https://github.com/mutualmobile/CardStackUI/releases
```
dependencies {
...
compile 'com.mutualmobile.android:cardstack:0.3'
compile 'com.mutualmobile.android:cardstack:0.6.0'
}
```

@@ -45,10 +42,15 @@ Usage
card_stack:showInitAnimation="true" />
```

Known Issues
-------

```parallax_enabled``` and ```parallax_scale``` are not working currently. Also the drag to move cards also is not working.

License
-------

Copyright 2015 - 2016 Mutual Mobile
Copyright 2015 - 2019 Mutual Mobile

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
48 changes: 31 additions & 17 deletions app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,27 +1,41 @@
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-android'

android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
compileSdkVersion rootProject.ext.COMPILE_SDK_VERSION

defaultConfig {
applicationId "com.mutualmobile.cardstack.sample"
minSdkVersion 14
targetSdkVersion 23
versionCode 1
versionName "1.0"
defaultConfig {
applicationId "com.mutualmobile.cardstack.sample"

minSdkVersion rootProject.ext.MIN_SDK_VERSION
targetSdkVersion rootProject.ext.TARGET_SDK_VERSION

versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
debuggable true
minifyEnabled false
}
}
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:cardview-v7:23.1.1'
compile 'com.tramsun.libs:prefcompat:0.7'
compile project(':cardstack')
compile fileTree(dir: 'libs', include: ['*.jar'])
implementation "com.android.support:cardview-v7:${rootProject.ext.SUPPORT_LIB_VERSION}"
implementation "com.android.support:animated-vector-drawable:${rootProject.ext.SUPPORT_LIB_VERSION}"
implementation "com.android.support:appcompat-v7:${rootProject.ext.SUPPORT_LIB_VERSION}"
implementation 'com.tramsun.libs:prefcompat:0.7'
implementation 'com.mutualmobile.android:cardstack:0.5.3'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.jakewharton.timber:timber:4.7.1'
}
repositories {
mavenCentral()
}
38 changes: 20 additions & 18 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,24 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.mutualmobile.cardstack.sample">

<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:name="com.mutualmobile.cardstack.sample.Application"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity
android:name="com.mutualmobile.cardstack.sample.MainActivity"
android:label="@string/title_activity_main"
android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<application
android:name="com.mutualmobile.cardstack.sample.SampleApplication"
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme"
tools:ignore="GoogleAppIndexingWarning">
<activity
android:name="com.mutualmobile.cardstack.sample.MainActivity"
android:label="@string/title_activity_main"
android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
</application>

</manifest>
</manifest>

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
package com.mutualmobile.cardstack.sample

import android.os.Bundle
import android.support.v7.app.AppCompatActivity
import android.view.View

import com.mutualmobile.cardstack.CardStackLayout
import com.mutualmobile.cardstack.sample.adapters.MyCardStackAdapter
import com.mutualmobile.cardstack.sample.interfaces.OnRestartRequest
import com.mutualmobile.cardstack.sample.utils.PrefsUtil
import com.mutualmobile.cardstack.utils.Units
import timber.log.Timber

class MainActivity : AppCompatActivity(), OnRestartRequest {

private var mCardStackLayout: CardStackLayout? = null

override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)

mCardStackLayout = findViewById<View>(R.id.cardStack) as CardStackLayout
setupAdapter()
}

private fun setupAdapter() {

mCardStackLayout?.isShowInitAnimation = PrefsUtil.isShowInitAnimationEnabled

mCardStackLayout?.isParallaxEnabled = PrefsUtil.isParallaxEnabled
mCardStackLayout?.parallaxScale = PrefsUtil.getParallaxScale(this)

mCardStackLayout?.cardGap = Units.dpToPx(this, PrefsUtil.getCardGap(this))
.toFloat()
mCardStackLayout?.cardGapBottom = Units.dpToPx(this, PrefsUtil.getCardGapBottom(this))
.toFloat()

mCardStackLayout?.adapter = MyCardStackAdapter(this)
}

override fun onBackPressed() {
mCardStackLayout?.let {
if (it.isCardSelected) {
mCardStackLayout?.restoreCards()
} else {
super.onBackPressed()
}
}
}

override fun requestRestart() {
Timber.d("Restarting MainActivity..")
mCardStackLayout?.removeAdapter()

mCardStackLayout?.postDelayed({ setupAdapter() }, 200)
}
}
Loading