summaryrefslogtreecommitdiff
path: root/tex/context/base/java-imp-fld.mkiv
diff options
context:
space:
mode:
authorMarius <mariausol@gmail.com>2011-05-14 17:20:12 +0300
committerMarius <mariausol@gmail.com>2011-05-14 17:20:12 +0300
commitbcc46b67b4d49116c17086f6a20f6de1220dc688 (patch)
tree71cb87c71e683cffd113242383638ba6667ecbec /tex/context/base/java-imp-fld.mkiv
parentf498e5373a3cbd7da0c32567b55735ffb8fcb4f3 (diff)
downloadcontext-bcc46b67b4d49116c17086f6a20f6de1220dc688.tar.gz
beta 2011.05.14 16:14
Diffstat (limited to 'tex/context/base/java-imp-fld.mkiv')
-rw-r--r--tex/context/base/java-imp-fld.mkiv21
1 files changed, 11 insertions, 10 deletions
diff --git a/tex/context/base/java-imp-fld.mkiv b/tex/context/base/java-imp-fld.mkiv
index 2186368bb..9eb7d7ed5 100644
--- a/tex/context/base/java-imp-fld.mkiv
+++ b/tex/context/base/java-imp-fld.mkiv
@@ -27,7 +27,8 @@
%D different escaping of \type {\\}.
%D
%D Watch out: cf. the latest pdf specification we've changed
-%D On into Yes.
+%D On into Yes. Also, we've changed the test for the on value
+%D into !Off as we dón't know what value it gets in the reader.
\startluasetups javascript:pdfencoding
local verbatim = context.verbatim
@@ -222,7 +223,7 @@ function Field_Off(Name) {
function Toggle_Value(Name) {
var v = this.getField(Name) ;
if (v) {
- if (v.value == "Yes") {
+ if (v.value != "Off") {
v.value = "Off" ;
} else {
v.value = "Yes" ;
@@ -310,15 +311,15 @@ function Reset_Field(FieldSet, FieldName) {
function Walk_Field(FieldSet) {
var i = 1 ;
while (true) {
- v = this.getField(FieldSet+":"+i) ;
+ v = this.getField(FieldSet + ":" + i) ;
if (v) {
- if (v.value=="Yes") {
+ if (v.value != "Off") {
v.value = "Off" ;
var ii = i ;
ii++ ;
- v = this.getField(FieldSet+":"+ii) ;
- if (!v) {
- v = this.getField(FieldSet+":"+1) ;
+ v = this.getField(FieldSet + ":" + ii) ;
+ if (! v) {
+ v = this.getField(FieldSet + ":" + 1) ;
}
if (v) {
v.value = "Yes" ;
@@ -354,7 +355,7 @@ function Do_Next_Auto_Walk_Field(FieldSet) {
if (fieldset) {
var v = this.getField(FieldSet + ":" + fieldset.number) ;
if (v) {
- if (v.value == "Yes") {
+ if (v.value != "Off") {
v.value = "Off" ;
}
}
@@ -447,7 +448,7 @@ function Previous_Walk_Field(FieldSet) {
if (fieldset.number>0) {
var v = this.getField(FieldSet + ":" + fieldset.number) ;
if (v) {
- if (v.value == "Yes") {
+ if (v.value != "Off") {
v.value = "Off" ;
}
}
@@ -471,7 +472,7 @@ function Next_Walk_Field(FieldSet) {
if (v) {
var v = this.getField(FieldSet + ":" + fieldset.number) ;
if (v) {
- if (v.value == "Yes") {
+ if (v.value != "Off") {
v.value = "Off" ;
}
}