kopia lustrzana https://github.com/c9/core
Merge branch 'master' of github.com:c9/newclient into integrate-upgrade-upsell-dialog
commit
aa9b87a210
|
@ -546,7 +546,7 @@ module.exports = function(options) {
|
|||
{
|
||||
packagePath: "plugins/c9.ide.layout.classic/preload",
|
||||
themePrefix: options.themePrefix,
|
||||
defaultTheme: options.defaultTheme || "flat-light"
|
||||
defaultTheme: options.defaultTheme || "dark"
|
||||
},
|
||||
{
|
||||
packagePath: "plugins/c9.ide.tree/tree",
|
||||
|
|
|
@ -11,8 +11,9 @@ function compress(sources, opts) {
|
|||
var literals = [];
|
||||
|
||||
sources.forEach(function(pkg){
|
||||
if (/^"disable compress"/.test(pkg.source))
|
||||
if (/"disable compress"/.test(pkg.source)) {
|
||||
return literals.push(pkg.source);
|
||||
}
|
||||
|
||||
if (pkg.file) console.log("Adding '" + pkg.file + "'.");
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "c9",
|
||||
"description": "New Cloud9 Client",
|
||||
"version": "3.1.1432",
|
||||
"version": "3.1.1483",
|
||||
"author": "Ajax.org B.V. <info@ajax.org>",
|
||||
"private": true,
|
||||
"main": "bin/c9",
|
||||
|
@ -56,7 +56,7 @@
|
|||
"c9"
|
||||
],
|
||||
"c9plugins": {
|
||||
"c9.ide.language": "#050c0de5a4",
|
||||
"c9.ide.language": "#4c02a26baf",
|
||||
"c9.ide.language.css": "#be07d72209",
|
||||
"c9.ide.language.generic": "#a4023db7f6",
|
||||
"c9.ide.language.html": "#22fdc74869",
|
||||
|
@ -90,7 +90,7 @@
|
|||
"c9.ide.format": "#5ec97fb083",
|
||||
"c9.ide.help.support": "#e46a619c93",
|
||||
"c9.ide.imgeditor": "#612e75ef4f",
|
||||
"c9.ide.immediate": "#a962119bec",
|
||||
"c9.ide.immediate": "#19758abe08",
|
||||
"c9.ide.installer": "#0fde9f0067",
|
||||
"c9.ide.language.python": "#675ddb4c8f",
|
||||
"c9.ide.language.go": "#8f6d0beae7",
|
||||
|
@ -102,7 +102,7 @@
|
|||
"c9.ide.preview.browser": "#a732ce9853",
|
||||
"c9.ide.preview.markdown": "#bc846e1562",
|
||||
"c9.ide.pubsub": "#a85fb27eca",
|
||||
"c9.ide.readonly": "#f5121c3a57",
|
||||
"c9.ide.readonly": "#719881e192",
|
||||
"c9.ide.recentfiles": "#7c099abf40",
|
||||
"c9.ide.remote": "#301d2ab519",
|
||||
"c9.ide.processlist": "#2b12cd1bdd",
|
||||
|
|
|
@ -31,80 +31,38 @@ define(function(require, exports, module) {
|
|||
};
|
||||
|
||||
var SupportedIcons = {
|
||||
"application/xhtml+xml":"html",
|
||||
"text/css": "css",
|
||||
"text/x-scss": "css",
|
||||
"text/x-sass": "css",
|
||||
"text/html":"html",
|
||||
"application/pdf":"page_white_acrobat",
|
||||
"image":"image",
|
||||
"application/xml":"page_white_code_red",
|
||||
"image/svg+xml": "page_white_picture",
|
||||
"text/plain": "page_white_text",
|
||||
"application/javascript": "page_white_code",
|
||||
"application/json": "page_white_code",
|
||||
"text/x-script.python": "page_white_code",
|
||||
"text/x-script.ocaml": "page_white_code",
|
||||
"text/x-script.clojure": "page_white_code",
|
||||
"application/x-httpd-php": "page_white_php",
|
||||
"application/x-sh": "page_white_wrench",
|
||||
"text/x-coldfusion": "page_white_coldfusion",
|
||||
"text/x-script.ruby": "page_white_ruby",
|
||||
"text/x-script.coffeescript": "page_white_cup",
|
||||
"text/cpp": "page_white_cplusplus",
|
||||
"text/x-c": "page_white_c",
|
||||
"text/x-logiql": "logiql",
|
||||
"text/x-csharp": "page_white_csharp",
|
||||
"text/x-java-source": "page_white_cup",
|
||||
"text/x-markdown": "page_white_text",
|
||||
"text/x-xquery": "page_white_code",
|
||||
"text/x-go": "page_white_code",
|
||||
};
|
||||
|
||||
var contentTypes = {
|
||||
"c9search": "text/x-c9search",
|
||||
|
||||
"js": "application/javascript",
|
||||
"json": "application/json",
|
||||
"run": "application/javascript",
|
||||
"build": "application/javascript",
|
||||
"css": "text/css",
|
||||
"scss": "text/x-scss",
|
||||
"sass": "text/x-sass",
|
||||
|
||||
"xml": "application/xml",
|
||||
"rdf": "application/rdf+xml",
|
||||
"rss": "application/rss+xml",
|
||||
"svg": "image/svg+xml",
|
||||
"wsdl": "application/wsdl+xml",
|
||||
"xslt": "application/xslt+xml",
|
||||
"atom": "application/atom+xml",
|
||||
"mathml": "application/mathml+xml",
|
||||
"mml": "application/mathml+xml",
|
||||
|
||||
"php": "application/x-httpd-php",
|
||||
"phtml": "application/x-httpd-php",
|
||||
"html": "text/html",
|
||||
"xhtml": "application/xhtml+xml",
|
||||
"coffee": "text/x-script.coffeescript",
|
||||
"py": "text/x-script.python",
|
||||
"go": "text/x-go",
|
||||
"java": "text/x-java-source",
|
||||
"logic": "text/x-logiql",
|
||||
|
||||
"ru": "text/x-script.ruby",
|
||||
"gemspec": "text/x-script.ruby",
|
||||
"rake": "text/x-script.ruby",
|
||||
"rb": "text/x-script.ruby",
|
||||
|
||||
"c": "text/x-c",
|
||||
"cc": "text/x-c",
|
||||
"cpp": "text/x-c",
|
||||
"cxx": "text/x-c",
|
||||
"h": "text/x-c",
|
||||
"hh": "text/x-c",
|
||||
"hpp": "text/x-c",
|
||||
|
||||
"c9search": "page_white_magnify",
|
||||
"js": "page_white_code",
|
||||
"jsx": "page_white_code_red",
|
||||
"ts": "page_white_code",
|
||||
"tsx": "page_white_code_red",
|
||||
"json": "page_white_code",
|
||||
"css": "css",
|
||||
"scss": "css",
|
||||
"sass": "css",
|
||||
"less": "css",
|
||||
"xml": "page_white_code_red",
|
||||
"svg": "page_white_picture",
|
||||
"php": "page_white_php",
|
||||
"phtml": "page_white_php",
|
||||
"html": "html",
|
||||
"xhtml": "html",
|
||||
"coffee": "page_white_cup",
|
||||
"py": "page_white_code",
|
||||
"go": "page_white_code",
|
||||
"java": "page_white_cup",
|
||||
"logic": "logiql",
|
||||
"ru": "page_white_ruby",
|
||||
"gemspec": "page_white_ruby",
|
||||
"rake": "page_white_ruby",
|
||||
"rb": "page_white_ruby",
|
||||
"c": "page_white_c",
|
||||
"cc": "page_white_c",
|
||||
"cpp": "page_white_cplusplus",
|
||||
"cxx": "page_white_c",
|
||||
"h": "page_white_h",
|
||||
"hh": "page_white_h",
|
||||
"hpp": "page_white_h",
|
||||
"bmp": "image",
|
||||
"djv": "image",
|
||||
"djvu": "image",
|
||||
|
@ -123,19 +81,32 @@ define(function(require, exports, module) {
|
|||
"tiff": "image",
|
||||
"xbm": "image",
|
||||
"xpm": "image",
|
||||
|
||||
"clj": "text/x-script.clojure",
|
||||
"ml": "text/x-script.ocaml",
|
||||
"mli": "text/x-script.ocaml",
|
||||
"cfm": "text/x-coldfusion",
|
||||
"sql": "text/x-sql",
|
||||
|
||||
"sh": "application/x-sh",
|
||||
"bash": "application/x-sh",
|
||||
|
||||
"xq": "text/x-xquery",
|
||||
|
||||
"terminal": "terminal"
|
||||
"pdf": "page_white_acrobat",
|
||||
"clj": "page_white_code",
|
||||
"ml": "page_white_code",
|
||||
"mli": "page_white_code",
|
||||
"cfm": "page_white_coldfusion",
|
||||
"sql": "page_white_database",
|
||||
"db": "page_white_database",
|
||||
"sh": "page_white_wrench",
|
||||
"bash": "page_white_wrench",
|
||||
"xq": "page_white_code",
|
||||
"xz": "page_white_zip",
|
||||
"gz": "page_white_zip",
|
||||
"bz": "page_white_zip",
|
||||
"zip": "page_white_zip",
|
||||
"tar": "page_white_zip",
|
||||
"rar": "page_white_compressed",
|
||||
"exe": "page_white_swoosh",
|
||||
"o": "page_white_swoosh",
|
||||
"lnk": "page_white_swoosh",
|
||||
"txt": "page_white_text",
|
||||
"settings": "page_white_gear",
|
||||
"run": "page_white_gear",
|
||||
"build": "page_white_gear",
|
||||
"gitignore": "page_white_gear",
|
||||
"profile": "page_white_gear",
|
||||
"bashrc": "page_white_gear",
|
||||
};
|
||||
|
||||
plugin.getFileIcon = function(name) {
|
||||
|
@ -144,7 +115,7 @@ define(function(require, exports, module) {
|
|||
|
||||
if (name) {
|
||||
ext = name.split(".").pop().toLowerCase();
|
||||
icon = SupportedIcons[contentTypes[ext]] || "page_white_text";
|
||||
icon = SupportedIcons[ext] || "page_white_text";
|
||||
}
|
||||
return icon;
|
||||
};
|
||||
|
@ -167,8 +138,8 @@ define(function(require, exports, module) {
|
|||
};
|
||||
|
||||
plugin.getContentType = function(filename) {
|
||||
var type = filename.split(".").pop().split("!").pop().toLowerCase() || "";
|
||||
return contentTypes[type] || "text/plain";
|
||||
console.warn("util content type is deprecated");
|
||||
return "text/plain";
|
||||
};
|
||||
|
||||
// taken from http://xregexp.com/
|
||||
|
|
|
@ -25,11 +25,7 @@ require(["lib/architect/architect", "lib/chai/chai"], function (architect, chai)
|
|||
function main(options, imports, register) {
|
||||
var util = imports.util;
|
||||
|
||||
describe('getContentType, getFileIcon', function() {
|
||||
it('should retrieve the content type based on a filename', function() {
|
||||
expect(util.getContentType("test.js")).to.equal("application/javascript");
|
||||
expect(util.getContentType("test.html")).to.equal("text/html");
|
||||
});
|
||||
describe('getFileIcon', function() {
|
||||
it('should retrieve the icon class name based on a filename', function() {
|
||||
expect(util.getFileIcon("test.js")).to.equal("page_white_code");
|
||||
expect(util.getFileIcon("test.html")).to.equal("html");
|
||||
|
|
|
@ -571,7 +571,6 @@ define(function(require, exports, module) {
|
|||
if (isFolder) {
|
||||
node.status = node.status || "pending";
|
||||
} else {
|
||||
node.contenttype = stat.mime || util.getContentType(name);
|
||||
node.status = "loaded";
|
||||
}
|
||||
if (typeof stat.mtime !== "number" && stat.mtime) {
|
||||
|
|
|
@ -2058,8 +2058,8 @@ define(function(require, exports, module) {
|
|||
else {
|
||||
tab.classList.remove("dark");
|
||||
html.style.boxShadow = skin.indexOf("flat") == -1
|
||||
"0 1px 0 0 rgba(255, 255, 255, .3) inset"
|
||||
"";
|
||||
? "0 1px 0 0 rgba(255, 255, 255, .3) inset"
|
||||
: "";
|
||||
}
|
||||
|
||||
html.style.backgroundColor = theme.bg;
|
||||
|
@ -2104,7 +2104,7 @@ define(function(require, exports, module) {
|
|||
value = false;
|
||||
|
||||
// Own Implementations
|
||||
switch(name) {
|
||||
switch (name) {
|
||||
case "theme":
|
||||
ace.setTheme(value);
|
||||
return;
|
||||
|
@ -2537,13 +2537,16 @@ define(function(require, exports, module) {
|
|||
|
||||
var data = ace.getCopyText();
|
||||
ace.onCut();
|
||||
e.clipboardData.setData("text/plain", data);
|
||||
data && e.clipboardData.setData("text/plain", data);
|
||||
});
|
||||
plugin.on("copy", function(e) {
|
||||
if (e.native) return; // Ace handles this herself
|
||||
|
||||
var data = ace.getCopyText();
|
||||
e.clipboardData.setData("text/plain", data);
|
||||
// check if user tries to copy text from line widget
|
||||
if (!data && document.activeElement != ace.textInput.getElement())
|
||||
data = document.getSelection().toString().replace(/\xa0/, " ");
|
||||
data && e.clipboardData.setData("text/plain", data);
|
||||
});
|
||||
plugin.on("paste", function(e) {
|
||||
if (e.native) return; // Ace handles this herself
|
||||
|
@ -2685,7 +2688,6 @@ define(function(require, exports, module) {
|
|||
else {
|
||||
return handle.theme;
|
||||
}
|
||||
return theme;
|
||||
},
|
||||
|
||||
_events: [
|
||||
|
|
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 934 B |
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 944 B |
|
@ -1,12 +1,16 @@
|
|||
BODY.loading{
|
||||
background: -moz-linear-gradient(top, rgba(255,255,255,1) 0%, rgba(251,251,251,1) 100%); /* FF3.6-15 */
|
||||
background: -webkit-linear-gradient(top, rgba(255,255,255,1) 0%,rgba(251,251,251,1) 100%); /* Chrome10-25,Safari5.1-6 */
|
||||
background: linear-gradient(to bottom, rgba(255,255,255,1) 0%,rgba(251,251,251,1) 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
|
||||
#loadingcontainer{
|
||||
background: url(images/loadingbgrepeat.png);
|
||||
background-size: 1px 8px;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
z-index: 200000;
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
BODY.loading.dark{
|
||||
background: -moz-linear-gradient(top, rgba(37,37,37,1) 0%, rgba(35,35,35,1) 100%); /* FF3.6-15 */
|
||||
background: -webkit-linear-gradient(top, rgba(37,37,37,1) 0%,rgba(35,35,35,1) 100%); /* Chrome10-25,Safari5.1-6 */
|
||||
background: linear-gradient(to bottom, rgba(37,37,37,1) 0%,rgba(35,35,35,1) 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
|
||||
#loadingcontainer.dark{
|
||||
background: url(images/loadingbgrepeat_dark.png);
|
||||
background-size: 1px 8px;
|
||||
}
|
||||
|
||||
#loadingide {
|
||||
|
@ -16,15 +20,15 @@ BODY.loading.dark{
|
|||
font-style: normal;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
text-align: center;
|
||||
position: absolute;
|
||||
z-index: 200000;
|
||||
left: 0;
|
||||
top: 0;
|
||||
text-align: center;
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale !important;
|
||||
}
|
||||
#loadingide.dark {
|
||||
.dark #loadingide{
|
||||
background-image: url(images/c9-logo-white.png);
|
||||
}
|
||||
|
||||
|
@ -118,14 +122,14 @@ BODY.loading.dark{
|
|||
width: 200px;
|
||||
text-align: center;
|
||||
top: 57%;
|
||||
margin-top: 200px;
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
#loadingide .cool-message {
|
||||
display: block;
|
||||
font-family: Arial;
|
||||
font-size: 30px;
|
||||
color: #A7A7A7;
|
||||
color: #717171;
|
||||
white-space: nowrap;
|
||||
position: absolute;
|
||||
top: 30%;
|
||||
|
@ -133,7 +137,7 @@ BODY.loading.dark{
|
|||
width: 1000px;
|
||||
text-align: center;
|
||||
margin-left: -500px;
|
||||
margin-top: 250px;
|
||||
margin-top: 350px;
|
||||
}
|
||||
#loadingide.dark .cool-message {
|
||||
color: #757575;
|
||||
|
@ -143,10 +147,14 @@ BODY.loading.dark{
|
|||
background: url(images/running_flat_light@2x.png);
|
||||
background-size: 300px 20px;
|
||||
animation: rotation 0.6s infinite steps(16);
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
width: 20px !important;
|
||||
height: 20px !important;
|
||||
background-repeat: no-repeat;
|
||||
display: inline-block;
|
||||
min-width: 20px !important;
|
||||
min-height: 20px !important;
|
||||
box-sizing: content-box;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
@-webkit-keyframes rotation { 0% { -webkit-transform: rotate(0deg); transform: rotate(0deg); } 100% {-webkit-transform: rotate(359deg); transform: rotate(359deg);}}
|
||||
|
|
|
@ -1,14 +1,16 @@
|
|||
<link rel="stylesheet" type="text/css" href="<%=staticPrefix%>/plugins/c9.ide.layout.classic/loading-flat.css" />
|
||||
<div id="loadingide" class="<%-: theme + (isDark ? " dark" : "") %>">
|
||||
<div class="cool-message"></div>
|
||||
<div class="status" style="display:none"><div class="spinner"></div></div>
|
||||
|
||||
<div id="content" class="loading-progress">
|
||||
</div>
|
||||
<div class="footer">
|
||||
<a href="https://docs.c9.io">Documentation</a> |
|
||||
<a href="http://status.c9.io">Server Status</a> |
|
||||
<a href="http://support.c9.io">Support</a>
|
||||
<div id="loadingcontainer" class="<%-: theme + (isDark ? " dark" : "") %>">
|
||||
<div id="loadingide">
|
||||
<div class="cool-message"></div>
|
||||
<div class="status" style="display:none"><div class="spinner"></div></div>
|
||||
|
||||
<div id="content" class="loading-progress">
|
||||
</div>
|
||||
<div class="footer">
|
||||
<a href="https://docs.c9.io">Documentation</a> |
|
||||
<a href="http://status.c9.io">Server Status</a> |
|
||||
<a href="http://support.c9.io">Support</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
|
@ -19,30 +21,24 @@
|
|||
"It's better up here.",
|
||||
"Happy coding!",
|
||||
"Everything as you left it.",
|
||||
"Give some love to your colleague on the left!",
|
||||
"Thank you Ada Lovelace!",
|
||||
"Feel the power of a full IDE — in the cloud.",
|
||||
"Code for the cloud, in the cloud",
|
||||
"Out with the old, in with the new",
|
||||
"POST /desktop/era",
|
||||
"#OnCloud9",
|
||||
"I ❤ Cloud9",
|
||||
"My life. My code. My Cloud9.",
|
||||
"For the love of code",
|
||||
"Get Your Code On",
|
||||
"Skip the hazing, love the coding",
|
||||
"Stop cursing, start coding",
|
||||
"GET /this/workspace#loaded",
|
||||
"Use our Vim mode for extra addictive effect!",
|
||||
"Not your grandmother's IDE",
|
||||
"Now made with 20% more cloud!",
|
||||
"Literally makes your laptop cooler",
|
||||
"Makes your laptop cooler"
|
||||
];
|
||||
|
||||
var idx = Math.floor(Math.random() * messages.length);
|
||||
if (idx == messages.length) idx = messages.length - 1;
|
||||
document.querySelector("#loadingide .cool-message").innerHTML =
|
||||
messages[idx];
|
||||
var msg = messages[idx];
|
||||
|
||||
if (~location.hash.indexOf("create")) {
|
||||
msg = "Creating Your New Workspace";
|
||||
location.hash = location.hash.replace(/&?create/, "");
|
||||
}
|
||||
|
||||
document.querySelector("#loadingide .cool-message").innerHTML = msg;
|
||||
|
||||
setTimeout(function(){
|
||||
var s = document.querySelector("#loadingide .status");
|
||||
|
@ -50,7 +46,7 @@
|
|||
}, 2000);
|
||||
|
||||
window.hideLoader = function(){
|
||||
var loader = document.getElementById("loadingide");
|
||||
var loader = document.getElementById("loadingcontainer");
|
||||
loader.parentNode.removeChild(loader);
|
||||
|
||||
document.body.className = document.body.className.replace("loading " + loadingIde.className, "");
|
||||
|
|
|
@ -285,8 +285,7 @@ define(function(require, exports, module) {
|
|||
*
|
||||
* Example:
|
||||
*
|
||||
* anims.animateMultiple({
|
||||
* node : someDiv,
|
||||
* anims.animate(node, {
|
||||
* width : "200px",
|
||||
* height : "300px"
|
||||
* }, function(){});
|
||||
|
|
|
@ -87,7 +87,7 @@ define(function(require, exports, module) {
|
|||
|
||||
// first time take the ones from the options
|
||||
var _servers = servers;
|
||||
if (_servers) {
|
||||
if (_servers && _servers.length) {
|
||||
servers = null;
|
||||
return callback(null, _servers);
|
||||
}
|
||||
|
|
|
@ -101,13 +101,23 @@
|
|||
|
||||
// For Development only
|
||||
function done(){
|
||||
app.services.c9.ready();
|
||||
app.services.c9.totalLoadTime = Date.now() - start;
|
||||
var vfs = app.services.vfs;
|
||||
var c9 = app.services.c9;
|
||||
|
||||
c9.ready();
|
||||
c9.totalLoadTime = Date.now() - start;
|
||||
|
||||
console.warn("Total Load Time: ", Date.now() - start);
|
||||
|
||||
if (window.hideLoader)
|
||||
window.hideLoader();
|
||||
if (window.hideLoader) {
|
||||
if (vfs.connected)
|
||||
window.hideLoader();
|
||||
else {
|
||||
vfs.once("connect", function(){
|
||||
window.hideLoader();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}, function loadError(mod) {
|
||||
if (mod.id === "plugins/c9.ide.clipboard/html5")
|
||||
|
|
Ładowanie…
Reference in New Issue