| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. 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 * * Neither the name of Google Inc. nor the names of its | 10 * * Neither the name of Google Inc. nor the names of its |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 class ScriptCallStack; | 43 class ScriptCallStack; |
| 44 class ScriptState; | 44 class ScriptState; |
| 45 class SecurityContext; | 45 class SecurityContext; |
| 46 | 46 |
| 47 class ExecutionContextClient { | 47 class ExecutionContextClient { |
| 48 public: | 48 public: |
| 49 virtual void postTask(PassOwnPtr<ExecutionContextTask>) = 0; // Executes the
task on context's thread asynchronously. | 49 virtual void postTask(PassOwnPtr<ExecutionContextTask>) = 0; // Executes the
task on context's thread asynchronously. |
| 50 | 50 |
| 51 virtual bool isDocument() const { return false; } | 51 virtual bool isDocument() const { return false; } |
| 52 virtual bool isWorkerGlobalScope() const { return false; } | 52 virtual bool isWorkerGlobalScope() const { return false; } |
| 53 virtual bool isDedicatedWorkerGlobalScope() const { return false; } |
| 54 virtual bool isSharedWorkerGlobalScope() const { return false; } |
| 55 virtual bool isServiceWorkerGlobalScope() const { return false; } |
| 53 virtual bool isJSExecutionForbidden() const = 0; | 56 virtual bool isJSExecutionForbidden() const = 0; |
| 54 virtual LocalDOMWindow* executingWindow() { return 0; } | 57 virtual LocalDOMWindow* executingWindow() { return 0; } |
| 55 virtual String userAgent(const KURL&) const = 0; | 58 virtual String userAgent(const KURL&) const = 0; |
| 56 virtual void disableEval(const String& errorMessage) = 0; | 59 virtual void disableEval(const String& errorMessage) = 0; |
| 57 virtual SecurityContext& securityContext() = 0; | 60 virtual SecurityContext& securityContext() = 0; |
| 58 virtual void addMessage(PassRefPtrWillBeRawPtr<ConsoleMessage>) = 0; | 61 virtual void addMessage(PassRefPtrWillBeRawPtr<ConsoleMessage>) = 0; |
| 59 virtual EventTarget* errorEventTarget() = 0; | 62 virtual EventTarget* errorEventTarget() = 0; |
| 60 virtual void logExceptionToConsole(const String& errorMessage, const String&
sourceURL, int lineNumber, int columnNumber, PassRefPtrWillBeRawPtr<ScriptCallS
tack>) = 0; | 63 virtual void logExceptionToConsole(const String& errorMessage, const String&
sourceURL, int lineNumber, int columnNumber, PassRefPtrWillBeRawPtr<ScriptCallS
tack>) = 0; |
| 61 virtual double timerAlignmentInterval() const = 0; | 64 virtual double timerAlignmentInterval() const = 0; |
| 62 virtual void didUpdateSecurityOrigin() = 0; | 65 virtual void didUpdateSecurityOrigin() = 0; |
| 63 | 66 |
| 64 virtual void tasksWereSuspended() { } | 67 virtual void tasksWereSuspended() { } |
| 65 virtual void tasksWereResumed() { } | 68 virtual void tasksWereResumed() { } |
| 66 | 69 |
| 67 void addConsoleMessage(PassRefPtrWillBeRawPtr<ConsoleMessage> consoleMessage
) { addMessage(consoleMessage); } | 70 void addConsoleMessage(PassRefPtrWillBeRawPtr<ConsoleMessage> consoleMessage
) { addMessage(consoleMessage); } |
| 68 | 71 |
| 69 protected: | 72 protected: |
| 70 virtual ~ExecutionContextClient() { } | 73 virtual ~ExecutionContextClient() { } |
| 71 | 74 |
| 72 }; | 75 }; |
| 73 | 76 |
| 74 | 77 |
| 75 } // namespace | 78 } // namespace |
| 76 | 79 |
| 77 #endif | 80 #endif |
| OLD | NEW |