| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
| 3 * Copyright (C) 2012 Google Inc. All Rights Reserved. | 3 * Copyright (C) 2012 Google 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 | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 virtual bool isSharedWorkerGlobalScope() const { return false; } | 62 virtual bool isSharedWorkerGlobalScope() const { return false; } |
| 63 virtual bool isServiceWorkerGlobalScope() const { return false; } | 63 virtual bool isServiceWorkerGlobalScope() const { return false; } |
| 64 virtual bool isJSExecutionForbidden() const { return false; } | 64 virtual bool isJSExecutionForbidden() const { return false; } |
| 65 SecurityOrigin* securityOrigin(); | 65 SecurityOrigin* securityOrigin(); |
| 66 ContentSecurityPolicy* contentSecurityPolicy(); | 66 ContentSecurityPolicy* contentSecurityPolicy(); |
| 67 const KURL& url() const; | 67 const KURL& url() const; |
| 68 KURL completeURL(const String& url) const; | 68 KURL completeURL(const String& url) const; |
| 69 virtual void disableEval(const String& errorMessage) = 0; | 69 virtual void disableEval(const String& errorMessage) = 0; |
| 70 virtual LocalDOMWindow* executingWindow() { return 0; } | 70 virtual LocalDOMWindow* executingWindow() { return 0; } |
| 71 virtual String userAgent(const KURL&) const = 0; | 71 virtual String userAgent(const KURL&) const = 0; |
| 72 virtual void postTask(const WebTraceLocation&, PassOwnPtr<ExecutionContextTa
sk>) = 0; // Executes the task on context's thread asynchronously. | 72 virtual void postTask(PassOwnPtr<ExecutionContextTask>) = 0; // Executes the
task on context's thread asynchronously. |
| 73 virtual double timerAlignmentInterval() const = 0; | 73 virtual double timerAlignmentInterval() const = 0; |
| 74 | 74 |
| 75 // Gets the DOMTimerCoordinator which maintains the "active timer | 75 // Gets the DOMTimerCoordinator which maintains the "active timer |
| 76 // list" of tasks created by setTimeout and setInterval. The | 76 // list" of tasks created by setTimeout and setInterval. The |
| 77 // DOMTimerCoordinator is owned by the ExecutionContext and should | 77 // DOMTimerCoordinator is owned by the ExecutionContext and should |
| 78 // not be used after the ExecutionContext is destroyed. | 78 // not be used after the ExecutionContext is destroyed. |
| 79 virtual DOMTimerCoordinator* timers() = 0; | 79 virtual DOMTimerCoordinator* timers() = 0; |
| 80 | 80 |
| 81 virtual void reportBlockedScriptExecutionToInspector(const String& directive
Text) = 0; | 81 virtual void reportBlockedScriptExecutionToInspector(const String& directive
Text) = 0; |
| 82 | 82 |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 // Counter that keeps track of how many window interaction calls are allowed | 167 // Counter that keeps track of how many window interaction calls are allowed |
| 168 // for this ExecutionContext. Callers are expected to call | 168 // for this ExecutionContext. Callers are expected to call |
| 169 // |allowWindowInteraction()| and |consumeWindowInteraction()| in order to | 169 // |allowWindowInteraction()| and |consumeWindowInteraction()| in order to |
| 170 // increment and decrement the counter. | 170 // increment and decrement the counter. |
| 171 int m_windowInteractionTokens; | 171 int m_windowInteractionTokens; |
| 172 }; | 172 }; |
| 173 | 173 |
| 174 } // namespace blink | 174 } // namespace blink |
| 175 | 175 |
| 176 #endif // ExecutionContext_h | 176 #endif // ExecutionContext_h |
| OLD | NEW |