зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1482753 - Move network/Types.h into hal/ and NetworkObserver into hal namespace. r=gsvelto
Differential Revision: https://phabricator.services.mozilla.com/D3179 --HG-- rename : dom/network/Types.h => hal/HalNetworkInformation.h
This commit is contained in:
Родитель
0381486a5f
Коммит
ce58f0c053
|
@ -8,15 +8,15 @@
|
|||
#define mozilla_dom_network_ConnectionMainThread_h
|
||||
|
||||
#include "Connection.h"
|
||||
#include "mozilla/Hal.h"
|
||||
#include "mozilla/Observer.h"
|
||||
#include "Types.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
namespace network {
|
||||
|
||||
class ConnectionMainThread final : public Connection
|
||||
, public NetworkObserver
|
||||
, public hal::NetworkObserver
|
||||
{
|
||||
public:
|
||||
explicit ConnectionMainThread(nsPIDOMWindowInner* aWindow);
|
||||
|
|
|
@ -14,7 +14,7 @@ namespace mozilla {
|
|||
namespace dom {
|
||||
namespace network {
|
||||
|
||||
class ConnectionProxy final : public NetworkObserver
|
||||
class ConnectionProxy final : public hal::NetworkObserver
|
||||
{
|
||||
public:
|
||||
NS_INLINE_DECL_THREADSAFE_REFCOUNTING(ConnectionProxy)
|
||||
|
|
|
@ -8,8 +8,6 @@
|
|||
#define mozilla_dom_network_ConnectionWorker_h
|
||||
|
||||
#include "Connection.h"
|
||||
#include "mozilla/Observer.h"
|
||||
#include "Types.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
|
|
@ -25,7 +25,6 @@ EXPORTS.mozilla.dom.network += [
|
|||
'TCPServerSocketParent.h',
|
||||
'TCPSocketChild.h',
|
||||
'TCPSocketParent.h',
|
||||
'Types.h',
|
||||
'UDPSocketChild.h',
|
||||
'UDPSocketParent.h',
|
||||
]
|
||||
|
|
|
@ -11,10 +11,10 @@
|
|||
#include "base/platform_thread.h"
|
||||
#include "nsTArray.h"
|
||||
#include "mozilla/dom/battery/Types.h"
|
||||
#include "mozilla/dom/network/Types.h"
|
||||
#include "mozilla/dom/power/Types.h"
|
||||
#include "mozilla/dom/ScreenOrientation.h"
|
||||
#include "mozilla/hal_sandbox/PHal.h"
|
||||
#include "mozilla/HalNetworkInformation.h"
|
||||
#include "mozilla/HalScreenConfiguration.h"
|
||||
#include "mozilla/HalTypes.h"
|
||||
#include "mozilla/Types.h"
|
||||
|
@ -147,13 +147,13 @@ void DisableSensorNotifications(hal::SensorType aSensor);
|
|||
* Inform the network backend there is a new network observer.
|
||||
* @param aNetworkObserver The observer that should be added.
|
||||
*/
|
||||
void RegisterNetworkObserver(NetworkObserver* aNetworkObserver);
|
||||
void RegisterNetworkObserver(hal::NetworkObserver* aNetworkObserver);
|
||||
|
||||
/**
|
||||
* Inform the network backend a network observer unregistered.
|
||||
* @param aNetworkObserver The observer that should be removed.
|
||||
*/
|
||||
void UnregisterNetworkObserver(NetworkObserver* aNetworkObserver);
|
||||
void UnregisterNetworkObserver(hal::NetworkObserver* aNetworkObserver);
|
||||
|
||||
/**
|
||||
* Returns the current network information.
|
||||
|
|
|
@ -4,19 +4,16 @@
|
|||
* 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/. */
|
||||
|
||||
#ifndef mozilla_dom_network_Types_h
|
||||
#define mozilla_dom_network_Types_h
|
||||
#ifndef mozilla_HalNetworkInformation_h
|
||||
#define mozilla_HalNetworkInformation_h
|
||||
|
||||
#include "mozilla/Observer.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace hal {
|
||||
class NetworkInformation;
|
||||
} // namespace hal
|
||||
|
||||
template <class T>
|
||||
class Observer;
|
||||
|
||||
typedef Observer<hal::NetworkInformation> NetworkObserver;
|
||||
|
||||
} // namespace hal
|
||||
} // namespace mozilla
|
||||
|
||||
#endif // mozilla_dom_network_Types_h
|
||||
#endif // mozilla_HalNetworkInformation_h
|
|
@ -10,6 +10,7 @@ with Files('**'):
|
|||
EXPORTS.mozilla += [
|
||||
'Hal.h',
|
||||
'HalImpl.h',
|
||||
'HalNetworkInformation.h',
|
||||
'HalSandbox.h',
|
||||
'HalScreenConfiguration.h',
|
||||
'HalSensor.h',
|
||||
|
|
|
@ -13,7 +13,6 @@
|
|||
#include "mozilla/dom/TabParent.h"
|
||||
#include "mozilla/dom/TabChild.h"
|
||||
#include "mozilla/dom/battery/Types.h"
|
||||
#include "mozilla/dom/network/Types.h"
|
||||
#include "mozilla/dom/ScreenOrientation.h"
|
||||
#include "mozilla/fallback/FallbackScreenConfiguration.h"
|
||||
#include "mozilla/EnumeratedRange.h"
|
||||
|
|
Загрузка…
Ссылка в новой задаче