Bug 1519636 - Reformat recent changes to the Google coding style. r=glandium

Updated with clang-format version 14.0.5 (taskcluster-DydCt-ryTuKvBYw1HQOugw)
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D154661
This commit is contained in:
Andi-Bogdan Postelnicu 2022-08-16 07:08:27 +00:00
parent efd406d7c1
commit eeac3728d2
9 changed files with 30 additions and 25 deletions

View file

@ -215,9 +215,7 @@ already_AddRefed<EventTarget> MouseEvent::GetRelatedTarget() {
return EnsureWebAccessibleRelatedTarget(relatedTarget); return EnsureWebAccessibleRelatedTarget(relatedTarget);
} }
void MouseEvent::GetRegion(nsAString& aRegion) { void MouseEvent::GetRegion(nsAString& aRegion) { SetDOMStringToNull(aRegion); }
SetDOMStringToNull(aRegion);
}
CSSIntPoint MouseEvent::ScreenPoint(CallerType aCallerType) const { CSSIntPoint MouseEvent::ScreenPoint(CallerType aCallerType) const {
if (mEvent->mFlags.mIsPositionless) { if (mEvent->mFlags.mIsPositionless) {

View file

@ -295,15 +295,17 @@ class WorkerStreamOwner final {
RefPtr<WorkerStreamOwner> self = RefPtr<WorkerStreamOwner> self =
new WorkerStreamOwner(aStream, std::move(target)); new WorkerStreamOwner(aStream, std::move(target));
self->mWorkerRef = StrongWorkerRef::Create(aWorker, "JSStreamConsumer", [self]() { self->mWorkerRef =
if (self->mStream) { StrongWorkerRef::Create(aWorker, "JSStreamConsumer", [self]() {
// If this Close() calls JSStreamConsumer::OnInputStreamReady and drops if (self->mStream) {
// the last reference to the JSStreamConsumer, 'this' will not be // If this Close() calls JSStreamConsumer::OnInputStreamReady and
// destroyed since ~JSStreamConsumer() only enqueues a release proxy. // drops the last reference to the JSStreamConsumer, 'this' will not
self->mStream->Close(); // be destroyed since ~JSStreamConsumer() only enqueues a release
self->mStream = nullptr; // proxy.
} self->mStream->Close();
}); self->mStream = nullptr;
}
});
if (!self->mWorkerRef) { if (!self->mWorkerRef) {
return nullptr; return nullptr;

View file

@ -8,10 +8,10 @@
#define mozilla_layers_AnimationStorageData_h #define mozilla_layers_AnimationStorageData_h
#include "mozilla/dom/Nullable.h" #include "mozilla/dom/Nullable.h"
#include "mozilla/ServoStyleConsts.h" // for ComputedTimingFunction #include "mozilla/ServoStyleConsts.h" // for ComputedTimingFunction
#include "mozilla/layers/LayersMessages.h" // for TransformData, etc #include "mozilla/layers/LayersMessages.h" // for TransformData, etc
#include "mozilla/layers/LayersTypes.h" // for LayersId #include "mozilla/layers/LayersTypes.h" // for LayersId
#include "mozilla/TimeStamp.h" // for TimeStamp #include "mozilla/TimeStamp.h" // for TimeStamp
#include "mozilla/TimingParams.h" #include "mozilla/TimingParams.h"
#include "X11UndefineNone.h" #include "X11UndefineNone.h"

View file

@ -56,9 +56,10 @@ struct ParamTraits<mozilla::wr::ImageDescriptor> {
template <> template <>
struct ParamTraits<mozilla::wr::GeckoDisplayListType::Tag> struct ParamTraits<mozilla::wr::GeckoDisplayListType::Tag>
: public ContiguousEnumSerializer<mozilla::wr::GeckoDisplayListType::Tag, : public ContiguousEnumSerializer<
mozilla::wr::GeckoDisplayListType::Tag::None, mozilla::wr::GeckoDisplayListType::Tag,
mozilla::wr::GeckoDisplayListType::Tag::Sentinel> {}; mozilla::wr::GeckoDisplayListType::Tag::None,
mozilla::wr::GeckoDisplayListType::Tag::Sentinel> {};
template <> template <>
struct ParamTraits<mozilla::wr::GeckoDisplayListType> { struct ParamTraits<mozilla::wr::GeckoDisplayListType> {

View file

@ -258,7 +258,8 @@ static nsresult GetIconHandleFromPathInfo(const IconPathInfo& aPathInfo,
} }
// Match stock icons with names // Match stock icons with names
static mozilla::Maybe<SHSTOCKICONID> GetStockIconIDForName(const nsACString& aStockName) { static mozilla::Maybe<SHSTOCKICONID> GetStockIconIDForName(
const nsACString& aStockName) {
return aStockName.EqualsLiteral("uac-shield") ? Some(SIID_SHIELD) : Nothing(); return aStockName.EqualsLiteral("uac-shield") ? Some(SIID_SHIELD) : Nothing();
} }

View file

@ -77,8 +77,8 @@ class nsAnimationManager final
return false; return false;
} }
return keyframe.mTimingFunction return keyframe.mTimingFunction
? *keyframe.mTimingFunction == aTimingFunctionToMatch ? *keyframe.mTimingFunction == aTimingFunctionToMatch
: aTimingFunctionToMatch.IsLinearKeyword(); : aTimingFunctionToMatch.IsLinearKeyword();
}(); }();
if (matches) { if (matches) {
return true; return true;

View file

@ -64,7 +64,7 @@ bool ExternalHelperAppParent::Init(
nsIURI* aReferrer, BrowsingContext* aContext, nsIURI* aReferrer, BrowsingContext* aContext,
const bool& aShouldCloseWindow) { const bool& aShouldCloseWindow) {
nsresult rv = mozilla::ipc::LoadInfoArgsToLoadInfo(aLoadInfoArgs, nsresult rv = mozilla::ipc::LoadInfoArgsToLoadInfo(aLoadInfoArgs,
getter_AddRefs(mLoadInfo)); getter_AddRefs(mLoadInfo));
if (NS_FAILED(rv)) { if (NS_FAILED(rv)) {
return false; return false;
} }

View file

@ -608,7 +608,8 @@ class nsWindow final : public nsBaseWidget {
DWORD WindowStyle(); DWORD WindowStyle();
DWORD WindowExStyle(); DWORD WindowExStyle();
static const wchar_t* ChooseWindowClass(nsWindowType, bool aForMenupopupFrame); static const wchar_t* ChooseWindowClass(nsWindowType,
bool aForMenupopupFrame);
// This method registers the given window class, and returns the class name. // This method registers the given window class, and returns the class name.
static const wchar_t* RegisterWindowClass(const wchar_t* aClassName, static const wchar_t* RegisterWindowClass(const wchar_t* aClassName,
UINT aExtraStyle, LPWSTR aIconID); UINT aExtraStyle, LPWSTR aIconID);

View file

@ -520,7 +520,9 @@ class LogModuleManager {
void SetIsSync(bool aIsSync) { mIsSync = aIsSync; } void SetIsSync(bool aIsSync) { mIsSync = aIsSync; }
void SetRecordMarkers(bool aRecordMarkers) { mAddProfilerMarker = aRecordMarkers; } void SetRecordMarkers(bool aRecordMarkers) {
mAddProfilerMarker = aRecordMarkers;
}
void SetAddTimestamp(bool aAddTimestamp) { mAddTimestamp = aAddTimestamp; } void SetAddTimestamp(bool aAddTimestamp) { mAddTimestamp = aAddTimestamp; }