diff options
author | Armen Kesablyan | 2012-06-19 00:45:26 -0700 |
---|---|---|
committer | Armen Kesablyan | 2012-06-19 00:45:26 -0700 |
commit | c59eb371559a3061ce53223e249ca97daace5968 (patch) | |
tree | f9540e26c0f273d35f92010605da65dd85bbe70c /js/document/document-html.js | |
parent | 0f040acabfb7a4bf3138debec5aff869487ceb11 (diff) | |
parent | 918a4f5870e972b6e4e301c3237e065a1ffd26f5 (diff) | |
download | ninja-c59eb371559a3061ce53223e249ca97daace5968.tar.gz |
Merge branch 'master' of github.com:Motorola-Mobility/ninja-internal
Diffstat (limited to 'js/document/document-html.js')
-rwxr-xr-x | js/document/document-html.js | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/js/document/document-html.js b/js/document/document-html.js index 04565753..b9c8e797 100755 --- a/js/document/document-html.js +++ b/js/document/document-html.js | |||
@@ -36,7 +36,7 @@ exports.HtmlDocument = Montage.create(Component, { | |||
36 | //////////////////////////////////////////////////////////////////// | 36 | //////////////////////////////////////////////////////////////////// |
37 | // | 37 | // |
38 | exclusionList: { | 38 | exclusionList: { |
39 | value: ["HTML", "BODY", "NINJA-CONTENT"] | 39 | value: ["HTML", "BODY", "NINJA-CONTENT", "NINJA-VIEWPORT"] |
40 | }, | 40 | }, |
41 | //////////////////////////////////////////////////////////////////// | 41 | //////////////////////////////////////////////////////////////////// |
42 | // | 42 | // |
@@ -107,6 +107,12 @@ exports.HtmlDocument = Montage.create(Component, { | |||
107 | }, | 107 | }, |
108 | handleViewReady: { | 108 | handleViewReady: { |
109 | value: function() { | 109 | value: function() { |
110 | // TODO: Find a better way to initialize this property | ||
111 | // Assign the domContainer to be the document root on open | ||
112 | if(typeof this.model.domContainer !== "undefined") { | ||
113 | this.model.domContainer = this.model.documentRoot; | ||
114 | } | ||
115 | |||
110 | //Making callback after view is loaded | 116 | //Making callback after view is loaded |
111 | this.loaded.callback.call(this.loaded.context, this); | 117 | this.loaded.callback.call(this.loaded.context, this); |
112 | } | 118 | } |
@@ -115,10 +121,8 @@ exports.HtmlDocument = Montage.create(Component, { | |||
115 | // | 121 | // |
116 | closeDocument: { | 122 | closeDocument: { |
117 | value: function (context, callback) { | 123 | value: function (context, callback) { |
118 | //Closing document and getting outcome | 124 | //Closing document (sending null to close all views) |
119 | var closed = this.model.close(null); | 125 | this.model.close(null, function () {if (callback) callback.call(context, this);}.bind(this)); |
120 | //Making callback if specified | ||
121 | if (callback) callback.call(context, this); | ||
122 | } | 126 | } |
123 | }, | 127 | }, |
124 | //////////////////////////////////////////////////////////////////// | 128 | //////////////////////////////////////////////////////////////////// |