Opened 13 years ago

Closed 13 years ago

Last modified 12 years ago

#1043 closed defect (fixed)

dojo.lfx.html.wipeIn() does not work for elements with display:none

Reported by: hannes.wyss@… Owned by: bill
Priority: high Milestone:
Component: General Version: 0.3
Keywords: Cc: hannes.wyss@…, markus.huggler@…
Blocked By: Blocking:

Description

Before creating an Animation, wipeIn calls dojo.style.show to ensure a positive scrollHeight:

dojo.lfx.html.wipeIn = function(nodes, duration, easing, callback){
    [...]
    node.style.height = "0px";
    dojo.style.show(node);

    var anim = dojo.lfx.propertyAnimation(node,
      [{  property: "height",
        start: 0,
        end: node.scrollHeight }], duration, easing);
    [...]
}

Changes in dojo.style.show() (does not set style.display = 'block' anymore) have broken this behavior.

Suggested fix: replace dojo.style.show(node) with dojo.style.setDisplay(node, 'block'):

--- src/lfx/html.js     (revision 4544)
+++ src/lfx/html.js     (working copy)
@@ -206,7 +206,7 @@
                        node.style.overflow = "hidden";
                }
                node.style.height = "0px";
-               dojo.style.show(node);
+               dojo.style.setDisplay(node, "block");

                var anim = dojo.lfx.propertyAnimation(node,
                        [{      property: "height",

Tested on Firefox 1.5.0.1 and IE 6

TIA

Hannes & Maege

Change History (4)

comment:1 Changed 13 years ago by dylan

Milestone: 0.4
Owner: changed from anonymous to Bryan Forbes

comment:2 Changed 13 years ago by bill

Owner: changed from Bryan Forbes to bill
Status: newassigned

comment:3 Changed 13 years ago by bill

Resolution: fixed
Status: assignedclosed

(In [6158]) Various fixes related to wipeIn()/wipeOut(). Fixes #1043, #1626, #704, #1316, #1605, and gap between title pane label and content

comment:4 Changed 12 years ago by (none)

Milestone: 0.4

Milestone 0.4 deleted

Note: See TracTickets for help on using tickets.