33 #include <sbIMediaItemStatusEvent.h>
35 #include <nsComponentManagerUtils.h>
36 #include <nsIProgrammingLanguage.h>
45 static PRLogModuleInfo* gRemoteEventLog = nsnull;
49 #define LOG(args) PR_LOG(gRemoteEventLog, PR_LOG_WARN, args)
63 "classinfo:classDescription",
64 "classinfo:contractID",
66 "classinfo:implementationLanguage",
96 sbRemoteMediaItemStatusEvent::sbRemoteMediaItemStatusEvent(
sbRemotePlayer* aRemotePlayer ) :
97 mRemotePlayer(aRemotePlayer),
100 NS_ASSERTION(aRemotePlayer,
"aRemotePlayer is null");
101 MOZ_COUNT_CTOR(sbRemoteMediaItemStatusEvent);
103 if (!gRemoteEventLog) {
104 gRemoteEventLog = PR_NewLogModule(
"sbRemoteMediaItemStatusEvent");
106 LOG((
"sbRemoteMediaItemStatusEvent::sbRemoteMediaItemStatusEvent()"));
122 sbRemoteMediaItemStatusEvent::GetRemotePlayer(
sbIRemotePlayer * *aRemotePlayer)
125 NS_ENSURE_ARG_POINTER(aRemotePlayer);
128 *aRemotePlayer = nsnull;
133 NS_ENSURE_SUCCESS( rv, rv );
135 remotePlayer.swap( *aRemotePlayer );
144 NS_ENSURE_ARG( aEvent );
145 NS_ENSURE_ARG( aMediaItem );
151 NS_ENSURE_SUCCESS(rv, rv);
155 NS_ENSURE_SUCCESS(rv, rv);
162 NS_IMETHODIMP sbRemoteMediaItemStatusEvent::GetItem(
sbIMediaItem * *aItem)
164 NS_ENSURE_ARG(aItem);
171 return (*aItem ?
NS_OK : NS_ERROR_FAILURE);
175 NS_IMETHODIMP sbRemoteMediaItemStatusEvent::GetStatus(PRInt32 *aStatus)
177 NS_ENSURE_ARG(aStatus);
185 #define FORWARD_NSIPRIVATEDOMEVENT(_method, _type, _arg, _rettype, _default) \
186 NS_IMETHODIMP_(_rettype) sbRemoteMediaItemStatusEvent::_method( _type _arg ) \
189 nsCOMPtr<nsIPrivateDOMEvent> inner( do_QueryInterface(mEvent, &rv) ); \
190 NS_ENSURE_SUCCESS(rv, _default); \
191 return inner->_method( _arg ); \
#define SB_IMPL_SECURITYCHECKEDCOMP_INIT(_class)
readonly attribute sbIRemotePlayer remotePlayer
This interface is a composition of many of our other interfaces with the goal of exposing a more web-...
A marker interface for objects that aggregate the security mixin.
static nsresult SB_WrapMediaItem(sbRemotePlayer *aRemotePlayer, sbIMediaItem *aMediaItem, sbIMediaItem **aRemoteMediaItem)
#define SB_IMPL_CLASSINFO_INTERFACES_ONLY(_class)