Skip to content

Instantly share code, notes, and snippets.

View srohde's full-sized avatar

Sönke Rohde srohde

View GitHub Profile
<swiz:BeanProvider
xmlns:swiz="http://swiz.swizframework.org"
xmlns:storage="org.swizframework.storage.*">
<storage:SharedObjectBean id="soBean" name="myName" />
</swiz:BeanProvider>
package com.soenkerohde.mobile{
import flash.display.Stage;
import flash.events.ErrorEvent;
import flash.events.Event;
import flash.events.LocationChangeEvent;
import flash.geom.Rectangle;
import flash.media.StageWebView;
import mx.core.UIComponent;
<?xml version="1.0" encoding="utf-8"?>
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark" title="Home"
xmlns:local="*">
<fx:Script>
<![CDATA[
import mx.events.FlexEvent;
protected function stageWebView_locationChangingHandler(event:LocationChangeEvent):void
<?xml version="1.0" encoding="utf-8"?>
<s:MobileApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
firstView="views.ActionBarSkinExampleHome"
skinClass="skin.ApplicationSkin">
</s:MobileApplication>
<?xml version="1.0" encoding="utf-8"?>
<s:Skin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark">
<!-- host component -->
<fx:Metadata>
[HostComponent("spark.components.MobileApplication")]
</fx:Metadata>
<s:states>
<s:State name="normal" />
@srohde
srohde / ViewNavigatorSkin.mxml
Created November 7, 2010 22:42
There is a small bug in the SlideViewTransition.as so we have to set the direction to right on creationComplete for now.
<?xml version="1.0" encoding="utf-8"?>
<s:Skin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
creationComplete="creationCompleteHandler(event)">
<!-- host component -->
<fx:Metadata>
[HostComponent("spark.components.ViewNavigator")]
</fx:Metadata>
<fx:Script>
@srohde
srohde / ActionBarSkin.mxml
Created November 7, 2010 22:45
Because of a small bug in the Flex SDK we have to define an empty Group at the 1st position for now.
<?xml version="1.0" encoding="utf-8"?>
<s:Skin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark" xmlns:fxg="skin.fxg.*">
<!-- host component -->
<fx:Metadata>
[HostComponent("spark.components.ActionBar")]
</fx:Metadata>
<s:states>
<s:State name="normal" />
<?xml version="1.0" encoding="utf-8"?>
<s:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx">
<s:Rect left="10"
right="10"
top="10"
bottom="10">
<s:fill>
<s:LinearGradient rotation="90">
<?xml version="1.0" encoding="utf-8"?>
<s:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:local="*">
<local:Background left="10" right="10" bottom="10" top="10"/>
</s:Group>
<?xml version='1.0' encoding='UTF-8'?>
<Graphic xmlns="http://ns.adobe.com/fxg/2008" version="2">
<Rect width="200" height="200">
<fill>
<LinearGradient rotation="90">
<GradientEntry color="#60a0d0" />
<GradientEntry color="#4f83aa" />
</LinearGradient>
</fill>
</Rect>