"}"
],
"| void updateSelectedLine" : [
- "() {",
+ "(int line) {",
+ "\t",
+ "\tvar new_row = -1;",
+ "\tvar sym = _this.navliststore.symbolAtLine(line);",
+ "\tif (sym) {",
+ "\t \tnew_row = _this.navigationselmodel.getRowFromSymbol(sym);",
+ " \t}",
+ " \tif (new_row == this.selected_row) {",
+ " \t\treturn;",
+ "\t}",
+ "\tif (this.selected_row > -1) {",
+ "\t\tvar old = this.getWidgetAtRow(this.selected_row);",
+ "\t\tif (old !=null) {",
+ "\t\t\told.remove_css_class(\"selcted-row\");",
+ "\t\t}",
+ "\t}\t",
+ "\tif (new_row > -1) {",
+ "\t\tvar row = this.getWidgetAtRow((new_row);",
+ "\t\tif (row != null) {",
+ "\t\t\trow.remove_css_class(\"selcted-row\");",
+ "\t\t}",
+ "\t}",
+ "",
"",
"}"
]
}
return rn;
}
- public void updateSelectedLine () {
+ public void updateSelectedLine (int line) {
+
+ var new_row = -1;
+ var sym = _this.navliststore.symbolAtLine(line);
+ if (sym) {
+ new_row = _this.navigationselmodel.getRowFromSymbol(sym);
+ }
+ if (new_row == this.selected_row) {
+ return;
+ }
+ if (this.selected_row > -1) {
+ var old = this.getWidgetAtRow(this.selected_row);
+ if (old !=null) {
+ old.remove_css_class("selcted-row");
+ }
+ }
+ if (new_row > -1) {
+ var row = this.getWidgetAtRow((new_row);
+ if (row != null) {
+ row.remove_css_class("selcted-row");
+ }
+ }
+
}
}