This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import androidx.compose.foundation.layout.Box | |
import androidx.compose.runtime.Composable | |
import androidx.compose.ui.Modifier | |
import androidx.compose.ui.draw.drawWithContent | |
import androidx.compose.ui.geometry.Offset | |
import androidx.compose.ui.graphics.BlendMode | |
import androidx.compose.ui.graphics.Color | |
import androidx.compose.ui.graphics.nativeCanvas | |
@Composable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"dependencies": { | |
"com.unity.cinemachine": "2.8.6", | |
"com.unity.collab-proxy": "1.15.15", | |
"com.unity.ide.rider": "3.0.13", | |
"com.unity.ide.visualstudio": "2.0.14", | |
"com.unity.ide.vscode": "1.2.5", | |
"com.unity.postprocessing": "3.2.2", | |
"com.unity.recorder": "3.0.3", | |
"com.unity.test-framework": "1.1.31", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CommandInvokationFailure: Gradle build failed. | |
D:\Unity Editors\2021.3.0f1\Editor\Data\PlaybackEngines\AndroidPlayer\OpenJDK\bin\java.exe -classpath "D:\Gradle\gradle-6.1.1\lib\gradle-launcher-6.1.1.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease" | |
stderr[ | |
D:\Unity Projeler\SlidingBlast\Library\Bee\Android\Prj\IL2CPP\Gradle\unityLibrary\src\main\java\com\unity\androidnotifications\UnityNotificationManager.java:328: error: lambda expressions are not supported in -source 1.7 | |
Thread housekeepingThread = new Thread(() -> { | |
^ | |
(use -source 8 or higher to enable lambda expressions) | |
1 error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
android { | |
applicationVariants.all { variant -> | |
delete rootProject.buildDir | |
if(variant.name.toString().toLowerCase().contains("appgallery")){ | |
copy { | |
from "src/appgallery" | |
include "agconnect-services.json" | |
into "." | |
} | |
} else if(variant.name.toString().toLowerCase().contains("playstore")){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
android{ | |
android.productFlavors.each { flavor -> | |
if (getGradle().getStartParameter().getTaskRequests().toString().toLowerCase().contains("appgallery") ){ | |
apply plugin: 'com.huawei.agconnect' | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class LoginHelper(private val context: Context) : BaseLogin() { | |
private lateinit var mGoogleSignInClient: GoogleSignInClient | |
override fun init() { | |
val gso = GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN) | |
.requestEmail() | |
.requestProfile() | |
.build() | |
mGoogleSignInClient = GoogleSignIn.getClient(context, gso) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) | |
setContentView(R.layout.activity_main) | |
val loginHelper: BaseLogin = LoginHelper(applicationContext) | |
loginHelper.init() | |
findViewById<View>(R.id.btn_login).setOnClickListener { | |
loginResultContract.launch(loginHelper.getLoginIntent()) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class LoginHelper(private val context: Context) : BaseLogin() { | |
override fun init() { | |
AGConnectInstance.initialize(context) | |
} | |
override fun getLoginIntent(): Intent { | |
val authParams: AccountAuthParams = | |
AccountAuthParamsHelper(AccountAuthParams.DEFAULT_AUTH_REQUEST_PARAM) | |
.setProfile() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
abstract class BaseLogin { | |
abstract fun init() | |
abstract fun getLoginIntent(): Intent | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
buildTypes { | |
debug{ | |
debuggable true | |
minifyEnabled false | |
buildConfigField "String","BaseUrl","\"test.api.com\"" | |
} | |
release { | |
debuggable false | |
minifyEnabled false | |
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' |
NewerOlder