OpenLayers OpenLayers

Ticket #514 (closed feature: fixed)

Opened 2 years ago

Last modified 1 year ago

Safari: getCurrentSize fails on display:none elements

Reported by: crschmidt Assigned to: crschmidt
Priority: major Milestone: 2.4 Release
Component: general Version: SVN
Keywords: Cc:
State:

Description

Elements with display:none set will fail to return the correct value for getCurrentSize in Safari. Hidden elements return 'NaN' for clientWidth (as opposed to '0' from other browsers) so the fallback logic in getCurrentSize is never executed. The Overview Map not working in Safari is a symptom of this bug: because the overview map element is created as display:none, the map has 0 size on creation, and is therefore not displayed correctly.

Confirmed with svn r2301.

Attachments

safari.patch (2.0 kB) - added by crschmidt on 03/05/07 01:55:59.
Fix getCurrentSize for hidden elements in safari

Change History

03/05/07 01:55:59 changed by crschmidt

  • attachment safari.patch added.

Fix getCurrentSize for hidden elements in safari

03/05/07 01:58:26 changed by crschmidt

  • keywords set to review.

Attached patch includes getCurrentSize fix. It also includes a standalone test file. Because our current test framework does not handle safari, this file is not integrated into the existing framework, but instead implements a a single regression test, while allowing for the addition of other safari-only breakages to the file.

03/05/07 07:49:48 changed by sderle

  • status changed from new to closed.
  • resolution set to fixed.

Applied as r2206.

07/05/07 17:03:22 changed by euzuro

  • keywords deleted.