Skip to content

Commit

Permalink
[embedlite] Replace macros with C++ keywords
Browse files Browse the repository at this point in the history
  • Loading branch information
rojkov committed May 13, 2015
1 parent a30b4e1 commit 9d5536a
Show file tree
Hide file tree
Showing 15 changed files with 140 additions and 140 deletions.
4 changes: 2 additions & 2 deletions embedding/embedlite/embedprocess/EmbedLiteAppProcessChild.h
Expand Up @@ -39,12 +39,12 @@ class EmbedLiteAppProcessChild : public EmbedLiteAppBaseChild
}

protected:
virtual PEmbedLiteViewChild* AllocPEmbedLiteViewChild(const uint32_t&, const uint32_t& parentId, const bool& isPrivateWindow) MOZ_OVERRIDE;
virtual PEmbedLiteViewChild* AllocPEmbedLiteViewChild(const uint32_t&, const uint32_t& parentId, const bool& isPrivateWindow) override;

virtual PCompositorChild* AllocPCompositorChild(Transport* aTransport, ProcessId aOtherProcess);

// IPDL protocol impl
virtual void ActorDestroy(ActorDestroyReason aWhy) MOZ_OVERRIDE;
virtual void ActorDestroy(ActorDestroyReason aWhy) override;

private:
void QuickExit();
Expand Down
Expand Up @@ -51,7 +51,7 @@ namespace mozilla {
namespace embedlite {

// Temporary manager which allows to call InitLog
class EmbedLiteAppProcessParentManager MOZ_FINAL : public mozilla::layers::LayerManager
class EmbedLiteAppProcessParentManager final : public mozilla::layers::LayerManager
{
public:
explicit EmbedLiteAppProcessParentManager()
Expand Down
Expand Up @@ -31,7 +31,7 @@ class EmbedLiteAppProcessParent : public PEmbedLiteAppParent
void GetPrefs(InfallibleTArray<PrefSetting>* prefs);

protected:
void OnChannelConnected(int32_t pid) MOZ_OVERRIDE;
void OnChannelConnected(int32_t pid) override;

virtual bool
RecvInitialized();
Expand Down
44 changes: 22 additions & 22 deletions embedding/embedlite/embedprocess/EmbedLiteCompositorProcessParent.h
Expand Up @@ -29,55 +29,55 @@ class EmbedLiteCompositorProcessParent MOZ_FINAL : public PCompositorParent,
virtual IToplevelProtocol*
CloneToplevel(const InfallibleTArray<mozilla::ipc::ProtocolFdMapping>& aFds,
base::ProcessHandle aPeerProcess,
mozilla::ipc::ProtocolCloneContext* aCtx) MOZ_OVERRIDE;
mozilla::ipc::ProtocolCloneContext* aCtx) override;

virtual void ActorDestroy(ActorDestroyReason aWhy) MOZ_OVERRIDE;
virtual void ActorDestroy(ActorDestroyReason aWhy) override;

// FIXME/bug 774388: work out what shutdown protocol we need.
virtual bool RecvRequestOverfill() MOZ_OVERRIDE { return true; }
virtual bool RecvWillStop() MOZ_OVERRIDE { return true; }
virtual bool RecvStop() MOZ_OVERRIDE { return true; }
virtual bool RecvPause() MOZ_OVERRIDE { return true; }
virtual bool RecvResume() MOZ_OVERRIDE { return true; }
virtual bool RecvNotifyChildCreated(const uint64_t& child) MOZ_OVERRIDE;
virtual bool RecvAdoptChild(const uint64_t& child) MOZ_OVERRIDE { return false; }
virtual bool RecvRequestOverfill() override { return true; }
virtual bool RecvWillStop() override { return true; }
virtual bool RecvStop() override { return true; }
virtual bool RecvPause() override { return true; }
virtual bool RecvResume() override { return true; }
virtual bool RecvNotifyChildCreated(const uint64_t& child) override;
virtual bool RecvAdoptChild(const uint64_t& child) override { return false; }
virtual bool RecvMakeSnapshot(const SurfaceDescriptor& aInSnapshot,
const nsIntRect& aRect)
{ return true; }
virtual bool RecvFlushRendering() MOZ_OVERRIDE { return true; }
virtual bool RecvFlushRendering() override { return true; }
virtual bool RecvNotifyRegionInvalidated(const nsIntRegion& aRegion) { return true; }
virtual bool RecvStartFrameTimeRecording(const int32_t& aBufferSize, uint32_t* aOutStartIndex) MOZ_OVERRIDE { return true; }
virtual bool RecvStopFrameTimeRecording(const uint32_t& aStartIndex, InfallibleTArray<float>* intervals) MOZ_OVERRIDE { return true; }
virtual bool RecvGetTileSize(int32_t* aWidth, int32_t* aHeight) MOZ_OVERRIDE;
virtual bool RecvStartFrameTimeRecording(const int32_t& aBufferSize, uint32_t* aOutStartIndex) override { return true; }
virtual bool RecvStopFrameTimeRecording(const uint32_t& aStartIndex, InfallibleTArray<float>* intervals) override { return true; }
virtual bool RecvGetTileSize(int32_t* aWidth, int32_t* aHeight) override;

/**
* Tells this CompositorParent to send a message when the compositor has received the transaction.
*/
virtual bool RecvRequestNotifyAfterRemotePaint() MOZ_OVERRIDE;
virtual bool RecvRequestNotifyAfterRemotePaint() override;

virtual PLayerTransactionParent*
AllocPLayerTransactionParent(const nsTArray<LayersBackend>& aBackendHints,
const uint64_t& aId,
TextureFactoryIdentifier* aTextureFactoryIdentifier,
bool *aSuccess) MOZ_OVERRIDE;
bool *aSuccess) override;

virtual bool DeallocPLayerTransactionParent(PLayerTransactionParent* aLayers) MOZ_OVERRIDE;
virtual bool DeallocPLayerTransactionParent(PLayerTransactionParent* aLayers) override;

virtual void ShadowLayersUpdated(LayerTransactionParent* aLayerTree,
const uint64_t& aTransactionId,
const TargetConfig& aTargetConfig,
bool aIsFirstPaint,
bool aScheduleComposite,
uint32_t aPaintSequenceNumber,
bool aIsRepeatTransaction) MOZ_OVERRIDE;
virtual void ForceComposite(LayerTransactionParent* aLayerTree) MOZ_OVERRIDE;
bool aIsRepeatTransaction) override;
virtual void ForceComposite(LayerTransactionParent* aLayerTree) override;
virtual bool SetTestSampleTime(LayerTransactionParent* aLayerTree,
const TimeStamp& aTime) MOZ_OVERRIDE;
virtual void LeaveTestMode(LayerTransactionParent* aLayerTree) MOZ_OVERRIDE;
const TimeStamp& aTime) override;
virtual void LeaveTestMode(LayerTransactionParent* aLayerTree) override;
virtual void GetAPZTestData(const LayerTransactionParent* aLayerTree,
APZTestData* aOutData) MOZ_OVERRIDE;
APZTestData* aOutData) override;

