stop control characters from being entered (works properly this time. I hope)
authorRichard Fairhurst <richard@systemed.net>
Sat, 11 Dec 2010 12:12:41 +0000 (12:12 +0000)
committerRichard Fairhurst <richard@systemed.net>
Sat, 11 Dec 2010 12:12:41 +0000 (12:12 +0000)
net/systemeD/controls/AutoComplete.as
net/systemeD/potlatch2/TagGrid.mxml
net/systemeD/potlatch2/TagViewer.mxml
net/systemeD/potlatch2/mapfeatures/editors/FreeTextEditor.mxml
net/systemeD/potlatch2/save/SaveDialog.mxml

index 2d7d9dc..e164f1a 100644 (file)
@@ -81,7 +81,6 @@ package net.systemeD.controls {
                        setStyle("paddingLeft",0);
                        setStyle("paddingRight",0);
                        rowCount = 7;
-//                     restrict="\u0020-\uFFFF";
                }
                
                //--------------------------------------------------------------------------
index f8d5f4b..5c21cb6 100644 (file)
@@ -19,6 +19,7 @@
                                                dataProvider="{MapFeatures.getInstance().getAutoCompleteKeys(outerDocument.getEntityType())}" 
                                                labelField="name" 
                                                rowCount="10"
+                                               restrict="&#x0020;-&#x10FFFF;"
                                                typedText="{outerDocument.selectedItem.key}">
                                        <mx:Script><![CDATA[ import net.systemeD.potlatch2.mapfeatures.*; ]]></mx:Script>
                                        </controls:AutoComplete>
@@ -35,6 +36,7 @@
                                                dataProvider="{MapFeatures.getInstance().getAutoCompleteValues(outerDocument.getEntityType(),outerDocument.selectedItem.key)}" 
                                                labelField="name" 
                                                rowCount="10"
+                                               restrict="&#x0020;-&#x10FFFF;"
                                                typedText="{outerDocument.selectedItem.value}">
                                        <mx:Script><![CDATA[ import net.systemeD.potlatch2.mapfeatures.*; ]]></mx:Script>
                                        </controls:AutoComplete>
index 3df543e..b6ef6a5 100644 (file)
@@ -83,7 +83,7 @@
                 <mx:DataGridColumn editable="false" dataField="description" headerText="Relation"/>
                 <mx:DataGridColumn editable="false" dataField="id_idx" headerText="ID"/>
                 <mx:DataGridColumn editable="true" dataField="role" headerText="Role">
-<!--                    <mx:itemEditor><mx:Component><mx:TextInput restrict="\u0020-\uFFFF" /></mx:Component></mx:itemEditor> -->
+                    <mx:itemEditor><mx:Component><mx:TextInput restrict="&#x0020;-&#x10FFFF;" /></mx:Component></mx:itemEditor>
                 </mx:DataGridColumn>
             </mx:columns>
         </mx:DataGrid>
             <mx:DataGridColumn editable="false" dataField="type" headerText="Type"/>
             <mx:DataGridColumn editable="false" dataField="id" headerText="ID"/>
             <mx:DataGridColumn editable="true" dataField="role" headerText="Role">
-<!--                           <mx:itemEditor><mx:Component><mx:TextInput restrict="\u0020-\uFFFF" /></mx:Component></mx:itemEditor> -->
+                               <mx:itemEditor><mx:Component><mx:TextInput restrict="&#x0020;-&#x10FFFF;" /></mx:Component></mx:itemEditor>
                        </mx:DataGridColumn>
           </mx:columns>
         </mx:DataGrid>
index 91786dc..2141807 100644 (file)
@@ -8,7 +8,7 @@
     direction="{fieldDirection}" styleName="titledEditor">
 
   <mx:Label text="{fieldName}:"/>
-  <flexlib:PromptingTextInput id="inputBox" prompt="{prompt}" text="{value}" width="100%" change="value = inputBox.text"/><!-- restrict="\u0020-\uFFFF" -->
+  <flexlib:PromptingTextInput id="inputBox" prompt="{prompt}" text="{value}" width="100%" change="value = inputBox.text" restrict="&#x0020;-&#x10FFFF;" />
 
   <mx:Script><![CDATA[
   
index c29d7f3..03344bf 100644 (file)
               itemEditEnd="verifyInput(event)">
             <mx:columns>
                 <mx:DataGridColumn editable="true" dataField="k" headerText="Key">
-<!--                    <mx:itemEditor><mx:Component><mx:TextInput restrict="\u0020-\uFFFF" /></mx:Component></mx:itemEditor> -->
+                    <mx:itemEditor><mx:Component><mx:TextInput restrict="&#x0020;-&#x10FFFF;" /></mx:Component></mx:itemEditor>
                 </mx:DataGridColumn>
                 <mx:DataGridColumn editable="true" dataField="v" headerText="Value">
-<!--                    <mx:itemEditor><mx:Component><mx:TextInput restrict="\u0020-\uFFFF" /></mx:Component></mx:itemEditor> -->
+                    <mx:itemEditor><mx:Component><mx:TextInput restrict="&#x0020;-&#x10FFFF;" /></mx:Component></mx:itemEditor>
                 </mx:DataGridColumn>
             </mx:columns>
           </mx:DataGrid>