зеркало из https://github.com/mozilla/gecko-dev.git
111 строки
14 KiB
HTML
111 строки
14 KiB
HTML
<?xml version="1.0" encoding="ISO-8859-1"?>
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US" class="willBeRemoved">
|
|
<head>
|
|
<link rel="stylesheet" type="text/css" href="frame_selection_underline.css"/>
|
|
<script type="text/javascript" src="decorationline.js"></script>
|
|
<script type="text/javascript">
|
|
<![CDATA[
|
|
|
|
function onLoad()
|
|
{
|
|
netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect');
|
|
|
|
var docShell =
|
|
window.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
|
|
.getInterface(Components.interfaces.nsIWebNavigation)
|
|
.QueryInterface(Components.interfaces.nsIDocShell);
|
|
var controller =
|
|
docShell.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
|
|
.getInterface(Components.interfaces.nsISelectionDisplay)
|
|
.QueryInterface(Components.interfaces.nsISelectionController);
|
|
|
|
const selections = [
|
|
{
|
|
id: "selectionSpellChecker",
|
|
selectionType: controller.SELECTION_SPELLCHECK
|
|
},
|
|
{
|
|
id: "selectionIMERawInput",
|
|
selectionType: controller.SELECTION_IME_RAWINPUT
|
|
},
|
|
{
|
|
id: "selectionIMESelectedRawText",
|
|
selectionType: controller.SELECTION_IME_SELECTEDRAWTEXT
|
|
},
|
|
{
|
|
id: "selectionIMEConvertedText",
|
|
selectionType: controller.SELECTION_IME_CONVERTEDTEXT
|
|
},
|
|
{
|
|
id: "selectionIMESelectedConvertedText",
|
|
selectionType: controller.SELECTION_IME_SELECTEDCONVERTEDTEXT
|
|
},
|
|
];
|
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
var sel = controller.getSelection(selections[i].selectionType);
|
|
var range = document.createRange();
|
|
range.selectNodeContents(document.getElementById(selections[i].id));
|
|
sel.addRange(range);
|
|
}
|
|
|
|
document.documentElement.removeAttribute("class");
|
|
}
|
|
|
|
]]>
|
|
</script>
|
|
</head>
|
|
<body class="test" onload="onLoad();">
|
|
<div id="selectionSpellChecker" class="selection"><div
|
|
class="fontsize size1"><div
|
|
class="font1"><span id="t0" > </span></div><div
|
|
class="font2"><span id="t1" > </span></div></div><div
|
|
class="fontsize size2"><div
|
|
class="font1"><span id="t2" > </span></div><div
|
|
class="font2"><span id="t3" > </span></div></div><div
|
|
class="fontsize size3"><div
|
|
class="font1"><span id="t4" > </span></div><div
|
|
class="font2"><span id="t5" > </span></div></div></div>
|
|
<div id="selectionIMERawInput" class="selection IMEselection"><div
|
|
class="fontsize size1"><div
|
|
class="font1"><span id="t6" > </span></div><div
|
|
class="font2"><span id="t7" > </span></div></div><div
|
|
class="fontsize size2"><div
|
|
class="font1"><span id="t8" > </span></div><div
|
|
class="font2"><span id="t9" > </span></div></div><div
|
|
class="fontsize size3"><div
|
|
class="font1"><span id="t10"> </span></div><div
|
|
class="font2"><span id="t11"> </span></div></div></div>
|
|
<div id="selectionIMESelectedRawText" class="selection IMEselection"><div
|
|
class="fontsize size1"><div
|
|
class="font1"><span id="t12"> </span></div><div
|
|
class="font2"><span id="t13"> </span></div></div><div
|
|
class="fontsize size2"><div
|
|
class="font1"><span id="t14"> </span></div><div
|
|
class="font2"><span id="t15"> </span></div></div><div
|
|
class="fontsize size3"><div
|
|
class="font1"><span id="t16"> </span></div><div
|
|
class="font2"><span id="t17"> </span></div></div></div>
|
|
<div id="selectionIMEConvertedText" class="selection IMEselection"><div
|
|
class="fontsize size1"><div
|
|
class="font1"><span id="t18"> </span></div><div
|
|
class="font2"><span id="t19"> </span></div></div><div
|
|
class="fontsize size2"><div
|
|
class="font1"><span id="t20"> </span></div><div
|
|
class="font2"><span id="t21"> </span></div></div><div
|
|
class="fontsize size3"><div
|
|
class="font1"><span id="t22"> </span></div><div
|
|
class="font2"><span id="t23"> </span></div></div></div>
|
|
<div id="selectionIMESelectedConvertedText" class="selection IMEselection"><div
|
|
class="fontsize size1"><div
|
|
class="font1"><span id="t24"> </span></div><div
|
|
class="font2"><span id="t25"> </span></div></div><div
|
|
class="fontsize size2"><div
|
|
class="font1"><span id="t26"> </span></div><div
|
|
class="font2"><span id="t27"> </span></div></div><div
|
|
class="fontsize size3"><div
|
|
class="font1"><span id="t28"> </span></div><div
|
|
class="font2"><span id="t29"> </span></div></div></div>
|
|
</body>
|
|
</html> |