Bug 1597964 - Restructure all <xul:dialog> usages such that they are not the top level element in chat/. r=mkmelin
This commit is contained in:
Родитель
1cfb4acfcf
Коммит
f1aa0b1c4e
|
@ -70,7 +70,7 @@ var otrAddFinger = {
|
||||||
this.fingerError.hidden = true;
|
this.fingerError.hidden = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
document.documentElement.getButton("accept").disabled =
|
document.getElementById("otrAddFingerDialog").getButton("accept").disabled =
|
||||||
input.value && !input.validity.valid;
|
input.value && !input.validity.valid;
|
||||||
|
|
||||||
this.keyCount.value = `${hex.length}/40`;
|
this.keyCount.value = `${hex.length}/40`;
|
||||||
|
|
|
@ -6,59 +6,60 @@
|
||||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
|
<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
|
||||||
<?xml-stylesheet href="chrome://chat/skin/otrFingerprintDialog.css" type="text/css"?>
|
<?xml-stylesheet href="chrome://chat/skin/otrFingerprintDialog.css" type="text/css"?>
|
||||||
|
|
||||||
<!DOCTYPE dialog>
|
<!DOCTYPE window>
|
||||||
|
|
||||||
<dialog id="otrAddFingerDialog"
|
<window data-l10n-id="otr-add-finger"
|
||||||
data-l10n-id="otr-add-finger"
|
|
||||||
windowtype="OTR:AddFinger"
|
windowtype="OTR:AddFinger"
|
||||||
onload="otrAddFinger.onload()"
|
onload="otrAddFinger.onload()"
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||||
xmlns:html="http://www.w3.org/1999/xhtml"
|
xmlns:html="http://www.w3.org/1999/xhtml">
|
||||||
buttons="accept,cancel"
|
<dialog id="otrAddFingerDialog"
|
||||||
buttondisabledaccept="true">
|
buttons="accept,cancel"
|
||||||
|
buttondisabledaccept="true">
|
||||||
|
|
||||||
<keyset id="mailKeys">
|
<keyset id="mailKeys">
|
||||||
<key keycode="VK_ESCAPE" oncommand="window.close();"/>
|
<key keycode="VK_ESCAPE" oncommand="window.close();"/>
|
||||||
</keyset>
|
</keyset>
|
||||||
|
|
||||||
<linkset>
|
<linkset>
|
||||||
<html:link rel="localization" href="messenger/otr/add-finger.ftl"/>
|
<html:link rel="localization" href="messenger/otr/add-finger.ftl"/>
|
||||||
</linkset>
|
</linkset>
|
||||||
|
|
||||||
<script src="chrome://chat/content/otr-add-fingerprint.js"/>
|
<script src="chrome://chat/content/otr-add-fingerprint.js"/>
|
||||||
<script src="chrome://global/content/globalOverlay.js"/>
|
<script src="chrome://global/content/globalOverlay.js"/>
|
||||||
<script src="chrome://global/content/editMenuOverlay.js"/>
|
<script src="chrome://global/content/editMenuOverlay.js"/>
|
||||||
<vbox class="dialog-container" flex="1">
|
<vbox class="dialog-container" flex="1">
|
||||||
<hbox align="center" pack="center" class="header-container">
|
<hbox align="center" pack="center" class="header-container">
|
||||||
<vbox>
|
<vbox>
|
||||||
<image class="header-icon icon-login"/>
|
<image class="header-icon icon-login"/>
|
||||||
</vbox>
|
</vbox>
|
||||||
<vbox flex="1">
|
<vbox flex="1">
|
||||||
<description id="otrDescription"/>
|
<description id="otrDescription"/>
|
||||||
</vbox>
|
</vbox>
|
||||||
</hbox>
|
|
||||||
<hbox class="form-control" align="center">
|
|
||||||
<label data-l10n-id="otr-add-finger-fingerprint"
|
|
||||||
class="label-box"
|
|
||||||
control="fingerprint"/>
|
|
||||||
<hbox class="input-control" align="center" flex="1">
|
|
||||||
<html:input id="fingerprint" type="text"
|
|
||||||
data-l10n-id="otr-add-finger-input"
|
|
||||||
class="input-field"
|
|
||||||
oninput="otrAddFinger.oninput(this);"
|
|
||||||
onblur="otrAddFinger.onblur(this);"
|
|
||||||
pattern="[ 0-9a-fA-F]*"
|
|
||||||
minlength="44"
|
|
||||||
maxlength="44"/>
|
|
||||||
</hbox>
|
</hbox>
|
||||||
<image id="fingerWarning" class="form-icon icon-warning" hidden="true"/>
|
<hbox class="form-control" align="center">
|
||||||
</hbox>
|
<label data-l10n-id="otr-add-finger-fingerprint"
|
||||||
<vbox class="input-helper-container" flex="1" align="end">
|
class="label-box"
|
||||||
<label id="fingerError"
|
control="fingerprint"/>
|
||||||
data-l10n-id="otr-add-finger-tooltip-error"
|
<hbox class="input-control" align="center" flex="1">
|
||||||
class="msg-error"
|
<html:input id="fingerprint" type="text"
|
||||||
hidden="true"/>
|
data-l10n-id="otr-add-finger-input"
|
||||||
<label id="keyCount" class="input-helper" value="0/40"/>
|
class="input-field"
|
||||||
|
oninput="otrAddFinger.oninput(this);"
|
||||||
|
onblur="otrAddFinger.onblur(this);"
|
||||||
|
pattern="[ 0-9a-fA-F]*"
|
||||||
|
minlength="44"
|
||||||
|
maxlength="44"/>
|
||||||
|
</hbox>
|
||||||
|
<image id="fingerWarning" class="form-icon icon-warning" hidden="true"/>
|
||||||
|
</hbox>
|
||||||
|
<vbox class="input-helper-container" flex="1" align="end">
|
||||||
|
<label id="fingerError"
|
||||||
|
data-l10n-id="otr-add-finger-tooltip-error"
|
||||||
|
class="msg-error"
|
||||||
|
hidden="true"/>
|
||||||
|
<label id="keyCount" class="input-helper" value="0/40"/>
|
||||||
|
</vbox>
|
||||||
</vbox>
|
</vbox>
|
||||||
</vbox>
|
</dialog>
|
||||||
</dialog>
|
</window>
|
||||||
|
|
|
@ -173,7 +173,9 @@ var otrAuth = {
|
||||||
},
|
},
|
||||||
|
|
||||||
oninput(e) {
|
oninput(e) {
|
||||||
document.documentElement.getButton("accept").disabled = !e.value;
|
document
|
||||||
|
.getElementById("otrAuthDialog")
|
||||||
|
.getButton("accept").disabled = !e.value;
|
||||||
},
|
},
|
||||||
|
|
||||||
how() {
|
how() {
|
||||||
|
|
|
@ -6,89 +6,89 @@
|
||||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
|
<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
|
||||||
<?xml-stylesheet type="text/css" href="chrome://messenger/skin/input-fields.css"?>
|
<?xml-stylesheet type="text/css" href="chrome://messenger/skin/input-fields.css"?>
|
||||||
|
|
||||||
<!DOCTYPE dialog>
|
<!DOCTYPE winodw>
|
||||||
<dialog
|
<window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
xmlns:html="http://www.w3.org/1999/xhtml"
|
||||||
xmlns:html="http://www.w3.org/1999/xhtml"
|
data-l10n-id="otr-auth"
|
||||||
id="otrAuthDialog"
|
data-l10n-attrs="buttonlabelaccept"
|
||||||
data-l10n-id="otr-auth"
|
windowtype="OTR:Auth"
|
||||||
data-l10n-attrs="buttonlabelaccept"
|
onload="otrAuth.onload()">
|
||||||
windowtype="OTR:Auth"
|
|
||||||
onload="otrAuth.onload()"
|
|
||||||
buttons="accept,cancel,help"
|
|
||||||
buttondisabledaccept="true">
|
|
||||||
|
|
||||||
<linkset>
|
<dialog id="otrAuthDialog"
|
||||||
<html:link rel="localization" href="messenger/otr/auth.ftl"/>
|
buttons="accept,cancel,help"
|
||||||
</linkset>
|
buttondisabledaccept="true">
|
||||||
|
|
||||||
<script src="chrome://global/content/globalOverlay.js"/>
|
<linkset>
|
||||||
<script src="chrome://global/content/editMenuOverlay.js"/>
|
<html:link rel="localization" href="messenger/otr/auth.ftl"/>
|
||||||
<script src="chrome://chat/content/otr-auth.js"/>
|
</linkset>
|
||||||
|
|
||||||
<groupbox id="how" hidden="true">
|
<script src="chrome://global/content/globalOverlay.js"/>
|
||||||
<label><html:h4 data-l10n-id="auth-how"/></label>
|
<script src="chrome://global/content/editMenuOverlay.js"/>
|
||||||
<menulist id="howOption" oncommand="otrAuth.how();">
|
<script src="chrome://chat/content/otr-auth.js"/>
|
||||||
<menupopup>
|
|
||||||
<menuitem data-l10n-id="auth-questionAndAnswer-label" value="questionAndAnswer"/>
|
|
||||||
<menuitem data-l10n-id="auth-sharedSecret-label" value="sharedSecret"/>
|
|
||||||
<menuitem data-l10n-id="auth-manualVerification-label" value="manualVerification"/>
|
|
||||||
</menupopup>
|
|
||||||
</menulist>
|
|
||||||
</groupbox>
|
|
||||||
|
|
||||||
<groupbox id="questionAndAnswer" hidden="true">
|
<groupbox id="how" hidden="true">
|
||||||
<label><html:h4 data-l10n-id="auth-questionAndAnswer"/></label>
|
<label><html:h4 data-l10n-id="auth-how"/></label>
|
||||||
<description style="width: 300px; white-space: pre-wrap;" data-l10n-id="auth-qaInstruction"></description>
|
<menulist id="howOption" oncommand="otrAuth.how();">
|
||||||
<label data-l10n-id="auth-question" control="question" flex="1"/>
|
|
||||||
<html:input id="question" type="text" class="input-inline"
|
|
||||||
aria-labelledby="auth-question"/>
|
|
||||||
<label data-l10n-id="auth-answer" control="answer" flex="1"/>
|
|
||||||
<html:input id="answer" type="text" class="input-inline"
|
|
||||||
aria-labelledby="auth-answer"
|
|
||||||
oninput="otrAuth.oninput(this)"/>
|
|
||||||
</groupbox>
|
|
||||||
|
|
||||||
<groupbox id="sharedSecret" hidden="true">
|
|
||||||
<label><html:h4 data-l10n-id="auth-sharedSecret"/></label>
|
|
||||||
<description style="width: 300px; white-space: pre-wrap;" data-l10n-id="auth-secretInstruction"></description>
|
|
||||||
<label data-l10n-id="auth-secret" control="secret" flex="1"/>
|
|
||||||
<html:input id="secret" type="text" class="input-inline"
|
|
||||||
aria-labelledby="auth-secret"
|
|
||||||
oninput="otrAuth.oninput(this)"/>
|
|
||||||
</groupbox>
|
|
||||||
|
|
||||||
<groupbox id="manualVerification" hidden="true">
|
|
||||||
<label><html:h4 data-l10n-id="auth-manualVerification"/></label>
|
|
||||||
<description style="width: 300px; white-space: pre-wrap;" data-l10n-id="auth-manualInstruction"></description>
|
|
||||||
|
|
||||||
<label id="yourFPLabel"/>
|
|
||||||
<html:input id="yourFPValue" type="text" class="input-inline"
|
|
||||||
readonly="readonly"
|
|
||||||
aria-labelledby="yourFPLabel"/>
|
|
||||||
<label id="theirFPLabel"/>
|
|
||||||
<html:input id="theirFPValue" type="text" class="input-inline"
|
|
||||||
readonly="readonly"
|
|
||||||
aria-labelledby="theirFPLabel"/>
|
|
||||||
|
|
||||||
<hbox align="center">
|
|
||||||
<label data-l10n-id="auth-verified"/>
|
|
||||||
<menulist id="verifiedOption">
|
|
||||||
<menupopup>
|
<menupopup>
|
||||||
<menuitem data-l10n-id="auth-yes" value="yes"/>
|
<menuitem data-l10n-id="auth-questionAndAnswer-label" value="questionAndAnswer"/>
|
||||||
<menuitem data-l10n-id="auth-no" value="no"/>
|
<menuitem data-l10n-id="auth-sharedSecret-label" value="sharedSecret"/>
|
||||||
|
<menuitem data-l10n-id="auth-manualVerification-label" value="manualVerification"/>
|
||||||
</menupopup>
|
</menupopup>
|
||||||
</menulist>
|
</menulist>
|
||||||
</hbox>
|
</groupbox>
|
||||||
</groupbox>
|
|
||||||
|
|
||||||
<groupbox id="ask" hidden="true">
|
<groupbox id="questionAndAnswer" hidden="true">
|
||||||
<label id="receivedQuestionLabel" data-l10n-id="auth-questionReceived"/>
|
<label><html:h4 data-l10n-id="auth-questionAndAnswer"/></label>
|
||||||
<description id="receivedQuestion" style="width: 300px; white-space: pre-wrap;"/>
|
<description style="width: 300px; white-space: pre-wrap;" data-l10n-id="auth-qaInstruction"></description>
|
||||||
<label id="responseLabel" control="response" flex="1"/>
|
<label data-l10n-id="auth-question" control="question" flex="1"/>
|
||||||
<html:input id="response" type="text" class="input-inline"
|
<html:input id="question" type="text" class="input-inline"
|
||||||
aria-labelledby="responseLabel"
|
aria-labelledby="auth-question"/>
|
||||||
oninput="otrAuth.oninput(this)"/>
|
<label data-l10n-id="auth-answer" control="answer" flex="1"/>
|
||||||
</groupbox>
|
<html:input id="answer" type="text" class="input-inline"
|
||||||
|
aria-labelledby="auth-answer"
|
||||||
|
oninput="otrAuth.oninput(this)"/>
|
||||||
|
</groupbox>
|
||||||
|
|
||||||
</dialog>
|
<groupbox id="sharedSecret" hidden="true">
|
||||||
|
<label><html:h4 data-l10n-id="auth-sharedSecret"/></label>
|
||||||
|
<description style="width: 300px; white-space: pre-wrap;" data-l10n-id="auth-secretInstruction"></description>
|
||||||
|
<label data-l10n-id="auth-secret" control="secret" flex="1"/>
|
||||||
|
<html:input id="secret" type="text" class="input-inline"
|
||||||
|
aria-labelledby="auth-secret"
|
||||||
|
oninput="otrAuth.oninput(this)"/>
|
||||||
|
</groupbox>
|
||||||
|
|
||||||
|
<groupbox id="manualVerification" hidden="true">
|
||||||
|
<label><html:h4 data-l10n-id="auth-manualVerification"/></label>
|
||||||
|
<description style="width: 300px; white-space: pre-wrap;" data-l10n-id="auth-manualInstruction"></description>
|
||||||
|
|
||||||
|
<label id="yourFPLabel"/>
|
||||||
|
<html:input id="yourFPValue" type="text" class="input-inline"
|
||||||
|
readonly="readonly"
|
||||||
|
aria-labelledby="yourFPLabel"/>
|
||||||
|
<label id="theirFPLabel"/>
|
||||||
|
<html:input id="theirFPValue" type="text" class="input-inline"
|
||||||
|
readonly="readonly"
|
||||||
|
aria-labelledby="theirFPLabel"/>
|
||||||
|
|
||||||
|
<hbox align="center">
|
||||||
|
<label data-l10n-id="auth-verified"/>
|
||||||
|
<menulist id="verifiedOption">
|
||||||
|
<menupopup>
|
||||||
|
<menuitem data-l10n-id="auth-yes" value="yes"/>
|
||||||
|
<menuitem data-l10n-id="auth-no" value="no"/>
|
||||||
|
</menupopup>
|
||||||
|
</menulist>
|
||||||
|
</hbox>
|
||||||
|
</groupbox>
|
||||||
|
|
||||||
|
<groupbox id="ask" hidden="true">
|
||||||
|
<label id="receivedQuestionLabel" data-l10n-id="auth-questionReceived"/>
|
||||||
|
<description id="receivedQuestion" style="width: 300px; white-space: pre-wrap;"/>
|
||||||
|
<label id="responseLabel" control="response" flex="1"/>
|
||||||
|
<html:input id="response" type="text" class="input-inline"
|
||||||
|
aria-labelledby="responseLabel"
|
||||||
|
oninput="otrAuth.oninput(this)"/>
|
||||||
|
</groupbox>
|
||||||
|
<dialog>
|
||||||
|
</window>
|
||||||
|
|
|
@ -5,50 +5,51 @@
|
||||||
|
|
||||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
|
<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
|
||||||
|
|
||||||
<!DOCTYPE dialog>
|
<!DOCTYPE window>
|
||||||
|
|
||||||
<dialog
|
<window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
xmlns:html="http://www.w3.org/1999/xhtml"
|
||||||
xmlns:html="http://www.w3.org/1999/xhtml"
|
data-l10n-id="otr-finger"
|
||||||
id="otr-fingerwindow"
|
data-l10n-attrs="buttonlabelaccept"
|
||||||
data-l10n-id="otr-finger"
|
onload="otrFinger.onload()">
|
||||||
data-l10n-attrs="buttonlabelaccept"
|
|
||||||
onload="otrFinger.onload()"
|
|
||||||
buttons="accept">
|
|
||||||
|
|
||||||
<linkset>
|
<dialog id="otr-fingerwindow"
|
||||||
<html:link rel="localization" href="messenger/otr/finger.ftl"/>
|
buttons="accept">
|
||||||
</linkset>
|
|
||||||
|
|
||||||
<script src="chrome://chat/content/otr-finger.js"/>
|
<linkset>
|
||||||
|
<html:link rel="localization" href="messenger/otr/finger.ftl"/>
|
||||||
|
</linkset>
|
||||||
|
|
||||||
<label data-l10n-id="finger-intro" />
|
<script src="chrome://chat/content/otr-finger.js"/>
|
||||||
<separator class="thin"/>
|
|
||||||
<vbox id="fingerprints" class="contentPane" flex="1">
|
<label data-l10n-id="finger-intro" />
|
||||||
<tree id="fingerTree"
|
|
||||||
flex="1"
|
|
||||||
width="800"
|
|
||||||
style="height: 20em;"
|
|
||||||
onselect="otrFinger.select()">
|
|
||||||
<treecols>
|
|
||||||
<treecol id="screenname" data-l10n-id="finger-screenName" flex="20" />
|
|
||||||
<splitter class="tree-splitter"/>
|
|
||||||
<treecol id="fingerprint" data-l10n-id="finger-fingerprint" flex="120" />
|
|
||||||
<splitter class="tree-splitter"/>
|
|
||||||
<treecol id="verified" data-l10n-id="finger-verified" flex="10" />
|
|
||||||
<splitter class="tree-splitter"/>
|
|
||||||
</treecols>
|
|
||||||
<treechildren/>
|
|
||||||
</tree>
|
|
||||||
<separator class="thin"/>
|
<separator class="thin"/>
|
||||||
<hbox>
|
<vbox id="fingerprints" class="contentPane" flex="1">
|
||||||
<button id="remove"
|
<tree id="fingerTree"
|
||||||
data-l10n-id="finger-remove"
|
flex="1"
|
||||||
disabled="true"
|
width="800"
|
||||||
oncommand="otrFinger.remove()"/>
|
style="height: 20em;"
|
||||||
<button id="remove-all"
|
onselect="otrFinger.select()">
|
||||||
data-l10n-id="finger-remove-all"
|
<treecols>
|
||||||
oncommand="otrFinger.removeAll()"/>
|
<treecol id="screenname" data-l10n-id="finger-screenName" flex="20" />
|
||||||
</hbox>
|
<splitter class="tree-splitter"/>
|
||||||
</vbox>
|
<treecol id="fingerprint" data-l10n-id="finger-fingerprint" flex="120" />
|
||||||
</dialog>
|
<splitter class="tree-splitter"/>
|
||||||
|
<treecol id="verified" data-l10n-id="finger-verified" flex="10" />
|
||||||
|
<splitter class="tree-splitter"/>
|
||||||
|
</treecols>
|
||||||
|
<treechildren/>
|
||||||
|
</tree>
|
||||||
|
<separator class="thin"/>
|
||||||
|
<hbox>
|
||||||
|
<button id="remove"
|
||||||
|
data-l10n-id="finger-remove"
|
||||||
|
disabled="true"
|
||||||
|
oncommand="otrFinger.remove()"/>
|
||||||
|
<button id="remove-all"
|
||||||
|
data-l10n-id="finger-remove-all"
|
||||||
|
oncommand="otrFinger.removeAll()"/>
|
||||||
|
</hbox>
|
||||||
|
</vbox>
|
||||||
|
</dialog>
|
||||||
|
</window>
|
||||||
|
|
Загрузка…
Ссылка в новой задаче