Skip to content

Instantly share code, notes, and snippets.

View pierot's full-sized avatar
🏠
Working from home

Pieter Michels pierot

🏠
Working from home
View GitHub Profile
import be.wellconsidered.social.facebook.events.FacebookBridgeEvent;
import be.wellconsidered.social.facebook.FacebookBridge;
private function init():void {
FacebookBridge.getInstance().addEventListener(FacebookBridgeEvent.RESULT, onFBResult, false, 0, true);
FacebookBridge.getInstance().init();
}
private function onFBResult(e:FacebookBridgeEvent):void {
trace("Response of " + e.func);
package be.proximity.freemind.ui
{
import flash.text.Font;
public class FreemindBold extends Font
{
public function FreemindBold() {
super();
}
var st:StyleSheet = new StyleSheet();
st.setStyle(".strong", {fontFamily: new FreemindBold().fontName});
txt.embedFonts = true;
txt.styleSheet = st;
<key id="intro_txt"><![CDATA[<span class="strong">Teken in voordat uw wagen 1 jaar oud wordt en krijg uw 1ste onderhoud volledig terugbetaald.</span>]]></key>
import be.proximity.sociallayer.SocialLayer;
import be.proximity.sociallayer.events.SocialLayerEvent;
import be.proximity.sociallayer.platform.FacebookConnectPlatform;
var sl:SocialLayer = new SocialLayer(this.stage.loaderInfo);
sl.addEventListener(SocialLayerEvent.READY, onSocialReady, false, 0, true);
sl.init("7936555f01bb73002d1a76cc209410cf", "876c40aab2eee21fb3b762e147f2750f");
private function onSocialReady(e:SocialLayerEvent):void {
trace("OnSocialReady Type: " + sl.platformType);
}
public const PLATFORM_NETLOG:String = "netlog";
public const PLATFORM_NETLOG_GAME:String = "netlog_game";
public const PLATFORM_FB:String = "facebook";
public const PLATFORM_FB_CONNECT:String = "facebook_connect";
(sl.platform as FacebookConnectPlatform).login();
if(sl.platformType == sl.PLATFORM_FB_CONNECT && !(sl.platform as FacebookConnectPlatform).logged_in) {
// Do login
}
(sl.platform as FacebookConnectPlatform).askPermissions([
FacebookConnectPlatform.PERM_EMAIL,
FacebookConnectPlatform.PERM_STREAM_PUBLISH,
FacebookConnectPlatform.PERM_STREAM_READ,
FacebookConnectPlatform.PERM_OFFLINE_ACCESS]);