Skip to content

Commit

Permalink
fix gradle plugin version
Browse files Browse the repository at this point in the history
  • Loading branch information
mrZizik committed Oct 2, 2023
2 parents 3d1fcbe + 32e55c2 commit c5ed72e
Show file tree
Hide file tree
Showing 251 changed files with 1,993 additions and 1,511 deletions.
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ def pipeline = new org.android.AppPipeline(steps: this,
jobParams: jobParams,
appPushNoti: true,
gitUpdateSubmodule: true,
dockerImage: 'build-tools/android-build-box-jdk11:latest',
dockerImage: 'build-tools/android-build-box:jdk17',
gpgFiles: ['app/google-services.json'])
pipeline.runPipeline('sora')
2 changes: 1 addition & 1 deletion android-foundation
14 changes: 5 additions & 9 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ apply plugin: 'com.google.firebase.crashlytics'
apply plugin: 'com.github.triplet.play'
apply from: '../tests.gradle'

kotlin {
jvmToolchain(11)
}

android {
compileSdkVersion compileVersion
flavorDimensions "default"
Expand Down Expand Up @@ -68,15 +72,6 @@ android {
}
}

compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}

kotlinOptions {
jvmTarget = JavaVersion.VERSION_17
}

buildFeatures {
viewBinding true
buildConfig true
Expand Down Expand Up @@ -134,6 +129,7 @@ android {
configurations {
all*.exclude module: 'bcprov-jdk15on'
}
namespace 'jp.co.soramitsu.sora'
}

hilt {
Expand Down
115 changes: 115 additions & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,121 @@
#Firebase Crashlytics
-keep,includedescriptorclasses public class * extends java.lang.Exception

###########
-keep public class * extends jp.co.soramitsu.common.util.ParseModel {
<fields>;
<methods>;
}

# This is generated automatically by the Android Gradle plugin.
-dontwarn build.IgnoreJava8API
-dontwarn java.awt.Component
-dontwarn java.awt.GraphicsEnvironment
-dontwarn java.awt.HeadlessException
-dontwarn java.awt.Window
-dontwarn java.beans.ConstructorProperties
-dontwarn java.beans.Transient
-dontwarn java.lang.management.ManagementFactory
-dontwarn java.lang.management.RuntimeMXBean
-dontwarn java.lang.management.ThreadMXBean
-dontwarn javax.servlet.ServletContextListener
-dontwarn lombok.NonNull
-dontwarn org.apache.avalon.framework.logger.Logger
-dontwarn org.apache.log.Hierarchy
-dontwarn org.apache.log.Logger
-dontwarn org.apache.log4j.Level
-dontwarn org.apache.log4j.Logger
-dontwarn org.apache.log4j.Priority
-dontwarn org.apache.xml.resolver.Catalog
-dontwarn org.apache.xml.resolver.CatalogManager
-dontwarn org.apache.xml.resolver.readers.CatalogReader
-dontwarn org.apache.xml.resolver.readers.SAXCatalogReader
-dontwarn org.ietf.jgss.GSSContext
-dontwarn org.ietf.jgss.GSSCredential
-dontwarn org.ietf.jgss.GSSException
-dontwarn org.ietf.jgss.GSSManager
-dontwarn org.ietf.jgss.GSSName
-dontwarn org.ietf.jgss.Oid
-dontwarn org.slf4j.impl.StaticLoggerBinder
-dontwarn org.slf4j.impl.StaticMDCBinder
-dontwarn org.slf4j.impl.StaticMarkerBinder
-dontwarn org.w3c.dom.events.DocumentEvent
-dontwarn org.w3c.dom.events.Event
-dontwarn org.w3c.dom.events.EventException
-dontwarn org.w3c.dom.events.EventListener
-dontwarn org.w3c.dom.events.EventTarget
-dontwarn org.w3c.dom.events.MouseEvent
-dontwarn org.w3c.dom.events.MutationEvent
-dontwarn org.w3c.dom.events.UIEvent
-dontwarn org.w3c.dom.html.HTMLAnchorElement
-dontwarn org.w3c.dom.html.HTMLAppletElement
-dontwarn org.w3c.dom.html.HTMLAreaElement
-dontwarn org.w3c.dom.html.HTMLBRElement
-dontwarn org.w3c.dom.html.HTMLBaseElement
-dontwarn org.w3c.dom.html.HTMLBaseFontElement
-dontwarn org.w3c.dom.html.HTMLBodyElement
-dontwarn org.w3c.dom.html.HTMLButtonElement
-dontwarn org.w3c.dom.html.HTMLCollection
-dontwarn org.w3c.dom.html.HTMLDListElement
-dontwarn org.w3c.dom.html.HTMLDirectoryElement
-dontwarn org.w3c.dom.html.HTMLDivElement
-dontwarn org.w3c.dom.html.HTMLDocument
-dontwarn org.w3c.dom.html.HTMLElement
-dontwarn org.w3c.dom.html.HTMLFieldSetElement
-dontwarn org.w3c.dom.html.HTMLFontElement
-dontwarn org.w3c.dom.html.HTMLFormElement
-dontwarn org.w3c.dom.html.HTMLFrameElement
-dontwarn org.w3c.dom.html.HTMLFrameSetElement
-dontwarn org.w3c.dom.html.HTMLHRElement
-dontwarn org.w3c.dom.html.HTMLHeadElement
-dontwarn org.w3c.dom.html.HTMLHeadingElement
-dontwarn org.w3c.dom.html.HTMLHtmlElement
-dontwarn org.w3c.dom.html.HTMLIFrameElement
-dontwarn org.w3c.dom.html.HTMLImageElement
-dontwarn org.w3c.dom.html.HTMLInputElement
-dontwarn org.w3c.dom.html.HTMLIsIndexElement
-dontwarn org.w3c.dom.html.HTMLLIElement
-dontwarn org.w3c.dom.html.HTMLLabelElement
-dontwarn org.w3c.dom.html.HTMLLegendElement
-dontwarn org.w3c.dom.html.HTMLLinkElement
-dontwarn org.w3c.dom.html.HTMLMapElement
-dontwarn org.w3c.dom.html.HTMLMenuElement
-dontwarn org.w3c.dom.html.HTMLMetaElement
-dontwarn org.w3c.dom.html.HTMLModElement
-dontwarn org.w3c.dom.html.HTMLOListElement
-dontwarn org.w3c.dom.html.HTMLObjectElement
-dontwarn org.w3c.dom.html.HTMLOptGroupElement
-dontwarn org.w3c.dom.html.HTMLOptionElement
-dontwarn org.w3c.dom.html.HTMLParagraphElement
-dontwarn org.w3c.dom.html.HTMLParamElement
-dontwarn org.w3c.dom.html.HTMLPreElement
-dontwarn org.w3c.dom.html.HTMLQuoteElement
-dontwarn org.w3c.dom.html.HTMLScriptElement
-dontwarn org.w3c.dom.html.HTMLSelectElement
-dontwarn org.w3c.dom.html.HTMLStyleElement
-dontwarn org.w3c.dom.html.HTMLTableCaptionElement
-dontwarn org.w3c.dom.html.HTMLTableCellElement
-dontwarn org.w3c.dom.html.HTMLTableColElement
-dontwarn org.w3c.dom.html.HTMLTableElement
-dontwarn org.w3c.dom.html.HTMLTableRowElement
-dontwarn org.w3c.dom.html.HTMLTableSectionElement
-dontwarn org.w3c.dom.html.HTMLTextAreaElement
-dontwarn org.w3c.dom.html.HTMLTitleElement
-dontwarn org.w3c.dom.html.HTMLUListElement
-dontwarn org.w3c.dom.ls.LSSerializerFilter
-dontwarn org.w3c.dom.ranges.DocumentRange
-dontwarn org.w3c.dom.ranges.Range
-dontwarn org.w3c.dom.ranges.RangeException
-dontwarn org.w3c.dom.traversal.DocumentTraversal
-dontwarn org.w3c.dom.traversal.NodeFilter
-dontwarn org.w3c.dom.traversal.NodeIterator
-dontwarn org.w3c.dom.traversal.TreeWalker
-dontwarn org.web3j.abi.datatypes.generated.AbiTypes
-dontwarn org.webrtc.Dav1dDecoder
-dontwarn sun.security.x509.X509Key

-dontwarn java.lang.invoke.StringConcatFactory

# Gson
-keep,allowobfuscation,allowoptimization class * {
@com.google.gson.annotations.SerializedName <fields>;
Expand Down
5 changes: 1 addition & 4 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="jp.co.soramitsu.sora">
xmlns:tools="http://schemas.android.com/tools">

<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.INTERNET"/>
Expand All @@ -26,7 +25,6 @@
<activity
android:name=".splash.presentation.SplashActivity"
android:screenOrientation="portrait"
android:theme="@style/SplashTheme"
android:exported="true">

<intent-filter>
Expand Down Expand Up @@ -55,7 +53,6 @@

<activity
android:name="jp.co.soramitsu.feature_assets_impl.presentation.screens.scan.QRCodeScannerActivity"
android:theme="@style/SplashTheme"
android:exported="false"/>

<meta-data
Expand Down
6 changes: 6 additions & 0 deletions app/src/main/java/jp/co/soramitsu/sora/SoraApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ import coil.decode.SvgDecoder
import com.google.firebase.FirebaseApp
import dagger.hilt.android.HiltAndroidApp
import javax.inject.Inject
import jp.co.soramitsu.common.domain.DarkThemeManager
import jp.co.soramitsu.common.domain.OptionsProvider
import jp.co.soramitsu.common.io.FileManager
import jp.co.soramitsu.common.resourses.ResourceManager
Expand Down Expand Up @@ -68,6 +69,9 @@ open class SoraApp : Application(), Configuration.Provider, ImageLoaderFactory {
@Inject
lateinit var workerFactory: HiltWorkerFactory

@Inject
lateinit var darkThemeManager: DarkThemeManager

override fun newImageLoader(): ImageLoader {
val loader = ImageLoader.Builder(this).components {
add(svg)
Expand All @@ -91,6 +95,8 @@ open class SoraApp : Application(), Configuration.Provider, ImageLoaderFactory {
OptionsProvider.CURRENT_VERSION_CODE = BuildConfig.VERSION_CODE
OptionsProvider.CURRENT_VERSION_NAME = BuildConfig.VERSION_NAME
OptionsProvider.APPLICATION_ID = BuildConfig.APPLICATION_ID

darkThemeManager.updateUiModeFromCache()
}

private fun initLogger() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,18 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
package jp.co.soramitsu.sora.splash.presentation

import android.animation.ValueAnimator
import android.graphics.PorterDuff
import android.graphics.PorterDuffColorFilter
import android.os.Bundle
import android.view.View
import androidx.activity.viewModels
import androidx.appcompat.app.AppCompatActivity
import com.airbnb.lottie.LottieProperty
import com.airbnb.lottie.model.KeyPath
import dagger.hilt.android.AndroidEntryPoint
import javax.inject.Inject
import jp.co.soramitsu.common.R
import jp.co.soramitsu.common.util.ext.getColorFromAttrs
import jp.co.soramitsu.feature_main_api.launcher.MainStarter
import jp.co.soramitsu.feature_multiaccount_api.MultiaccountStarter
import jp.co.soramitsu.sora.databinding.ActivitySplashBinding
Expand Down Expand Up @@ -78,7 +84,27 @@ class SplashActivity : AppCompatActivity() {
super.onCreate(savedInstanceState)
setContentView(ActivitySplashBinding.inflate(layoutInflater).also { viewBinding = it }.root)

viewBinding.animationView.addAnimatorUpdateListener(animatorUpdateListener)
val currentPageColorTypedValue = getColorFromAttrs(R.attr.baseBackground)

viewBinding.animationView.apply {
addValueCallback(
KeyPath(
LOTTIE_WILDCARD_GLOBSTAR,
WAVE_ANIMATION_RINGS_PATH,
LOTTIE_WILDCARD_GLOBSTAR,
),
LottieProperty.COLOR_FILTER
) {
PorterDuffColorFilter(
currentPageColorTypedValue.data,
PorterDuff.Mode.MULTIPLY
)
}

addAnimatorUpdateListener(
animatorUpdateListener
)
}

splashViewModel.runtimeInitiated.observe(
this
Expand Down Expand Up @@ -116,4 +142,9 @@ class SplashActivity : AppCompatActivity() {
viewBinding.animationView.removeUpdateListener(animatorUpdateListener)
splashViewModel.nextScreen()
}

private companion object {
const val LOTTIE_WILDCARD_GLOBSTAR = "*"
const val WAVE_ANIMATION_RINGS_PATH = "Ellipse 1"
}
}
4 changes: 2 additions & 2 deletions app/src/main/res/layout/activity_splash.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
android:id="@+id/splashContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/neu_color_100">
android:background="?attr/baseBackground">

<com.airbnb.lottie.LottieAnimationView
android:id="@+id/animation_view"
Expand All @@ -27,7 +27,7 @@
android:visibility="gone"
android:textStyle="bold"
android:fontFamily="@font/sora_bold"
android:textColor="@color/neu_black_default"
android:textColor="?attr/secondaryBackground"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
Expand Down
Loading

0 comments on commit c5ed72e

Please sign in to comment.