diff --git a/widget/nsIWidget.h b/widget/nsIWidget.h index fceaff168e40..dac93db2d841 100644 --- a/widget/nsIWidget.h +++ b/widget/nsIWidget.h @@ -244,7 +244,7 @@ struct nsIMEUpdatePreference { { } - nsIMEUpdatePreference(Notifications aWantUpdates) + explicit nsIMEUpdatePreference(Notifications aWantUpdates) : mWantUpdates(aWantUpdates | DEFAULT_CONDITIONS_OF_NOTIFYING_CHANGES) { } @@ -369,7 +369,7 @@ struct IMEState { IMEState() : mEnabled(ENABLED), mOpen(DONT_CHANGE_OPEN_STATE) { } - IMEState(Enabled aEnabled, Open aOpen = DONT_CHANGE_OPEN_STATE) : + explicit IMEState(Enabled aEnabled, Open aOpen = DONT_CHANGE_OPEN_STATE) : mEnabled(aEnabled), mOpen(aOpen) { } @@ -452,8 +452,8 @@ struct InputContextAction { { } - InputContextAction(Cause aCause, - FocusChange aFocusChange = FOCUS_NOT_CHANGED) : + explicit InputContextAction(Cause aCause, + FocusChange aFocusChange = FOCUS_NOT_CHANGED) : mCause(aCause), mFocusChange(aFocusChange) { } @@ -510,7 +510,7 @@ enum IMEMessage MOZ_ENUM_TYPE(int8_t) struct IMENotification { - IMENotification(IMEMessage aMessage) + MOZ_IMPLICIT IMENotification(IMEMessage aMessage) : mMessage(aMessage) { switch (aMessage) { diff --git a/widget/xpwidgets/GfxInfoCollector.h b/widget/xpwidgets/GfxInfoCollector.h index c4c1a618ee1e..66c35fe96722 100644 --- a/widget/xpwidgets/GfxInfoCollector.h +++ b/widget/xpwidgets/GfxInfoCollector.h @@ -29,7 +29,7 @@ class MOZ_STACK_CLASS InfoObject private: // We need to ensure that this object lives on the stack so that GC sees it properly - InfoObject(JSContext *aCx); + explicit InfoObject(JSContext *aCx); InfoObject(InfoObject&); JSContext *mCx;