xmlns:edit="net.systemeD.potlatch2.mapfeatures.editors.*"
xmlns:flexlib="flexlib.controls.*"
width="100%"
- toolTip="{fieldDescription}"
+ helpContent="{fieldDescription ? help : null}"
label="{fieldName}:">
<mx:CheckBox id="inputBox" creationComplete="initCheckbox()"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:edit="net.systemeD.potlatch2.mapfeatures.editors.*"
- toolTip="{fieldDescription}"
+ helpContent="{fieldDescription ? help : null}"
label="{fieldName}:"
styleName="titledEditor">
xmlns:flexlib="flexlib.controls.*"
xmlns:controls="net.systemeD.controls.*"
width="100%"
- toolTip="{fieldDescription}"
+ helpContent="{fieldDescription ? help : null}"
styleName="titledEditor" label="{fieldName}:">
<controls:PromptingTextInputWarning id="inputBox" prompt="{prompt}" text="{value}" width="100%"
focusOut="value = inputBox.text" enter="value = inputBox.text; focusManager.getNextFocusManagerComponent().setFocus();"
restrict=" -" />
+
<fx:Script><![CDATA[
[Bindable(event="factory_set")]
protected function get prompt():String {
xmlns:edit="net.systemeD.potlatch2.mapfeatures.editors.*"
xmlns:flexlib="flexlib.controls.*"
width="100%"
- toolTip="{fieldDescription}"
+ helpContent="{fieldDescription ? help : null}"
label="{fieldName}:"
styleName="titledEditor">
dispatchEvent(new Event("tag_changed"));
}
+ [Embed(source="../../../../../embedded/help.png")] private var infoIcon:Class;
+
+ import spark.components.*;
+ import mx.managers.ToolTipManager;
+ import mx.controls.ToolTip;
+ import mx.core.IUIComponent;
+ import flash.geom.Point;
+ private var _tip:ToolTip;
+
+ [Bindable(event="factory_set")]
+ protected function get help():Image {
+ var image:Image = new Image();
+ image.source = infoIcon;
+ image.width = 16;
+ image.height = 16;
+ image.addEventListener("mouseOver",showHelpBalloon,false,0,true);
+ image.addEventListener("mouseOut" ,hideHelpBalloon,false,0,true);
+ return image;
+ }
+
+ private function showHelpBalloon(e:Event):void {
+ var point:Point=e.target.contentToGlobal(new Point(-8,16));
+ _tip=ToolTipManager.createToolTip(fieldDescription,point.x,point.y,"errorTipBelow",IUIComponent(e.target)) as ToolTip;
+ }
+ private function hideHelpBalloon(e:Event):void {
+ ToolTipManager.destroyToolTip(_tip);
+ }
+
}
}
xmlns:edit="net.systemeD.potlatch2.mapfeatures.editors.*"
xmlns:flexlib="flexlib.controls.*"
width="100%"
- toolTip="{fieldDescription}"
+ helpContent="{fieldDescription ? help : null}"
label="{fieldName}:"
styleName="titledEditor">
xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:edit="net.systemeD.potlatch2.mapfeatures.editors.*"
- toolTip="{fieldDescription}"
+ helpContent="{fieldDescription ? help : null}"
label="{fieldName}:"
styleName="titledEditor">
bottom="row1:0" baseline="row1:0"/>
<!--- @copy spark.components.FormItem#labelDisplay -->
<s:Label id="labelDisplay"
- fontWeight="bold"
+ maxWidth="75"
left="labelCol:0" right="labelCol:5"
bottom="row1:0" baseline="row1:0"/>
<!--- @copy spark.components.SkinnableContainer#contentGroup -->
closedIcon: Embed(source="../embedded/CollapsiblePanelAssets.swf", symbol="CollapseButtonOver");
}
+/* Tag tooltips */
+
+.errorTip {
+ borderColor: #2929CE;
+}
+
/* Toolbox */
.theToolBox {