OpenLayers OpenLayers

Changeset 6638

Show
Ignore:
Timestamp:
03/27/08 09:01:25 (10 months ago)
Author:
crschmidt
Message:

Improve performance when not using transitions by not forcing a reflow,
which can slow rendering significantly when many layers are in place.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/openlayers/lib/OpenLayers/Tile/Image.js

    r6452 r6638  
    395395        // Force a reflow on gecko based browsers to actually show the element 
    396396        // before continuing execution. 
    397         if (navigator.userAgent.toLowerCase().indexOf("gecko") != -1) {  
    398             this.frame.scrollLeft = this.frame.scrollLeft;  
    399         }  
     397        if (OpenLayers.Util.indexOf(this.layer.SUPPORTED_TRANSITIONS,  
     398                this.layer.transitionEffect) != -1) { 
     399            if (navigator.userAgent.toLowerCase().indexOf("gecko") != -1) {  
     400                this.frame.scrollLeft = this.frame.scrollLeft;  
     401            }  
     402        } 
    400403    }, 
    401404