Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(108)

Side by Side Diff: third_party/WebKit/Source/core/events/ApplicationCacheErrorEvent.h

Issue 2217763003: Remove Blink-WebKit-only document.createEvent strings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ApplicationCacheErrorEvent_h 5 #ifndef ApplicationCacheErrorEvent_h
6 #define ApplicationCacheErrorEvent_h 6 #define ApplicationCacheErrorEvent_h
7 7
8 #include "core/events/ApplicationCacheErrorEventInit.h" 8 #include "core/events/ApplicationCacheErrorEventInit.h"
9 #include "core/events/Event.h" 9 #include "core/events/Event.h"
10 #include "core/loader/appcache/ApplicationCacheHost.h" 10 #include "core/loader/appcache/ApplicationCacheHost.h"
11 #include "public/platform/WebApplicationCacheHostClient.h" 11 #include "public/platform/WebApplicationCacheHostClient.h"
12 12
13 namespace blink { 13 namespace blink {
14 14
15 class ApplicationCacheErrorEvent final : public Event { 15 class ApplicationCacheErrorEvent final : public Event {
16 DEFINE_WRAPPERTYPEINFO(); 16 DEFINE_WRAPPERTYPEINFO();
17 public: 17 public:
18 ~ApplicationCacheErrorEvent() override; 18 ~ApplicationCacheErrorEvent() override;
19 19
20 static ApplicationCacheErrorEvent* create()
21 {
22 return new ApplicationCacheErrorEvent;
23 }
24
25 static ApplicationCacheErrorEvent* create(WebApplicationCacheHost::ErrorReas on reason, const String& url, int status, const String& message) 20 static ApplicationCacheErrorEvent* create(WebApplicationCacheHost::ErrorReas on reason, const String& url, int status, const String& message)
26 { 21 {
27 return new ApplicationCacheErrorEvent(reason, url, status, message); 22 return new ApplicationCacheErrorEvent(reason, url, status, message);
28 } 23 }
29 24
30 static ApplicationCacheErrorEvent* create(const AtomicString& eventType, con st ApplicationCacheErrorEventInit& initializer) 25 static ApplicationCacheErrorEvent* create(const AtomicString& eventType, con st ApplicationCacheErrorEventInit& initializer)
31 { 26 {
32 return new ApplicationCacheErrorEvent(eventType, initializer); 27 return new ApplicationCacheErrorEvent(eventType, initializer);
33 } 28 }
34 29
35 const String& reason() const { return m_reason; } 30 const String& reason() const { return m_reason; }
36 const String& url() const { return m_url; } 31 const String& url() const { return m_url; }
37 int status() const { return m_status; } 32 int status() const { return m_status; }
38 const String& message() const { return m_message; } 33 const String& message() const { return m_message; }
39 34
40 const AtomicString& interfaceName() const override { return EventNames::Appl icationCacheErrorEvent; } 35 const AtomicString& interfaceName() const override { return EventNames::Appl icationCacheErrorEvent; }
41 36
42 DECLARE_VIRTUAL_TRACE(); 37 DECLARE_VIRTUAL_TRACE();
43 38
44 private: 39 private:
45 ApplicationCacheErrorEvent();
46 ApplicationCacheErrorEvent(WebApplicationCacheHost::ErrorReason, const Strin g& url, int status, const String& message); 40 ApplicationCacheErrorEvent(WebApplicationCacheHost::ErrorReason, const Strin g& url, int status, const String& message);
47 ApplicationCacheErrorEvent(const AtomicString& eventType, const ApplicationC acheErrorEventInit& initializer); 41 ApplicationCacheErrorEvent(const AtomicString& eventType, const ApplicationC acheErrorEventInit& initializer);
48 42
49 String m_reason; 43 String m_reason;
50 String m_url; 44 String m_url;
51 int m_status; 45 int m_status;
52 String m_message; 46 String m_message;
53 }; 47 };
54 48
55 } // namespace blink 49 } // namespace blink
56 50
57 #endif // ApplicationCacheErrorEvent_h 51 #endif // ApplicationCacheErrorEvent_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698