MCPcopy Create free account
hub / github.com/witheve/Eve / refresh

Method refresh

src/ide/spans.ts:907–928  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

905 }
906
907 refresh() {
908 let loc = this.find();
909 if(!loc) return this.clear();
910
911 if(!this.annotation) {
912 this.annotation = this.editor.cm.annotateScrollbar({className: `scrollbar-annotation ${this.kind}`});
913 }
914 if(loc) {
915 this.annotation.update([loc]);
916 if(!this.hidden) {
917 updateLineClasses(loc.from.line, loc.to.line, this.editor, this);
918 } else {
919 clearLineClasses(loc.from.line, loc.to.line, this.editor, this);
920 }
921
922 if(loc.to.line !== this.widgetLine) {
923 this.widgetLine = loc.to.line;
924 if(this.commentWidget) this.commentWidget.clear();
925 this.updateWidget();
926 }
927 }
928 }
929
930 updateWidget() {
931 if(this.commentWidget) this.commentWidget.clear();

Callers

nothing calls this directly

Calls 8

clearMethod · 0.95
updateWidgetMethod · 0.95
clearLineClassesFunction · 0.85
annotateScrollbarMethod · 0.80
updateLineClassesFunction · 0.70
findMethod · 0.65
updateMethod · 0.65
clearMethod · 0.65

Tested by

no test coverage detected