| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 m_threadSafeIsolateWrapper = threadSafeIsolateWrapper; | 79 m_threadSafeIsolateWrapper = threadSafeIsolateWrapper; |
| 80 } | 80 } |
| 81 | 81 |
| 82 PassRefPtr<ThreadSafeDartIsolateWrapper> DartDOMData::threadSafeIsolateWrapper() | 82 PassRefPtr<ThreadSafeDartIsolateWrapper> DartDOMData::threadSafeIsolateWrapper() |
| 83 { | 83 { |
| 84 ASSERT(m_threadSafeIsolateWrapper); | 84 ASSERT(m_threadSafeIsolateWrapper); |
| 85 MutexLocker locker(m_isolateWrapperMutex); | 85 MutexLocker locker(m_isolateWrapperMutex); |
| 86 return m_threadSafeIsolateWrapper; | 86 return m_threadSafeIsolateWrapper; |
| 87 } | 87 } |
| 88 | 88 |
| 89 void DartDOMData::addCustomElementBinding(CustomElementDefinition* definition, P
assOwnPtr<DartCustomElementBinding> binding) |
| 90 { |
| 91 ASSERT(!m_customElementBindings.contains(definition)); |
| 92 m_customElementBindings.add(definition, binding); |
| 89 } | 93 } |
| 94 |
| 95 void DartDOMData::clearCustomElementBinding(CustomElementDefinition* definition) |
| 96 { |
| 97 DartCustomElementBindingMap::iterator it = m_customElementBindings.find(defi
nition); |
| 98 ASSERT(it != m_customElementBindings.end()); |
| 99 m_customElementBindings.remove(it); |
| 100 } |
| 101 |
| 102 DartCustomElementBinding* DartDOMData::customElementBinding(CustomElementDefinit
ion* definition) |
| 103 { |
| 104 DartCustomElementBindingMap::const_iterator it = m_customElementBindings.fin
d(definition); |
| 105 ASSERT(it != m_customElementBindings.end()); |
| 106 return it->value.get(); |
| 107 } |
| 108 |
| 109 } |
| OLD | NEW |