diff --git a/application/ui.extkeywidget.class.inc.php b/application/ui.extkeywidget.class.inc.php
index d61e42308..c5dac3ae5 100644
--- a/application/ui.extkeywidget.class.inc.php
+++ b/application/ui.extkeywidget.class.inc.php
@@ -253,11 +253,11 @@ EOF
$sDisplayValue = $this->GetObjectName($value);
}
$iMinChars = isset($aArgs['iMinChars']) ? $aArgs['iMinChars'] : 3; //@@@ $this->oAttDef->GetMinAutoCompleteChars();
- $iFieldSize = isset($aArgs['iFieldSize']) ? $aArgs['iFieldSize'] : 30; //@@@ $this->oAttDef->GetMaxSize();
+ $iFieldSize = isset($aArgs['iFieldSize']) ? $aArgs['iFieldSize'] : 20; //@@@ $this->oAttDef->GetMaxSize();
// the input for the auto-complete
$sHTMLValue = "Count()."\" type=\"text\" id=\"label_$this->iId\" size=\"$iFieldSize\" value=\"$sDisplayValue\"/> ";
- $sHTMLValue .= "iId}\" style=\"border:0;vertical-align:middle;cursor:pointer;\" src=\"../images/mini_search.gif\" onClick=\"oACWidget_{$this->iId}.Search();\"/> ";
+ $sHTMLValue .= "
iId}\" style=\"border:0;vertical-align:middle;cursor:pointer;\" src=\"../images/mini_search.gif\" onClick=\"oACWidget_{$this->iId}.Search();\"/>";
// another hidden input to store & pass the object's Id
$sHTMLValue .= "iId\" name=\"{$sAttrFieldPrefix}{$sFieldName}\" value=\"".htmlentities($value, ENT_QUOTES, 'UTF-8')."\" />\n";
diff --git a/css/jquery.autocomplete.css b/css/jquery.autocomplete.css
index 4e6b634f1..f089a2ade 100644
--- a/css/jquery.autocomplete.css
+++ b/css/jquery.autocomplete.css
@@ -17,6 +17,8 @@
.ac_results li {
margin: 0px;
padding: 2px 5px;
+ white-space: nowrap;
+ padding-right: 20px; /* Space for the scrollbar */
cursor: default;
display: block;
/*
diff --git a/js/jquery.autocomplete.js b/js/jquery.autocomplete.js
index 0b9fc7027..a38d71be9 100644
--- a/js/jquery.autocomplete.js
+++ b/js/jquery.autocomplete.js
@@ -671,7 +671,7 @@ $.Autocompleter.Select = function (options, input, select, config) {
continue;
// Escape dangerous characters to prevent XSS vulnerabilities
formatted = formatted.replace('&', '&').replace('"', '"').replace('>', '>').replace('<', '<');
- var li = $("