Skip to content

Instantly share code, notes, and snippets.

@Flashspeed
Flashspeed / animations.kt
Created Feb 25, 2020
Animation Extension Functions
View animations.kt
fun View.slideDownToShow(startPosition: Float, duration: Long = 300L){
if (this.visibility == View.GONE || this.visibility == View.INVISIBLE){
this.visibility = View.VISIBLE
}
val translationAnimation = TranslateAnimation(
0f, // fromXDelta
0f, // toXDelta
- startPosition, // fromYDelta
@Flashspeed
Flashspeed / Android learning resources.md
Last active Aug 27, 2020
List of online resources for improving Android development skills.
View create_jpeg_filename_with_timestamp.txt
private fun createImageFile(albumName: String): File?
{
val randomString = UUID.randomUUID().toString()
val fileLocation = File(
context?.getExternalFilesDir(Environment.DIRECTORY_PICTURES), albumName
)
fileLocation.apply {
if(!this.exists())
@Flashspeed
Flashspeed / usefulAndroidLibraries.md
Last active Feb 23, 2021
Collection of useful android libraries
View usefulAndroidLibraries.md