Skip to content

Instantly share code, notes, and snippets.

chris95x8 / build.gradle
Created Oct 28, 2014
Extended toolbar with two floating-label edit texts. The layout was made according to this image from the Material Design guidelines: The layout below looks like this:
View build.gradle
dependencies {
compile ''
compile 'com.wrapp.floatlabelededittext:library:0.0.5'
JakeWharton /
Created Jun 2, 2012
ImageView that respects an aspect ratio applied to a specific measurement.
// Copyright 2012 Square, Inc.
package com.squareup.widgets;
import android.content.Context;
import android.content.res.TypedArray;
import android.util.AttributeSet;
import android.widget.ImageView;
/** Maintains an aspect ratio based on either width or height. Disabled by default. */
public class AspectRatioImageView extends ImageView {