forked from mirrors/gecko-dev
		
	Bug 1236040 - When updating the scroll position, only schedule image visibility checks if the display port has changed. r=tn
--HG-- extra : commitid : Hir2YBOuC1J extra : rebase_source : 6c8d9df502979615e9f72a47b035b15d17f9c518
This commit is contained in:
		
							parent
							
								
									8ac683bf41
								
							
						
					
					
						commit
						901b7c53e8
					
				
					 1 changed files with 8 additions and 4 deletions
				
			
		| 
						 | 
					@ -2530,10 +2530,6 @@ ScrollFrameHelper::ScrollToImpl(nsPoint aPt, const nsRect& aRange, nsIAtom* aOri
 | 
				
			||||||
    needImageVisibilityUpdate = true;
 | 
					    needImageVisibilityUpdate = true;
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  if (needImageVisibilityUpdate) {
 | 
					 | 
				
			||||||
    presContext->PresShell()->ScheduleImageVisibilityUpdate();
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  // notify the listeners.
 | 
					  // notify the listeners.
 | 
				
			||||||
  for (uint32_t i = 0; i < mListeners.Length(); i++) {
 | 
					  for (uint32_t i = 0; i < mListeners.Length(); i++) {
 | 
				
			||||||
    mListeners[i]->ScrollPositionWillChange(pt.x, pt.y);
 | 
					    mListeners[i]->ScrollPositionWillChange(pt.x, pt.y);
 | 
				
			||||||
| 
						 | 
					@ -2564,9 +2560,17 @@ ScrollFrameHelper::ScrollToImpl(nsPoint aPt, const nsRect& aRange, nsIAtom* aOri
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (!displayPort.IsEqualEdges(oldDisplayPort)) {
 | 
					    if (!displayPort.IsEqualEdges(oldDisplayPort)) {
 | 
				
			||||||
      mOuter->SchedulePaint();
 | 
					      mOuter->SchedulePaint();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      if (needImageVisibilityUpdate) {
 | 
				
			||||||
 | 
					        presContext->PresShell()->ScheduleImageVisibilityUpdate();
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  } else {
 | 
					  } else {
 | 
				
			||||||
    mOuter->SchedulePaint();
 | 
					    mOuter->SchedulePaint();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if (needImageVisibilityUpdate) {
 | 
				
			||||||
 | 
					      presContext->PresShell()->ScheduleImageVisibilityUpdate();
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  if (mOuter->ChildrenHavePerspective()) {
 | 
					  if (mOuter->ChildrenHavePerspective()) {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue