Modal popup: Reuse the viewport size to avoid some layout thrashing. When showing the modal popup, first the viewport size is measured to determine the size of the background and later it's measured again to determine the position to center the popup. In between the size of the background is set. So the second time the viewport size is measured, the browser needs to recalculate styles and layout. We avoid this by avoiding measuring the viewport size for a second time.
Modal popup: Reuse the viewport size to avoid some layout thrashing.
When showing the modal popup, first the viewport size is measured to determine the size of the background and later it's measured again to determine the position to center the popup. In between the size of the background is set. So the second time the viewport size is measured, the browser needs to recalculate styles and layout. We avoid this by avoiding measuring the viewport size for a second time.

See also #13 on b/13672409.
-------------
Created by MOE: http://code.google.com/p/moe-java
MOE_MIGRATED_REVID=66785455

moagrius/closure-library,real/closure-library,Anish2/closure-library,AlastairTaft/closure-library,Tinkerforge/tvpl-closure-library,plu83/closure-library,yathit/closure-library,mail-apps/closure-library,ducklord/closure-library,manakor/closure-library,google/closure-library,codyebberson/closure-library,sevaseva/closure-library,igrep/closure-library,sevaseva/closure-library,kangkot/closure-library,sunilkumargit/closure-library,neraliu/closure-library,moagrius/closure-library,Luzzifa/closure-library,Dominator008/closure-library,jbnicolai/closure-library,Ju2ender/closure-library,mrourke/closure-library,ominux/closure-library,AlastairTaft/closure-library,sunilkumargit/closure-library,maureknob/blockly-maure,ikabirov/closure-library,mail-apps/closure-library,federkasten/closure-library,kencheung/closure-library,joeltine/closure-library,nicks/closure-library,kangkot/closure-library,JasOXIII/closure-library,vincenta/closure-library,Medium/closure-library,ralic/closure-library,mail-apps/closure-library,Dominator008/closure-library,sevaseva/closure-library,jbnicolai/closure-library,AlexanderZon/closure-library,alexg-dev/closure-library,real/closure-library,redforks/closure-library,ducklord/closure-library,beni55/closure-library,ominux/closure-library,yathit/closure-library,ikabirov/closure-library,Prinhotels/closure-library,joeltine/closure-library,vlkous/closure-library,jooking/closure-library,bebbi/closure-library,plu83/closure-library,ralic/closure-library,jvu/closure-library,vlkous/closure-library,Medium/closure-library,AlexanderZon/closure-library,Dominator008/closure-library,grpbwl/closure-library,concavelenz/closure-library,teppeis/closure-library,AlexanderZon/closure-library,gfredericks/closure-library,gingerik/closure-library,redforks/closure-library,vlkous/closure-library,rikuayanokozy/closure-library,beni55/closure-library,ominux/closure-library,nicks/closure-library,beni55/closure-library,valerysamovich/closure-library,gfredericks/closure-library,concavelenz/closure-library,alexg-dev/closure-library,AlexanderZon/closure-library,rikuayanokozy/closure-library,mrourke/closure-library,JasOXIII/closure-library,bebbi/closure-library,google/closure-library,nicks/closure-library,kencheung/closure-library,mrourke/closure-library,ChadKillingsworth/closure-library,yathit/closure-library,ducklord/closure-library,valerysamovich/closure-library,valerysamovich/closure-library,plu83/closure-library,chrisprice/closure-library,ikabirov/closure-library,kangkot/closure-library,jhiswin/idiil-closure-library,jeffbcross/closure-library,codyebberson/closure-library,kencheung/closure-library,ralic/closure-library,codyebberson/closure-library,grpbwl/closure-library,gterzian/closure-library,mail-apps/closure-library,ducklord/closure-library,ralic/closure-library,ChadKillingsworth/closure-library,real/closure-library,sunilkumargit/closure-library,moagrius/closure-library,platinumpixs/google-closure-library,vlkous/closure-library,Medium/closure-library,moagrius/closure-library,vincenta/closure-library,Prinhotels/closure-library,lewistg/closure-library,google/closure-library,JasOXIII/closure-library,gterzian/closure-library,jvu/closure-library,gterzian/closure-library,Anish2/closure-library,igrep/closure-library,Prinhotels/closure-library,Prinhotels/closure-library,chone/closure-library,teppeis/closure-library,google/closure-library,manakor/closure-library,lewistg/closure-library,chone/closure-library,AlastairTaft/closure-library,federkasten/closure-library,vincenta/closure-library,maureknob/blockly-maure,gingerik/closure-library,Anish2/closure-library,AlastairTaft/closure-library,kangkot/closure-library,teppeis/closure-library,plu83/closure-library,ikabirov/closure-library,gfredericks/closure-library,grpbwl/closure-library,Tinkerforge/tvpl-closure-library,jhiswin/idiil-closure-library,platinumpixs/google-closure-library,rikuayanokozy/closure-library,jupeter/composer-closure-library,valerysamovich/closure-library,manakor/closure-library,nicks/closure-library,beni55/closure-library,federkasten/closure-library,concavelenz/closure-library,rikuayanokozy/closure-library,neraliu/closure-library,lucidsoftware/closure-library,gingerik/closure-library,Luzzifa/closure-library,JasOXIII/closure-library,lucidsoftware/closure-library,alexg-dev/closure-library,kencheung/closure-library,jupeter/composer-closure-library,Ju2ender/closure-library,jooking/closure-library,sunilkumargit/closure-library,igrep/closure-library,jeffbcross/closure-library,federkasten/closure-library,neraliu/closure-library,jhiswin/idiil-closure-library,Luzzifa/closure-library,sevaseva/closure-library,chone/closure-library,Medium/closure-library,chrisprice/closure-library,jeffbcross/closure-library,chrisprice/closure-library,bebbi/closure-library,Ju2ender/closure-library,vincenta/closure-library,gfredericks/closure-library,Tinkerforge/tvpl-closure-library,ominux/closure-library,Luzzifa/closure-library,concavelenz/closure-library,real/closure-library,jupeter/composer-closure-library,jvu/closure-library,mrourke/closure-library,maureknob/blockly-maure,ChadKillingsworth/closure-library,neraliu/closure-library,codyebberson/closure-library,alexg-dev/closure-library,chone/closure-library,jooking/closure-library,teppeis/closure-library,Ju2ender/closure-library,Tinkerforge/tvpl-closure-library,chrisprice/closure-library,redforks/closure-library,grpbwl/closure-library,bebbi/closure-library,jeffbcross/closure-library,platinumpixs/google-closure-library,lucidsoftware/closure-library,Anish2/closure-library,lewistg/closure-library,gingerik/closure-library,lewistg/closure-library,manakor/closure-library,google/closure-library,gterzian/closure-library,joeltine/closure-library,yathit/closure-library,maureknob/blockly-maure,lucidsoftware/closure-library,platinumpixs/google-closure-library,joeltine/closure-library,jooking/closure-library,jbnicolai/closure-library,jbnicolai/closure-library,ChadKillingsworth/closure-library,jhiswin/idiil-closure-library,jvu/closure-library,Dominator008/closure-library,redforks/closure-library,igrep/closure-library