(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
int maxScrollExtent = (int) ((mOverlayTop.getContentHeight() * mOverlayTop.getScale()) - mOverlayTop.getHeight()); |
public class ScaleToFitWidthHeightTransform implements Transformation { | |
private int mSize; | |
private boolean isHeightScale; | |
public ScaleToFitWidthHeightTransform(int size, boolean isHeightScale){ | |
mSize =size; | |
this.isHeightScale = isHeightScale; | |
} |
@Override | |
public void onResult(People.LoadPeopleResult loadPeopleResult) { | |
if (!loadPeopleResult.getStatus().isSuccess()) { | |
Log.e(TAG, loadPeopleResult.getStatus().toString()); | |
return; | |
} | |
PersonBuffer people = loadPeopleResult.getPersonBuffer(); | |
Log.d(TAG, "" + people.getCount()); | |
for(Person p : people) { | |
Log.d(TAG, p.getDisplayName()); // For example. |
/* | |
* Copyright 2014 Chris Banes | |
* | |
* 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 |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
package apptest.realm.io.androidmtest; | |
import android.Manifest; | |
import android.content.pm.PackageManager; | |
import android.os.Bundle; | |
import android.os.Environment; | |
import android.support.design.widget.FloatingActionButton; | |
import android.support.design.widget.Snackbar; | |
import android.support.v4.app.ActivityCompat; | |
import android.support.v4.content.ContextCompat; |
import android.app.Activity; | |
import android.content.Context; | |
import android.graphics.Rect; | |
import android.view.View; | |
import android.view.inputmethod.InputMethodManager; | |
public class KeyboardUtils { | |
public static void hideKeyboard(Activity activity) { | |
View view = activity.findViewById(android.R.id.content); |
package com.ubiqueworks.android.security; | |
import android.annotation.SuppressLint; | |
import android.annotation.TargetApi; | |
import android.content.Context; | |
import android.content.SharedPreferences; | |
import android.os.Build; | |
import android.security.KeyPairGeneratorSpec; | |
import android.security.keystore.KeyGenParameterSpec; | |
import android.security.keystore.KeyProperties; |
package com.common.utils | |
import org.koin.KoinContext | |
import org.koin.standalone.StandAloneContext | |
import kotlin.jvm.internal.Reflection | |
/** | |
* @author @fredy_mederos | |
*/ |