Bug 1539295 - fix tab after auto-complete in mailing list add/edit. r=aceman a=jorgk
authorJorg K <jorgk@jorgk.com>
Wed, 27 Mar 2019 23:34:08 +0100
changeset 33970 e4751d2e281f
parent 33969 922f9c9d7024
child 33971 1599c84ad552
push id2394
push usermozilla@jorgk.com
push dateSat, 30 Mar 2019 21:10:54 +0000
treeherdercomm-beta@a07bc5354c40 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaceman, jorgk
bugs1539295
Bug 1539295 - fix tab after auto-complete in mailing list add/edit. r=aceman a=jorgk
mail/components/addrbook/content/abEditListDialog.xul
mail/components/addrbook/content/abMailListDialog.xul
suite/mailnews/components/addrbook/content/abListOverlay.xul
--- a/mail/components/addrbook/content/abEditListDialog.xul
+++ b/mail/components/addrbook/content/abEditListDialog.xul
@@ -58,17 +58,17 @@
         <hbox class="addressingWidgetCell" flex="1">
           <textbox id="addressCol1#1" class="plain textbox-addressingWidget uri-element"
                    type="autocomplete" flex="1"
                    autocompletesearch="addrbook ldap"
                    autocompletesearchparam="{}" timeout="300" maxrows="4"
                    completedefaultindex="true" forcecomplete="true"
                    completeselectedindex="true"
                    minresultsforpopup="3"
-                   ontextentered="awRecipientTextCommand(param, this); if (this.value != '') event.preventDefault();"
+                   ontextentered="awRecipientTextCommand(param, this); if (param &amp;&amp; this.value != '') param.preventDefault();"
                    onkeydown="awRecipientKeyDown(event, this);"
                    onclick="awNotAnEmptyArea(event);">
             <image onclick="this.parentNode.select();" class="person-icon"/>
           </textbox>
         </hbox>
       </richlistitem>
     </richlistbox>
   </vbox>
--- a/mail/components/addrbook/content/abMailListDialog.xul
+++ b/mail/components/addrbook/content/abMailListDialog.xul
@@ -69,17 +69,17 @@
         <hbox class="addressingWidgetCell" flex="1">
           <textbox id="addressCol1#1" class="plain textbox-addressingWidget uri-element"
                    type="autocomplete" flex="1"
                    autocompletesearch="addrbook ldap"
                    autocompletesearchparam="{}" timeout="300" maxrows="4"
                    completedefaultindex="true" forcecomplete="true"
                    completeselectedindex="true"
                    minresultsforpopup="3"
-                   ontextentered="awRecipientTextCommand(param, this); if (this.value != '') event.preventDefault();"
+                   ontextentered="awRecipientTextCommand(param, this); if (param &amp;&amp; this.value != '') param.preventDefault();"
                    onkeydown="awRecipientKeyDown(event, this);"
                    onclick="awNotAnEmptyArea(event);">
             <image onclick="this.parentNode.select();" class="person-icon"/>
           </textbox>
         </hbox>
       </richlistitem>
     </richlistbox>
   </vbox>
--- a/suite/mailnews/components/addrbook/content/abListOverlay.xul
+++ b/suite/mailnews/components/addrbook/content/abListOverlay.xul
@@ -66,17 +66,17 @@
         <textbox id="addressCol1#1"
                  class="plain textbox-addressingWidget uri-element"
                  type="autocomplete"
                  flex="1"
                  autocompletesearch="addrbook ldap"
                  autocompletesearchparam="{}" timeout="300" maxrows="4"
                  completedefaultindex="true" forcecomplete="true"
                  minresultsforpopup="3"
-                 ontextentered="awRecipientTextCommand(param, this); if (this.value != '') event.preventDefault();"
+                 ontextentered="awRecipientTextCommand(eventParam, this)"
                  onkeydown="awRecipientKeyDown(event, this);"
                  onclick="awNotAnEmptyArea(event);">
           <image onclick="awNotAnEmptyArea(event)" class="person-icon"/>
         </textbox>
       </listcell>
     </listitem>
   </listbox>
 </vbox>