Skip to content

Instantly share code, notes, and snippets.

Avatar

Jin Changhoon susemi99

View GitHub Profile
@lnicolet
lnicolet / EndlessRecyclerViewScrollListener.kt
Created Oct 17, 2018
EndlessRecyclerViewScrollListener file for kotlin projects
View EndlessRecyclerViewScrollListener.kt
/**
* Created by Luca Nicoletti
* © 17/10/2018
* Copied from: https://gist.github.com/nesquena/d09dc68ff07e845cc622; added some little edits for Kotlin
*/
abstract class EndlessRecyclerViewScrollListener(private var visibleThreshold: Int = 5): RecyclerView.OnScrollListener() {
private var currentPage = 0
private var previousTotalItemCount = 0
private var loading = true
@jtallant
jtallant / setting-up-sinatra-with-active-record.md
Last active Oct 5, 2020
Setting up Sinatra with Active Record
View setting-up-sinatra-with-active-record.md

Setting up Sinatra Project

create an empty project and add a Gemfile

cd ~/Desktop
mkdir project-name
cd project-name
touch Gemfile
@ianbarber
ianbarber / RetrieveAccessTokenActivity.java
Created Mar 17, 2014
A quick example of retrieving an access token with GoogleAuthUtil
View RetrieveAccessTokenActivity.java
package com.google.devrel.samples.gmstest.app;
import android.app.Activity;
import android.content.Intent;
import android.os.AsyncTask;
import android.os.Bundle;
import android.util.Log;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
You can’t perform that action at this time.