Migrate to AndroidX (#169)

This commit is contained in:
Rafał Borcz 2018-10-20 20:59:46 +02:00 committed by Mikołaj Pich
parent f35d9d4b93
commit b680cc4366
58 changed files with 179 additions and 180 deletions

View File

@ -26,7 +26,7 @@ android {
versionCode 16 versionCode 16
versionName "0.5.2" versionName "0.5.2"
multiDexEnabled true multiDexEnabled true
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true vectorDrawables.useSupportLibrary = true
playAccountConfig = playAccountConfigs.defaultAccountConfig playAccountConfig = playAccountConfigs.defaultAccountConfig
manifestPlaceholders = [ manifestPlaceholders = [
@ -68,38 +68,39 @@ play {
uploadImages = true uploadImages = true
} }
ext.supportVersion = "28.0.0" ext.androidx_version = "1.0.0"
dependencies { dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation('com.github.wulkanowy:api:1400211f0d') { exclude module: "threetenbp" } implementation('com.github.wulkanowy:api:1400211f0d') { exclude module: "threetenbp" }
implementation "com.android.support:support-v4:$supportVersion" implementation "androidx.legacy:legacy-support-v4:$androidx_version"
implementation "com.android.support:appcompat-v7:$supportVersion" implementation "androidx.appcompat:appcompat:$androidx_version"
implementation "com.android.support:design:$supportVersion" implementation "androidx.cardview:cardview:$androidx_version"
implementation "com.android.support:cardview-v7:$supportVersion" implementation "androidx.legacy:legacy-preference-v14:$androidx_version"
implementation "com.android.support:preference-v14:$supportVersion" implementation "com.google.android.material:material:$androidx_version"
implementation 'com.android.support:multidex:1.0.3' implementation 'androidx.multidex:multidex:2.0.0'
implementation "com.google.android.gms:play-services-oss-licenses:16.0.1" implementation "com.google.android.gms:play-services-oss-licenses:16.0.1"
implementation "com.firebase:firebase-jobdispatcher:0.8.5" implementation "com.firebase:firebase-jobdispatcher:0.8.5"
implementation "com.google.dagger:dagger-android-support:2.17" //Do not update dagger https://github.com/google/dagger/issues/1245
kapt "com.google.dagger:dagger-compiler:2.17" implementation "com.google.dagger:dagger-android-support:2.16"
kapt "com.google.dagger:dagger-android-processor:2.17" kapt "com.google.dagger:dagger-compiler:2.16"
kapt "com.google.dagger:dagger-android-processor:2.16"
implementation "android.arch.persistence.room:runtime:1.1.1" implementation "androidx.room:room-runtime:2.1.0-alpha01"
implementation "android.arch.persistence.room:rxjava2:1.1.1" implementation "androidx.room:room-rxjava2:2.1.0-alpha01"
kapt "android.arch.persistence.room:compiler:1.1.1" kapt "androidx.room:room-compiler:2.1.0-alpha01"
implementation "eu.davidea:flexible-adapter:5.0.6" implementation "eu.davidea:flexible-adapter:5.1.0"
implementation "eu.davidea:flexible-adapter-ui:1.0.0-b5" implementation "eu.davidea:flexible-adapter-ui:1.0.0"
implementation "com.aurelhubert:ahbottomnavigation:2.2.0" implementation "com.aurelhubert:ahbottomnavigation:2.2.0"
implementation 'com.ncapdevi:frag-nav:3.0.0-RC3' implementation 'com.ncapdevi:frag-nav:3.0.0-RC3'
implementation 'com.github.pwittchen:reactivenetwork-rx2:2.1.0' implementation 'com.github.pwittchen:reactivenetwork-rx2:3.0.0'
implementation 'io.reactivex.rxjava2:rxandroid:2.0.2' implementation 'io.reactivex.rxjava2:rxandroid:2.1.0'
implementation "io.reactivex.rxjava2:rxjava:2.2.1" implementation "io.reactivex.rxjava2:rxjava:2.2.2"
implementation "com.jakewharton.threetenabp:threetenabp:1.1.0" implementation "com.jakewharton.threetenabp:threetenabp:1.1.0"
@ -115,11 +116,13 @@ dependencies {
debugImplementation "com.amitshekhar.android:debug-db:1.0.4" debugImplementation "com.amitshekhar.android:debug-db:1.0.4"
testImplementation "junit:junit:4.12" testImplementation "junit:junit:4.12"
testImplementation "io.mockk:mockk:1.8.8" testImplementation "io.mockk:mockk:1.8.9"
testImplementation "org.mockito:mockito-inline:2.21.0" testImplementation "org.mockito:mockito-inline:2.23.0"
testImplementation 'org.threeten:threetenbp:1.3.7' testImplementation 'org.threeten:threetenbp:1.3.7'
androidTestImplementation 'com.android.support.test:runner:1.0.2' androidTestImplementation 'androidx.test:core:1.0.0-beta02'
androidTestImplementation "org.mockito:mockito-android:2.21.0" androidTestImplementation 'androidx.test:runner:1.1.0-beta02'
androidTestImplementation 'androidx.test.ext:junit:1.0.0-beta02'
androidTestImplementation "org.mockito:mockito-android:2.23.0"
androidTestImplementation "org.jetbrains.kotlin:kotlin-test:$kotlin_version" androidTestImplementation "org.jetbrains.kotlin:kotlin-test:$kotlin_version"
} }

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.repositories.local package io.github.wulkanowy.data.repositories.local
import android.arch.persistence.room.Room import androidx.room.Room
import android.support.test.InstrumentationRegistry import androidx.test.core.app.ApplicationProvider
import android.support.test.runner.AndroidJUnit4 import androidx.test.ext.junit.runners.AndroidJUnit4
import io.github.wulkanowy.data.db.AppDatabase import io.github.wulkanowy.data.db.AppDatabase
import io.github.wulkanowy.data.db.entities.Attendance import io.github.wulkanowy.data.db.entities.Attendance
import io.github.wulkanowy.data.db.entities.Semester import io.github.wulkanowy.data.db.entities.Semester
@ -22,7 +22,7 @@ class AttendanceLocalTest {
@Before @Before
fun createDb() { fun createDb() {
testDb = Room.inMemoryDatabaseBuilder(InstrumentationRegistry.getContext(), AppDatabase::class.java).build() testDb = Room.inMemoryDatabaseBuilder(ApplicationProvider.getApplicationContext(), AppDatabase::class.java).build()
attendanceLocal = AttendanceLocal(testDb.attendanceDao()) attendanceLocal = AttendanceLocal(testDb.attendanceDao())
} }

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.repositories.local package io.github.wulkanowy.data.repositories.local
import android.arch.persistence.room.Room import androidx.room.Room
import android.support.test.InstrumentationRegistry import androidx.test.core.app.ApplicationProvider
import android.support.test.runner.AndroidJUnit4 import androidx.test.ext.junit.runners.AndroidJUnit4
import io.github.wulkanowy.data.db.AppDatabase import io.github.wulkanowy.data.db.AppDatabase
import io.github.wulkanowy.data.db.entities.Exam import io.github.wulkanowy.data.db.entities.Exam
import io.github.wulkanowy.data.db.entities.Semester import io.github.wulkanowy.data.db.entities.Semester
@ -22,7 +22,7 @@ class ExamLocalTest {
@Before @Before
fun createDb() { fun createDb() {
testDb = Room.inMemoryDatabaseBuilder(InstrumentationRegistry.getContext(), AppDatabase::class.java).build() testDb = Room.inMemoryDatabaseBuilder(ApplicationProvider.getApplicationContext(), AppDatabase::class.java).build()
examLocal = ExamLocal(testDb.examsDao()) examLocal = ExamLocal(testDb.examsDao())
} }

View File

@ -1,9 +1,9 @@
package io.github.wulkanowy.data.repositories.local package io.github.wulkanowy.data.repositories.local
import android.arch.persistence.room.Room
import android.content.Context import android.content.Context
import android.support.test.InstrumentationRegistry import androidx.room.Room
import android.support.test.runner.AndroidJUnit4 import androidx.test.core.app.ApplicationProvider
import androidx.test.ext.junit.runners.AndroidJUnit4
import io.github.wulkanowy.data.db.AppDatabase import io.github.wulkanowy.data.db.AppDatabase
import io.github.wulkanowy.data.db.SharedPrefHelper import io.github.wulkanowy.data.db.SharedPrefHelper
import io.github.wulkanowy.data.db.entities.Student import io.github.wulkanowy.data.db.entities.Student
@ -24,7 +24,7 @@ class SessionLocalTest {
@Before @Before
fun createDb() { fun createDb() {
val context = InstrumentationRegistry.getContext() val context = ApplicationProvider.getApplicationContext<Context>()
testDb = Room.inMemoryDatabaseBuilder(context, AppDatabase::class.java) testDb = Room.inMemoryDatabaseBuilder(context, AppDatabase::class.java)
.build() .build()
sharedHelper = SharedPrefHelper(context.getSharedPreferences("TEST", Context.MODE_PRIVATE)) sharedHelper = SharedPrefHelper(context.getSharedPreferences("TEST", Context.MODE_PRIVATE))

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.repositories.local package io.github.wulkanowy.data.repositories.local
import android.arch.persistence.room.Room import androidx.room.Room
import android.support.test.InstrumentationRegistry import androidx.test.core.app.ApplicationProvider
import android.support.test.runner.AndroidJUnit4 import androidx.test.ext.junit.runners.AndroidJUnit4
import io.github.wulkanowy.data.db.AppDatabase import io.github.wulkanowy.data.db.AppDatabase
import io.github.wulkanowy.data.db.entities.Semester import io.github.wulkanowy.data.db.entities.Semester
import io.github.wulkanowy.data.db.entities.Timetable import io.github.wulkanowy.data.db.entities.Timetable
@ -23,7 +23,7 @@ class TimetableLocalTest {
@Before @Before
fun createDb() { fun createDb() {
testDb = Room.inMemoryDatabaseBuilder(InstrumentationRegistry.getContext(), AppDatabase::class.java).build() testDb = Room.inMemoryDatabaseBuilder(ApplicationProvider.getApplicationContext(), AppDatabase::class.java).build()
timetableDb = TimetableLocal(testDb.timetableDao()) timetableDb = TimetableLocal(testDb.timetableDao())
} }

View File

@ -1,16 +1,15 @@
package io.github.wulkanowy.utils.security package io.github.wulkanowy.utils.security
import android.support.test.InstrumentationRegistry import androidx.test.core.app.ApplicationProvider
import android.support.test.filters.SdkSuppress import androidx.test.ext.junit.runners.AndroidJUnit4
import android.support.test.filters.SmallTest import androidx.test.filters.SdkSuppress
import android.support.test.runner.AndroidJUnit4 import androidx.test.filters.SmallTest
import org.junit.Test import org.junit.Test
import org.junit.runner.RunWith import org.junit.runner.RunWith
import java.security.KeyStore import java.security.KeyStore
import kotlin.test.assertEquals import kotlin.test.assertEquals
import kotlin.test.assertFailsWith import kotlin.test.assertFailsWith
@SmallTest @SmallTest
@RunWith(AndroidJUnit4::class) @RunWith(AndroidJUnit4::class)
class ScramblerTest { class ScramblerTest {
@ -18,7 +17,7 @@ class ScramblerTest {
@Test @Test
fun encryptDecryptTest() { fun encryptDecryptTest() {
assertEquals("TEST", decrypt(encrypt("TEST", assertEquals("TEST", decrypt(encrypt("TEST",
InstrumentationRegistry.getTargetContext()))) ApplicationProvider.getApplicationContext())))
} }
@Test @Test
@ -28,14 +27,14 @@ class ScramblerTest {
} }
assertFailsWith<ScramblerException> { assertFailsWith<ScramblerException> {
encrypt("", InstrumentationRegistry.getTargetContext()) encrypt("", ApplicationProvider.getApplicationContext())
} }
} }
@Test @Test
@SdkSuppress(minSdkVersion = 18) @SdkSuppress(minSdkVersion = 18)
fun emptyKeyStoreTest() { fun emptyKeyStoreTest() {
val text = encrypt("test", InstrumentationRegistry.getTargetContext()) val text = encrypt("test", ApplicationProvider.getApplicationContext())
val keyStore = KeyStore.getInstance("AndroidKeyStore") val keyStore = KeyStore.getInstance("AndroidKeyStore")
keyStore.load(null) keyStore.load(null)

View File

@ -13,6 +13,7 @@
android:icon="@mipmap/ic_launcher" android:icon="@mipmap/ic_launcher"
android:label="@string/app_name" android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round" android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="false"
android:theme="@style/WulkanowyTheme" android:theme="@style/WulkanowyTheme"
android:usesCleartextTraffic="true"> android:usesCleartextTraffic="true">
<activity <activity

View File

@ -1,7 +1,7 @@
package io.github.wulkanowy package io.github.wulkanowy
import android.content.Context import android.content.Context
import android.support.multidex.MultiDex import androidx.multidex.MultiDex
import com.crashlytics.android.Crashlytics import com.crashlytics.android.Crashlytics
import com.crashlytics.android.answers.Answers import com.crashlytics.android.answers.Answers
import com.crashlytics.android.core.CrashlyticsCore import com.crashlytics.android.core.CrashlyticsCore

View File

@ -2,7 +2,7 @@ package io.github.wulkanowy.data
import android.content.Context import android.content.Context
import android.content.SharedPreferences import android.content.SharedPreferences
import android.support.v7.preference.PreferenceManager import androidx.preference.PreferenceManager
import com.github.pwittchen.reactivenetwork.library.rx2.internet.observing.InternetObservingSettings import com.github.pwittchen.reactivenetwork.library.rx2.internet.observing.InternetObservingSettings
import com.github.pwittchen.reactivenetwork.library.rx2.internet.observing.strategy.SocketInternetObservingStrategy import com.github.pwittchen.reactivenetwork.library.rx2.internet.observing.strategy.SocketInternetObservingStrategy
import dagger.Module import dagger.Module
@ -17,7 +17,7 @@ internal class RepositoryModule {
@Singleton @Singleton
@Provides @Provides
fun provideInternetObservingSettings(): InternetObservingSettings { fun provideInternetObservingSettings(): InternetObservingSettings {
return InternetObservingSettings return InternetObservingSettings.builder()
.strategy(SocketInternetObservingStrategy()) .strategy(SocketInternetObservingStrategy())
.host("www.google.com") .host("www.google.com")
.build() .build()

View File

@ -1,10 +1,10 @@
package io.github.wulkanowy.data.db package io.github.wulkanowy.data.db
import android.arch.persistence.room.Database
import android.arch.persistence.room.Room
import android.arch.persistence.room.RoomDatabase
import android.arch.persistence.room.TypeConverters
import android.content.Context import android.content.Context
import androidx.room.Database
import androidx.room.Room
import androidx.room.RoomDatabase
import androidx.room.TypeConverters
import io.github.wulkanowy.data.db.dao.* import io.github.wulkanowy.data.db.dao.*
import io.github.wulkanowy.data.db.entities.* import io.github.wulkanowy.data.db.entities.*
import javax.inject.Singleton import javax.inject.Singleton

View File

@ -1,6 +1,6 @@
package io.github.wulkanowy.data.db package io.github.wulkanowy.data.db
import android.arch.persistence.room.TypeConverter import androidx.room.TypeConverter
import org.threeten.bp.* import org.threeten.bp.*
import java.util.* import java.util.*

View File

@ -1,9 +1,9 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.Dao import androidx.room.Dao
import android.arch.persistence.room.Delete import androidx.room.Delete
import android.arch.persistence.room.Insert import androidx.room.Insert
import android.arch.persistence.room.Query import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Attendance import io.github.wulkanowy.data.db.entities.Attendance
import io.reactivex.Maybe import io.reactivex.Maybe
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate

View File

@ -1,9 +1,9 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.Dao import androidx.room.Dao
import android.arch.persistence.room.Delete import androidx.room.Delete
import android.arch.persistence.room.Insert import androidx.room.Insert
import android.arch.persistence.room.Query import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Exam import io.github.wulkanowy.data.db.entities.Exam
import io.reactivex.Maybe import io.reactivex.Maybe
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate

View File

@ -1,6 +1,6 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.* import androidx.room.*
import io.github.wulkanowy.data.db.entities.Grade import io.github.wulkanowy.data.db.entities.Grade
import io.reactivex.Maybe import io.reactivex.Maybe

View File

@ -1,10 +1,10 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.Dao import androidx.room.Dao
import android.arch.persistence.room.Delete import androidx.room.Delete
import android.arch.persistence.room.Insert import androidx.room.Insert
import android.arch.persistence.room.OnConflictStrategy.REPLACE import androidx.room.OnConflictStrategy.REPLACE
import android.arch.persistence.room.Query import androidx.room.Query
import io.github.wulkanowy.data.db.entities.GradeSummary import io.github.wulkanowy.data.db.entities.GradeSummary
import io.reactivex.Maybe import io.reactivex.Maybe

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.Dao import androidx.room.Dao
import android.arch.persistence.room.Insert import androidx.room.Insert
import android.arch.persistence.room.Query import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Semester import io.github.wulkanowy.data.db.entities.Semester
import io.reactivex.Single import io.reactivex.Single

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.Dao import androidx.room.Dao
import android.arch.persistence.room.Insert import androidx.room.Insert
import android.arch.persistence.room.Query import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Student import io.github.wulkanowy.data.db.entities.Student
import io.reactivex.Maybe import io.reactivex.Maybe

View File

@ -1,9 +1,9 @@
package io.github.wulkanowy.data.db.dao package io.github.wulkanowy.data.db.dao
import android.arch.persistence.room.Dao import androidx.room.Dao
import android.arch.persistence.room.Delete import androidx.room.Delete
import android.arch.persistence.room.Insert import androidx.room.Insert
import android.arch.persistence.room.Query import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Timetable import io.github.wulkanowy.data.db.entities.Timetable
import io.reactivex.Maybe import io.reactivex.Maybe
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate
import java.io.Serializable import java.io.Serializable

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate
import java.io.Serializable import java.io.Serializable

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate
import java.io.Serializable import java.io.Serializable

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
@Entity(tableName = "Grades_Summary") @Entity(tableName = "Grades_Summary")
data class GradeSummary( data class GradeSummary(

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
@Entity(tableName = "Semesters") @Entity(tableName = "Semesters")
data class Semester( data class Semester(

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
@Entity(tableName = "Students") @Entity(tableName = "Students")
data class Student( data class Student(

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.data.db.entities package io.github.wulkanowy.data.db.entities
import android.arch.persistence.room.ColumnInfo import androidx.room.ColumnInfo
import android.arch.persistence.room.Entity import androidx.room.Entity
import android.arch.persistence.room.PrimaryKey import androidx.room.PrimaryKey
import org.threeten.bp.LocalDate import org.threeten.bp.LocalDate
import org.threeten.bp.LocalDateTime import org.threeten.bp.LocalDateTime
import java.io.Serializable import java.io.Serializable

View File

@ -1,10 +1,10 @@
package io.github.wulkanowy.ui.base package io.github.wulkanowy.ui.base
import android.os.Bundle import android.os.Bundle
import android.support.design.widget.Snackbar
import android.support.design.widget.Snackbar.LENGTH_LONG
import android.support.v7.app.AppCompatDelegate
import android.view.View import android.view.View
import androidx.appcompat.app.AppCompatDelegate
import com.google.android.material.snackbar.Snackbar
import com.google.android.material.snackbar.Snackbar.LENGTH_LONG
import dagger.android.support.DaggerAppCompatActivity import dagger.android.support.DaggerAppCompatActivity
abstract class BaseActivity : DaggerAppCompatActivity(), BaseView { abstract class BaseActivity : DaggerAppCompatActivity(), BaseView {

View File

@ -1,8 +1,8 @@
package io.github.wulkanowy.ui.base package io.github.wulkanowy.ui.base
import android.support.design.widget.Snackbar
import android.support.design.widget.Snackbar.LENGTH_LONG
import android.view.View import android.view.View
import com.google.android.material.snackbar.Snackbar
import com.google.android.material.snackbar.Snackbar.LENGTH_LONG
import dagger.android.support.DaggerFragment import dagger.android.support.DaggerFragment
abstract class BaseFragment : DaggerFragment(), BaseView { abstract class BaseFragment : DaggerFragment(), BaseView {

View File

@ -1,9 +1,9 @@
package io.github.wulkanowy.ui.base package io.github.wulkanowy.ui.base
import android.support.v4.app.Fragment
import android.support.v4.app.FragmentManager
import android.support.v4.app.FragmentStatePagerAdapter
import android.view.ViewGroup import android.view.ViewGroup
import androidx.fragment.app.Fragment
import androidx.fragment.app.FragmentManager
import androidx.fragment.app.FragmentStatePagerAdapter
class BasePagerAdapter(fragmentManager: FragmentManager) : FragmentStatePagerAdapter(fragmentManager) { class BasePagerAdapter(fragmentManager: FragmentManager) : FragmentStatePagerAdapter(fragmentManager) {

View File

@ -1,12 +1,12 @@
package io.github.wulkanowy.ui.login.options package io.github.wulkanowy.ui.login.options
import android.os.Bundle import android.os.Bundle
import android.support.v7.app.AppCompatActivity
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
import android.view.View.GONE import android.view.View.GONE
import android.view.View.VISIBLE import android.view.View.VISIBLE
import android.view.ViewGroup import android.view.ViewGroup
import androidx.appcompat.app.AppCompatActivity
import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.FlexibleAdapter
import eu.davidea.flexibleadapter.common.SmoothScrollLinearLayoutManager import eu.davidea.flexibleadapter.common.SmoothScrollLinearLayoutManager
import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.AbstractFlexibleItem

View File

@ -3,7 +3,7 @@ package io.github.wulkanowy.ui.main
import android.content.Context import android.content.Context
import android.content.Intent import android.content.Intent
import android.os.Bundle import android.os.Bundle
import android.support.v4.content.ContextCompat import androidx.core.content.ContextCompat
import com.aurelhubert.ahbottomnavigation.AHBottomNavigation import com.aurelhubert.ahbottomnavigation.AHBottomNavigation
import com.aurelhubert.ahbottomnavigation.AHBottomNavigationItem import com.aurelhubert.ahbottomnavigation.AHBottomNavigationItem
import com.ncapdevi.fragnav.FragNavController import com.ncapdevi.fragnav.FragNavController

View File

@ -1,10 +1,10 @@
package io.github.wulkanowy.ui.main.attendance package io.github.wulkanowy.ui.main.attendance
import android.os.Bundle import android.os.Bundle
import android.support.v4.app.DialogFragment
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
import android.view.ViewGroup import android.view.ViewGroup
import androidx.fragment.app.DialogFragment
import io.github.wulkanowy.R import io.github.wulkanowy.R
import io.github.wulkanowy.data.db.entities.Attendance import io.github.wulkanowy.data.db.entities.Attendance
import io.github.wulkanowy.utils.toFormattedString import io.github.wulkanowy.utils.toFormattedString

View File

@ -1,10 +1,10 @@
package io.github.wulkanowy.ui.main.exam package io.github.wulkanowy.ui.main.exam
import android.os.Bundle import android.os.Bundle
import android.support.v4.app.DialogFragment
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
import android.view.ViewGroup import android.view.ViewGroup
import androidx.fragment.app.DialogFragment
import io.github.wulkanowy.R import io.github.wulkanowy.R
import io.github.wulkanowy.data.db.entities.Exam import io.github.wulkanowy.data.db.entities.Exam
import io.github.wulkanowy.utils.toFormattedString import io.github.wulkanowy.utils.toFormattedString

View File

@ -1,6 +1,5 @@
package io.github.wulkanowy.ui.main.exam package io.github.wulkanowy.ui.main.exam
import android.support.v7.widget.RecyclerView
import android.view.View import android.view.View
import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.FlexibleAdapter
import eu.davidea.flexibleadapter.items.AbstractSectionableItem import eu.davidea.flexibleadapter.items.AbstractSectionableItem
@ -15,7 +14,7 @@ class ExamItem(header: ExamHeader, val exam: Exam) : AbstractSectionableItem<Exa
override fun getLayoutRes() = R.layout.item_exam override fun getLayoutRes() = R.layout.item_exam
override fun createViewHolder(view: View, adapter: FlexibleAdapter<IFlexible<RecyclerView.ViewHolder>>): ViewHolder { override fun createViewHolder(view: View, adapter: FlexibleAdapter<IFlexible<*>>): ViewHolder {
return ViewHolder(view, adapter) return ViewHolder(view, adapter)
} }

View File

@ -1,10 +1,10 @@
package io.github.wulkanowy.ui.main.grade package io.github.wulkanowy.ui.main.grade
import android.os.Bundle import android.os.Bundle
import android.support.v7.app.AlertDialog
import android.view.* import android.view.*
import android.view.View.INVISIBLE import android.view.View.INVISIBLE
import android.view.View.VISIBLE import android.view.View.VISIBLE
import androidx.appcompat.app.AlertDialog
import io.github.wulkanowy.R import io.github.wulkanowy.R
import io.github.wulkanowy.ui.base.BaseFragment import io.github.wulkanowy.ui.base.BaseFragment
import io.github.wulkanowy.ui.base.BasePagerAdapter import io.github.wulkanowy.ui.base.BasePagerAdapter

View File

@ -1,11 +1,11 @@
package io.github.wulkanowy.ui.main.grade.details package io.github.wulkanowy.ui.main.grade.details
import android.os.Bundle import android.os.Bundle
import android.support.v4.app.DialogFragment
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
import android.view.View.GONE import android.view.View.GONE
import android.view.ViewGroup import android.view.ViewGroup
import androidx.fragment.app.DialogFragment
import io.github.wulkanowy.R import io.github.wulkanowy.R
import io.github.wulkanowy.data.db.entities.Grade import io.github.wulkanowy.data.db.entities.Grade
import io.github.wulkanowy.utils.colorStringId import io.github.wulkanowy.utils.colorStringId

View File

@ -2,11 +2,11 @@ package io.github.wulkanowy.ui.main.timetable
import android.annotation.SuppressLint import android.annotation.SuppressLint
import android.os.Bundle import android.os.Bundle
import android.support.v4.app.DialogFragment
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
import android.view.View.GONE import android.view.View.GONE
import android.view.ViewGroup import android.view.ViewGroup
import androidx.fragment.app.DialogFragment
import io.github.wulkanowy.R import io.github.wulkanowy.R
import io.github.wulkanowy.data.db.entities.Timetable import io.github.wulkanowy.data.db.entities.Timetable
import io.github.wulkanowy.utils.toFormattedString import io.github.wulkanowy.utils.toFormattedString

View File

@ -1,6 +1,6 @@
package io.github.wulkanowy.utils package io.github.wulkanowy.utils
import android.support.v4.app.Fragment import androidx.fragment.app.Fragment
import com.ncapdevi.fragnav.FragNavController import com.ncapdevi.fragnav.FragNavController
inline fun FragNavController.setOnTabTransactionListener(crossinline listener: (index: Int) -> Unit) { inline fun FragNavController.setOnTabTransactionListener(crossinline listener: (index: Int) -> Unit) {

View File

@ -1,6 +1,6 @@
package io.github.wulkanowy.utils package io.github.wulkanowy.utils
import android.support.v4.view.ViewPager import androidx.viewpager.widget.ViewPager
inline fun ViewPager.setOnSelectPageListener(crossinline selectListener: (position: Int) -> Unit) { inline fun ViewPager.setOnSelectPageListener(crossinline selectListener: (position: Int) -> Unit) {
addOnPageChangeListener(object : ViewPager.OnPageChangeListener { addOnPageChangeListener(object : ViewPager.OnPageChangeListener {

View File

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 4.4 KiB

View File

@ -1,7 +1,7 @@
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/loginContainer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent">
android:id="@+id/loginContainer">
<com.aurelhubert.ahbottomnavigation.AHBottomNavigationViewPager <com.aurelhubert.ahbottomnavigation.AHBottomNavigationViewPager
android:id="@+id/loginViewpager" android:id="@+id/loginViewpager"

View File

@ -1,22 +1,21 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/mainContainer" android:id="@+id/mainContainer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.design.widget.AppBarLayout <com.google.android.material.appbar.AppBarLayout
android:id="@+id/mainAppBarContainer" android:id="@+id/mainAppBarContainer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
app:elevation="0dp"> app:elevation="0dp">
<android.support.v7.widget.Toolbar <androidx.appcompat.widget.Toolbar
android:id="@+id/mainToolbar" android:id="@+id/mainToolbar"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize" /> android:layout_height="?attr/actionBarSize" />
</com.google.android.material.appbar.AppBarLayout>
</android.support.design.widget.AppBarLayout>
<FrameLayout <FrameLayout
android:id="@+id/mainFragmentContainer" android:id="@+id/mainFragmentContainer"
@ -30,4 +29,4 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="bottom" /> android:layout_gravity="bottom" />
</android.support.design.widget.CoordinatorLayout> </androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@ -4,7 +4,7 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.design.widget.CoordinatorLayout <androidx.coordinatorlayout.widget.CoordinatorLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_marginBottom="50dp"> android:layout_marginBottom="50dp">
@ -16,17 +16,16 @@
android:layout_gravity="center" android:layout_gravity="center"
android:indeterminate="true" /> android:indeterminate="true" />
<android.support.v4.widget.SwipeRefreshLayout <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/attendanceSwipe" android:id="@+id/attendanceSwipe"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/attendanceRecycler" android:id="@+id/attendanceRecycler"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" /> android:layout_height="match_parent" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</android.support.v4.widget.SwipeRefreshLayout>
<LinearLayout <LinearLayout
android:id="@+id/attendanceEmpty" android:id="@+id/attendanceEmpty"
@ -37,7 +36,7 @@
android:padding="10dp" android:padding="10dp"
android:visibility="gone"> android:visibility="gone">
<android.support.v7.widget.AppCompatImageView <androidx.appcompat.widget.AppCompatImageView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:minWidth="100dp" android:minWidth="100dp"
@ -54,7 +53,7 @@
android:text="@string/attendance_no_items" android:text="@string/attendance_no_items"
android:textSize="20sp" /> android:textSize="20sp" />
</LinearLayout> </LinearLayout>
</android.support.design.widget.CoordinatorLayout> </androidx.coordinatorlayout.widget.CoordinatorLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@ -4,7 +4,7 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.design.widget.CoordinatorLayout <androidx.coordinatorlayout.widget.CoordinatorLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_marginBottom="50dp"> android:layout_marginBottom="50dp">
@ -16,17 +16,16 @@
android:layout_gravity="center" android:layout_gravity="center"
android:indeterminate="true" /> android:indeterminate="true" />
<android.support.v4.widget.SwipeRefreshLayout <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/examSwipe" android:id="@+id/examSwipe"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/examRecycler" android:id="@+id/examRecycler"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" /> android:layout_height="match_parent" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</android.support.v4.widget.SwipeRefreshLayout>
<LinearLayout <LinearLayout
android:id="@+id/examEmpty" android:id="@+id/examEmpty"
@ -37,7 +36,7 @@
android:padding="10dp" android:padding="10dp"
android:visibility="gone"> android:visibility="gone">
<android.support.v7.widget.AppCompatImageView <androidx.appcompat.widget.AppCompatImageView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:minWidth="100dp" android:minWidth="100dp"
@ -54,7 +53,7 @@
android:text="@string/exam_no_items" android:text="@string/exam_no_items"
android:textSize="20sp" /> android:textSize="20sp" />
</LinearLayout> </LinearLayout>
</android.support.design.widget.CoordinatorLayout> </androidx.coordinatorlayout.widget.CoordinatorLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@ -1,10 +1,10 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.design.widget.TabLayout <com.google.android.material.tabs.TabLayout
android:id="@+id/gradeTabLayout" android:id="@+id/gradeTabLayout"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="48dp" android:layout_height="48dp"
@ -17,7 +17,7 @@
app:tabMode="fixed" app:tabMode="fixed"
app:tabTextColor="@android:color/white" /> app:tabTextColor="@android:color/white" />
<android.support.v4.view.ViewPager <androidx.viewpager.widget.ViewPager
android:id="@+id/gradeViewPager" android:id="@+id/gradeViewPager"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
@ -30,4 +30,4 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center" android:layout_gravity="center"
android:indeterminate="true" /> android:indeterminate="true" />
</android.support.design.widget.CoordinatorLayout> </androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@ -4,16 +4,16 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v4.widget.SwipeRefreshLayout <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/gradeDetailsSwipe" android:id="@+id/gradeDetailsSwipe"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/gradeDetailsRecycler" android:id="@+id/gradeDetailsRecycler"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" /> android:layout_height="match_parent" />
</android.support.v4.widget.SwipeRefreshLayout> </androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<ProgressBar <ProgressBar
android:id="@+id/gradeDetailsProgress" android:id="@+id/gradeDetailsProgress"
@ -30,7 +30,7 @@
android:orientation="vertical" android:orientation="vertical"
android:visibility="invisible"> android:visibility="invisible">
<android.support.v7.widget.AppCompatImageView <androidx.appcompat.widget.AppCompatImageView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:minWidth="100dp" android:minWidth="100dp"

View File

@ -4,16 +4,16 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v4.widget.SwipeRefreshLayout <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/gradeSummarySwipe" android:id="@+id/gradeSummarySwipe"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/gradeSummaryRecycler" android:id="@+id/gradeSummaryRecycler"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" /> android:layout_height="match_parent" />
</android.support.v4.widget.SwipeRefreshLayout> </androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<ProgressBar <ProgressBar
android:id="@+id/gradeSummaryProgress" android:id="@+id/gradeSummaryProgress"
@ -30,7 +30,7 @@
android:orientation="vertical" android:orientation="vertical"
android:visibility="invisible"> android:visibility="invisible">
<android.support.v7.widget.AppCompatImageView <androidx.appcompat.widget.AppCompatImageView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:minWidth="100dp" android:minWidth="100dp"

View File

@ -1,5 +1,6 @@
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
@ -62,28 +63,28 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:orientation="vertical"> android:orientation="vertical">
<android.support.design.widget.TextInputLayout <com.google.android.material.textfield.TextInputLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginBottom="15dp" android:layout_marginBottom="15dp"
android:hint="@string/login_nickname_hint"> android:hint="@string/login_nickname_hint">
<android.support.design.widget.TextInputEditText <com.google.android.material.textfield.TextInputEditText
android:id="@+id/loginNicknameEdit" android:id="@+id/loginNicknameEdit"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:inputType="textEmailAddress" android:inputType="textEmailAddress"
android:maxLines="1" /> android:maxLines="1" />
</android.support.design.widget.TextInputLayout> </com.google.android.material.textfield.TextInputLayout>
<android.support.design.widget.TextInputLayout <com.google.android.material.textfield.TextInputLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginBottom="15dp" android:layout_marginBottom="15dp"
android:hint="@string/login_password_hint"> android:hint="@string/login_password_hint">
<android.support.design.widget.TextInputEditText <com.google.android.material.textfield.TextInputEditText
android:id="@+id/loginPassEdit" android:id="@+id/loginPassEdit"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
@ -93,16 +94,16 @@
android:maxLines="1" android:maxLines="1"
app:fontFamily="sans-serif" /> app:fontFamily="sans-serif" />
</android.support.design.widget.TextInputLayout> </com.google.android.material.textfield.TextInputLayout>
<android.support.v7.widget.AppCompatSpinner <androidx.appcompat.widget.AppCompatSpinner
android:id="@+id/loginHostEdit" android:id="@+id/loginHostEdit"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:hint="@string/login_host_hint" /> android:hint="@string/login_host_hint" />
</LinearLayout> </LinearLayout>
<android.support.design.widget.TextInputLayout <com.google.android.material.textfield.TextInputLayout
android:id="@+id/loginSymbolInput" android:id="@+id/loginSymbolInput"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
@ -116,11 +117,11 @@
android:imeActionLabel="@string/login_sign_in" android:imeActionLabel="@string/login_sign_in"
android:imeOptions="actionDone" android:imeOptions="actionDone"
android:inputType="textAutoComplete" android:inputType="textAutoComplete"
android:maxLines="1" /> android:maxLines="1"
tools:ignore="LabelFor" />
</com.google.android.material.textfield.TextInputLayout>
</android.support.design.widget.TextInputLayout> <androidx.appcompat.widget.AppCompatButton
<android.support.v7.widget.AppCompatButton
android:id="@+id/loginSignButton" android:id="@+id/loginSignButton"
style="?android:textAppearanceSmall" style="?android:textAppearanceSmall"
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@ -30,7 +30,7 @@
android:text="@string/login_sync" /> android:text="@string/login_sync" />
</RelativeLayout> </RelativeLayout>
<android.support.v7.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/loginOptionsRecycler" android:id="@+id/loginOptionsRecycler"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" /> android:layout_height="match_parent" />

View File

@ -4,7 +4,7 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.design.widget.CoordinatorLayout <androidx.coordinatorlayout.widget.CoordinatorLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_marginBottom="50dp"> android:layout_marginBottom="50dp">
@ -16,17 +16,16 @@
android:layout_gravity="center" android:layout_gravity="center"
android:indeterminate="true" /> android:indeterminate="true" />
<android.support.v4.widget.SwipeRefreshLayout <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/timetableSwipe" android:id="@+id/timetableSwipe"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/timetableRecycler" android:id="@+id/timetableRecycler"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" /> android:layout_height="match_parent" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</android.support.v4.widget.SwipeRefreshLayout>
<LinearLayout <LinearLayout
android:id="@+id/timetableEmpty" android:id="@+id/timetableEmpty"
@ -37,7 +36,7 @@
android:padding="10dp" android:padding="10dp"
android:visibility="gone"> android:visibility="gone">
<android.support.v7.widget.AppCompatImageView <androidx.appcompat.widget.AppCompatImageView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:minWidth="100dp" android:minWidth="100dp"
@ -54,7 +53,7 @@
android:text="@string/timetable_no_items" android:text="@string/timetable_no_items"
android:textSize="20sp" /> android:textSize="20sp" />
</LinearLayout> </LinearLayout>
</android.support.design.widget.CoordinatorLayout> </androidx.coordinatorlayout.widget.CoordinatorLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@ -2,7 +2,7 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="?attr/colorControlHighlight" android:foreground="?attr/colorControlHighlight"
android:minHeight="40dp" android:minHeight="40dp"
android:orientation="horizontal" android:orientation="horizontal"
android:paddingLeft="20dp" android:paddingLeft="20dp"

View File

@ -2,7 +2,7 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="?attr/colorControlHighlight" android:foreground="?attr/colorControlHighlight"
android:orientation="horizontal" android:orientation="horizontal"
android:paddingLeft="20dp" android:paddingLeft="20dp"
android:paddingTop="7dp" android:paddingTop="7dp"

View File

@ -14,7 +14,7 @@
android:paddingStart="10dp" android:paddingStart="10dp"
android:paddingTop="5dp"> android:paddingTop="5dp">
<android.support.v7.widget.AppCompatImageView <androidx.appcompat.widget.AppCompatImageView
android:id="@+id/loginItemImage" android:id="@+id/loginItemImage"
android:layout_width="60dp" android:layout_width="60dp"
android:layout_height="60dp" android:layout_height="60dp"

View File

@ -2,7 +2,7 @@
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:background="@android:color/white"> android:foreground="@android:color/white">
<RelativeLayout <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="MissingTranslation"> <resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="MissingTranslation,Typos">
<string-array name="symbols"> <string-array name="symbols">
<item>Andrychów</item> <item>Andrychów</item>
<item>Augustów</item> <item>Augustów</item>

View File

@ -1,7 +1,6 @@
package io.github.wulkanowy.ui.login.form package io.github.wulkanowy.ui.login.form
import io.github.wulkanowy.TestSchedulers import io.github.wulkanowy.TestSchedulers
import io.github.wulkanowy.api.Api
import io.github.wulkanowy.data.db.entities.Student import io.github.wulkanowy.data.db.entities.Student
import io.github.wulkanowy.data.repositories.SessionRepository import io.github.wulkanowy.data.repositories.SessionRepository
import io.github.wulkanowy.ui.login.LoginErrorHandler import io.github.wulkanowy.ui.login.LoginErrorHandler

View File

@ -1,7 +1,6 @@
package io.github.wulkanowy.ui.login.options package io.github.wulkanowy.ui.login.options
import io.github.wulkanowy.TestSchedulers import io.github.wulkanowy.TestSchedulers
import io.github.wulkanowy.api.Api
import io.github.wulkanowy.data.ErrorHandler import io.github.wulkanowy.data.ErrorHandler
import io.github.wulkanowy.data.db.entities.Student import io.github.wulkanowy.data.db.entities.Student
import io.github.wulkanowy.data.repositories.SessionRepository import io.github.wulkanowy.data.repositories.SessionRepository

View File

@ -9,6 +9,8 @@
# Specifies the JVM arguments used for the daemon process. # Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings. # The setting is particularly useful for tweaking memory settings.
android.enableJetifier=true
android.useAndroidX=true
org.gradle.jvmargs=-Xmx1536m org.gradle.jvmargs=-Xmx1536m
# When configured, Gradle will run in incubating parallel mode. # When configured, Gradle will run in incubating parallel mode.