Skip to content

Instantly share code, notes, and snippets.

View netoleal's full-sized avatar

Neto Leal netoleal

View GitHub Profile
[
{
"title": "Net promoters score",
"legend": "how likely would you recommend Electrolux to a friend?",
"score": 0,
"target": 100,
"min": -100,
"max": 100,
"chart": "https://next.json-generator.com/api/json/get/VJAO0PC28"
},
@netoleal
netoleal / UIImage+Tint.h
Created August 5, 2014 20:56
UIImage+Tint
#import <UIKit/UIKit.h>
@interface UIImage (Tint)
- (UIImage *)tintedImageUsingColor:(UIColor *)tintColor;
@end
@netoleal
netoleal / FacebookApplicationExample.as
Created November 28, 2011 21:01
Exemplo FacebookApplication
package
{
import com.netoleal.facebook.app.FacebookApplication;
import com.netoleal.facebook.model.FacebookFriendModel;
public class FacebookApplicationExample
{
private var fb:FacebookApplication;
public function FacebookApplicationExample( )
@netoleal
netoleal / flow_example.as
Created November 22, 2011 21:27
Exemplo de uso de Flow
import asf.events.FlowEvent;
import asf.flow.LoadShowFlow;
import asf.interfaces.ISequence;
flow = new LoadShowFlow( app.navigation, true );
flow.addEventListener( FlowEvent.SHOW_LOADING, onFlowShowLoading );
flow.addEventListener( FlowEvent.HIDE_LOADING, onFlowHideLoading );
flow.addEventListener( DependenciesProgressEvent.LOAD_PROGRESS, onSectionLoadProgress );
@netoleal
netoleal / broadcaster.as
Created October 4, 2011 18:46
Exemplo CommandsDispatcher
import asf.core.commands.CommandsDispatcher;
CommandsDispatcher.broadcastCommand( "someEvent" );
CommandsDispatcher.broadcastCommand( "otherEvent", "some param to pass" );
@netoleal
netoleal / ScaleProperty.as
Created August 30, 2011 10:44
SimpleTweenSpecialProperties
/*
Exemplo de criação de propriedade personalizada.
Exemplo de uso:
SimpleTween.registerSpecialProperty( "scale", new ScaleProperty( ) );
SimpleTween.create( ).make( foolMC, { scale: 1.5 }, 666, easeOutCirc );
*/
@netoleal
netoleal / chance.as
Created August 16, 2011 19:09
Chance function
private function chance( value:Number ):Boolean
{
return Math.random( ) < value;
}