diff options
author | Ananya Sen | 2012-02-18 18:49:45 -0800 |
---|---|---|
committer | Ananya Sen | 2012-02-18 18:49:45 -0800 |
commit | 8fdce771bfcf662cf1acc16d45e4361ffd06c53e (patch) | |
tree | 4ac283e0e7724e5ede21c1a1e97d121033578c72 /js/document | |
parent | c2a5918480adae0124e1dc2531c019562f1e3e60 (diff) | |
parent | e23708721a71ca4c71365f5f8e8ac7d6113926db (diff) | |
download | ninja-8fdce771bfcf662cf1acc16d45e4361ffd06c53e.tar.gz |
Merge branch 'refs/heads/FileIO-jose' into FileIO
Conflicts:
js/controllers/document-controller.js
Signed-off-by: Ananya Sen <Ananya.Sen@motorola.com>
Diffstat (limited to 'js/document')
-rwxr-xr-x | js/document/html-document.js | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/js/document/html-document.js b/js/document/html-document.js index ae2b4600..77cc711d 100755 --- a/js/document/html-document.js +++ b/js/document/html-document.js | |||
@@ -363,6 +363,9 @@ exports.HTMLDocument = Montage.create(TextDocument, { | |||
363 | // | 363 | // |
364 | handleEvent: { | 364 | handleEvent: { |
365 | value: function(event){ | 365 | value: function(event){ |
366 | //TODO: Remove | ||
367 | window.hackPreview = this.livePreview.bind(this); | ||
368 | |||
366 | this.application.ninja.documentController._hackRootFlag = true; | 369 | this.application.ninja.documentController._hackRootFlag = true; |
367 | //console.log(this._userDocument.root, this); | 370 | //console.log(this._userDocument.root, this); |
368 | //TODO: Clean up, using for prototyping save | 371 | //TODO: Clean up, using for prototyping save |
@@ -471,6 +474,48 @@ exports.HTMLDocument = Montage.create(TextDocument, { | |||
471 | } | 474 | } |
472 | }, | 475 | }, |
473 | 476 | ||
477 | |||
478 | |||
479 | |||
480 | |||
481 | |||
482 | |||
483 | |||
484 | |||
485 | |||
486 | |||
487 | |||
488 | |||
489 | |||
490 | |||
491 | |||
492 | |||
493 | |||
494 | |||
495 | |||
496 | |||
497 | |||
498 | |||
499 | //////////////////////////////////////////////////////////////////// | ||
500 | // | ||
501 | livePreview: { | ||
502 | enumerable: false, | ||
503 | value: function () { | ||
504 | //this.application.ninja.documentController | ||
505 | //console.log(this.application.ninja.coreIoApi.rootUrl+this.application.ninja.documentController._activeDocument.uri.split(this.application.ninja.coreIoApi.cloudData.root)[1]); | ||
506 | chrome.tabs.create({url: this.application.ninja.coreIoApi.rootUrl+this.application.ninja.documentController._activeDocument.uri.split(this.application.ninja.coreIoApi.cloudData.root)[1]}); | ||
507 | } | ||
508 | }, | ||
509 | //////////////////////////////////////////////////////////////////// | ||
510 | |||
511 | |||
512 | |||
513 | |||
514 | |||
515 | |||
516 | |||
517 | |||
518 | |||
474 | //////////////////////////////////////////////////////////////////// | 519 | //////////////////////////////////////////////////////////////////// |
475 | // | 520 | // |
476 | save: { | 521 | save: { |