mirror of
https://github.com/MapMakersAndProgrammers/alternativa-editor-mod.git
synced 2025-10-26 17:59:07 -07:00
editor seems to almost working
This commit is contained in:
48
src/ErrorWindow.mxml
Normal file
48
src/ErrorWindow.mxml
Normal file
@@ -0,0 +1,48 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<local:ResizableTitleWindowX 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="*"
|
||||
width="400" title="Error Window"
|
||||
close="close();">
|
||||
|
||||
<fx:Script>
|
||||
<![CDATA[
|
||||
import mx.events.CloseEvent;
|
||||
import mx.managers.PopUpManager;
|
||||
import flash.events.MouseEvent;
|
||||
]]>
|
||||
</fx:Script>
|
||||
|
||||
<!-- Define the layout using MXML -->
|
||||
<s:VGroup percentWidth="100" percentHeight="100" paddingTop="5" paddingLeft="5" paddingBottom="5" paddingRight="5">
|
||||
<!-- Message Label -->
|
||||
<s:Label id="message" />
|
||||
|
||||
<!-- Scroller for text area -->
|
||||
<s:Scroller percentWidth="100" percentHeight="100">
|
||||
<s:Group percentWidth="100">
|
||||
<s:TextArea id="text" percentWidth="100" percentHeight="100" />
|
||||
</s:Group>
|
||||
</s:Scroller>
|
||||
|
||||
<!-- OK Button -->
|
||||
<s:Button id="ok" label="Okay" click="ok_click();" />
|
||||
</s:VGroup>
|
||||
|
||||
<!-- Script for event handling -->
|
||||
<fx:Script>
|
||||
<![CDATA[
|
||||
// Close event handler
|
||||
public function close():void {
|
||||
PopUpManager.removePopUp(this);
|
||||
}
|
||||
|
||||
// OK button click handler
|
||||
public function ok_click():void {
|
||||
this.dispatchEvent(new CloseEvent(CloseEvent.CLOSE));
|
||||
}
|
||||
]]>
|
||||
</fx:Script>
|
||||
|
||||
</local:ResizableTitleWindowX>
|
||||
Reference in New Issue
Block a user