| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 #include "wtf/RefCounted.h" | 51 #include "wtf/RefCounted.h" |
| 52 | 52 |
| 53 namespace blink { | 53 namespace blink { |
| 54 | 54 |
| 55 class ExecutionContext; | 55 class ExecutionContext; |
| 56 class NotificationAction; | 56 class NotificationAction; |
| 57 class NotificationOptions; | 57 class NotificationOptions; |
| 58 class NotificationPermissionCallback; | 58 class NotificationPermissionCallback; |
| 59 class ScriptState; | 59 class ScriptState; |
| 60 | 60 |
| 61 class MODULES_EXPORT Notification final : public RefCountedGarbageCollectedEvent
TargetWithInlineData<Notification>, public ActiveScriptWrappable, public ActiveD
OMObject, public WebNotificationDelegate { | 61 class MODULES_EXPORT Notification final : public EventTargetWithInlineData, publ
ic ActiveScriptWrappable, public ActiveDOMObject, public WebNotificationDelegate
{ |
| 62 REFCOUNTED_GARBAGE_COLLECTED_EVENT_TARGET(Notification); | 62 REFCOUNTED_GARBAGE_COLLECTED_EVENT_TARGET(Notification); |
| 63 USING_GARBAGE_COLLECTED_MIXIN(Notification); | 63 USING_GARBAGE_COLLECTED_MIXIN(Notification); |
| 64 DEFINE_WRAPPERTYPEINFO(); | 64 DEFINE_WRAPPERTYPEINFO(); |
| 65 public: | 65 public: |
| 66 // Used for JavaScript instantiations of the Notification object. Will autom
atically schedule for | 66 // Used for JavaScript instantiations of the Notification object. Will autom
atically schedule for |
| 67 // the notification to be displayed to the user when the developer-provided
data is valid. | 67 // the notification to be displayed to the user when the developer-provided
data is valid. |
| 68 static Notification* create(ExecutionContext*, const String& title, const No
tificationOptions&, ExceptionState&); | 68 static Notification* create(ExecutionContext*, const String& title, const No
tificationOptions&, ExceptionState&); |
| 69 | 69 |
| 70 // Used for embedder-created Notification objects. If |showing| is true, wil
l initialize the | 70 // Used for embedder-created Notification objects. If |showing| is true, wil
l initialize the |
| 71 // Notification's state as showing, or as closed otherwise. | 71 // Notification's state as showing, or as closed otherwise. |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 void setState(NotificationState state) { m_state = state; } | 160 void setState(NotificationState state) { m_state = state; } |
| 161 | 161 |
| 162 NotificationState m_state; | 162 NotificationState m_state; |
| 163 | 163 |
| 164 Member<AsyncMethodRunner<Notification>> m_asyncRunner; | 164 Member<AsyncMethodRunner<Notification>> m_asyncRunner; |
| 165 }; | 165 }; |
| 166 | 166 |
| 167 } // namespace blink | 167 } // namespace blink |
| 168 | 168 |
| 169 #endif // Notification_h | 169 #endif // Notification_h |
| OLD | NEW |