mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-28 05:10:49 +00:00
Bug 807222 part 2. Condition MozTimeManager classinfo so we don't stick it on the global in builds that don't ship the xpt for it. r=jlebar
This commit is contained in:
parent
b0d460cbbb
commit
404d9ab987
@ -42,6 +42,7 @@ MOZ_APP_ID={3c2e2abc-06d4-11e1-ac3b-374f68613e61}
|
||||
MOZ_EXTENSION_MANAGER=1
|
||||
|
||||
MOZ_SYS_MSG=1
|
||||
MOZ_TIME_MANAGER=1
|
||||
|
||||
MOZ_PAY=1
|
||||
MOZ_TOOLKIT_SEARCH=
|
||||
|
@ -4293,6 +4293,7 @@ MOZ_WEBSMS_BACKEND=
|
||||
MOZ_GRAPHITE=1
|
||||
ACCESSIBILITY=1
|
||||
MOZ_SYS_MSG=
|
||||
MOZ_TIME_MANAGER=
|
||||
MOZ_PAY=
|
||||
|
||||
case "$target_os" in
|
||||
@ -7452,6 +7453,14 @@ if test -n "$MOZ_SYS_MSG"; then
|
||||
fi
|
||||
AC_SUBST(MOZ_SYS_MSG)
|
||||
|
||||
dnl ========================================================
|
||||
dnl = Enable Support for Time Manager API
|
||||
dnl ========================================================
|
||||
if test -n "$MOZ_TIME_MANAGER"; then
|
||||
AC_DEFINE(MOZ_TIME_MANAGER)
|
||||
fi
|
||||
AC_SUBST(MOZ_TIME_MANAGER)
|
||||
|
||||
dnl ========================================================
|
||||
dnl = Enable Camera Interface for B2G (Gonk usually)
|
||||
dnl ========================================================
|
||||
|
@ -129,7 +129,9 @@ NS_INTERFACE_MAP_BEGIN(Navigator)
|
||||
#endif
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDOMNavigatorCamera)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDOMNavigatorSystemMessages)
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDOMMozNavigatorTime)
|
||||
#endif
|
||||
NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(Navigator)
|
||||
NS_INTERFACE_MAP_END
|
||||
|
||||
@ -1334,6 +1336,7 @@ Navigator::MozSetMessageHandler(const nsAString& aType,
|
||||
//*****************************************************************************
|
||||
// Navigator::nsIDOMNavigatorTime
|
||||
//*****************************************************************************
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
NS_IMETHODIMP
|
||||
Navigator::GetMozTime(nsIDOMMozTimeManager** aTime)
|
||||
{
|
||||
@ -1350,6 +1353,7 @@ Navigator::GetMozTime(nsIDOMMozTimeManager** aTime)
|
||||
NS_ADDREF(*aTime = mTimeManager);
|
||||
return NS_OK;
|
||||
}
|
||||
#endif
|
||||
|
||||
//*****************************************************************************
|
||||
// nsNavigator::nsIDOMNavigatorCamera
|
||||
|
@ -102,7 +102,9 @@ class Navigator : public nsIDOMNavigator
|
||||
#endif
|
||||
, public nsIDOMNavigatorCamera
|
||||
, public nsIDOMNavigatorSystemMessages
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
, public nsIDOMMozNavigatorTime
|
||||
#endif
|
||||
{
|
||||
public:
|
||||
Navigator(nsPIDOMWindow *aInnerWindow);
|
||||
@ -132,7 +134,9 @@ public:
|
||||
NS_DECL_NSIDOMNAVIGATORBLUETOOTH
|
||||
#endif
|
||||
NS_DECL_NSIDOMNAVIGATORSYSTEMMESSAGES
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
NS_DECL_NSIDOMMOZNAVIGATORTIME
|
||||
#endif
|
||||
|
||||
static void Init();
|
||||
|
||||
|
@ -526,7 +526,9 @@ using mozilla::dom::indexedDB::IDBWrapperCache;
|
||||
#ifdef MOZ_SYS_MSG
|
||||
#include "mozilla/dom/Activity.h"
|
||||
#endif
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
#include "TimeManager.h"
|
||||
#endif
|
||||
|
||||
#include "DOMCameraManager.h"
|
||||
#include "DOMCameraControl.h"
|
||||
@ -1698,8 +1700,10 @@ static nsDOMClassInfoData sClassInfoData[] = {
|
||||
EVENTTARGET_SCRIPTABLE_FLAGS)
|
||||
#endif
|
||||
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
NS_DEFINE_CLASSINFO_DATA(MozTimeManager, nsDOMGenericSH,
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
#endif
|
||||
|
||||
#ifdef MOZ_WEBRTC
|
||||
NS_DEFINE_CLASSINFO_DATA(DataChannel, nsEventTargetSH,
|
||||
@ -2478,7 +2482,9 @@ nsDOMClassInfo::Init()
|
||||
#ifdef MOZ_SYS_MSG
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMNavigatorSystemMessages)
|
||||
#endif
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMMozNavigatorTime)
|
||||
#endif
|
||||
|
||||
DOM_CLASSINFO_MAP_END
|
||||
|
||||
@ -4461,9 +4467,11 @@ nsDOMClassInfo::Init()
|
||||
DOM_CLASSINFO_MAP_END
|
||||
#endif
|
||||
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
DOM_CLASSINFO_MAP_BEGIN(MozTimeManager, nsIDOMMozTimeManager)
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMMozTimeManager)
|
||||
DOM_CLASSINFO_MAP_END
|
||||
#endif
|
||||
|
||||
#ifdef MOZ_WEBRTC
|
||||
DOM_CLASSINFO_MAP_BEGIN(DataChannel, nsIDOMDataChannel)
|
||||
|
@ -523,7 +523,9 @@ DOMCI_CLASS(LockedFile)
|
||||
DOMCI_CLASS(MozActivity)
|
||||
#endif
|
||||
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
DOMCI_CLASS(MozTimeManager)
|
||||
#endif
|
||||
|
||||
#ifdef MOZ_WEBRTC
|
||||
DOMCI_CLASS(DataChannel)
|
||||
|
@ -7,7 +7,9 @@
|
||||
#include "nsITimeService.h"
|
||||
#include "TimeManager.h"
|
||||
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
DOMCI_DATA(MozTimeManager, mozilla::dom::time::TimeManager)
|
||||
#endif
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
@ -16,7 +18,9 @@ namespace time {
|
||||
NS_INTERFACE_MAP_BEGIN(TimeManager)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDOMMozTimeManager)
|
||||
NS_INTERFACE_MAP_ENTRY(nsISupports)
|
||||
#ifdef MOZ_TIME_MANAGER
|
||||
NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(MozTimeManager)
|
||||
#endif
|
||||
NS_INTERFACE_MAP_END
|
||||
|
||||
NS_IMPL_ADDREF(TimeManager)
|
||||
|
Loading…
x
Reference in New Issue
Block a user