diff options
author | dsinclair <dsinclair@chromium.org> | 2016-06-09 13:24:34 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-06-09 13:24:34 -0700 |
commit | 8bd9ce00a0755d72c9b5b8ad43d8f50c2f51e5c5 (patch) | |
tree | 9dd3a72354f353694cc52747acabf297a10251a3 /xfa/fxjse/scope_inline.h | |
parent | 3cace320e07bb954710c50fc7634ca3a8f3eda38 (diff) | |
download | pdfium-8bd9ce00a0755d72c9b5b8ad43d8f50c2f51e5c5.tar.xz |
Move xfa/fxjse/ to fxjse/
This makes it clear that fxjse/ is a standalone component and should not be
entangled with other xfa/ components.
BUG=pdfium:506
Review-Url: https://codereview.chromium.org/2056663004
Diffstat (limited to 'xfa/fxjse/scope_inline.h')
-rw-r--r-- | xfa/fxjse/scope_inline.h | 77 |
1 files changed, 0 insertions, 77 deletions
diff --git a/xfa/fxjse/scope_inline.h b/xfa/fxjse/scope_inline.h deleted file mode 100644 index 8ef9c85530..0000000000 --- a/xfa/fxjse/scope_inline.h +++ /dev/null @@ -1,77 +0,0 @@ -// Copyright 2014 PDFium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com - -#ifndef XFA_FXJSE_SCOPE_INLINE_H_ -#define XFA_FXJSE_SCOPE_INLINE_H_ - -#include "xfa/fxjse/context.h" -#include "xfa/fxjse/runtime.h" - -class CFXJSE_ScopeUtil_IsolateHandle { - public: - explicit CFXJSE_ScopeUtil_IsolateHandle(v8::Isolate* pIsolate) - : m_isolate(pIsolate), - m_iscope(pIsolate), - m_hscope(pIsolate) {} - v8::Isolate* GetIsolate() { return m_isolate; } - - private: - CFXJSE_ScopeUtil_IsolateHandle(const CFXJSE_ScopeUtil_IsolateHandle&) = - delete; - void operator=(const CFXJSE_ScopeUtil_IsolateHandle&) = delete; - void* operator new(size_t size) = delete; - void operator delete(void*, size_t) = delete; - - v8::Isolate* m_isolate; - v8::Isolate::Scope m_iscope; - v8::HandleScope m_hscope; -}; - -class CFXJSE_ScopeUtil_IsolateHandleRootContext { - public: - explicit CFXJSE_ScopeUtil_IsolateHandleRootContext(v8::Isolate* pIsolate) - : m_parent(pIsolate), - m_cscope(v8::Local<v8::Context>::New( - pIsolate, - CFXJSE_RuntimeData::Get(pIsolate)->m_hRootContext)) {} - - private: - CFXJSE_ScopeUtil_IsolateHandleRootContext( - const CFXJSE_ScopeUtil_IsolateHandleRootContext&) = delete; - void operator=(const CFXJSE_ScopeUtil_IsolateHandleRootContext&) = delete; - void* operator new(size_t size) = delete; - void operator delete(void*, size_t) = delete; - - CFXJSE_ScopeUtil_IsolateHandle m_parent; - v8::Context::Scope m_cscope; -}; - -class CFXJSE_ScopeUtil_IsolateHandleContext { - public: - explicit CFXJSE_ScopeUtil_IsolateHandleContext(CFXJSE_Context* pContext) - : m_context(pContext), - m_parent(pContext->m_pIsolate), - m_cscope(v8::Local<v8::Context>::New(pContext->m_pIsolate, - pContext->m_hContext)) {} - v8::Isolate* GetIsolate() { return m_context->m_pIsolate; } - v8::Local<v8::Context> GetLocalContext() { - return v8::Local<v8::Context>::New(m_context->m_pIsolate, - m_context->m_hContext); - } - - private: - CFXJSE_ScopeUtil_IsolateHandleContext( - const CFXJSE_ScopeUtil_IsolateHandleContext&) = delete; - void operator=(const CFXJSE_ScopeUtil_IsolateHandleContext&) = delete; - void* operator new(size_t size) = delete; - void operator delete(void*, size_t) = delete; - - CFXJSE_Context* m_context; - CFXJSE_ScopeUtil_IsolateHandle m_parent; - v8::Context::Scope m_cscope; -}; - -#endif // XFA_FXJSE_SCOPE_INLINE_H_ |