Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update project #3

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ allprojects {
Add the dependency:
```Groovy
dependencies {
implementation 'com.github.Yalantis:Kalendar:v0.0.1-alpha'
implementation 'com.github.Yalantis:Kalendar:v0.0.2-alpha'
}
```

Expand Down
8 changes: 4 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
ext.kotlin_version = '1.3.20'
ext.kotlin_version = '1.7.10'
repositories {
google()
jcenter()
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.3.0'
classpath 'com.android.tools.build:gradle:7.3.0'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"

// NOTE: Do not place your application dependencies here; they belong
Expand All @@ -18,7 +18,7 @@ buildscript {
allprojects {
repositories {
google()
jcenter()
mavenCentral()
}
}

Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip
26 changes: 14 additions & 12 deletions sample/build.gradle
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
android {

compileSdkVersion 28
compileSdkVersion 33

defaultConfig {
applicationId "com.yalantis.sample"
minSdkVersion 21
targetSdkVersion 28
versionCode 1
versionName "1.0"
targetSdkVersion 33
versionCode 2
versionName "1.0.2"

testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

Expand All @@ -23,23 +22,26 @@ android {
}
}

buildFeatures {
viewBinding true
}
}

repositories {
google()
jcenter()
mavenCentral()
maven { url 'https://jitpack.io' }
}

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation "androidx.appcompat:appcompat:1.5.1"
implementation "androidx.constraintlayout:constraintlayout:2.1.4"

implementation 'com.github.yalantis:VishnuCalendar:v0.0.1-alpha'
implementation "com.github.yalantis:VishnuCalendar:v0.0.1-alpha"

testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
testImplementation "junit:junit:4.13.2"
androidTestImplementation "com.android.support.test:runner:1.0.2"
androidTestImplementation "com.android.support.test.espresso:espresso-core:3.0.2"
}
3 changes: 2 additions & 1 deletion sample/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity android:name=".MainActivity">
<activity android:name=".MainActivity"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<action android:name="android.intent.action.VIEW"/>
Expand Down
19 changes: 10 additions & 9 deletions vishnu/build.gradle
Original file line number Diff line number Diff line change
@@ -1,27 +1,28 @@
apply plugin: 'com.android.library'

apply plugin: 'kotlin-android'

apply plugin: 'kotlin-android-extensions'

android {
compileSdkVersion 28
compileSdkVersion 33
defaultConfig {
minSdkVersion 17
targetSdkVersion 28
versionCode 1
versionName "1.0"
targetSdkVersion 33
versionCode 2
versionName "1.0.2"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}

buildFeatures {
viewBinding true
}
}

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.android.support:design:28.0.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation "com.google.android.material:material:1.6.1"
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ class MoveManagerImpl(private val viewProvider: ViewProvider) : MoveManager {
private var startPoint = EMPTY_FLOAT

private val finishListener = object : Animator.AnimatorListener {
override fun onAnimationRepeat(animation: Animator?) {}
override fun onAnimationCancel(animation: Animator?) {}
override fun onAnimationStart(animation: Animator?) {
override fun onAnimationRepeat(animation: Animator) {}
override fun onAnimationCancel(animation: Animator) {}
override fun onAnimationStart(animation: Animator) {
isInAction = true
}

override fun onAnimationEnd(animation: Animator?) {
override fun onAnimationEnd(animation: Animator) {
isInAction = false
isCollapsed = isCollapsed.not()
viewProvider.moveStateChanged(isCollapsed, selectedWeek)
Expand Down Expand Up @@ -119,7 +119,7 @@ class MoveManagerImpl(private val viewProvider: ViewProvider) : MoveManager {
val newHeight = (totalHeight * (touchY / totalHeight)) + dragHeight

when {
touchY in topLimit..bottomLimit -> {
touchY in topLimit.toFloat()..bottomLimit.toFloat() -> {
performMovement(newHeight, touchY)
}
touchY > bottomLimit -> {
Expand Down