| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009 Apple 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 | 28 |
| 29 #include "core/events/ThreadLocalEventNames.h" | 29 #include "core/events/ThreadLocalEventNames.h" |
| 30 #include "core/storage/Storage.h" | 30 #include "core/storage/Storage.h" |
| 31 | 31 |
| 32 namespace WebCore { | 32 namespace WebCore { |
| 33 | 33 |
| 34 StorageEventInit::StorageEventInit() | 34 StorageEventInit::StorageEventInit() |
| 35 { | 35 { |
| 36 } | 36 } |
| 37 | 37 |
| 38 PassRefPtrWillBeRawPtr<StorageEvent> StorageEvent::create() | 38 PassRefPtr<StorageEvent> StorageEvent::create() |
| 39 { | 39 { |
| 40 return adoptRefWillBeRefCountedGarbageCollected(new StorageEvent); | 40 return adoptRef(new StorageEvent); |
| 41 } | 41 } |
| 42 | 42 |
| 43 StorageEvent::StorageEvent() | 43 StorageEvent::StorageEvent() |
| 44 { | 44 { |
| 45 ScriptWrappable::init(this); | 45 ScriptWrappable::init(this); |
| 46 } | 46 } |
| 47 | 47 |
| 48 StorageEvent::~StorageEvent() | 48 StorageEvent::~StorageEvent() |
| 49 { | 49 { |
| 50 } | 50 } |
| 51 | 51 |
| 52 PassRefPtrWillBeRawPtr<StorageEvent> StorageEvent::create(const AtomicString& ty
pe, const String& key, const String& oldValue, const String& newValue, const Str
ing& url, Storage* storageArea) | 52 PassRefPtr<StorageEvent> StorageEvent::create(const AtomicString& type, const St
ring& key, const String& oldValue, const String& newValue, const String& url, St
orage* storageArea) |
| 53 { | 53 { |
| 54 return adoptRefWillBeRefCountedGarbageCollected(new StorageEvent(type, key,
oldValue, newValue, url, storageArea)); | 54 return adoptRef(new StorageEvent(type, key, oldValue, newValue, url, storage
Area)); |
| 55 } | 55 } |
| 56 | 56 |
| 57 PassRefPtrWillBeRawPtr<StorageEvent> StorageEvent::create(const AtomicString& ty
pe, const StorageEventInit& initializer) | 57 PassRefPtr<StorageEvent> StorageEvent::create(const AtomicString& type, const St
orageEventInit& initializer) |
| 58 { | 58 { |
| 59 return adoptRefWillBeRefCountedGarbageCollected(new StorageEvent(type, initi
alizer)); | 59 return adoptRef(new StorageEvent(type, initializer)); |
| 60 } | 60 } |
| 61 | 61 |
| 62 StorageEvent::StorageEvent(const AtomicString& type, const String& key, const St
ring& oldValue, const String& newValue, const String& url, Storage* storageArea) | 62 StorageEvent::StorageEvent(const AtomicString& type, const String& key, const St
ring& oldValue, const String& newValue, const String& url, Storage* storageArea) |
| 63 : Event(type, false, false) | 63 : Event(type, false, false) |
| 64 , m_key(key) | 64 , m_key(key) |
| 65 , m_oldValue(oldValue) | 65 , m_oldValue(oldValue) |
| 66 , m_newValue(newValue) | 66 , m_newValue(newValue) |
| 67 , m_url(url) | 67 , m_url(url) |
| 68 , m_storageArea(storageArea) | 68 , m_storageArea(storageArea) |
| 69 { | 69 { |
| (...skipping 29 matching lines...) Expand all Loading... |
| 99 { | 99 { |
| 100 return EventNames::StorageEvent; | 100 return EventNames::StorageEvent; |
| 101 } | 101 } |
| 102 | 102 |
| 103 void StorageEvent::trace(Visitor* visitor) | 103 void StorageEvent::trace(Visitor* visitor) |
| 104 { | 104 { |
| 105 Event::trace(visitor); | 105 Event::trace(visitor); |
| 106 } | 106 } |
| 107 | 107 |
| 108 } // namespace WebCore | 108 } // namespace WebCore |
| OLD | NEW |