virtual AsyncCompositionManager* GetCompositionManager(LayerTransactionParent* aParent) MOZ_OVERRIDE;
virtual AsyncCompositionManager* GetCompositionManager(LayerTransactionParent* aParent) override;

void DidComposite(uint64_t aId);

Expand Down
26 changes: 13 additions & 13 deletions embedding/embedlite/embedshared/EmbedLiteAppBaseChild.h
Expand Up @@ -36,23 +36,23 @@ class EmbedLiteAppBaseChild : public PEmbedLiteAppChild,
virtual ~EmbedLiteAppBaseChild();

// Embed API ipdl interface
virtual bool RecvSetBoolPref(const nsCString&, const bool&) MOZ_OVERRIDE;
virtual bool RecvSetCharPref(const nsCString&, const nsCString&) MOZ_OVERRIDE;
virtual bool RecvSetIntPref(const nsCString&, const int&) MOZ_OVERRIDE;
virtual bool RecvLoadGlobalStyleSheet(const nsCString&, const bool&) MOZ_OVERRIDE;
virtual bool RecvLoadComponentManifest(const nsCString&) MOZ_OVERRIDE;
virtual bool RecvSetBoolPref(const nsCString&, const bool&) override;
virtual bool RecvSetCharPref(const nsCString&, const nsCString&) override;
virtual bool RecvSetIntPref(const nsCString&, const int&) override;
virtual bool RecvLoadGlobalStyleSheet(const nsCString&, const bool&) override;
virtual bool RecvLoadComponentManifest(const nsCString&) override;

