OLD | NEW |
1 // Copyright (c) 2008, Google Inc. | 1 // Copyright (c) 2008, Google Inc. |
2 // All rights reserved. | 2 // All rights reserved. |
3 // | 3 // |
4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
6 // met: | 6 // met: |
7 // | 7 // |
8 // * Redistributions of source code must retain the above copyright | 8 // * Redistributions of source code must retain the above copyright |
9 // notice, this list of conditions and the following disclaimer. | 9 // notice, this list of conditions and the following disclaimer. |
10 // * Redistributions in binary form must reproduce the above | 10 // * Redistributions in binary form must reproduce the above |
(...skipping 21 matching lines...) Expand all Loading... |
32 #include "V8NPUtils.h" | 32 #include "V8NPUtils.h" |
33 | 33 |
34 #include "DOMWindow.h" | 34 #include "DOMWindow.h" |
35 #include "Frame.h" | 35 #include "Frame.h" |
36 #include "PlatformString.h" | 36 #include "PlatformString.h" |
37 #undef LOG | 37 #undef LOG |
38 | 38 |
39 #include "npruntime_priv.h" | 39 #include "npruntime_priv.h" |
40 #include "NPV8Object.h" | 40 #include "NPV8Object.h" |
41 #include "V8NPObject.h" | 41 #include "V8NPObject.h" |
42 #include "v8_proxy.h" | 42 #include "V8Proxy.h" |
43 | 43 |
44 void convertV8ObjectToNPVariant(v8::Local<v8::Value> object, NPObject *owner, NP
Variant* result) | 44 void convertV8ObjectToNPVariant(v8::Local<v8::Value> object, NPObject *owner, NP
Variant* result) |
45 { | 45 { |
46 VOID_TO_NPVARIANT(*result); | 46 VOID_TO_NPVARIANT(*result); |
47 | 47 |
48 // It is really the caller's responsibility to deal with the empty handle | 48 // It is really the caller's responsibility to deal with the empty handle |
49 // case because there could be different actions to take in different | 49 // case because there could be different actions to take in different |
50 // contexts. | 50 // contexts. |
51 ASSERT(!object.IsEmpty()); | 51 ASSERT(!object.IsEmpty()); |
52 | 52 |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 // Here we should only use the stack space for stack_buf when it's used, | 115 // Here we should only use the stack space for stack_buf when it's used, |
116 // not when we use the heap. | 116 // not when we use the heap. |
117 char stackBuf[kStackBufSize]; | 117 char stackBuf[kStackBufSize]; |
118 str->WriteAscii(stackBuf); | 118 str->WriteAscii(stackBuf); |
119 return NPN_GetStringIdentifier(stackBuf); | 119 return NPN_GetStringIdentifier(stackBuf); |
120 } | 120 } |
121 | 121 |
122 v8::String::AsciiValue ascii(str); | 122 v8::String::AsciiValue ascii(str); |
123 return NPN_GetStringIdentifier(*ascii); | 123 return NPN_GetStringIdentifier(*ascii); |
124 } | 124 } |
OLD | NEW |