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
fun sendEvent(name: String, group: String, screen: String, parameters: Map<String, String>) { | |
singleEventDispatcher.dispatch(name, group, screen, parameters) | |
} | |
fun enqueueEvent(name: String, group: String, screen: String, parameters: Map<String, String>) { | |
batchEventDispatcher.dispatch(name, group, screen, parameters) | |
} |
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
apply plugin: 'maven-publish' | |
static def isReleaseBuild() { | |
return !Config.versionName.contains("SNAPSHOT") | |
} | |
def getOutputDir() { | |
if (isReleaseBuild()) { | |
return "${project.buildDir}/releases" | |
} else { |
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 onCreateDialog(savedInstanceState: Bundle?): Dialog { | |
val bottomSheetDialog = super.onCreateDialog(savedInstanceState) as BottomSheetDialog | |
bottomSheetDialog.setOnShowListener { | |
val containerLayout = dialog?.findViewById( | |
com.google.android.material.R.id.container | |
) as? FrameLayout | |
val buttonLayout = LayoutInflater.from(dialog?.context) | |
.inflate(R.layout.layout_delivery_bottom_sheet_buttons, null) | |
.findViewById<LinearLayout>(R.id.layoutButtons) |
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
allprojects { | |
repositories { | |
google() | |
jcenter() | |
... | |
maven { | |
url "https://gitlab.com/api/v4/projects/projectid/packages/maven" | |
name "GitLab" | |
credentials(HttpHeaderCredentials) { | |
name = 'Private-Token' |
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
implementation "com.company.project:artifact:1.0.0-SNAPSHOT" |
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
apply from: "$rootDir/gradle-mvn-push.gradle" |
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
buildscript { | |
... | |
} | |
plugins { | |
id 'maven-publish' | |
} | |
allprojects { | |
... |
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
( printf "\x1f\x8b\x08\x00\x00\x00\x00\x00" ; tail -c +25 cat.ab ) | tar xfvz - |
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
/*https://www.youtube.com/watch?v=_JOapnq8hrs&t=852s | |
video tutorial for consent sdk android | |
*/ | |
import android.support.v7.app.AppCompatActivity; | |
import android.os.Bundle; | |
import android.util.Log; |
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 LivePreference<T> constructor(private val updates: Observable<String>, | |
private val preferences: SharedPreferences, | |
private val key: String, | |
private val defaultValue: T) : MutableLiveData<T>() { | |
private var disposable: Disposable? = null | |
override fun onActive() { | |
super.onActive() | |
value = (preferences.all[key] as T) ?: defaultValue |