// IPDL protocol impl
virtual void ActorDestroy(ActorDestroyReason aWhy) MOZ_OVERRIDE;
virtual void ActorDestroy(ActorDestroyReason aWhy) override;

virtual bool RecvPreDestroy() MOZ_OVERRIDE;
virtual bool RecvPreDestroy() override;
virtual bool RecvObserve(const nsCString& topic,
const nsString& data) MOZ_OVERRIDE;
virtual bool RecvAddObserver(const nsCString&) MOZ_OVERRIDE;
virtual bool RecvRemoveObserver(const nsCString&) MOZ_OVERRIDE;
virtual bool RecvAddObservers(InfallibleTArray<nsCString>&& observers) MOZ_OVERRIDE;
virtual bool RecvRemoveObservers(InfallibleTArray<nsCString>&& observers) MOZ_OVERRIDE;
virtual bool DeallocPEmbedLiteViewChild(PEmbedLiteViewChild*) MOZ_OVERRIDE;
const nsString& data) override;
virtual bool RecvAddObserver(const nsCString&) override;
virtual bool RecvRemoveObserver(const nsCString&) override;
virtual bool RecvAddObservers(InfallibleTArray<nsCString>&& observers) override;
virtual bool RecvRemoveObservers(InfallibleTArray<nsCString>&& observers) override;
virtual bool DeallocPEmbedLiteViewChild(PEmbedLiteViewChild*) override;

protected:
MessageLoop* mParentLoop;
Expand Down
2 changes: 1 addition & 1 deletion embedding/embedlite/embedshared/EmbedLitePuppetWidget.h
Expand Up @@ -144,7 +144,7 @@ class EmbedLitePuppetWidget : public nsBaseWidget,
LayerManagerPersistence aPersistence = LAYER_MANAGER_CURRENT,
bool* aAllowRetaining = nullptr);

virtual mozilla::layers::CompositorParent* NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight) MOZ_OVERRIDE;
virtual mozilla::layers::CompositorParent* NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight) override;
virtual void CreateCompositor(int aWidth, int aHeight);
virtual void CreateCompositor();
virtual nsIntRect GetNaturalBounds();
Expand Down
92 changes: 46 additions & 46 deletions embedding/embedlite/embedshared/EmbedLiteViewBaseChild.h
Expand Up @@ -38,31 +38,31 @@ class EmbedLiteViewBaseChild : public PEmbedLiteViewChild,
virtual bool
ZoomToRect(const uint32_t& aPresShellId,
const ViewID& aViewId,
const CSSRect& aRect) MOZ_OVERRIDE;
const CSSRect& aRect) override;

virtual bool
UpdateZoomConstraints(const uint32_t& aPresShellId,
const ViewID& aViewId,
const bool& aIsRoot,
const ZoomConstraints& aConstraints) MOZ_OVERRIDE;
const ZoomConstraints& aConstraints) override;

virtual bool HasMessageListener(const nsAString& aMessageName) MOZ_OVERRIDE;
virtual bool HasMessageListener(const nsAString& aMessageName) override;

virtual bool DoSendAsyncMessage(const char16_t* aMessageName, const char16_t* aMessage) MOZ_OVERRIDE;
virtual bool DoSendAsyncMessage(const char16_t* aMessageName, const char16_t* aMessage) override;
virtual bool DoSendSyncMessage(const char16_t* aMessageName,
const char16_t* aMessage,
InfallibleTArray<nsString>* aJSONRetVal) MOZ_OVERRIDE;
InfallibleTArray<nsString>* aJSONRetVal) override;
virtual bool DoCallRpcMessage(const char16_t* aMessageName,
const char16_t* aMessage,
InfallibleTArray<nsString>* aJSONRetVal) MOZ_OVERRIDE;
InfallibleTArray<nsString>* aJSONRetVal) override;

