author | Nicholas Nethercote <nnethercote@mozilla.com> |
Fri, 02 Aug 2019 11:59:06 +0000 | |
changeset 486138 | ae1e48d740a752dcac4852460c6848d715145247 |
parent 486137 | 15fbd2a9c32d7504bb24fdc153781e14ee82e090 |
child 486139 | 8e72c66c307675d621018cb7638f4c0292a9ab9f |
push id | 36390 |
push user | cbrindusan@mozilla.com |
push date | Mon, 05 Aug 2019 09:54:13 +0000 |
treeherder | mozilla-central@d681969e4480 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | heycam |
bugs | 1570212 |
milestone | 70.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
layout/base/PresShell.cpp | file | annotate | diff | comparison | revisions | |
modules/libpref/init/StaticPrefList.yaml | file | annotate | diff | comparison | revisions |
--- a/layout/base/PresShell.cpp +++ b/layout/base/PresShell.cpp @@ -747,17 +747,16 @@ void PresShell::RemoveWeakFrame(WeakFram already_AddRefed<nsFrameSelection> PresShell::FrameSelection() { RefPtr<nsFrameSelection> ret = mSelection; return ret.forget(); } //---------------------------------------------------------------------- -static bool sSynthMouseMove = true; static uint32_t sNextPresShellId; /* static */ bool PresShell::AccessibleCaretEnabled(nsIDocShell* aDocShell) { // If the pref forces it on, then enable it. if (StaticPrefs::layout_accessiblecaret_enabled()) { return true; } @@ -844,22 +843,16 @@ PresShell::PresShell() #ifdef MOZ_REFLOW_PERF mReflowCountMgr = MakeUnique<ReflowCountMgr>(); mReflowCountMgr->SetPresContext(mPresContext); mReflowCountMgr->SetPresShell(this); #endif mLastOSWake = mLoadBegin = TimeStamp::Now(); - static bool addedSynthMouseMove = false; - if (!addedSynthMouseMove) { - Preferences::AddBoolVarCache(&sSynthMouseMove, - "layout.reflow.synthMouseMove", true); - addedSynthMouseMove = true; - } PointerEventHandler::Initialize(); } NS_INTERFACE_TABLE_HEAD(PresShell) NS_INTERFACE_TABLE_BEGIN // In most cases, PresShell should be treated as concrete class, but need to // QI for weak reference. Therefore, the case needed by do_QueryReferent() // should be tested first. @@ -5331,17 +5324,17 @@ void PresShell::SetRenderingState(const } } mRenderingStateFlags = aState.mRenderingStateFlags; mResolution = aState.mResolution; } void PresShell::SynthesizeMouseMove(bool aFromScroll) { - if (!sSynthMouseMove) return; + if (!StaticPrefs::layout_reflow_synthMouseMove()) return; if (mPaintingSuppressed || !mIsActive || !mPresContext) { return; } if (!mPresContext->IsRoot()) { if (PresShell* rootPresShell = GetRootPresShell()) { rootPresShell->SynthesizeMouseMove(aFromScroll); @@ -9116,17 +9109,17 @@ void PresShell::DidDoReflow(bool aInterr DOMHighResTimeStamp now = GetPerformanceNowUnclamped(); docShell->NotifyReflowObservers(aInterruptible, mLastReflowStart, now); } if (!mPresContext->HasPendingInterrupt()) { mDocument->ScheduleResizeObserversNotification(); } - if (sSynthMouseMove) { + if (StaticPrefs::layout_reflow_synthMouseMove()) { SynthesizeMouseMove(false); } mPresContext->NotifyMissingFonts(); } DOMHighResTimeStamp PresShell::GetPerformanceNowUnclamped() { DOMHighResTimeStamp now = 0;
--- a/modules/libpref/init/StaticPrefList.yaml +++ b/modules/libpref/init/StaticPrefList.yaml @@ -4427,16 +4427,21 @@ value: 64 mirror: always - name: layout.paint_rects_separately type: bool value: true mirror: once +- name: layout.reflow.synthMouseMove + type: bool + value: true + mirror: always + # This and code dependent on it should be removed once containerless scrolling looks stable. - name: layout.scroll.root-frame-containers type: RelaxedAtomicBool value: false mirror: always # This pref is to be set by test code only. - name: layout.scrollbars.always-layerize-track