mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-26 23:23:33 +00:00
Improve performance on Mac: make the root view invisible
This commit is contained in:
parent
fa82921b1c
commit
f8315aa628
@ -650,6 +650,13 @@ nsresult DocumentViewerImpl::MakeWindow(nsNativeWidget aNativeParent,
|
||||
// Setup hierarchical relationship in view manager
|
||||
mViewManager->SetRootView(mView);
|
||||
|
||||
#ifdef XP_MAC
|
||||
// Making the root view invisible on Mac slightly improves the performance.
|
||||
// It's not much but it helps. Besides, there is no reason not to make it invisble:
|
||||
// it's entirely covered by other views and we don't use it to paint, just to resize.
|
||||
mView->SetVisibility(nsViewVisibility_kHide);
|
||||
#endif
|
||||
|
||||
mView->GetWidget(mWindow);
|
||||
|
||||
//set frame rate to 25 fps
|
||||
|
Loading…
x
Reference in New Issue
Block a user