This file contains hidden or 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 com.firebase.client; | |
| import com.firebase.client.core.Constants; | |
| import rx.Observable; | |
| import rx.Subscriber; | |
| import rx.functions.Action0; | |
| import rx.functions.Func1; | |
| import rx.subscriptions.Subscriptions; | |
| public class RxFirebase { |
This file contains hidden or 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
| adb shell screenrecord /sdcard/v.mp4 | |
| adb pull /sdcard/v.mp4 v.mp4 | |
| avconv -i v.mp4 -r 24 frame%005d.png | |
This file contains hidden or 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.media.AudioManager; | |
| import android.media.MediaPlayer; | |
| import android.util.Pair; | |
| import org.jetbrains.annotations.NotNull; | |
| import java.io.File; | |
| import java.io.IOException; | |
| import java.util.concurrent.TimeUnit; | |
| import rx.Observable; | |
| import rx.subscriptions.Subscriptions; |
This file contains hidden or 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
| GooglePlusContactsSync E Failed to clear out contacts | |
| E java.lang.SecurityException: Permission Denial: opening provider com.android.providers.contacts.ContactsProvider2 from ProcessRecord{4a8bb85 28657:com.google.android.apps.plus/u0a79} (pid=28657, uid=10079) requir | |
| es android.permission.READ_CONTACTS or android.permission.WRITE_CONTACTS | |
| E at android.os.Parcel.readException(Parcel.java:1620) | |
| E at android.os.Parcel.readException(Parcel.java:1573) | |
| E at android.app.ActivityManagerProxy.getContentProvider(ActivityManagerNative.java:3550) | |
| E at android.app.ActivityThread.acquireProvider(ActivityThread.java:4783) | |
| E at android.app.ContextImpl$ApplicationContentResolver.acquireUnstableProvider(ContextImpl.java:2018) | |
| E at android.content.ContentResolver.acquireUnstableProvider(Content |
This file contains hidden or 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 rx.Observable.Operator; | |
| import rx.Subscriber; | |
| import rx.exceptions.Exceptions; | |
| import rx.functions.Func2; | |
| /** | |
| * Created by Artem Kholodnyi on 3/23/16. | |
| */ | |
| /** |
This file contains hidden or 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 rx.android.observables; | |
| import rx.Observable; | |
| import rx.Observable.OnSubscribe; | |
| import rx.Subscriber; | |
| import rx.android.subscriptions.AndroidSubscriptions; | |
| import rx.functions.Action0; | |
| import android.content.BroadcastReceiver; | |
| import android.content.Context; | |
| import android.content.Intent; |
This file contains hidden or 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 -> | |
| def flavor = variant.mergedFlavor | |
| def name = flavor.getVersionName() | |
| def versionName = name + '-' + variant.properties.get('flavorName') | |
| if (variant.buildType.isDebuggable()) { | |
| versionName += '-debug'; | |
| } | |
| flavor.versionName = versionName; | |
| } |
This file contains hidden or 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 CubesWithVboWithStride extends Cubes { | |
| final int mCubeBufferIdx; | |
| CubesWithVboWithStride(float[] cubePositions, float[] cubeNormals, float[] cubeTextureCoordinates, int generatedCubeFactor) { | |
| FloatBuffer cubeBuffer = getInterleavedBuffer(cubePositions, cubeNormals, cubeTextureCoordinates, generatedCubeFactor); | |
| // Second, copy these buffers into OpenGL's memory. After, we don't need to keep the client-side buffers around. | |
| final int buffers[] = new int[1]; | |
| GLES20.glGenBuffers(1, buffers, 0); |
This file contains hidden or 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
| // Top-level build file where you can add configuration options common to all sub-projects/modules. | |
| buildscript { | |
| repositories { | |
| jcenter() | |
| maven { | |
| url 'https://repos.zeroturnaround.com/nexus/content/repositories/zt-public-releases' | |
| } | |
| } | |
| dependencies { |
This file contains hidden or 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
| float[] result = new float[3]; | |
| Location.distanceBetween( | |
| -33.947730, 25.559675, | |
| -33.94772833333333, 25.55967333333333, | |
| result | |
| ); | |
| Log.d("distance", "" + result[0]); |