Dev: https://dev001.rimpark.io
Test: https://test.rimpark.io
Dev: https://dev001.rimpark.io
Test: https://test.rimpark.io
/** | |
* In our production code, this typealias is more interesting, | |
* something like AlertContainerScreen<PanelContainerScreen<R>> | |
*/ | |
typealias MetaRootRendering<R>: AlertContainerScreen<R> | |
data class ActivityAndRoot<R> ( | |
val activity: Activity, | |
val root: R | |
) |
/* | |
* Copyright 2020 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
/** | |
* Designed and developed by Seanghay Yath (@seanghay) | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
/* Copyright 2019 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* https://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software | |
* distributed under the License is distributed on an "AS IS" BASIS, |
import android.content.Context | |
import android.graphics.Point | |
import android.graphics.Rect | |
import android.util.AttributeSet | |
import android.view.View | |
import android.view.ViewParent | |
import com.google.android.material.textfield.TextInputEditText | |
import com.google.android.material.textfield.TextInputLayout | |
class MyTextInputEditText : TextInputEditText { |
import android.content.Context | |
import android.graphics.Canvas | |
import android.graphics.Color | |
import android.graphics.Paint | |
import android.util.AttributeSet | |
import android.view.View | |
private const val N = 16 | |
private const val PERIOD1 = -10000.0 | |
private const val PERIOD2 = -500.0 |
Apache License | |
Version 2.0, January 2004 | |
http://www.apache.org/licenses/ | |
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION | |
1. Definitions. | |
"License" shall mean the terms and conditions for use, reproduction, | |
and distribution as defined by Sections 1 through 9 of this document. |
/** | |
* An [Observer] for [Event]s, simplifying the pattern of checking if the [Event]'s content has | |
* already been handled. | |
* | |
* [onEventUnhandledContent] is *only* called if the [Event]'s contents has not been handled. | |
*/ | |
class EventObserver<T>(private val onEventUnhandledContent: (T) -> Unit) : Observer<Event<T>> { | |
override fun onChanged(event: Event<T>?) { | |
event?.getContentIfNotHandled()?.let { value -> | |
onEventUnhandledContent(value) |
package statemachine | |
import debug | |
import fail | |
import io.reactivex.Observable | |
import kotlinx.coroutines.experimental.channels.Channel | |
import kotlinx.coroutines.experimental.channels.produce | |
import kotlinx.coroutines.experimental.delay | |
import kotlinx.coroutines.experimental.launch | |
import kotlinx.coroutines.experimental.runBlocking |