GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

Commit d3c66f51 authored by Kathleen Brade's avatar Kathleen Brade Committed by Georg Koppen

Bug 32154: Custom bridge field only allows one line of input

Mozilla is working on removing XUL <textbox>, and prior to ESR68
they removed support for the multiline attribute. Switch to
<html:textarea> and adjust styles to make the appearance closely
match <textbox>.
parent 6a22ee94
......@@ -122,9 +122,9 @@ var bridgeSettings = `
<vbox id="bridgeCustomEntry">
<label id="bridgeListLabel" style="margin-top:0px;"
value="&torsettings.useBridges.label;" control="bridgeList"/>
<textbox id="bridgeList" multiline="true" rows="3" wrap="off"
oninput="onCustomBridgesTextInput();"
placeholder="&torsettings.useBridges.placeholder;"/>
<html:textarea id="bridgeList" rows="3" wrap="off"
oninput="onCustomBridgesTextInput();"
placeholder="&torsettings.useBridges.placeholder;"/>
</vbox>
</groupbox>
</vbox>
......
......@@ -12,6 +12,7 @@
<wizard id="TorNetworkSettings"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
xmlns:html="http://www.w3.org/1999/xhtml"
defaulttitle="&torsettings.wizard.title.default;"
windowtype="TorLauncher:NetworkSettings"
persist="screenX screenY"
......
......@@ -2485,6 +2485,7 @@ function setElemValue(aID, aValue)
elem.checked = val;
toggleElemUI(elem);
break;
case "html:textarea":
case "textbox":
if (Array.isArray(aValue))
{
......@@ -2534,7 +2535,7 @@ function setBridgeListElemValue(aBridgeArray)
// Returns a Boolean (for checkboxes/radio buttons) or a
// string (textbox and menulist).
// string (textarea, textbox, and menulist).
// Leading and trailing white space is trimmed from strings.
function getElemValue(aID, aDefaultValue)
{
......@@ -2550,6 +2551,7 @@ function getElemValue(aID, aDefaultValue)
case "radio":
rv = elem.selected;
break;
case "html:textarea":
case "textbox":
case "menulist":
case "richlistbox":
......
......@@ -13,6 +13,7 @@
<dialog id="TorNetworkSettings"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
xmlns:html="http://www.w3.org/1999/xhtml"
title="&torsettings.dialog.title;"
windowtype="TorLauncher:NetworkSettings"
persist="screenX screenY"
......
......@@ -5,6 +5,8 @@
* vim: set sw=2 sts=2 ts=8 et syntax=css:
*/
@namespace html "http://www.w3.org/1999/xhtml";
dialog {
width: 45em;
height: 41em;
......@@ -294,13 +296,20 @@ dialog .help {
max-width: 34em;
}
html|textarea {
padding: 4px !important;
margin-top: 4px;
font-family: inherit;
}
/* Increase font size on Windows for readability */
.os-windows div,
.os-windows label,
.os-windows description,
.os-windows html|textarea,
.os-windows textbox
{
font-size: 120%;
font-size: 120% !important;
}
.torWarning {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment