Commit 7bea1bd8 authored by csillag's avatar csillag

Update annotator to 3aca4b72c (introduce-focus branch)

parent 1d588521
......@@ -26,6 +26,19 @@ class Highlight
setActive: (value, batch = false) ->
throw "Operation not implemented."
# Mark/unmark this hl as focused
#
# Value specifies whether it should be focused or not
#
# The 'batch' field specifies whether this call is only one of
# many subsequent calls, which should be executed together.
#
# In this case, a "finalizeHighlights" event will be published
# when all the flags have been set, and the changes should be
# executed.
setFocused: (value, batch = false) ->
throw "Operation not implemented."
# React to changes in the underlying annotation
annotationUpdated: ->
#console.log "In HL", this, "annotation has been updated."
......
......@@ -115,6 +115,13 @@ class TextHighlight extends Annotator.Highlight
else
@$(@_highlights).removeClass('annotator-hl-active')
# Mark/unmark this hl as focused
setFocused: (value) ->
if value
@$(@_highlights).addClass('annotator-hl-focused')
else
@$(@_highlights).removeClass('annotator-hl-focused')
# Remove all traces of this hl from the document
removeFromDocument: ->
for hl in @_highlights
......
// Generated by CoffeeScript 1.6.3
/*
** Annotator 1.2.6-dev-04d1465
** Annotator 1.2.6-dev-816c71f
** https://github.com/okfn/annotator/
**
** Copyright 2012 Aron Carroll, Rufus Pollock, and Nick Stenning.
** Dual licensed under the MIT and GPLv3 licenses.
** https://github.com/okfn/annotator/blob/master/LICENSE
**
** Built at: 2014-03-31 18:03:10Z
** Built at: 2014-04-01 08:46:09Z
*/
......@@ -906,6 +906,13 @@
throw "Operation not implemented.";
};
Highlight.prototype.setFocused = function(value, batch) {
if (batch == null) {
batch = false;
}
throw "Operation not implemented.";
};
Highlight.prototype.annotationUpdated = function() {};
Highlight.prototype.removeFromDocument = function() {
......
This diff is collapsed.
// Generated by CoffeeScript 1.6.3
/*
** Annotator 1.2.6-dev-8b9bc0e
** Annotator 1.2.6-dev-816c71f
** https://github.com/okfn/annotator/
**
** Copyright 2012 Aron Carroll, Rufus Pollock, and Nick Stenning.
** Dual licensed under the MIT and GPLv3 licenses.
** https://github.com/okfn/annotator/blob/master/LICENSE
**
** Built at: 2014-03-31 22:37:06Z
** Built at: 2014-04-01 08:47:02Z
*/
......@@ -132,6 +132,14 @@
}
};
TextHighlight.prototype.setFocused = function(value) {
if (value) {
return this.$(this._highlights).addClass('annotator-hl-focused');
} else {
return this.$(this._highlights).removeClass('annotator-hl-focused');
}
};
TextHighlight.prototype.removeFromDocument = function() {
var child, event, hl, _i, _len, _ref, _results;
_ref = this._highlights;
......
{"version":3,"file":"annotator.texthighlights.js","sources":["_preamble.coffee","_annotator_mapsrc/src/plugin/texthighlights.coffee"],"names":[],"mappings":";AAAA;;;;;;;;;;CAAA;CAAA;;;;;;;ACGA;CAAA,KAAA,aAAA;KAAA;;0JAAA;;CAAA,CAAM;CAIJ;;CAAA,EAAa,CAAb,KAAA,IAAC;;CAAD,EACK,CAAL,KAAc,IAAb;;CADD,EAEiB,CAAjB,SAAC,EAFD;;CAAA,EAKa,CAAb,GAAa,EAAC,CAAd,GAAC;CAA0B,GAAA,GAAD,CAAA,KAAA,CAAA;CAL1B,IAKa;;CALb,EAQuB,CAAvB,GAAuB,EAAC,IAAvB,OAAD;CACG,GAAA,GAAD,MAAA,gBAAA;CATF,IAQuB;;CARvB,CAAA,CAYU,CAAV,GAAA,MAAC;;CAZD,EAeiB,CAAjB,CAAiB,IAAC,IAAjB,CAAD;CACgB,EAAd,EAAqB,CAArB,CAAA,EAGQ,IAHR,EAAA;CAGyB,GAAd,QAAA,CAAa,EAAb;CAHX,MAGQ;CAnBV,IAeiB;;CAfjB,EAuBQ,CAAR,CAAA,IAAS,IAAR;CACC,SAAA,EAAA;CAAA,CAAU,EAAA,EAAV,CAAU,EAAA,MAAa;CAAvB,aAAA;QAAA;CAAA,CAE4C,CACzC,CADH,CACG,CADH,CAAiB,CAAjB,CAAS,EAAT,IAAA;CACwB,IAAV,IAAS,MAAT,EAAA;CADd,MACG;CAHH,CAK4C,CACzC,CADH,CACG,CADH,CAAiB,CAAjB,CAAS,CAAT,KAAA;CACwB,IAAV,IAAS,MAAT,CAAA;CADd,MACG;CANH,CAQ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CAQoC,EAAnC,EAAD,IAAA,CAAA,CAAA;CAxFF,IA+Ea;;CA/Eb,EA6Fa,MAAA,EAAb;CAAiB,GAAA,SAAD;CA7FhB,IA6Fa;;CA7Fb,EAgGc,EAAA,IAAC,GAAf;CACE,EAAc,CAAb,CAAD,CAAA,IAAA;CACA,GAAG,CAAH,CAAA;CACG,GAAA,IAAD,GAAA,IAAA,SAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,SAAA;QALU;CAhGd,IAgGc;;CAhGd,EAwGW,EAAA,IAAX;CACE,GAAG,CAAH,CAAA;CACG,GAAA,IAAD,GAAA,IAAA,MAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,MAAA;QAJO;CAxGX,IAwGW;;CAxGX,EA+GoB,MAAA,SAApB;CACE,SAAA,gCAAA;CAAA;CAAA;YAAA,+BAAA;uBAAA;CAEE,GAAG,IAAH,CAAgC,GAAV,WAAnB;CAED,CAAU,CAAF,EAAR,KAAA;CAAA,CACA,EAAC,MAAD,CAAA;CADA,EAGQ,EAAR,GAAgB,EAAhB,CAAQ;CAHR,CAI+B,EAA/B,CAAK,CAAL,IAAA,CAAA;CAJA,EAKe,EAAV,CAAL,IAAA,2BALA;CAAA,IAMK,KAAW,GAAhB;MARF,IAAA;CAAA;UAFF;CAAA;uBADkB;CA/GpB,IA+GoB;;CA/GpB,EA6HiB,MAAA,MAAjB;CAAqB,GAAA,SAAD;CA7HpB,IA6HiB;;CA7HjB;;CAJ0B,QAAS;;CAArC,CAmIM,IAAgB,GAAP;CAGb;;;;;CAAA;;CAAA,EAAY,MAAA,CAAZ;CAEY,EAAgB,MAAjB,IAAT;CAFF,IAAY;;CAAZ;;CAH4C,QAAS;CAnIvD"}
\ No newline at end of file
{"version":3,"file":"annotator.texthighlights.js","sources":["_preamble.coffee","_annotator_mapsrc/src/plugin/texthighlights.coffee"],"names":[],"mappings":";AAAA;;;;;;;;;;CAAA;CAAA;;;;;;;ACGA;CAAA,KAAA,aAAA;KAAA;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;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,MAAA;QAJO;CAxGX,IAwGW;;CAxGX,EA+GY,EAAA,IAAC,CAAb;CACE,GAAG,CAAH,CAAA;CACG,GAAA,IAAD,GAAA,IAAA,OAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,OAAA;QAJQ;CA/GZ,IA+GY;;CA/GZ,EAsHoB,MAAA,SAApB;CACE,SAAA,gCAAA;CAAA;CAAA;YAAA,+BAAA;uBAAA;CAEE,GAAG,IAAH,CAAgC,GAAV,WAAnB;CAED,CAAU,CAAF,EAAR,KAAA;CAAA,CACA,EAAC,MAAD,CAAA;CADA,EAGQ,EAAR,GAAgB,EAAhB,CAAQ;CAHR,CAI+B,EAA/B,CAAK,CAAL,IAAA,CAAA;CAJA,EAKe,EAAV,CAAL,IAAA,2BALA;CAAA,IAMK,KAAW,GAAhB;MARF,IAAA;CAAA;UAFF;CAAA;uBADkB;CAtHpB,IAsHoB;;CAtHpB,EAoIiB,MAAA,MAAjB;CAAqB,GAAA,SAAD;CApIpB,IAoIiB;;CApIjB;;CAJ0B,QAAS;;CAArC,CA0IM,IAAgB,GAAP;CAGb;;;;;CAAA;;CAAA,EAAY,MAAA,CAAZ;CAEY,EAAgB,MAAjB,IAAT;CAFF,IAAY;;CAAZ;;CAH4C,QAAS;CA1IvD"}
\ No newline at end of file
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