Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 19 additions & 12 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
*.apk
*.ap_
*.dex
*.class
bin/
gen/
out/
build/
workspace.xml
.idea
local.properties
ks.properties
.classpath
.project
.DS_Store
/build
/captures
.externalNativeBuild
lint.xml
protected_strings.xml
.gradle
/dist
*.iml
5 changes: 4 additions & 1 deletion .idea/gradle.xml

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

1 change: 0 additions & 1 deletion app/.gitignore

This file was deleted.

10 changes: 0 additions & 10 deletions app/src/main/AndroidManifest.xml

This file was deleted.

34 changes: 0 additions & 34 deletions app/src/main/res/drawable-v24/ic_launcher_foreground.xml

This file was deleted.

74 changes: 0 additions & 74 deletions app/src/main/res/drawable/ic_launcher_background.xml

This file was deleted.

5 changes: 0 additions & 5 deletions app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml

This file was deleted.

5 changes: 0 additions & 5 deletions app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml

This file was deleted.

Binary file removed app/src/main/res/mipmap-hdpi/ic_launcher.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-hdpi/ic_launcher_round.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-mdpi/ic_launcher.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-mdpi/ic_launcher_round.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-xhdpi/ic_launcher.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-xxhdpi/ic_launcher.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
Binary file not shown.
Binary file removed app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Binary file not shown.
Binary file not shown.
6 changes: 0 additions & 6 deletions app/src/main/res/values/colors.xml

This file was deleted.

11 changes: 0 additions & 11 deletions app/src/main/res/values/styles.xml

This file was deleted.

20 changes: 20 additions & 0 deletions lib/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
*.apk
*.ap_
*.dex
*.class
bin/
gen/
out/
build/
workspace.xml
.idea
local.properties
ks.properties
.classpath
.project
.DS_Store
lint.xml
protected_strings.xml
.gradle
/dist
*.iml
8 changes: 5 additions & 3 deletions app/build.gradle → lib/build.gradle
Original file line number Diff line number Diff line change
@@ -1,20 +1,22 @@
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'

android {
compileSdkVersion 28

defaultConfig {
minSdkVersion 21
targetSdkVersion 28
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}

}

dependencies {
implementation"org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
}
implementation 'androidx.appcompat:appcompat:1.0.2'
}
File renamed without changes.
2 changes: 2 additions & 0 deletions lib/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.buffer.android.utils"/>
14 changes: 14 additions & 0 deletions lib/src/main/java/org/buffer/android/utils/ApiLevelHelper.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package org.buffer.android.utils

import android.os.Build

object ApiLevelHelper {

fun isAtLeast(apiLevel: Int): Boolean {
return Build.VERSION.SDK_INT >= apiLevel
}

fun isLowerThan(apiLevel: Int): Boolean {
return Build.VERSION.SDK_INT < apiLevel
}
}
15 changes: 15 additions & 0 deletions lib/src/main/java/org/buffer/android/utils/KeyboardUtil.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package org.buffer.android.utils

import android.content.Context
import android.view.View
import android.view.inputmethod.InputMethodManager

object KeyboardUtil {
fun closeSoftKeyboard(view: View?) {
if (view != null) {
val inputManager = view.context.getSystemService(
Context.INPUT_METHOD_SERVICE) as InputMethodManager?
inputManager?.hideSoftInputFromWindow(view.windowToken, 0)
}
}
}
2 changes: 1 addition & 1 deletion settings.gradle
Original file line number Diff line number Diff line change
@@ -1 +1 @@
include ':app'
include ':lib'