Skip to content
This repository has been archived by the owner on Jul 4, 2024. It is now read-only.

Commit

Permalink
remove Unnecessary utils
Browse files Browse the repository at this point in the history
  • Loading branch information
roiacult committed Sep 7, 2020
1 parent b277d74 commit 46632e5
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions backdrop/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,16 @@ android {
}
}

kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8
}

}

dependencies {

implementation deps.android.drawableToolbox
implementation deps.kotlin.kotlin_jre
implementation deps.android.appcompat
implementation deps.android.androidx_core
}
7 changes: 4 additions & 3 deletions backdrop/src/main/java/com/roacult/backdrop/BackdropLayout.kt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import android.util.Log
import android.view.View
import android.widget.FrameLayout
import androidx.appcompat.widget.Toolbar
import androidx.core.view.isVisible
import top.defaults.drawabletoolbox.DrawableBuilder

class BackdropLayout @JvmOverloads constructor(context: Context, attribute : AttributeSet? = null, defStyleAttr: Int = 0)
Expand Down Expand Up @@ -140,7 +141,7 @@ class BackdropLayout @JvmOverloads constructor(context: Context, attribute : Att
if(disableWhenOpened) {
getDisablingView().translationY = transitionHeight
getDisablingView().alpha = calculateAlphaVlue(transitionHeight)
getDisablingView().visible(true)
getDisablingView().isVisible = true
}
}
}
Expand All @@ -153,7 +154,7 @@ class BackdropLayout @JvmOverloads constructor(context: Context, attribute : Att
if(disableWhenOpened) {
getDisablingView().translationY = 0F
getDisablingView().alpha = 0F
getDisablingView().visible(false)
getDisablingView().isVisible = false
}
}
}
Expand Down Expand Up @@ -230,7 +231,7 @@ class BackdropLayout @JvmOverloads constructor(context: Context, attribute : Att
val translation = it.animatedValue as Float
getFrontLayout().translationY = translation
if(disableWhenOpened) {
getDisablingView().visible(translation != 0F)
getDisablingView().isVisible = translation != 0F
getDisablingView().translationY = translation
getDisablingView().alpha = calculateAlphaVlue(translation)
}
Expand Down
7 changes: 0 additions & 7 deletions backdrop/src/main/java/com/roacult/backdrop/Utils.kt

This file was deleted.

4 changes: 3 additions & 1 deletion versions.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ ext.deps = [:]
//pairs below

def versions = [:]
versions.androidx = "1.3.1"
versions.espresso = "3.1.0"
versions.mockito = "2.13.0"
versions.junit = "5.1.1"
Expand Down Expand Up @@ -72,6 +73,7 @@ android.fragment = "androidx.fragment:fragment:$versions.appcompat"
android.recyclerview = "androidx.recyclerview:recyclerview:$versions.appcompat"
android.design = "com.google.android.material:material:$versions.design"
android.constraint_layout = "androidx.constraintlayout:constraintlayout:$versions.constraint_layout"
android.androidx_core = "androidx.core:core-ktx:$versions.androidx"
android.lifecycle_extensions = "androidx.lifecycle:lifecycle-extensions:$versions.lifecycle"
android.ktx_fragment = "androidx.fragment:fragment-ktx:$versions.ktx_fragment"
android.picasso = "com.squareup.picasso:picasso:$versions.picasso_version"
Expand Down Expand Up @@ -180,7 +182,7 @@ deps.rxJava = rxjava

def build_versions = [:]
build_versions.min_sdk = 16
build_versions.target_sdk = 28
build_versions.target_sdk = 29
ext.build_versions = build_versions

deps.android_gradle_plugin = "com.android.tools.build:gradle:$versions.android_gradle_plugin"
Expand Down

0 comments on commit 46632e5

Please sign in to comment.