OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 "use strict"; | 5 "use strict"; |
6 | 6 |
7 installClass("PrivateScriptTest", function(global) { | 7 installClass("PrivateScriptTest", function(global) { |
8 var InternalsPrototype = Object.create(Element.prototype); | 8 var InternalsPrototype = Object.create(Element.prototype); |
9 | 9 |
10 InternalsPrototype.initialize = function() { | 10 InternalsPrototype.initialize = function() { |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 | 122 |
123 InternalsPrototype.addIntegerForPrivateScriptOnly = function(value1, value2)
{ | 123 InternalsPrototype.addIntegerForPrivateScriptOnly = function(value1, value2)
{ |
124 return value1 + value2; | 124 return value1 + value2; |
125 } | 125 } |
126 | 126 |
127 Object.defineProperty(InternalsPrototype, "stringAttributeForPrivateScriptOn
ly", { | 127 Object.defineProperty(InternalsPrototype, "stringAttributeForPrivateScriptOn
ly", { |
128 get: function() { return this.m_stringAttributeForPrivateScriptOnly; }, | 128 get: function() { return this.m_stringAttributeForPrivateScriptOnly; }, |
129 set: function(value) { this.m_stringAttributeForPrivateScriptOnly = valu
e; } | 129 set: function(value) { this.m_stringAttributeForPrivateScriptOnly = valu
e; } |
130 }); | 130 }); |
131 | 131 |
| 132 InternalsPrototype.addIntegerImplementedInCPP = function(value1, value2) { |
| 133 return this.addIntegerImplementedInCPPForPrivateScriptOnly(value1, value
2); |
| 134 } |
| 135 |
| 136 Object.defineProperty(InternalsPrototype, "stringAttributeImplementedInCPP",
{ |
| 137 get: function() { return this.m_stringAttributeImplementedInCPPForPrivat
eScriptOnly; }, |
| 138 set: function(value) { this.m_stringAttributeImplementedInCPPForPrivateS
criptOnly = value; } |
| 139 }); |
| 140 |
132 return InternalsPrototype; | 141 return InternalsPrototype; |
133 }); | 142 }); |
OLD | NEW |