Merge pull request +8729 from c9/sdk

fix several small issues
pull/134/head
Ruben Daniels 2015-08-15 11:04:46 -07:00
commit 147ad8d0b2
3 zmienionych plików z 6 dodań i 4 usunięć

Wyświetl plik

@ -1375,7 +1375,7 @@ define(function(require, exports, module) {
} }
function getMode(syntax) { function getMode(syntax) {
syntax = (syntax || "text").toLowerCase(); syntax = (syntax || settings.get("project/ace/@defaultSyntax") || "text").toLowerCase();
if (syntax.indexOf("/") == -1) if (syntax.indexOf("/") == -1)
syntax = "ace/mode/" + syntax; syntax = "ace/mode/" + syntax;

Wyświetl plik

@ -44,7 +44,7 @@ define(function(require, module, exports) {
column.setWidth(CURWIDTH); column.setWidth(CURWIDTH);
column.setAttribute("class", where); column.setAttribute("class", where);
column.oncontextmenu = function(e) { bar.oncontextmenu = function(e) {
var menu = menus.get("Window").menu; var menu = menus.get("Window").menu;
menu.display(e.x, e.y); menu.display(e.x, e.y);
menu.childNodes.forEach(function(x) { menu.childNodes.forEach(function(x) {

Wyświetl plik

@ -22,6 +22,8 @@ define(function(require, exports, module) {
var basename = require("path").basename; var basename = require("path").basename;
var dirname = require("path").dirname; var dirname = require("path").dirname;
var escapeHTML = require("ace/lib/lang").escapeHTML;
/***** Initialization *****/ /***** Initialization *****/
@ -650,9 +652,9 @@ define(function(require, exports, module) {
model.getCaptionHTML = function(node) { model.getCaptionHTML = function(node) {
if (node.isFavorite) { if (node.isFavorite) {
var path = node.labelPath || node.path; var path = node.labelPath || node.path;
return basename(path) return escapeHTML(basename(path))
+ "<span class='extrainfo'> - " + "<span class='extrainfo'> - "
+ dirname(path) + "</span>"; + escapeHTML(dirname(path)) + "</span>";
} }
else else
return getCaptionHTML.call(model, node); return getCaptionHTML.call(model, node);