/**
* Relay given frame metrics to listeners subscribed via EmbedLiteAppService
*/
virtual void RelayFrameMetrics(const mozilla::layers::FrameMetrics& aFrameMetrics) MOZ_OVERRIDE;
virtual void RelayFrameMetrics(const mozilla::layers::FrameMetrics& aFrameMetrics) override;

virtual nsIWebNavigation* WebNavigation() MOZ_OVERRIDE;
virtual nsIWidget* WebWidget() MOZ_OVERRIDE;
virtual nsIWebNavigation* WebNavigation() override;
virtual nsIWidget* WebWidget() override;

/*---------TabChildIface---------------*/

Expand All @@ -84,8 +84,8 @@ class EmbedLiteViewBaseChild : public PEmbedLiteViewChild,

/*---------WidgetIface---------------*/

virtual void ResetInputState() MOZ_OVERRIDE;
virtual gfxSize GetGLViewSize() MOZ_OVERRIDE;
virtual void ResetInputState() override;
virtual gfxSize GetGLViewSize() override;

virtual bool
SetInputContext(const int32_t& IMEEnabled,
Expand All @@ -94,12 +94,12 @@ class EmbedLiteViewBaseChild : public PEmbedLiteViewChild,
const nsString& inputmode,
const nsString& actionHint,
const int32_t& cause,
const int32_t& focusChange) MOZ_OVERRIDE;
const int32_t& focusChange) override;

virtual bool
GetInputContext(int32_t* IMEEnabled,
int32_t* IMEOpen,
intptr_t* NativeIMEContext) MOZ_OVERRIDE;
intptr_t* NativeIMEContext) override;

/*---------WidgetIface---------------*/

Expand All @@ -108,49 +108,49 @@ class EmbedLiteViewBaseChild : public PEmbedLiteViewChild,
protected:
virtual ~EmbedLiteViewBaseChild();

virtual void ActorDestroy(ActorDestroyReason aWhy) MOZ_OVERRIDE;
virtual bool RecvDestroy() MOZ_OVERRIDE;
virtual bool RecvLoadURL(const nsString&) MOZ_OVERRIDE;
virtual bool RecvGoBack() MOZ_OVERRIDE;
virtual bool RecvGoForward() MOZ_OVERRIDE;
virtual bool RecvStopLoad() MOZ_OVERRIDE;
virtual bool RecvReload(const bool&) MOZ_OVERRIDE;

virtual bool RecvSetIsActive(const bool&) MOZ_OVERRIDE;
virtual bool RecvSetIsFocused(const bool&) MOZ_OVERRIDE;
virtual bool RecvSuspendTimeouts() MOZ_OVERRIDE;
virtual bool RecvResumeTimeouts() MOZ_OVERRIDE;
virtual bool RecvLoadFrameScript(const nsString&) MOZ_OVERRIDE;
virtual bool RecvSetViewSize(const gfxSize&) MOZ_OVERRIDE;
virtual void ActorDestroy(ActorDestroyReason aWhy) override;
virtual bool RecvDestroy() override;
virtual bool RecvLoadURL(const nsString&) override;
virtual bool RecvGoBack() override;
virtual bool RecvGoForward() override;
virtual bool RecvStopLoad() override;
virtual bool RecvReload(const bool&) override;

virtual bool RecvSetIsActive(const bool&) override;
virtual bool RecvSetIsFocused(const bool&) override;
virtual bool RecvSuspendTimeouts() override;
virtual bool RecvResumeTimeouts() override;
virtual bool RecvLoadFrameScript(const nsString&) override;
virtual bool RecvSetViewSize(const gfxSize&) override;
virtual bool RecvAsyncScrollDOMEvent(const gfxRect& contentRect,
const gfxSize& scrollSize) MOZ_OVERRIDE;
const gfxSize& scrollSize) override;

