| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved. | 3 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 virtual bool show(Notification*) = 0; | 56 virtual bool show(Notification*) = 0; |
| 57 | 57 |
| 58 // Requests that a notification that has already been shown be closed. | 58 // Requests that a notification that has already been shown be closed. |
| 59 virtual void close(Notification*) = 0; | 59 virtual void close(Notification*) = 0; |
| 60 | 60 |
| 61 // Informs the presenter that a Notification object has been destroyed | 61 // Informs the presenter that a Notification object has been destroyed |
| 62 // (such as by a page transition). The presenter may continue showing | 62 // (such as by a page transition). The presenter may continue showing |
| 63 // the notification, but must not attempt to call the event handlers. | 63 // the notification, but must not attempt to call the event handlers. |
| 64 virtual void notificationObjectDestroyed(Notification*) = 0; | 64 virtual void notificationObjectDestroyed(Notification*) = 0; |
| 65 | 65 |
| 66 // Requests user permission to show desktop notifications from a particular | |
| 67 // script context. The callback parameter should be run when the user has | |
| 68 // made a decision. | |
| 69 virtual void requestPermission(ExecutionContext*, PassOwnPtr<NotificationPer
missionCallback>) = 0; | |
| 70 | |
| 71 // Checks the current level of permission. | 66 // Checks the current level of permission. |
| 72 virtual Permission checkPermission(ExecutionContext*) = 0; | 67 virtual Permission checkPermission(ExecutionContext*) = 0; |
| 73 }; | 68 }; |
| 74 | 69 |
| 75 } // namespace blink | 70 } // namespace blink |
| 76 | 71 |
| 77 #endif // NotificationClient_h | 72 #endif // NotificationClient_h |
| OLD | NEW |