Skip to content

Instantly share code, notes, and snippets.

View asamoylenko's full-sized avatar

Aleksey Samoylenko asamoylenko

View GitHub Profile
@PareshMayani
PareshMayani / ic_password_visibility.xml
Last active January 9, 2020 07:49
Android Support library 24.2.0 - passwordToggleDrawable example
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24.0"
android:viewportWidth="24.0">
<path
android:fillColor="#FF000000"
android:pathData="M12,4.5C7,4.5 2.73,7.61 1,12c1.73,4.39 6,7.5 11,7.5s9.27,-3.11 11,-7.5c-1.73,-4.39 -6,-7.5 -11,-7.5zM12,17c-2.76,0 -5,-2.24 -5,-5s2.24,-5 5,-5 5,2.24 5,5 -2.24,5 -5,5zm0,-8c-1.66,0 -3,1.34 -3,3s1.34,3 3,3 3,-1.34 3,-3 -1.34,-3 -3,-3z" />
</vector>
@polbins
polbins / README.md
Last active September 6, 2019 11:08
Android Response Caching using Retrofit 1.9 + OkHttp 2.2

Android REST Controller with Cache-Control

Android REST Controller with Simple Cache Control Headers using Retrofit 1.9.0 + OkHttp 2.2.0

@ArtSabintsev
ArtSabintsev / viewFromBarButtonItem.m
Last active August 31, 2018 16:55
Accessing default view from a UIBarButtonItem
/*
UIBarButtonItem does not subclass UIView.
However, there is a way to access the UIBarButtonItem's default view without breaching
Apple's 'Do not use private APIs' rule.
That's because said view responds to KVO, such as changing the tint-color.
*/
/*
After setting your UIBarButton item inside the UINavigationBar object or UIToolBar object,
access your view in the following fashion: