-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master'
- Loading branch information
Showing
9 changed files
with
155 additions
and
13 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,9 @@ | |||
package com.kdata.mobile.presentation | |||
{ | |||
import mx.collections.ArrayCollection; | |||
|
|||
public class Documents | |||
{ | |||
[Bindable] public var documents : ArrayCollection; | |||
} | |||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
src/com/kdata/mobile/presentation/MobileActionMongoHome.mxml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,33 @@ | |||
<?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="MobileActionMongoHome" xmlns:parsley="http://www.spicefactory.org/parsley"> | |||
<fx:Declarations> | |||
<parsley:Configure /> | |||
</fx:Declarations> | |||
|
|||
<fx:Script> | |||
<![CDATA[ | |||
import com.kdata.mobile.application.MongoHandler; | |||
import com.kdata.mobile.application.MongoQueryEvent; | |||
import mx.collections.ArrayCollection; | |||
[MessageDispatcher] public var dispatchMessage : Function; | |||
[Inject] [Bindable] public var model :Documents; | |||
public function test() : void { | |||
// query to MongoDB | |||
dispatchMessage( MongoQueryEvent.getMongoSendQuery()); | |||
} | |||
]]> | |||
</fx:Script> | |||
|
|||
<s:navigationContent> | |||
<s:Button icon="@Embed('assets/back.png')" click="dispatchMessage(MongoQueryEvent.getMongoDisconnect()); navigator.popView()"/> | |||
</s:navigationContent> | |||
|
|||
<s:Label left="10" top="10" text="login ok"/> | |||
<s:Button id="btnTest" left="10" top="30" label="Test" click="test()"/> | |||
<s:DataGrid top="80" width="100%" height="100%" dataProvider="{model.documents}" /> | |||
</s:View> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,45 @@ | |||
<?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" width="200" height="150"> | |||
<fx:Declarations> | |||
<!-- Place non-visual elements (e.g., services, value objects) here --> | |||
</fx:Declarations> | |||
<fx:Script> | |||
<![CDATA[ | |||
import mx.core.FlexGlobals; | |||
import mx.managers.PopUpManager; | |||
[Bindable] | |||
private var data:Object = new Object(); | |||
public function show(data:Object):void | |||
{ | |||
this.data=data; | |||
PopUpManager.addPopUp(this,FlexGlobals.topLevelApplication.navigator.activeView); | |||
PopUpManager.centerPopUp(this); | |||
} | |||
protected function close():void | |||
{ | |||
PopUpManager.removePopUp(this); | |||
} | |||
]]> | |||
</fx:Script> | |||
<s:BorderContainer width="100%" height="100%" backgroundColor="0x333333" borderColor="#949494" | |||
borderWeight="4" cornerRadius="10"> | |||
<s:VGroup left="10" right="10" top="10" bottom="10" width="100%" height="100%" gap="5"> | |||
<s:Label width="100%" color="white" fontSize="32" fontWeight="bold" lineThrough="false" | |||
paddingTop="12" text="{data.title}" left="5"/> | |||
<s:Line width="100%"> | |||
<s:stroke> | |||
<s:SolidColorStroke color="0x5b5b5b" weight="2"/> | |||
</s:stroke> | |||
</s:Line> | |||
<s:Label width="100%" color="white" text="{data.text}" left="5"/> | |||
</s:VGroup> | |||
<s:Button x="0" y="0" height="34" label="Close" click="close()" bottom="5" right="5"/> | |||
</s:BorderContainer> | |||
</s:Group> |