OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved. |
3 * Copyright (C) 2009 Apple Inc. All rights reserved. | 3 * Copyright (C) 2009 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 #include "platform/Widget.h" | 72 #include "platform/Widget.h" |
73 #include "platform/weborigin/SecurityOrigin.h" | 73 #include "platform/weborigin/SecurityOrigin.h" |
74 #include "public/platform/Platform.h" | 74 #include "public/platform/Platform.h" |
75 #include "wtf/CurrentTime.h" | 75 #include "wtf/CurrentTime.h" |
76 #include "wtf/StdLibExtras.h" | 76 #include "wtf/StdLibExtras.h" |
77 #include "wtf/StringExtras.h" | 77 #include "wtf/StringExtras.h" |
78 #include "wtf/text/CString.h" | 78 #include "wtf/text/CString.h" |
79 #include "wtf/text/StringBuilder.h" | 79 #include "wtf/text/StringBuilder.h" |
80 #include "wtf/text/TextPosition.h" | 80 #include "wtf/text/TextPosition.h" |
81 | 81 |
82 namespace WebCore { | 82 namespace blink { |
83 | 83 |
84 bool ScriptController::canAccessFromCurrentOrigin(LocalFrame *frame) | 84 bool ScriptController::canAccessFromCurrentOrigin(LocalFrame *frame) |
85 { | 85 { |
86 if (!frame) | 86 if (!frame) |
87 return false; | 87 return false; |
88 v8::Isolate* isolate = toIsolate(frame); | 88 v8::Isolate* isolate = toIsolate(frame); |
89 return !isolate->InContext() || BindingSecurity::shouldAllowAccessToFrame(is
olate, frame); | 89 return !isolate->InContext() || BindingSecurity::shouldAllowAccessToFrame(is
olate, frame); |
90 } | 90 } |
91 | 91 |
92 ScriptController::ScriptController(LocalFrame* frame) | 92 ScriptController::ScriptController(LocalFrame* frame) |
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
627 evaluationResult = v8::Local<v8::Value>::New(m_isolate, v8::Undefine
d(m_isolate)); | 627 evaluationResult = v8::Local<v8::Value>::New(m_isolate, v8::Undefine
d(m_isolate)); |
628 resultArray->Set(i, evaluationResult); | 628 resultArray->Set(i, evaluationResult); |
629 } | 629 } |
630 | 630 |
631 if (results) { | 631 if (results) { |
632 for (size_t i = 0; i < resultArray->Length(); ++i) | 632 for (size_t i = 0; i < resultArray->Length(); ++i) |
633 results->append(handleScope.Escape(resultArray->Get(i))); | 633 results->append(handleScope.Escape(resultArray->Get(i))); |
634 } | 634 } |
635 } | 635 } |
636 | 636 |
637 } // namespace WebCore | 637 } // namespace blink |
OLD | NEW |