virtual bool RecvUpdateFrame(const mozilla::layers::FrameMetrics& aFrameMetrics) MOZ_OVERRIDE;
virtual bool RecvHandleDoubleTap(const nsIntPoint& aPoint) MOZ_OVERRIDE;
virtual bool RecvHandleSingleTap(const nsIntPoint& aPoint) MOZ_OVERRIDE;
virtual bool RecvUpdateFrame(const mozilla::layers::FrameMetrics& aFrameMetrics) override;
virtual bool RecvHandleDoubleTap(const nsIntPoint& aPoint) override;
virtual bool RecvHandleSingleTap(const nsIntPoint& aPoint) override;
virtual bool RecvHandleLongTap(const nsIntPoint& aPoint,
const mozilla::layers::ScrollableLayerGuid& aGuid,
const uint64_t& aInputBlockId) MOZ_OVERRIDE;
virtual bool RecvAcknowledgeScrollUpdate(const FrameMetrics::ViewID& aScrollId, const uint32_t& aScrollGeneration) MOZ_OVERRIDE;
const uint64_t& aInputBlockId) override;
virtual bool RecvAcknowledgeScrollUpdate(const FrameMetrics::ViewID& aScrollId, const uint32_t& aScrollGeneration) override;
virtual bool RecvMouseEvent(const nsString& aType,
const float& aX,
const float& aY,
const int32_t& aButton,
const int32_t& aClickCount,
const int32_t& aModifiers,
const bool& aIgnoreRootScrollFrame) MOZ_OVERRIDE;
virtual bool RecvHandleTextEvent(const nsString& commit, const nsString& preEdit) MOZ_OVERRIDE;
virtual bool RecvHandleKeyPressEvent(const int& domKeyCode, const int& gmodifiers, const int& charCode) MOZ_OVERRIDE;
virtual bool RecvHandleKeyReleaseEvent(const int& domKeyCode, const int& gmodifiers, const int& charCode) MOZ_OVERRIDE;
virtual bool RecvInputDataTouchEvent(const ScrollableLayerGuid& aGuid, const mozilla::MultiTouchInput&, const uint64_t& aInputBlockId) MOZ_OVERRIDE;
virtual bool RecvInputDataTouchMoveEvent(const ScrollableLayerGuid& aGuid, const mozilla::MultiTouchInput&, const uint64_t& aInputBlockId) MOZ_OVERRIDE;

virtual bool RecvAddMessageListener(const nsCString&) MOZ_OVERRIDE;
virtual bool RecvRemoveMessageListener(const nsCString&) MOZ_OVERRIDE;
virtual void RecvAsyncMessage(const nsAString& aMessage, const nsAString& aData) MOZ_OVERRIDE;
virtual bool RecvSetGLViewSize(const gfxSize&) MOZ_OVERRIDE;
virtual bool RecvAddMessageListeners(InfallibleTArray<nsString>&& messageNames) MOZ_OVERRIDE;
virtual bool RecvRemoveMessageListeners(InfallibleTArray<nsString>&& messageNames) MOZ_OVERRIDE;
const bool& aIgnoreRootScrollFrame) override;
virtual bool RecvHandleTextEvent(const nsString& commit, const nsString& preEdit) override;
virtual bool RecvHandleKeyPressEvent(const int& domKeyCode, const int& gmodifiers, const int& charCode) override;
virtual bool RecvHandleKeyReleaseEvent(const int& domKeyCode, const int& gmodifiers, const int& charCode) override;
virtual bool RecvInputDataTouchEvent(const ScrollableLayerGuid& aGuid, const mozilla::MultiTouchInput&, const uint64_t& aInputBlockId) override;
virtual bool RecvInputDataTouchMoveEvent(const ScrollableLayerGuid& aGuid, const mozilla::MultiTouchInput&, const uint64_t& aInputBlockId) override;

virtual bool RecvAddMessageListener(const nsCString&) override;
virtual bool RecvRemoveMessageListener(const nsCString&) override;
virtual void RecvAsyncMessage(const nsAString& aMessage, const nsAString& aData) /* FIXME: override */;
virtual bool RecvSetGLViewSize(const gfxSize&) override;
virtual bool RecvAddMessageListeners(InfallibleTArray<nsString>&& messageNames) override;
virtual bool RecvRemoveMessageListeners(InfallibleTArray<nsString>&& messageNames) override;
virtual void OnGeckoWindowInitialized() {}

private:
Expand Down

0 comments on commit 9d5536a

Please sign in to comment.