kopia lustrzana https://github.com/c9/core
commit
83806e8991
|
@ -137,7 +137,7 @@ var supportedModes = {
|
|||
Protobuf: ["proto"],
|
||||
Python: ["py"],
|
||||
R: ["r"],
|
||||
Razor: ["cshtml"],
|
||||
Razor: ["cshtml|asp"],
|
||||
RDoc: ["Rd"],
|
||||
RHTML: ["Rhtml"],
|
||||
RST: ["rst"],
|
||||
|
|
|
@ -176,6 +176,8 @@ function luma(color) {
|
|||
}
|
||||
|
||||
function parseColor(color) {
|
||||
if (color[0] != "#" && color.match(/^[a-f\d]+$/i))
|
||||
color = "#" + color;
|
||||
if (color.length == 4)
|
||||
color = color.replace(/[a-fA-F\d]/g, "$&$&");
|
||||
if (color.length == 7)
|
||||
|
|
|
@ -309,6 +309,7 @@ define.undef = require.undef = function(module, recursive) {
|
|||
var path = require.toUrl(module, ".js");
|
||||
delete define.errors[module];
|
||||
delete define.loaded[module];
|
||||
delete define.loading[module];
|
||||
delete define.modules[module];
|
||||
delete define.fetchedUrls[path];
|
||||
};
|
||||
|
@ -403,6 +404,7 @@ var loadScriptWithTag = function(path, id, callback) {
|
|||
};
|
||||
s.onerror = function(e) {
|
||||
processLoadQueue({
|
||||
message: "Error loading script " + id + ":" + path,
|
||||
id: id,
|
||||
path: path
|
||||
});
|
||||
|
|
|
@ -128,14 +128,7 @@ ReliableSocket.prototype.onMessage = function(msg) {
|
|||
this.emit(msg.t, msg);
|
||||
}
|
||||
else if (msg.d) {
|
||||
try {
|
||||
this.emit("message", msg.d);
|
||||
} catch (e) {
|
||||
console.error(e.stack);
|
||||
// Don't let engine.io catch this, it'll consider it a parser error,
|
||||
// making us reconnect
|
||||
setTimeout(function() { throw e; });
|
||||
}
|
||||
this.emit("message", msg.d);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -114,7 +114,7 @@
|
|||
"c9.ide.run.debug.xdebug": "#9956689819",
|
||||
"c9.ide.save": "#25a63f31e2",
|
||||
"c9.ide.scm": "#637a68cd04",
|
||||
"c9.ide.terminal.monitor": "#affa33572f",
|
||||
"c9.ide.terminal.monitor": "#5a6a54ce24",
|
||||
"c9.ide.test": "#102942ae4e",
|
||||
"c9.ide.test.mocha": "#38151a98c3",
|
||||
"c9.ide.theme.flat": "#81dadeee55",
|
||||
|
|
|
@ -645,7 +645,7 @@ define(function(require, exports, module) {
|
|||
if (!e && data) {
|
||||
session.terminal.setOutputHistory(data, true);
|
||||
session.getStatus({clients: true}, function(e, status) {
|
||||
if (e) return;
|
||||
if (e || !status) return;
|
||||
if (status.clients && status.clients.length > 0) {
|
||||
var terminal = session.terminal;
|
||||
var rows = terminal.rows;
|
||||
|
|
|
@ -13,7 +13,6 @@ require(["lib/architect/architect", "lib/chai/chai", "/vfs-root"], function (arc
|
|||
debug: true,
|
||||
hosted: true,
|
||||
local: false,
|
||||
davPrefix: "/"
|
||||
},
|
||||
|
||||
"plugins/c9.core/ext",
|
||||
|
@ -127,6 +126,7 @@ require(["lib/architect/architect", "lib/chai/chai", "/vfs-root"], function (arc
|
|||
|
||||
// Kill connection
|
||||
session.pty.kill();
|
||||
session.doc.editor.focus();
|
||||
});
|
||||
|
||||
it.skip('should reconnect when the session has been lost', function(done) {
|
||||
|
|
|
@ -61,7 +61,7 @@ define(function(require, exports, module) {
|
|||
};
|
||||
}
|
||||
|
||||
if (!api) return callback(new Error("Client is offline"));
|
||||
if (!api || !vfs.connection) return callback(new Error("Client is offline"));
|
||||
|
||||
if (!vfs.isIdle())
|
||||
return vfs.connection.once("message", ping.bind(null, callback));
|
||||
|
|
|
@ -263,7 +263,7 @@
|
|||
}
|
||||
|
||||
function getReport() {
|
||||
return mocha.lastReport;
|
||||
return mocha.lastReport || { failures: "didn't complete" };
|
||||
}
|
||||
|
||||
function safeDisconnect(cb) {
|
||||
|
@ -382,7 +382,11 @@
|
|||
return !/text!/.test(x);
|
||||
});
|
||||
function cleanupRequireModules() {
|
||||
Object.keys(define.modules).forEach(function(x) {
|
||||
[].concat(
|
||||
Object.keys(define.modules),
|
||||
Object.keys(define.errors),
|
||||
Object.keys(define.loading)
|
||||
).forEach(function(x) {
|
||||
if (/text!/.test(x) || defaultModules.indexOf(x) != -1)
|
||||
return;
|
||||
if (/^ace|^treehugger|\/ctags\/ctags$/.test(x) && !/_test/.test(x))
|
||||
|
@ -390,12 +394,13 @@
|
|||
|
||||
require.undef(x);
|
||||
});
|
||||
define.fetchedUrls = Object.create(null);
|
||||
}
|
||||
if (require == requirejs) {
|
||||
require = function(a, b, c) {
|
||||
if (!c && Array.isArray(a))
|
||||
c = function(err) {
|
||||
lastDone && lastDone(err.message);
|
||||
lastDone && lastDone(err.message || err);
|
||||
};
|
||||
// workaround for sync minirequire behaviour
|
||||
var bt = b && function() {
|
||||
|
|
|
@ -530,6 +530,12 @@ require([
|
|||
x.unregister = function(){};
|
||||
return x;
|
||||
})(),
|
||||
"terminal.monitor.message_view": (function(){
|
||||
var x = new EventEmitter();
|
||||
x.show = function(){};
|
||||
x.hide = function(){};
|
||||
return x;
|
||||
})()
|
||||
});
|
||||
};
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue