I am unable to select the text inside the textfield in my Firefox extension. The cursor just stays in the beginning of the textfield and does not move when I click and drag the mouse. However, I am able to select the text using the shift and arrow keys on the keyboard.
I am loading an html page that contains 2 textfields and 2 buttons in an iFrame within a XUL panel.
The code I am using is provided below:
//popup.xul
<?xml version="1.0" encoding="UTF-8"?>
<panel id="ext-popup" title="My Extension" orient="vertical" autostretch="always"
buttons=","
defaultButton=","
shadow="true"
style="padding: 0px; margin: 0px; height: 32px; -moz-window-shadow : sheet"
onload="init();"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<script src="chrome://myext/content/popup.js"/>
<iframe src="chrome://myext/content/popup.html" type="content"
style="background-color: white; -moz-window-shadow : default; width: 490px; height: 260px;overflow: hidden;"
id="popupContent"/>
</panel>
Is there any option that need to set to allow selection in the textfield?
<panel>
as the root tag of a dialog? What if you change that into<window>
? – Wladimir Palant