2012-05-21 11:12:37 +00:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2010-05-13 18:06:52 +00:00
|
|
|
|
2010-09-13 20:44:53 +00:00
|
|
|
#ifndef PCOMContentPermissionRequestChild_h
|
|
|
|
#define PCOMContentPermissionRequestChild_h
|
|
|
|
|
2010-09-10 05:00:08 +00:00
|
|
|
#include "mozilla/dom/PContentPermissionRequestChild.h"
|
|
|
|
// Microsoft's API Name hackery sucks
|
|
|
|
#undef CreateEvent
|
|
|
|
|
|
|
|
/*
|
|
|
|
PContentPermissionRequestChild implementations also are
|
|
|
|
XPCOM objects. Addref() is called on their implementation
|
2012-07-18 19:09:28 +00:00
|
|
|
before SendPContentPermissionRequestConstructor is called.
|
2010-09-10 05:00:08 +00:00
|
|
|
When Dealloc is called, IPDLRelease() is called.
|
|
|
|
Implementations of this method are expected to call
|
|
|
|
Release() on themselves. See Bug 594261 for more
|
|
|
|
information.
|
|
|
|
*/
|
|
|
|
class PCOMContentPermissionRequestChild : public mozilla::dom::PContentPermissionRequestChild {
|
|
|
|
public:
|
|
|
|
virtual void IPDLRelease() = 0;
|
2012-07-18 19:09:28 +00:00
|
|
|
#ifdef DEBUG
|
|
|
|
PCOMContentPermissionRequestChild() : mIPCOpen(false) {}
|
|
|
|
virtual ~PCOMContentPermissionRequestChild() {
|
|
|
|
// mIPCOpen is set to true in TabChild::SendPContentPermissionRequestConstructor
|
|
|
|
// and set to false in TabChild::DeallocPContentPermissionRequest
|
|
|
|
MOZ_ASSERT(!mIPCOpen, "Protocol must not be open when PCOMContentPermissionRequestChild is destroyed.");
|
|
|
|
}
|
|
|
|
bool mIPCOpen;
|
|
|
|
#endif /* DEBUG */
|
2010-05-13 18:06:52 +00:00
|
|
|
};
|
2010-09-13 20:44:53 +00:00
|
|
|
|
|
|
|
#endif
|