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
| // Just before switching jobs: | |
| // Add one of these. | |
| // Preferably into the same commit where you do a large merge. | |
| // | |
| // This started as a tweet with a joke of "C++ pro-tip: #define private public", | |
| // and then it quickly escalated into more and more evil suggestions. | |
| // I've tried to capture interesting suggestions here. | |
| // | |
| // Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_, | |
| // @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant, |
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
| public class MyApp extends Application { | |
| @Override | |
| public void onCreate() { | |
| TypefaceUtil.overrideFont(getApplicationContext(), "SERIF", "fonts/Roboto-Regular.ttf"); // font from assets: "assets/fonts/Roboto-Regular.ttf | |
| } | |
| } |
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
| <?xml version="1.0" encoding="utf-8"?> | |
| <layer-list xmlns:android="http://schemas.android.com/apk/res/android"> | |
| <item android:top="-6dp" android:left="-6dp" android:right="-6dp"> | |
| <shape> | |
| <solid android:color="#2b7996"/> | |
| <stroke android:color="#33b5e5" android:width="6dp"/> | |
| </shape> | |
| </item> | |
| </layer-list> |
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.phempto.ui.home.adapter; | |
| import android.support.v4.app.Fragment; | |
| import android.support.v4.app.FragmentManager; | |
| import android.support.v4.app.FragmentPagerAdapter; | |
| import com.phempto.ui.home.fragment.BaseFragment; | |
| import com.phempto.ui.home.fragment.HomeFragment; | |
| import com.viewpagerindicator.IconPagerAdapter; |
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
| //bytes array will be something like 0201061aff4c000215a33c91 | |
| //we need symbols on "4c00" position | |
| //for black Stick'n'find beacons: | |
| beaconManager.getBeaconParsers().add(new BeaconParser() | |
| .setBeaconLayout("m:2-3=4c00,i:4-19,i:20-21,i:22-23,p:24-24,d:25-25")); | |
| //for white beacons | |
| beaconManager.getBeaconParsers().add(new BeaconParser() | |
| .setBeaconLayout("m:2-3=0418,i:4-19,i:20-21,i:22-23,p:24-24,d:25-25")); |
NewerOlder