equal
deleted
inserted
replaced
910 </xsl:text> |
910 </xsl:text> |
911 <xsl:text> offset = 0; |
911 <xsl:text> offset = 0; |
912 </xsl:text> |
912 </xsl:text> |
913 <xsl:text> frequency = 10; /* FIXME arbitrary default max freq. Obtain from config ? */ |
913 <xsl:text> frequency = 10; /* FIXME arbitrary default max freq. Obtain from config ? */ |
914 </xsl:text> |
914 </xsl:text> |
|
915 <xsl:text> unsubscribable = false; |
|
916 </xsl:text> |
915 <xsl:text> constructor(elt_id,args,indexes,members){ |
917 <xsl:text> constructor(elt_id,args,indexes,members){ |
916 </xsl:text> |
918 </xsl:text> |
917 <xsl:text> this.element_id = elt_id; |
919 <xsl:text> this.element_id = elt_id; |
918 </xsl:text> |
920 </xsl:text> |
919 <xsl:text> this.element = id(elt_id); |
921 <xsl:text> this.element = id(elt_id); |
930 </xsl:text> |
932 </xsl:text> |
931 <xsl:text> unsub(){ |
933 <xsl:text> unsub(){ |
932 </xsl:text> |
934 </xsl:text> |
933 <xsl:text> /* remove subsribers */ |
935 <xsl:text> /* remove subsribers */ |
934 </xsl:text> |
936 </xsl:text> |
935 <xsl:text> for(let index of this.indexes){ |
937 <xsl:text> if(!this.unsubscribable) for(let index of this.indexes){ |
936 </xsl:text> |
938 </xsl:text> |
937 <xsl:text> let idx = index + this.offset; |
939 <xsl:text> let idx = index + this.offset; |
938 </xsl:text> |
940 </xsl:text> |
939 <xsl:text> subscribers[idx].delete(this); |
941 <xsl:text> subscribers[idx].delete(this); |
940 </xsl:text> |
942 </xsl:text> |
952 </xsl:text> |
954 </xsl:text> |
953 <xsl:text> this.offset = new_offset; |
955 <xsl:text> this.offset = new_offset; |
954 </xsl:text> |
956 </xsl:text> |
955 <xsl:text> /* add this's subsribers */ |
957 <xsl:text> /* add this's subsribers */ |
956 </xsl:text> |
958 </xsl:text> |
957 <xsl:text> for(let index of this.indexes){ |
959 <xsl:text> if(!this.unsubscribable) for(let index of this.indexes){ |
958 </xsl:text> |
960 </xsl:text> |
959 <xsl:text> subscribers[index + new_offset].add(this); |
961 <xsl:text> subscribers[index + new_offset].add(this); |
960 </xsl:text> |
962 </xsl:text> |
961 <xsl:text> } |
963 <xsl:text> } |
962 </xsl:text> |
964 </xsl:text> |
966 </xsl:text> |
968 </xsl:text> |
967 <xsl:text> |
969 <xsl:text> |
968 </xsl:text> |
970 </xsl:text> |
969 <xsl:text> apply_cache() { |
971 <xsl:text> apply_cache() { |
970 </xsl:text> |
972 </xsl:text> |
971 <xsl:text> for(let index of this.indexes){ |
973 <xsl:text> if(!this.unsubscribable) for(let index of this.indexes){ |
972 </xsl:text> |
974 </xsl:text> |
973 <xsl:text> /* dispatch current cache in newly opened page widgets */ |
975 <xsl:text> /* dispatch current cache in newly opened page widgets */ |
974 </xsl:text> |
976 </xsl:text> |
975 <xsl:text> let realindex = index+this.offset; |
977 <xsl:text> let realindex = index+this.offset; |
976 </xsl:text> |
978 </xsl:text> |
2290 <xsl:when test="$have_disability"> |
2292 <xsl:when test="$have_disability"> |
2291 <xsl:text> this.disabled_elt_style = this.disabled_elt.getAttribute("style"); |
2293 <xsl:text> this.disabled_elt_style = this.disabled_elt.getAttribute("style"); |
2292 </xsl:text> |
2294 </xsl:text> |
2293 </xsl:when> |
2295 </xsl:when> |
2294 <xsl:otherwise> |
2296 <xsl:otherwise> |
2295 <xsl:text> this.sub = function(){}; |
2297 <xsl:text> this.unsubscribable = true; |
2296 </xsl:text> |
|
2297 <xsl:text> this.unsub = function(){}; |
|
2298 </xsl:text> |
|
2299 <xsl:text> this.apply_cache = function(){}; |
|
2300 </xsl:text> |
2298 </xsl:text> |
2301 </xsl:otherwise> |
2299 </xsl:otherwise> |
2302 </xsl:choose> |
2300 </xsl:choose> |
2303 <xsl:text> }, |
2301 <xsl:text> }, |
2304 </xsl:text> |
2302 </xsl:text> |