зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1519636 - Reformat recent changes to the Google coding style r=emilio,media-playback-reviewers,padenot
# ignore-this-changeset Differential Revision: https://phabricator.services.mozilla.com/D207867
This commit is contained in:
Родитель
b1480c3f5c
Коммит
21f973ed5c
|
@ -121,7 +121,6 @@ class ResizeObservation final : public LinkedListElement<ResizeObservation> {
|
|||
* https://drafts.csswg.org/resize-observer/#api
|
||||
*/
|
||||
class ResizeObserver final : public nsISupports, public nsWrapperCache {
|
||||
|
||||
public:
|
||||
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
|
||||
NS_DECL_CYCLE_COLLECTION_WRAPPERCACHE_CLASS(ResizeObserver)
|
||||
|
|
|
@ -17,9 +17,7 @@ using namespace mozilla::layout;
|
|||
namespace mozilla::dom {
|
||||
|
||||
TabContext::TabContext()
|
||||
: mInitialized(false),
|
||||
mChromeOuterWindowID(0),
|
||||
mMaxTouchPoints(0) {}
|
||||
: mInitialized(false), mChromeOuterWindowID(0), mMaxTouchPoints(0) {}
|
||||
|
||||
uint64_t TabContext::ChromeOuterWindowID() const {
|
||||
return mChromeOuterWindowID;
|
||||
|
|
|
@ -14,4 +14,4 @@ bool Supports(const EncoderConfig& aConfig) {
|
|||
RefPtr<PEMFactory> pem = new PEMFactory();
|
||||
return pem->Supports(aConfig);
|
||||
}
|
||||
}
|
||||
} // namespace mozilla::EncodeTraits
|
||||
|
|
|
@ -58,12 +58,12 @@ class RemoteImageHolder final {
|
|||
gfx::ColorRange mColorRange = {};
|
||||
};
|
||||
|
||||
template <>
|
||||
struct ipc::IPDLParamTraits<RemoteImageHolder> {
|
||||
static void Write(IPC::MessageWriter* aWriter, IProtocol* aActor,
|
||||
RemoteImageHolder&& aParam);
|
||||
static bool Read(IPC::MessageReader* aReader, IProtocol* aActor,
|
||||
RemoteImageHolder* aResult);
|
||||
template <>
|
||||
struct ipc::IPDLParamTraits<RemoteImageHolder> {
|
||||
static void Write(IPC::MessageWriter* aWriter, IProtocol* aActor,
|
||||
RemoteImageHolder&& aParam);
|
||||
static bool Read(IPC::MessageReader* aReader, IProtocol* aActor,
|
||||
RemoteImageHolder* aResult);
|
||||
};
|
||||
|
||||
} // namespace mozilla
|
||||
|
|
|
@ -130,11 +130,11 @@ void GMPVideoDecoder::Decoded(GMPVideoi420Frame* aDecodedFrame) {
|
|||
mUnorderedData.AppendElement(std::move(v));
|
||||
}
|
||||
|
||||
if (mSamples.IsEmpty()) {
|
||||
// If we have no remaining samples in the table, then we have processed
|
||||
// all outstanding decode requests.
|
||||
ProcessReorderQueue(mDecodePromise, __func__);
|
||||
}
|
||||
if (mSamples.IsEmpty()) {
|
||||
// If we have no remaining samples in the table, then we have processed
|
||||
// all outstanding decode requests.
|
||||
ProcessReorderQueue(mDecodePromise, __func__);
|
||||
}
|
||||
}
|
||||
|
||||
void GMPVideoDecoder::ReceivedDecodedReferenceFrame(const uint64_t aPictureId) {
|
||||
|
|
|
@ -51,7 +51,8 @@ FFTBlock* FFTBlock::CreateInterpolatedBlock(const FFTBlock& block0,
|
|||
const FFTBlock& block1,
|
||||
double interp) {
|
||||
uint32_t fftSize = block0.FFTSize();
|
||||
FFTBlock* newBlock = new FFTBlock(fftSize, 1.0f / AssertedCast<float>(fftSize));
|
||||
FFTBlock* newBlock =
|
||||
new FFTBlock(fftSize, 1.0f / AssertedCast<float>(fftSize));
|
||||
|
||||
newBlock->InterpolateFrequencyComponents(block0, block1, interp);
|
||||
|
||||
|
|
|
@ -33,7 +33,9 @@ class RenderBundleEncoder final : public ObjectBase, public ChildOf<Device> {
|
|||
~RenderBundleEncoder();
|
||||
void Cleanup();
|
||||
|
||||
std::unique_ptr<ffi::WGPURenderBundleEncoder, ffiWGPURenderBundleEncoderDeleter> mEncoder;
|
||||
std::unique_ptr<ffi::WGPURenderBundleEncoder,
|
||||
ffiWGPURenderBundleEncoderDeleter>
|
||||
mEncoder;
|
||||
// keep all the used objects alive while the encoder is finished
|
||||
nsTArray<RefPtr<const BindGroup>> mUsedBindGroups;
|
||||
nsTArray<RefPtr<const Buffer>> mUsedBuffers;
|
||||
|
|
|
@ -24,9 +24,9 @@ class GLContextGLX : public GLContext {
|
|||
static bool FindVisual(Display* display, int screen, int* const out_visualId);
|
||||
|
||||
// Finds a GLXFBConfig compatible with the provided window.
|
||||
static bool FindFBConfigForWindow(
|
||||
Display* display, int screen, Window window,
|
||||
GLXFBConfig* const out_config, int* const out_visid, bool aWebRender);
|
||||
static bool FindFBConfigForWindow(Display* display, int screen, Window window,
|
||||
GLXFBConfig* const out_config,
|
||||
int* const out_visid, bool aWebRender);
|
||||
|
||||
virtual ~GLContextGLX();
|
||||
|
||||
|
|
|
@ -603,9 +603,8 @@ already_AddRefed<GLContext> CreateForWidget(Display* aXDisplay, Window aXWindow,
|
|||
|
||||
GLXFBConfig config;
|
||||
int visid;
|
||||
if (!GLContextGLX::FindFBConfigForWindow(aXDisplay, xscreen, aXWindow,
|
||||
&config, &visid,
|
||||
aHardwareWebRender)) {
|
||||
if (!GLContextGLX::FindFBConfigForWindow(
|
||||
aXDisplay, xscreen, aXWindow, &config, &visid, aHardwareWebRender)) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
@ -658,7 +657,8 @@ static bool ChooseConfig(GLXLibrary* glx, Display* display, int screen,
|
|||
};
|
||||
|
||||
int numConfigs = 0;
|
||||
const auto scopedConfigArr = glx->fChooseFBConfig(display, screen, attribs, &numConfigs);
|
||||
const auto scopedConfigArr =
|
||||
glx->fChooseFBConfig(display, screen, attribs, &numConfigs);
|
||||
const auto freeConfigList = MakeScopeExit([&]() {
|
||||
if (scopedConfigArr) {
|
||||
XFree(scopedConfigArr);
|
||||
|
@ -764,9 +764,11 @@ bool GLContextGLX::FindVisual(Display* display, int screen,
|
|||
return false;
|
||||
}
|
||||
|
||||
bool GLContextGLX::FindFBConfigForWindow(
|
||||
Display* display, int screen, Window window,
|
||||
GLXFBConfig* const out_config, int* const out_visid, bool aWebRender) {
|
||||
bool GLContextGLX::FindFBConfigForWindow(Display* display, int screen,
|
||||
Window window,
|
||||
GLXFBConfig* const out_config,
|
||||
int* const out_visid,
|
||||
bool aWebRender) {
|
||||
// XXX the visual ID is almost certainly the LOCAL_GLX_FBCONFIG_ID, so
|
||||
// we could probably do this first and replace the glXGetFBConfigs
|
||||
// with glXChooseConfigs. Docs are sparklingly clear as always.
|
||||
|
|
|
@ -15,13 +15,13 @@
|
|||
#include "mozilla/ServoStyleConsts.h" // for StyleComputedTimingFunction
|
||||
#include "mozilla/dom/AnimationEffectBinding.h" // for dom::FillMode
|
||||
#include "mozilla/dom/KeyframeEffectBinding.h" // for dom::IterationComposite
|
||||
#include "mozilla/dom/KeyframeEffect.h" // for dom::KeyFrameEffectReadOnly
|
||||
#include "mozilla/dom/Nullable.h" // for dom::Nullable
|
||||
#include "mozilla/layers/APZSampler.h" // for APZSampler
|
||||
#include "mozilla/dom/KeyframeEffect.h" // for dom::KeyFrameEffectReadOnly
|
||||
#include "mozilla/dom/Nullable.h" // for dom::Nullable
|
||||
#include "mozilla/layers/APZSampler.h" // for APZSampler
|
||||
#include "mozilla/AnimatedPropertyID.h"
|
||||
#include "mozilla/LayerAnimationInfo.h" // for GetCSSPropertiesFor()
|
||||
#include "mozilla/Maybe.h" // for Maybe<>
|
||||
#include "mozilla/MotionPathUtils.h" // for ResolveMotionPath()
|
||||
#include "mozilla/LayerAnimationInfo.h" // for GetCSSPropertiesFor()
|
||||
#include "mozilla/Maybe.h" // for Maybe<>
|
||||
#include "mozilla/MotionPathUtils.h" // for ResolveMotionPath()
|
||||
#include "mozilla/StyleAnimationValue.h" // for StyleAnimationValue, etc
|
||||
#include "nsCSSPropertyID.h" // for eCSSProperty_offset_path, etc
|
||||
#include "nsDisplayList.h" // for nsDisplayTransform, etc
|
||||
|
|
|
@ -72,7 +72,9 @@ class GPUVideoImage final : public Image {
|
|||
gfx::ColorDepth GetColorDepth() const override { return mColorDepth; }
|
||||
gfx::ColorSpace2 GetColorPrimaries() const { return mColorSpace; }
|
||||
gfx::YUVColorSpace GetYUVColorSpace() const { return mYUVColorSpace; }
|
||||
gfx::TransferFunction GetTransferFunction() const { return mTransferFunction; }
|
||||
gfx::TransferFunction GetTransferFunction() const {
|
||||
return mTransferFunction;
|
||||
}
|
||||
gfx::ColorRange GetColorRange() const { return mColorRange; }
|
||||
|
||||
Maybe<SurfaceDescriptor> GetDesc() override {
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
# error Unknown toolkit
|
||||
#endif
|
||||
|
||||
#include <string.h> // for memset
|
||||
#include <string.h> // for memset
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ namespace mozilla {
|
|||
namespace dom {
|
||||
class Document;
|
||||
enum class FetchPriority : uint8_t;
|
||||
}
|
||||
} // namespace dom
|
||||
} // namespace mozilla
|
||||
|
||||
class imgCacheEntry {
|
||||
|
|
|
@ -25,9 +25,7 @@ RevocableStore::~RevocableStore() {
|
|||
owning_reference_->set_store(NULL);
|
||||
}
|
||||
|
||||
void RevocableStore::Add(Revocable* item) {
|
||||
DCHECK(!item->revoked());
|
||||
}
|
||||
void RevocableStore::Add(Revocable* item) { DCHECK(!item->revoked()); }
|
||||
|
||||
void RevocableStore::RevokeAll() {
|
||||
// We revoke all the existing items in the store and reset our count.
|
||||
|
|
|
@ -24,8 +24,7 @@ inline bool EmulatesUndefined(JSObject* obj) {
|
|||
return actual->getClass()->emulatesUndefined();
|
||||
}
|
||||
|
||||
inline bool EmulatesUndefinedCheckFuse(JSObject* obj,
|
||||
size_t fuseValue) {
|
||||
inline bool EmulatesUndefinedCheckFuse(JSObject* obj, size_t fuseValue) {
|
||||
// This may be called off the main thread. It's OK not to expose the object
|
||||
// here as it doesn't escape.
|
||||
AutoUnsafeCallWithABI unsafe(UnsafeABIStrictness::AllowPendingExceptions);
|
||||
|
|
|
@ -286,7 +286,6 @@ static bool InflateUTF8ToUTF16(JSContext* cx, const UTF8Chars& src,
|
|||
break;
|
||||
}
|
||||
} else {
|
||||
|
||||
#define INVALID(report, arg, n2) \
|
||||
do { \
|
||||
if (ErrorAction == OnUTF8Error::Throw) { \
|
||||
|
|
|
@ -176,7 +176,8 @@ class MOZ_TEMPORARY_CLASS FunctionRef<Ret(Params...)> {
|
|||
FunctionRef>>* = nullptr>
|
||||
MOZ_IMPLICIT FunctionRef(Callable&& aCallable MOZ_LIFETIME_BOUND) noexcept
|
||||
: mAdaptor([](const Payload& aPayload, Params... aParams) {
|
||||
auto& func = *static_cast<std::remove_reference_t<Callable>*>(aPayload.mObject);
|
||||
auto& func = *static_cast<std::remove_reference_t<Callable>*>(
|
||||
aPayload.mObject);
|
||||
return static_cast<Ret>(func(std::forward<Params>(aParams)...));
|
||||
}) {
|
||||
::new (KnownNotNull, &mPayload.mObject) void*(&aCallable);
|
||||
|
|
|
@ -47,7 +47,6 @@ int __wrap_dl_iterate_phdr(dl_phdr_cb callback, void* data);
|
|||
#ifdef __ARM_EABI__
|
||||
const void* __wrap___gnu_Unwind_Find_exidx(void* pc, int* pcount);
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/* Forward declarations for use in LibHandle */
|
||||
|
|
|
@ -62,7 +62,8 @@ class ThemeColors {
|
|||
explicit ThemeColors(const nsIFrame* aFrame, StyleAppearance aAppearance)
|
||||
: mDoc(*aFrame->PresContext()->Document()),
|
||||
mHighContrastInfo(ShouldBeHighContrast(*aFrame->PresContext())),
|
||||
mColorScheme(ColorSchemeForWidget(aFrame, aAppearance, mHighContrastInfo)),
|
||||
mColorScheme(
|
||||
ColorSchemeForWidget(aFrame, aAppearance, mHighContrastInfo)),
|
||||
mAccentColor(*aFrame->Style(), mColorScheme) {}
|
||||
virtual ~ThemeColors() = default;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче