--- a/dom/base/Navigator.cpp
+++ b/dom/base/Navigator.cpp
@@ -27,19 +27,17 @@
#include "nsIScriptSecurityManager.h"
#include "nsCharSeparatedTokenizer.h"
#include "nsContentUtils.h"
#include "nsUnicharUtils.h"
#include "mozilla/Preferences.h"
#include "mozilla/Telemetry.h"
#include "BatteryManager.h"
#include "mozilla/dom/DeviceStorageAreaListener.h"
-#ifdef MOZ_GAMEPAD
#include "mozilla/dom/GamepadServiceTest.h"
-#endif
#include "mozilla/dom/PowerManager.h"
#include "mozilla/dom/WakeLock.h"
#include "mozilla/dom/power/PowerManagerService.h"
#include "mozilla/dom/FlyWebPublishedServer.h"
#include "mozilla/dom/FlyWebService.h"
#include "mozilla/dom/Permissions.h"
#include "mozilla/dom/Presentation.h"
#include "mozilla/dom/ServiceWorkerContainer.h"
@@ -212,19 +210,17 @@ NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mMediaDevices)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mTimeManager)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mServiceWorkerContainer)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mWindow)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mMediaKeySystemAccessManager)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mDeviceStorageAreaListener)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mPresentation)
-#ifdef MOZ_GAMEPAD
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mGamepadServiceTest)
-#endif
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mVRGetDisplaysPromises)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_SCRIPT_OBJECTS
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
NS_IMPL_CYCLE_COLLECTION_TRACE_WRAPPERCACHE(Navigator)
void
Navigator::Invalidate()
@@ -302,22 +298,20 @@ Navigator::Invalidate()
mMediaKeySystemAccessManager->Shutdown();
mMediaKeySystemAccessManager = nullptr;
}
if (mDeviceStorageAreaListener) {
mDeviceStorageAreaListener = nullptr;
}
-#ifdef MOZ_GAMEPAD
if (mGamepadServiceTest) {
mGamepadServiceTest->Shutdown();
mGamepadServiceTest = nullptr;
}
-#endif
mVRGetDisplaysPromises.Clear();
}
//*****************************************************************************
// Navigator::nsIDOMNavigator
//*****************************************************************************
@@ -1600,17 +1594,16 @@ Navigator::RequestWakeLock(const nsAStri
already_AddRefed<LegacyMozTCPSocket>
Navigator::MozTCPSocket()
{
RefPtr<LegacyMozTCPSocket> socket = new LegacyMozTCPSocket(GetWindow());
return socket.forget();
}
-#ifdef MOZ_GAMEPAD
void
Navigator::GetGamepads(nsTArray<RefPtr<Gamepad> >& aGamepads,
ErrorResult& aRv)
{
if (!mWindow) {
aRv.Throw(NS_ERROR_UNEXPECTED);
return;
}
@@ -1623,17 +1616,16 @@ Navigator::GetGamepads(nsTArray<RefPtr<G
GamepadServiceTest*
Navigator::RequestGamepadServiceTest()
{
if (!mGamepadServiceTest) {
mGamepadServiceTest = GamepadServiceTest::CreateTestService(mWindow);
}
return mGamepadServiceTest;
}
-#endif
already_AddRefed<Promise>
Navigator::GetVRDisplays(ErrorResult& aRv)
{
if (!mWindow || !mWindow->GetDocShell()) {
aRv.Throw(NS_ERROR_UNEXPECTED);
return nullptr;
}
--- a/dom/base/Navigator.h
+++ b/dom/base/Navigator.h
@@ -56,20 +56,18 @@ class Permissions;
namespace battery {
class BatteryManager;
} // namespace battery
class Promise;
class DesktopNotificationCenter;
class MozIdleObserver;
-#ifdef MOZ_GAMEPAD
class Gamepad;
class GamepadServiceTest;
-#endif // MOZ_GAMEPAD
class NavigatorUserMediaSuccessCallback;
class NavigatorUserMediaErrorCallback;
class MozGetUserMediaDevicesSuccessCallback;
namespace network {
class Connection;
} // namespace network
@@ -207,20 +205,18 @@ public:
GetDeviceStorageByNameAndType(const nsAString& aName, const nsAString& aType,
ErrorResult& aRv);
DesktopNotificationCenter* GetMozNotification(ErrorResult& aRv);
already_AddRefed<LegacyMozTCPSocket> MozTCPSocket();
network::Connection* GetConnection(ErrorResult& aRv);
MediaDevices* GetMediaDevices(ErrorResult& aRv);
-#ifdef MOZ_GAMEPAD
void GetGamepads(nsTArray<RefPtr<Gamepad> >& aGamepads, ErrorResult& aRv);
GamepadServiceTest* RequestGamepadServiceTest();
-#endif // MOZ_GAMEPAD
already_AddRefed<Promise> GetVRDisplays(ErrorResult& aRv);
void GetActiveVRDisplays(nsTArray<RefPtr<VRDisplay>>& aDisplays) const;
#ifdef MOZ_TIME_MANAGER
time::TimeManager* GetMozTime(ErrorResult& aRv);
#endif // MOZ_TIME_MANAGER
#ifdef MOZ_AUDIO_CHANNEL_MANAGER
system::AudioChannelManager* GetMozAudioChannelManager(ErrorResult& aRv);
#endif // MOZ_AUDIO_CHANNEL_MANAGER
@@ -306,19 +302,17 @@ private:
#endif
RefPtr<MediaDevices> mMediaDevices;
nsTArray<nsWeakPtr> mDeviceStorageStores;
RefPtr<time::TimeManager> mTimeManager;
RefPtr<ServiceWorkerContainer> mServiceWorkerContainer;
nsCOMPtr<nsPIDOMWindowInner> mWindow;
RefPtr<DeviceStorageAreaListener> mDeviceStorageAreaListener;
RefPtr<Presentation> mPresentation;
-#ifdef MOZ_GAMEPAD
RefPtr<GamepadServiceTest> mGamepadServiceTest;
-#endif
nsTArray<RefPtr<Promise> > mVRGetDisplaysPromises;
nsTArray<uint32_t> mRequestedVibrationPattern;
RefPtr<StorageManager> mStorageManager;
};
} // namespace dom
} // namespace mozilla
--- a/dom/base/nsGkAtomList.h
+++ b/dom/base/nsGkAtomList.h
@@ -2122,23 +2122,21 @@ GK_ATOM(ratechange, "ratechange")
GK_ATOM(durationchange, "durationchange")
GK_ATOM(volumechange, "volumechange")
GK_ATOM(ondataavailable, "ondataavailable")
GK_ATOM(onwarning, "onwarning")
GK_ATOM(onstart, "onstart")
GK_ATOM(onstop, "onstop")
GK_ATOM(onphoto, "onphoto")
GK_ATOM(onactivestatechanged, "onactivestatechanged")
-#ifdef MOZ_GAMEPAD
GK_ATOM(ongamepadbuttondown, "ongamepadbuttondown")
GK_ATOM(ongamepadbuttonup, "ongamepadbuttonup")
GK_ATOM(ongamepadaxismove, "ongamepadaxismove")
GK_ATOM(ongamepadconnected, "ongamepadconnected")
GK_ATOM(ongamepaddisconnected, "ongamepaddisconnected")
-#endif
// Content property names
GK_ATOM(animationsProperty, "AnimationsProperty") // FrameAnimations*
GK_ATOM(animationsOfBeforeProperty, "AnimationsOfBeforeProperty") // FrameAnimations*
GK_ATOM(animationsOfAfterProperty, "AnimationsOfAfterProperty") // FrameAnimations*
GK_ATOM(animationEffectsProperty, "AnimationEffectsProperty") // EffectSet*
GK_ATOM(animationEffectsForBeforeProperty, "AnimationsEffectsForBeforeProperty") // EffectSet*
GK_ATOM(animationEffectsForAfterProperty, "AnimationsEffectsForAfterProperty") // EffectSet*
--- a/dom/base/nsGlobalWindow.cpp
+++ b/dom/base/nsGlobalWindow.cpp
@@ -192,20 +192,18 @@
#include "mozilla/Logging.h"
#include "prenv.h"
#include "prprf.h"
#include "mozilla/dom/IDBFactory.h"
#include "mozilla/dom/MessageChannel.h"
#include "mozilla/dom/Promise.h"
-#ifdef MOZ_GAMEPAD
#include "mozilla/dom/Gamepad.h"
#include "mozilla/dom/GamepadManager.h"
-#endif
#include "mozilla/dom/VRDisplay.h"
#include "mozilla/dom/VREventObserver.h"
#include "nsRefreshDriver.h"
#include "Layers.h"
#include "mozilla/AddonPathService.h"
@@ -1234,19 +1232,17 @@ nsGlobalWindow::nsGlobalWindow(nsGlobalW
mIsChrome(false),
mCleanMessageManager(false),
mNeedsFocus(true),
mHasFocus(false),
mShowFocusRingForContent(false),
mFocusByKeyOccurred(false),
mHasGamepad(false),
mHasVREvents(false),
-#ifdef MOZ_GAMEPAD
mHasSeenGamepadInput(false),
-#endif
mNotifiedIDDestroyed(false),
mAllowScriptsToClose(false),
mSuspendDepth(0),
mFreezeDepth(0),
mFocusMethod(0),
mSerial(0),
mIdleRequestCallbackCounter(1),
#ifdef DEBUG
@@ -1804,21 +1800,19 @@ nsGlobalWindow::FreeInnerObjects()
CleanupCachedXBLHandlers(this);
for (uint32_t i = 0; i < mAudioContexts.Length(); ++i) {
mAudioContexts[i]->Shutdown();
}
mAudioContexts.Clear();
-#ifdef MOZ_GAMEPAD
DisableGamepadUpdates();
mHasGamepad = false;
mGamepads.Clear();
-#endif
DisableVRUpdates();
mHasVREvents = false;
mVRDisplays.Clear();
}
//*****************************************************************************
// nsGlobalWindow::nsISupports
//*****************************************************************************
@@ -1966,19 +1960,17 @@ NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_
}
for (IdleRequest* request : tmp->mThrottledIdleRequestCallbacks) {
cb.NoteNativeChild(request, NS_CYCLE_COLLECTION_PARTICIPANT(IdleRequest));
}
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mIdleObservers)
-#ifdef MOZ_GAMEPAD
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mGamepads)
-#endif
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mCacheStorage)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mVRDisplays)
// Traverse stuff from nsPIDOMWindow
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mChromeEventHandler)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mParentTarget)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mFrameElement)
@@ -2044,19 +2036,17 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(ns
NS_IMPL_CYCLE_COLLECTION_UNLINK(mIndexedDB)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mDocumentPrincipal)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mDoc)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mIdleService)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mWakeLock)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mPendingStorageEvents)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mIdleObservers)
-#ifdef MOZ_GAMEPAD
NS_IMPL_CYCLE_COLLECTION_UNLINK(mGamepads)
-#endif
NS_IMPL_CYCLE_COLLECTION_UNLINK(mCacheStorage)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mVRDisplays)
// Unlink stuff from nsPIDOMWindow
NS_IMPL_CYCLE_COLLECTION_UNLINK(mChromeEventHandler)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mParentTarget)
NS_IMPL_CYCLE_COLLECTION_UNLINK(mFrameElement)
@@ -10016,20 +10006,17 @@ void nsGlobalWindow::SetIsBackground(boo
return;
}
if (resetTimers) {
inner->mTimeoutManager->ResetTimersForThrottleReduction();
}
inner->UnthrottleIdleCallbackRequests();
-
-#ifdef MOZ_GAMEPAD
inner->SyncGamepadState();
-#endif
}
void nsGlobalWindow::MaybeUpdateTouchState()
{
FORWARD_TO_INNER_VOID(MaybeUpdateTouchState, ());
if (mMayHaveTouchEventListener) {
nsCOMPtr<nsIObserverService> observerService =
@@ -10044,37 +10031,33 @@ void nsGlobalWindow::MaybeUpdateTouchSta
}
void
nsGlobalWindow::EnableGamepadUpdates()
{
MOZ_ASSERT(IsInnerWindow());
if (mHasGamepad) {
-#ifdef MOZ_GAMEPAD
RefPtr<GamepadManager> gamepadManager(GamepadManager::GetService());
if (gamepadManager) {
gamepadManager->AddListener(this);
}
-#endif
}
}
void
nsGlobalWindow::DisableGamepadUpdates()
{
MOZ_ASSERT(IsInnerWindow());
if (mHasGamepad) {
-#ifdef MOZ_GAMEPAD
RefPtr<GamepadManager> gamepadManager(GamepadManager::GetService());
if (gamepadManager) {
gamepadManager->RemoveListener(this);
}
-#endif
}
}
void
nsGlobalWindow::EnableVRUpdates()
{
MOZ_ASSERT(IsInnerWindow());
@@ -12996,18 +12979,16 @@ nsGlobalWindow::AddSizeOfIncludingThis(n
}
if (EventListenerManager* elm = et->GetExistingListenerManager()) {
aWindowSizes->mDOMEventListenersCount += elm->ListenerCount();
}
++aWindowSizes->mDOMEventTargetsCount;
}
}
-
-#ifdef MOZ_GAMEPAD
void
nsGlobalWindow::AddGamepad(uint32_t aIndex, Gamepad* aGamepad)
{
MOZ_ASSERT(IsInnerWindow());
// Create the index we will present to content based on which indices are
// already taken, as required by the spec.
// https://w3c.github.io/gamepad/gamepad.html#widl-Gamepad-index
int index = 0;
@@ -13079,17 +13060,16 @@ nsGlobalWindow::SyncGamepadState()
MOZ_ASSERT(IsInnerWindow());
if (mHasSeenGamepadInput) {
RefPtr<GamepadManager> gamepadManager(GamepadManager::GetService());
for (auto iter = mGamepads.Iter(); !iter.Done(); iter.Next()) {
gamepadManager->SyncGamepadState(iter.Key(), iter.UserData());
}
}
}
-#endif // MOZ_GAMEPAD
bool
nsGlobalWindow::UpdateVRDisplays(nsTArray<RefPtr<mozilla::dom::VRDisplay>>& aDevices)
{
FORWARD_TO_INNER(UpdateVRDisplays, (aDevices), false);
VRDisplay::UpdateVRDisplays(mVRDisplays, AsInner());
aDevices = mVRDisplays;
--- a/dom/base/nsGlobalWindow.h
+++ b/dom/base/nsGlobalWindow.h
@@ -724,26 +724,24 @@ public:
enum SlowScriptResponse {
ContinueSlowScript = 0,
ContinueSlowScriptAndKeepNotifying,
AlwaysContinueSlowScript,
KillSlowScript
};
SlowScriptResponse ShowSlowScriptDialog();
-#ifdef MOZ_GAMEPAD
// Inner windows only.
void AddGamepad(uint32_t aIndex, mozilla::dom::Gamepad* aGamepad);
void RemoveGamepad(uint32_t aIndex);
void GetGamepads(nsTArray<RefPtr<mozilla::dom::Gamepad> >& aGamepads);
already_AddRefed<mozilla::dom::Gamepad> GetGamepad(uint32_t aIndex);
void SetHasSeenGamepadInput(bool aHasSeen);
bool HasSeenGamepadInput();
void SyncGamepadState();
-#endif
// Inner windows only.
// Enable/disable updates for gamepad input.
void EnableGamepadUpdates();
void DisableGamepadUpdates();
// Inner windows only.
// Enable/disable updates for VR
@@ -1752,21 +1750,19 @@ protected:
// Inner windows only.
// Indicates whether this window wants gamepad input events
bool mHasGamepad : 1;
// Inner windows only.
// Indicates whether this window wants VR events
bool mHasVREvents : 1;
-#ifdef MOZ_GAMEPAD
nsCheapSet<nsUint32HashKey> mGamepadIndexSet;
nsRefPtrHashtable<nsUint32HashKey, mozilla::dom::Gamepad> mGamepads;
bool mHasSeenGamepadInput;
-#endif
// whether we've sent the destroy notification for our window id
bool mNotifiedIDDestroyed : 1;
// whether scripts may close the window,
// even if "dom.allow_scripts_to_close_windows" is false.
bool mAllowScriptsToClose : 1;
nsCOMPtr<nsIScriptContext> mContext;
--- a/dom/events/EventNameList.h
+++ b/dom/events/EventNameList.h
@@ -891,17 +891,16 @@ NON_IDL_EVENT(MozAfterPaint,
EventNameType_None,
eBasicEventClass)
NON_IDL_EVENT(MozScrolledAreaChanged,
eScrolledAreaChanged,
EventNameType_None,
eScrollAreaEventClass)
-#ifdef MOZ_GAMEPAD
NON_IDL_EVENT(gamepadbuttondown,
eGamepadButtonDown,
EventNameType_None,
eBasicEventClass)
NON_IDL_EVENT(gamepadbuttonup,
eGamepadButtonUp,
EventNameType_None,
eBasicEventClass)
@@ -912,17 +911,16 @@ NON_IDL_EVENT(gamepadaxismove,
NON_IDL_EVENT(gamepadconnected,
eGamepadConnected,
EventNameType_None,
eBasicEventClass)
NON_IDL_EVENT(gamepaddisconnected,
eGamepadDisconnected,
EventNameType_None,
eBasicEventClass)
-#endif
// Simple gesture events
NON_IDL_EVENT(MozSwipeGestureMayStart,
eSwipeGestureMayStart,
EventNameType_None,
eSimpleGestureEventClass)
NON_IDL_EVENT(MozSwipeGestureStart,
eSwipeGestureStart,
--- a/dom/events/EventStateManager.cpp
+++ b/dom/events/EventStateManager.cpp
@@ -494,23 +494,19 @@ IsMessageMouseUserActivity(EventMessage
aMessage == eMouseClick ||
aMessage == eMouseActivate ||
aMessage == eMouseLongTap;
}
static bool
IsMessageGamepadUserActivity(EventMessage aMessage)
{
-#ifndef MOZ_GAMEPAD
- return false;
-#else
return aMessage == eGamepadButtonDown ||
aMessage == eGamepadButtonUp ||
aMessage == eGamepadAxisMove;
-#endif
}
nsresult
EventStateManager::PreHandleEvent(nsPresContext* aPresContext,
WidgetEvent* aEvent,
nsIFrame* aTargetFrame,
nsIContent* aTargetContent,
nsEventStatus* aStatus)
--- a/dom/webidl/GamepadServiceTest.webidl
+++ b/dom/webidl/GamepadServiceTest.webidl
@@ -1,21 +1,21 @@
/* 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/. */
[Pref="dom.gamepad.test.enabled"]
interface GamepadServiceTest
{
- readonly attribute unsigned long noMapping;
- readonly attribute unsigned long standardMapping;
+ readonly attribute GamepadMappingType noMapping;
+ readonly attribute GamepadMappingType standardMapping;
[Throws]
Promise<unsigned long> addGamepad(DOMString id,
- unsigned long mapping,
+ GamepadMappingType mapping,
unsigned long numButtons,
unsigned long numAxes);
void removeGamepad(unsigned long index);
void newButtonEvent(unsigned long index,
unsigned long button,
boolean pressed);
--- a/dom/webidl/Navigator.webidl
+++ b/dom/webidl/Navigator.webidl
@@ -267,27 +267,25 @@ partial interface Navigator {
};
// NetworkInformation
partial interface Navigator {
[Throws, Pref="dom.netinfo.enabled"]
readonly attribute NetworkInformation connection;
};
-#ifdef MOZ_GAMEPAD
// https://dvcs.w3.org/hg/gamepad/raw-file/default/gamepad.html#navigator-interface-extension
partial interface Navigator {
[Throws, Pref="dom.gamepad.enabled"]
sequence<Gamepad?> getGamepads();
};
partial interface Navigator {
[Pref="dom.gamepad.test.enabled"]
GamepadServiceTest requestGamepadServiceTest();
};
-#endif // MOZ_GAMEPAD
partial interface Navigator {
[Throws, Pref="dom.vr.enabled"]
Promise<sequence<VRDisplay>> getVRDisplays();
// TODO: Use FrozenArray once available. (Bug 1236777)
[Frozen, Cached, Pure, Pref="dom.vr.enabled"]
readonly attribute sequence<VRDisplay> activeVRDisplays;
};
--- a/dom/webidl/moz.build
+++ b/dom/webidl/moz.build
@@ -159,16 +159,19 @@ WEBIDL_FILES = [
'FlyWebWebSocketEvent.webidl',
'FocusEvent.webidl',
'FontFace.webidl',
'FontFaceSet.webidl',
'FontFaceSource.webidl',
'FormData.webidl',
'Function.webidl',
'GainNode.webidl',
+ 'Gamepad.webidl',
+ 'GamepadPose.webidl',
+ 'GamepadServiceTest.webidl',
'Geolocation.webidl',
'GeometryUtils.webidl',
'GetUserMediaRequest.webidl',
'Grid.webidl',
'Headers.webidl',
'HeapSnapshot.webidl',
'History.webidl',
'HTMLAllCollection.webidl',
@@ -631,23 +634,16 @@ if CONFIG['MOZ_WEBSPEECH']:
'SpeechRecognitionResultList.webidl',
'SpeechSynthesis.webidl',
'SpeechSynthesisErrorEvent.webidl',
'SpeechSynthesisEvent.webidl',
'SpeechSynthesisUtterance.webidl',
'SpeechSynthesisVoice.webidl',
]
-if CONFIG['MOZ_GAMEPAD']:
- WEBIDL_FILES += [
- 'Gamepad.webidl',
- 'GamepadPose.webidl',
- 'GamepadServiceTest.webidl'
- ]
-
WEBIDL_FILES += [
'CloseEvent.webidl',
'CustomEvent.webidl',
'DeviceOrientationEvent.webidl',
'DeviceStorageChangeEvent.webidl',
'HashChangeEvent.webidl',
'MozSettingsEvent.webidl',
'PageTransitionEvent.webidl',
@@ -689,16 +685,19 @@ GENERATED_EVENTS_WEBIDL_FILES = [
'DeviceLightEvent.webidl',
'DeviceOrientationEvent.webidl',
'DeviceProximityEvent.webidl',
'DeviceStorageAreaChangedEvent.webidl',
'DeviceStorageChangeEvent.webidl',
'DownloadEvent.webidl',
'ErrorEvent.webidl',
'FontFaceSetLoadEvent.webidl',
+ 'GamepadAxisMoveEvent.webidl',
+ 'GamepadButtonEvent.webidl',
+ 'GamepadEvent.webidl',
'GroupedHistoryEvent.webidl',
'HashChangeEvent.webidl',
'HiddenPluginEvent.webidl',
'ImageCaptureErrorEvent.webidl',
'MediaStreamEvent.webidl',
'MediaStreamTrackEvent.webidl',
'MozSettingsEvent.webidl',
'MozSettingsTransactionEvent.webidl',
@@ -735,23 +734,16 @@ if CONFIG['MOZ_WEBRTC']:
if CONFIG['MOZ_WEBSPEECH']:
GENERATED_EVENTS_WEBIDL_FILES += [
'SpeechRecognitionEvent.webidl',
'SpeechSynthesisErrorEvent.webidl',
'SpeechSynthesisEvent.webidl',
]
-if CONFIG['MOZ_GAMEPAD']:
- GENERATED_EVENTS_WEBIDL_FILES += [
- 'GamepadAxisMoveEvent.webidl',
- 'GamepadButtonEvent.webidl',
- 'GamepadEvent.webidl',
- ]
-
if CONFIG['MOZ_BUILD_APP'] in ['browser', 'xulrunner'] or CONFIG['MOZ_SUITE']:
WEBIDL_FILES += [
'BrowserFeedWriter.webidl',
]
if CONFIG['MOZ_BUILD_APP'] in ['browser', 'mobile/android', 'xulrunner']:
WEBIDL_FILES += [
'External.webidl',
--- a/widget/EventMessageList.h
+++ b/widget/EventMessageList.h
@@ -422,26 +422,24 @@ NS_EVENT_MESSAGE(eTimeChange)
NS_EVENT_MESSAGE(eNetworkUpload)
NS_EVENT_MESSAGE(eNetworkDownload)
// MediaRecorder events.
NS_EVENT_MESSAGE(eMediaRecorderDataAvailable)
NS_EVENT_MESSAGE(eMediaRecorderWarning)
NS_EVENT_MESSAGE(eMediaRecorderStop)
-#ifdef MOZ_GAMEPAD
// Gamepad input events
NS_EVENT_MESSAGE(eGamepadButtonDown)
NS_EVENT_MESSAGE(eGamepadButtonUp)
NS_EVENT_MESSAGE(eGamepadAxisMove)
NS_EVENT_MESSAGE(eGamepadConnected)
NS_EVENT_MESSAGE(eGamepadDisconnected)
NS_EVENT_MESSAGE_FIRST_LAST(eGamepadEvent,
eGamepadButtonDown, eGamepadDisconnected)
-#endif
// input and beforeinput events.
NS_EVENT_MESSAGE(eEditorInput)
// selection events
NS_EVENT_MESSAGE(eSelectStart)
NS_EVENT_MESSAGE(eSelectionChange)