Материалы к докладу на AppLive 2020.
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
package by.krossovochkin.testflow | |
import io.reactivex.Observable | |
import io.reactivex.exceptions.CompositeException | |
import io.reactivex.schedulers.Schedulers | |
import kotlinx.coroutines.* | |
import kotlinx.coroutines.flow.* | |
import org.junit.Test | |
import java.util.concurrent.CopyOnWriteArrayList | |
import java.util.concurrent.CountDownLatch |
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
public class MyApplication extends Application { | |
@Override | |
public void onCreate() { | |
super.onCreate(); | |
// Call helper to start Koin | |
JavaAppKoinKt.start(this); | |
} | |
} |
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: 'com.android.application' | |
apply from: "$rootDir/coverage.gradle" | |
//... | |
android { | |
//... | |
buildTypes { | |
//... | |
debug { |
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 android.content.Context; | |
import android.content.res.ColorStateList; | |
import android.content.res.Resources; | |
import android.content.res.Resources.Theme; | |
import android.graphics.Canvas; | |
import android.graphics.ColorFilter; | |
import android.graphics.Outline; | |
import android.graphics.PixelFormat; | |
import android.graphics.PorterDuff.Mode; | |
import android.graphics.Rect; |
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 UIKit | |
import AVFoundation | |
class ViewController: UIViewController, AVCaptureMetadataOutputObjectsDelegate { | |
@IBOutlet weak var myView: UIView! | |
var session: AVCaptureSession? | |
var device: AVCaptureDevice? | |
var input: AVCaptureDeviceInput? |
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
[alias] | |
revert-file = !sh /home/some-user/git-file-revert.sh |
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
public static class ExampleViewHolder extends RecyclerView.ViewHolder | |
implements View.OnClickListener { | |
private int originalHeight = 0; | |
private boolean isViewExpanded = false; | |
private YourCustomView yourCustomView | |
public ExampleViewHolder(View v) { | |
super(v); | |
v.setOnClickListener(this); |
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
/** | |
* Distinguishes different kinds of app starts: <li> | |
* <ul> | |
* First start ever ({@link #FIRST_TIME}) | |
* </ul> | |
* <ul> | |
* First start in this version ({@link #FIRST_TIME_VERSION}) | |
* </ul> | |
* <ul> | |
* Normal app start ({@link #NORMAL}) |
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
public class ScrollViewWithMaxHeight extends ScrollView { | |
public static int WITHOUT_MAX_HEIGHT_VALUE = -1; | |
private int maxHeight = WITHOUT_MAX_HEIGHT_VALUE; | |
public ScrollViewWithMaxHeight(Context context) { | |
super(context); | |
} |
NewerOlder