| 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 * Copyright (C) 2014 Opera Software ASA. All rights reserved. | 4 * Copyright (C) 2014 Opera Software ASA. All rights reserved. |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions are | 7 * modification, are permitted provided that the following conditions are |
| 8 * met: | 8 * met: |
| 9 * | 9 * |
| 10 * * Redistributions of source code must retain the above copyright | 10 * * Redistributions of source code must retain the above copyright |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 #include "wtf/text/StringBuilder.h" | 82 #include "wtf/text/StringBuilder.h" |
| 83 #include "wtf/text/TextPosition.h" | 83 #include "wtf/text/TextPosition.h" |
| 84 | 84 |
| 85 namespace blink { | 85 namespace blink { |
| 86 | 86 |
| 87 bool ScriptController::canAccessFromCurrentOrigin(LocalFrame *frame) | 87 bool ScriptController::canAccessFromCurrentOrigin(LocalFrame *frame) |
| 88 { | 88 { |
| 89 if (!frame) | 89 if (!frame) |
| 90 return false; | 90 return false; |
| 91 v8::Isolate* isolate = toIsolate(frame); | 91 v8::Isolate* isolate = toIsolate(frame); |
| 92 return !isolate->InContext() || BindingSecurity::shouldAllowAccessToFrame(is
olate, callingDOMWindow(isolate), frame); | 92 return !isolate->InContext() || BindingSecurity::shouldAllowAccessToFrame(is
olate, callingDOMWindow(isolate), frame, ReportSecurityError); |
| 93 } | 93 } |
| 94 | 94 |
| 95 ScriptController::ScriptController(LocalFrame* frame) | 95 ScriptController::ScriptController(LocalFrame* frame) |
| 96 : m_windowProxyManager(WindowProxyManager::create(*frame)) | 96 : m_windowProxyManager(WindowProxyManager::create(*frame)) |
| 97 , m_sourceURL(0) | 97 , m_sourceURL(0) |
| 98 , m_windowScriptNPObject(0) | 98 , m_windowScriptNPObject(0) |
| 99 { | 99 { |
| 100 } | 100 } |
| 101 | 101 |
| 102 ScriptController::~ScriptController() | 102 ScriptController::~ScriptController() |
| (...skipping 494 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 597 for (size_t i = 0; i < resultArray->Length(); ++i) { | 597 for (size_t i = 0; i < resultArray->Length(); ++i) { |
| 598 v8::Local<v8::Value> value; | 598 v8::Local<v8::Value> value; |
| 599 if (!resultArray->Get(scriptState->context(), i).ToLocal(&value)) | 599 if (!resultArray->Get(scriptState->context(), i).ToLocal(&value)) |
| 600 return; | 600 return; |
| 601 results->append(value); | 601 results->append(value); |
| 602 } | 602 } |
| 603 } | 603 } |
| 604 } | 604 } |
| 605 | 605 |
| 606 } // namespace blink | 606 } // namespace blink |
| OLD | NEW |