<?xml version="1.0" encoding="utf-8"?>
<mx:Module
xmlns:mx="http://www.adobe.com/2006/mxml"
xmlns:spicefactory="http://www.spicefactory.org/parsley"
width="100%" height="100%" layout="vertical"
verticalAlign="middle" horizontalAlign="center" implements="com.adobe.cairngorm.module.IParsleyModule">
<mx:Script>
<![CDATA[
import com.adobe.cairngorm.module.IParsleyModule;
import insync.messaging.MessagingContext;
import insync.messaging.presentation.ComposeMessagePM;
import org.spicefactory.parsley.core.context.Context;
[Inject]
[Bindable]
public var model:ComposeMessagePM;
public function get contextBuilder():ContextBuilderTag
{
return contextBuilderTag;
}
]]>
</mx:Script>
<spicefactory:ContextBuilder id="contextBuilderTag" config="{ MessagingContext }" />
<spicefactory:Configure/>
<mx:Label text="Compose Message to: { model.contact.fullName }" />
<mx:TextInput id="subjectInput"
text="{ model.message.subject }"
change="model.message.subject = subjectInput.text" />
<mx:TextArea id="bodyInput"
text="{ model.message.body }"
change="model.message.body = bodyInput.text" />
<mx:Button label="Send Message" click="model.sendMessage()" />
</mx:Module>