зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1620952: part 9) Rename `nsFrameSelection::GetBatching` to `IsBatching`. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D66061 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
c8fbeec19d
Коммит
76ae1d169f
|
@ -2887,7 +2887,9 @@ nsresult Selection::ScrollIntoView(SelectionRegion aRegion,
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
if (mFrameSelection->GetBatching()) return NS_OK;
|
||||
if (mFrameSelection->IsBatching()) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
if (!(aFlags & Selection::SCROLL_SYNCHRONOUS))
|
||||
return PostScrollSelectionIntoViewEvent(aRegion, aFlags, aVertical,
|
||||
|
@ -3036,7 +3038,7 @@ nsresult Selection::NotifySelectionListeners() {
|
|||
}
|
||||
|
||||
RefPtr<nsFrameSelection> frameSelection = mFrameSelection;
|
||||
if (frameSelection->GetBatching()) {
|
||||
if (frameSelection->IsBatching()) {
|
||||
frameSelection->SetChangesDuringBatchingFlag();
|
||||
return NS_OK;
|
||||
}
|
||||
|
|
|
@ -1408,7 +1408,9 @@ nsresult nsFrameSelection::TakeFocus(nsIContent* aNewFocus,
|
|||
}
|
||||
|
||||
// Don't notify selection listeners if batching is on:
|
||||
if (GetBatching()) return NS_OK;
|
||||
if (IsBatching()) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
// Be aware, the Selection instance may be destroyed after this call.
|
||||
return NotifySelectionListeners(SelectionType::eNormal);
|
||||
|
|
|
@ -781,7 +781,7 @@ class nsFrameSelection final {
|
|||
// get another.
|
||||
void SetDesiredPos(nsPoint aPos); // set the mDesiredPos.mValue
|
||||
|
||||
uint32_t GetBatching() const { return mBatching.mCounter; }
|
||||
bool IsBatching() const { return mBatching.mCounter > 0; }
|
||||
|
||||
void SetChangesDuringBatchingFlag() {
|
||||
MOZ_ASSERT(mBatching.mCounter > 0);
|
||||
|
|
Загрузка…
Ссылка в новой задаче