Fix lookup box sizing on subsequent opens

This commit is contained in:
Simon Kornblith 2014-04-27 20:29:22 -04:00
parent 6cf613c4fa
commit 35fe6490fe

View file

@ -225,6 +225,12 @@ const Zotero_Lookup = new function () {
//switch textboxes //switch textboxes
mlPanel.setAttribute("collapsed", !on); mlPanel.setAttribute("collapsed", !on);
slPanel.setAttribute("collapsed", !!on); slPanel.setAttribute("collapsed", !!on);
// Resize arrow box to fit content
var panel = document.getElementById("zotero-lookup-panel");
var box = panel.firstChild;
panel.sizeTo(box.scrollWidth, box.scrollHeight);
dest.focus(); dest.focus();
return dest; return dest;
} }