I have a save button at the bottom to confirm changes and everything I enter in the textfield, the keyboard stays open and doesn't close until I click the iOS iPad close keyboard button. I am tryng to blur for the only textfield on this window when I either click on the pop-up modal white area, or click on a tablerow. It's not working and is very frustrating as something simple like this should work easily.
//This is the view that all the objects are contained in $.mainView.addEventListener('click',function(e){ $.amount.blur(); }); //this is the window itself $.ingrModal.addEventListener('click',function(e){ $.amount.blur(); }); //one table view $.perList.addEventListener('click',function(e){ $.amount.blur(); }); //the other table view $.uomList.addEventListener('click',function(e){ $.amount.blur(); });Alloy Markup
<Alloy> <Window modal="true" navBarHidden="false" title="Change the Ingredient" backgroundColor="white" modal="true" id="ingrModal"> <View id="mainView" layout="vertical"> <View top="3%" height="40" layout="horizontal"> <Label id="titleIngr" left="34%" class="LabelTitle" text="Change the Ingredient" /> <Button borderWidth="1" borderColor="black" height="35" left="18%" id="close" title="X"/> </View> <Label color="red" height="40" width="70%" top="2%" text="test" id="ingredient" /> <Label top="3%" text="Amount:" right="74%" /> <TextField keyboardType="Titanium.UI.KEYBOARD_DECIMAL_PAD" bubbleParent="false" textAlign="left" right="55%" id="amount" borderRadius="1" backgroundColor="#c1c6c1" width="158" height="40" clearButtonMode="Titanium.UI.INPUT_BUTTONMODE_ALWAYS"></TextField> <Label top="4%" text="UOM:" right="74%" /> <TableView allowsSelection="true" rowHeight="30" showVerticalScrollIndicator="true" separatorStyle="Titanium.UI.iPhone.TableViewSeparatorStyle.SINGLE_LINE" top="1%" right="30%" id="uomList" width="230" height="130"> </TableView> <!-- <TextField right="55%" id="uom" borderRadius="1" backgroundColor="#c1c6c1" width="144" height="40" clearButtonMode="Titanium.UI.INPUT_BUTTONMODE_ALWAYS"></TextField> --> <View backgroundColor="black" width="80%" height="1" /> <Label top="1%" text="Per:" right="74%" /> <TableView allowsSelection="true" rowHeight="30" showVerticalScrollIndicator="true" separatorStyle="Titanium.UI.iPhone.TableViewSeparatorStyle.SINGLE_LINE" top="1%" right="30%" id="perList" width="230" height="130"> </TableView> <Button id="saveBut" height="60" width="144" top="2%" title="Save"/> <!-- <TextField right="55%" id="per" borderRadius="1" backgroundColor="#c1c6c1" width="144" height="40" clearButtonMode="Titanium.UI.INPUT_BUTTONMODE_ALWAYS"></TextField> --> </View> </Window> </Alloy>