Skip to content

Commit 4e77f24

Browse files
committed
Added Glide
1 parent 57c3c94 commit 4e77f24

File tree

20 files changed

+271
-14
lines changed

20 files changed

+271
-14
lines changed
47 Bytes
Binary file not shown.

.idea/gradle.xml

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/misc.xml

Lines changed: 8 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ dependencies {
2626
implementation 'androidx.appcompat:appcompat:1.1.0-alpha01'
2727

2828
api project(':omegatypes')
29-
api project(':picasso')
29+
api project(':glide')
3030

3131
testImplementation 'junit:junit:4.12'
3232
androidTestImplementation 'androidx.test:runner:1.1.1'

app/src/main/java/omega_r/com/omegatypesexample/MainActivity.kt

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,7 @@ import android.graphics.BitmapFactory
55
import android.os.Bundle
66
import android.widget.ImageView
77
import android.widget.TextView
8-
import com.omega_r.libs.omegatypes.Image
9-
import com.omega_r.libs.omegatypes.Text
10-
import com.omega_r.libs.omegatypes.applyTo
11-
import com.omega_r.libs.omegatypes.picasso.from
8+
import com.omega_r.libs.omegatypes.*
129
import kotlin.concurrent.thread
1310

1411
class MainActivity : BaseActivity() {

app/src/main/res/layout/activity_main.xml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,11 @@
1717

1818
<ImageView
1919
android:id="@+id/imageview"
20-
android:layout_width="150dp"
21-
android:layout_height="150dp"
20+
android:layout_width="250dp"
21+
android:layout_height="250dp"
2222
android:layout_centerInParent="true"
23+
android:scaleType="centerInside"
24+
android:background="@color/colorAccent"
2325
tools:src="@mipmap/ic_launcher"/>
2426

2527
</RelativeLayout>

build.gradle

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
// Top-level build file where you can add configuration options common to all sub-projects/modules.
22

33
buildscript {
4-
ext.kotlin_version = '1.3.11'
5-
ext.kotlin_version = '1.2.71'
4+
ext.kotlin_version = '1.3.30'
65
ext.supportVersion = '28.0.0'
76
ext.compileSdkVersion = 28
87
ext.targetSdkVersion = 28

glide/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/build

glide/build.gradle

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
apply plugin: 'com.android.library'
2+
apply plugin: 'kotlin-android-extensions'
3+
apply plugin: 'kotlin-android'
4+
apply plugin: 'kotlin-kapt'
5+
6+
android {
7+
compileSdkVersion 28
8+
9+
10+
11+
defaultConfig {
12+
minSdkVersion 14
13+
targetSdkVersion 28
14+
versionCode 1
15+
versionName "1.0"
16+
17+
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
18+
19+
}
20+
21+
buildTypes {
22+
release {
23+
minifyEnabled false
24+
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
25+
}
26+
}
27+
28+
}
29+
30+
dependencies {
31+
implementation project(':omegatypes')
32+
33+
implementation fileTree(dir: 'libs', include: ['*.jar'])
34+
35+
implementation ("com.github.bumptech.glide:glide:4.9.0") {
36+
exclude group: "com.android.support"
37+
}
38+
39+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
40+
}
41+
repositories {
42+
mavenCentral()
43+
}

glide/proguard-rules.pro

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Add project specific ProGuard rules here.
2+
# You can control the set of applied configuration files using the
3+
# proguardFiles setting in build.gradle.
4+
#
5+
# For more details, see
6+
# http://developer.android.com/guide/developing/tools/proguard.html
7+
8+
# If your project uses WebView with JS, uncomment the following
9+
# and specify the fully qualified class name to the JavaScript interface
10+
# class:
11+
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12+
# public *;
13+
#}
14+
15+
# Uncomment this to preserve the line number information for
16+
# debugging stack traces.
17+
#-keepattributes SourceFile,LineNumberTable
18+
19+
# If you keep the line number information, uncomment this to
20+
# hide the original source file name.
21+
#-renamesourcefileattribute SourceFile

0 commit comments

Comments
 (0)