This file contains 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
/** | |
* Created by anthony on 6/19/14. | |
* | |
* Instansiate this class with a string (The icon name you want to convert) then call getIconTextCode() | |
* on that instantiation to return the appropriate character for that forecast IO icon, utilized in the ttf font file. | |
* | |
* Icons: http://www.alessioatzeni.com/meteocons/ | |
* Forecast IO lib: https://github.com/dvdme/forecastio-lib-java | |
* | |
* This was made assumming you are using the meteo .ttf and not the actual icons. |
This file contains 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
#!/bin/bash | |
# | |
# 1. Place this in the /android/assets/images directory | |
# 2. chmod 755 DeclareTextureRegions.sh to make it executable | |
# 3. ./DeclareTextureRegions | |
# 4. Enter the directory you wish to generate statements for e.g. (pg03) | |
# 5. A file will be created in that images folder that contains statements for those png files. | |
echo "enter the path containg the images: " | |
read path |
This file contains 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
<a class="pushbullet-subscribe-widget" data-channel="android-libs" data-widget="button" data-size="small"></a> | |
<script type="text/javascript">(function(){var a=document.createElement('script');a.type='text/javascript';a.async=true;a.src='https://widget.pushbullet.com/embed.js';var b=document.getElementsByTagName('script')[0];b.parentNode.insertBefore(a,b);})();</script> |
This file contains 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.your.package; | |
import android.content.Context; | |
import android.support.v4.widget.DrawerLayout; | |
import android.util.AttributeSet; | |
import android.view.MotionEvent; | |
public class HackyDrawerLayout extends DrawerLayout { | |
This file contains 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
dependencies { | |
compile fileTree(dir: 'libs', include: ['*.jar']) | |
compile 'com.android.support:appcompat-v7:22.2.0' | |
compile 'com.google.android.gms:play-services:7.3.0' | |
compile 'com.android.support:appcompat-v7:22.2.0' | |
compile 'com.android.support:cardview-v7:22.2.0' | |
compile 'com.android.support:recyclerview-v7:22.2.0' | |
compile 'com.android.support:design:22.2.0' |
This file contains 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"?> | |
<android.support.v7.widget.Toolbar | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
android:layout_width="match_parent" | |
android:layout_height="?attr/actionBarSize" | |
android:background="?attr/colorPrimary" | |
android:id="@+id/main_toolbar" | |
/> |
This file contains 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
#!/bin/bash | |
# This requires imagemagick (a super awesome image tool) | |
# Install via: sudo apt-get install imagemagick | |
echo "Enter the path to the 512x512 icon" | |
read icon | |
mkdir "drawable-mdpi" "drawable-hdpi" "drawable-xhdpi" "drawable-xxhdpi" "drawable-xxxhdpi" |
This file contains 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
** | |
* Depends on android design library. | |
* | |
*/ | |
import android.content.Context; | |
import android.graphics.Canvas; | |
import android.support.design.widget.TextInputLayout; | |
import android.support.v4.view.ViewCompat; | |
import android.util.AttributeSet; | |
import android.view.View; |
This file contains 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
import android.os.Bundle; | |
import android.support.v7.app.AppCompatActivity; | |
import butterknife.ButterKnife; | |
/** | |
* Created by anthony on 7/17/15. | |
*/ | |
public abstract class ButterKnifeActivity extends AppCompatActivity { |
OlderNewer