move elastic_tabstops into ext to automatically include in build

This commit is contained in:
nightwing 2013-02-22 16:39:45 +04:00
commit e6fd9dc977
3 changed files with 8 additions and 9 deletions

View file

@ -62,7 +62,7 @@ var fillDropdown = util.fillDropdown;
var bindCheckbox = util.bindCheckbox;
var bindDropdown = util.bindDropdown;
var ElasticTabstopsLite = require("ace/elastic_tabstops_lite").ElasticTabstopsLite;
var ElasticTabstopsLite = require("ace/ext/elastic_tabstops_lite").ElasticTabstopsLite;
/*********** create editor ***************************/
var container = document.getElementById("editor-container");

View file

@ -145,14 +145,13 @@ var ElasticTabstopsLite = function(editor) {
this.$setBlockCellWidthsToMax = function(cellWidths) {
var startingNewBlock = true, blockStartRow, blockEndRow, maxWidth;
var columnInfo = this.$izip_longest(cellWidths);
for (var c = 0, l = columnInfo.length; c < l; c++) {
var column = columnInfo[c];
if (!column.push) {
console.error(column)
continue
console.error(column);
continue;
}
// add an extra None to the end so that the end of the column automatically
// finishes a block
@ -253,7 +252,7 @@ var ElasticTabstopsLite = function(editor) {
// the is a (naive) Python port--but works for these purposes
this.$izip_longest = function(iterables) {
if (!iterables[0])
return console.error(iterables);
return [];
var longest = iterables[0].length;
var iterablesLength = iterables.length;
@ -298,8 +297,8 @@ var ElasticTabstopsLite = function(editor) {
exports.ElasticTabstopsLite = ElasticTabstopsLite;
var Editor = require("./editor").Editor;
require("./config").defineOptions(Editor.prototype, "editor", {
var Editor = require("../editor").Editor;
require("../config").defineOptions(Editor.prototype, "editor", {
useElasticTabstops: {
set: function(val) {
if (val) {

View file

@ -43,12 +43,12 @@ dom.importCssString(searchboxCss, "ace_searchbox");
var html = '<div class="ace_search right">\
<button action="hide" class="ace_searchbtn_close"></button>\
<div class="ace_search_form">\
<input class="ace_search_field" placeholder="Search for" spellcheck="false">\
<input class="ace_search_field" placeholder="Search for" spellcheck="false"></input>\
<button action="findNext" class="ace_searchbtn next"></button>\
<button action="findPrev" class="ace_searchbtn prev"></button>\
</div>\
<div class="ace_replace_form">\
<input class="ace_search_field" placeholder="Replace with" spellcheck="false">\
<input class="ace_search_field" placeholder="Replace with" spellcheck="false"></input>\
<button action="replace" class="ace_replacebtn">Replace</button>\
<button action="replaceAll" class="ace_replacebtn">All</button>\
</div>\