Skip to content

Instantly share code, notes, and snippets.

Avatar

Sebastiano Poggi rock3r

View GitHub Profile
@rock3r
rock3r / prepareassets.sh
Last active Apr 28, 2017
Move/rename *-{m|h|xh|xxh|xxxh}dpi.png" assets into proper folder structure, ready for copypasta
View prepareassets.sh
#!/bin/bash
# License for any modification to the original (linked below):
# ----------------------------------------------------------------------------
# "THE BEER-WARE LICENSE" (Revision 42):
# Sebastiano Poggi wrote this file. As long as you retain this notice you
# can do whatever you want with this stuff. If we meet some day, and you think
# this stuff is worth it, you can buy me a beer in return.
# ----------------------------------------------------------------------------
prefix=${1-"drawable"}
buckets=( mdpi hdpi xhdpi xxhdpi xxxhdpi )
@rock3r
rock3r / ColorUtils.java
Last active Feb 25, 2020
ColorUtils: utilities for manipulating colours
View ColorUtils.java
package net.frakbot.util.color;
import android.graphics.Color;
/**
* The MIT License (MIT)
* <p/>
* Copyright (c) 2014 Sebastiano Poggi
* <p/>
* Permission is hereby granted, free of charge, to any person obtaining a copy
@rock3r
rock3r / WidgetHelper.java
Last active Aug 29, 2015
How to update an homescreen widget (the right way)
View WidgetHelper.java
package net.frakbot.gists.widgethelper;
/*
* Copyright 2014 Sebastiano Poggi
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
View ArcUtils.java
/**
* ArcUtils.java
* Copyright (c) 2014 BioWink GmbH. All rights reserved.
**/
/**
* Proper Java code style formatting
* Copyright (c) 2014 Sebastiano Poggi. Do whatever you want with this code.
*/
You can’t perform that action at this time.