Skip to content

Instantly share code, notes, and snippets.


Marc-André Appel marcandreappel

View GitHub Profile
bolot / PeekingLinearLayoutManager.kt
Last active Jul 8, 2020
LinearLayoutManager subclass that "peeks", shows a portion of the adjacent child views.
View PeekingLinearLayoutManager.kt
class PeekingLinearLayoutManager : LinearLayoutManager {
constructor(context: Context?, @RecyclerView.Orientation orientation: Int = RecyclerView.VERTICAL, reverseLayout: Boolean = false) : super(context, orientation, reverseLayout)
constructor(context: Context, attrs: AttributeSet, defStyleAttr: Int, defStyleRes: Int) : super(context, attrs, defStyleAttr, defStyleRes)
override fun generateDefaultLayoutParams() =
remy / hmr-index.js
Created Jun 1, 2017
A take on HMR. I don't remember exactly where it came from, but it works for me.
View hmr-index.js
import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import store from './store';
const rootEl = document.getElementById('root');
// Create a reusable render method that we can call more than once
let render = () => {
// Dynamically import our main App component, and render it
ccjeng /
Last active May 18, 2020
Custom InfoWindow Layout for Google Map in Android
public class CustomInfoWindowAdapter implements GoogleMap.InfoWindowAdapter {
private Activity context;
public CustomInfoWindowAdapter(Activity context){
this.context = context;
View iOS.8.3.txt
UIFont: family Thonburi
UIFont: font Thonburi-Bold
UIFont: font Thonburi
UIFont: font Thonburi-Light
UIFont: family Khmer Sangam MN
UIFont: font KhmerSangamMN
UIFont: family Snell Roundhand
UIFont: font SnellRoundhand-Black
UIFont: font SnellRoundhand-Bold
UIFont: font SnellRoundhand
beanmoss / RestControllerTrait.php
Created Apr 18, 2015
Playing with Laravel Lumen: simple RESTful trait.
View RestControllerTrait.php
<?php namespace App\Http\Controllers;
use Illuminate\Http\Request;
trait RestControllerTrait
public function index()
$m = self::MODEL;
return $this->listResponse($m::all());
huglester / gist:3860656
Created Oct 9, 2012
FuelPHP PHPStorm helper class
View gist:3860656
class Agent extends Fuel\Core\Agent {}
class Arr extends Fuel\Core\Arr {}
class Asset extends Fuel\Core\Asset {}
class Cache extends Fuel\Core\Cache {}
class CacheNotFoundException extends Fuel\Core\CacheNotFoundException {}
class CacheExpiredException extends Fuel\Core\CacheExpiredException {}
class Cli extends Fuel\Core\Cli {}
class Config extends Fuel\Core\Config {}
uriel1998 / volume.rb
Created Feb 10, 2012 — forked from jaspervdj/volume.rb
Set PulseAudio volume, mute, unmute, and change default sink (and automagically switch running audio streams) from the commandline
View volume.rb
# Moved to:
# This work is licensed under the Creative Commons Attribution-ShareAlike 3.0
# Unported License. To view a copy of this license, visit
# Forked/derived from original by Jasper Van der Jeugt (jaspervdj);
marcandreappel / states_provinces.php
Created Aug 29, 2011
Concrete5 - Liste des départements de la France dans : helpers / lists / states_provinces.php, il faut remplacer le fichier (ou son contenu) par le fichier ci-dessous
View states_provinces.php
* @package Helpers
* @category Concrete
* @author Andrew Embler <>
* @copyright Copyright (c) 2003-2008 Concrete5. (
* @license MIT License
You can’t perform that action at this time.