From: Richard Fairhurst Date: Tue, 15 Feb 2011 17:26:34 +0000 (+0000) Subject: point out forcibly to Flex that as I have closed the popup, I might like to be able... X-Git-Tag: 2.0~47 X-Git-Url: https://git.openstreetmap.org/potlatch2.git/commitdiff_plain/4228015331621625eb029c87be1b500fce9c8659 point out forcibly to Flex that as I have closed the popup, I might like to be able to click underneath where it was --- diff --git a/net/systemeD/potlatch2/TagViewer.mxml b/net/systemeD/potlatch2/TagViewer.mxml index f1fecd49..a4b35bbe 100644 --- a/net/systemeD/potlatch2/TagViewer.mxml +++ b/net/systemeD/potlatch2/TagViewer.mxml @@ -303,8 +303,12 @@ /** Set the icon, categorySelector and help text for the current entity. */ private function setCategorySelector(entity:Entity, feature:Feature):void { - // Remove the "user has selected something" event listener from previous categorySelector - if (currentCategorySelector) currentCategorySelector.removeEventListener("selectedType", changeFeatureType); + // Remove the "user has selected something" event listener from previous categorySelector, + // and make it invisible because Flex is crap at updating click areas otherwise + if (currentCategorySelector) { + currentCategorySelector.removeEventListener("selectedType", changeFeatureType); + currentCategorySelector.visible=false; + } // Have we cached the categorySelector for this limitType? If not, create one var lt:String=limitType(entity); @@ -334,7 +338,10 @@ iconText.htmlText = "No tags set
Please use the menu below to define what this "+entity.getType()+" is"; } } + + // Set it as the popup, and make sure it's visible popupChange.popUp=currentCategorySelector; + currentCategorySelector.visible=true; } private function isMultipleEditable(entities:Array):Boolean {