Skip to content
This repository has been archived by the owner on Dec 14, 2023. It is now read-only.

Commit

Permalink
goToLine now takes number as a param
Browse files Browse the repository at this point in the history
You can optionally pass through a param to goToLine
It will go to this given line instead of textfield value
This makes it more usable via API calls
  • Loading branch information
mattpass committed Jun 11, 2012
1 parent 229a089 commit 7c0cb2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/coder.js
Original file line number Diff line number Diff line change
Expand Up @@ -981,11 +981,11 @@ var ICEcoder = {
},

// Go to a specific line number
goToLine: function() {
goToLine: function(lineNo) {
var cM;

cM = ICEcoder.getcMInstance();
cM.setCursor(document.getElementById('goToLineNo').value-1);
cM.setCursor(lineNo ? lineNo-1 : document.getElementById('goToLineNo').value-1);
cM.focus();
return false;
},
Expand Down

0 comments on commit 7c0cb2d

Please sign in to comment.