Bug 1771736 part 2: Only push a cache update for text if the text actually changes. r=morgan
Layout sends a11y text update notifications during reflow even if the text hasn't changed. TextUpdater already detects this case, so just move our cache update calls to TextUpdater. Differential Revision: https://phabricator.services.mozilla.com/D147656
This commit is contained in:
@@ -5,7 +5,6 @@
|
||||
|
||||
#include "NotificationController.h"
|
||||
|
||||
#include "CacheConstants.h"
|
||||
#include "DocAccessible-inl.h"
|
||||
#include "DocAccessibleChild.h"
|
||||
#include "nsEventShell.h"
|
||||
@@ -745,10 +744,6 @@ void NotificationController::WillRefresh(mozilla::TimeStamp aTime) {
|
||||
#endif
|
||||
|
||||
TextUpdater::Run(mDocument, textAcc->AsTextLeaf(), text.mString);
|
||||
if (IPCAccessibilityActive() &&
|
||||
StaticPrefs::accessibility_cache_enabled_AtStartup()) {
|
||||
mDocument->QueueCacheUpdate(textAcc, CacheDomain::Text);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user