Closed Bug 20771 Opened 26 years ago Closed 26 years ago

contents disappear when input hidden and redisplayed

Categories

(Core :: Layout: Form Controls, defect, P3)

x86
Linux
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: dbaron, Assigned: nisheeth_mozilla)

References

Details

Attachments

(2 files)

DESCRIPTION: If an input element is (dynamically) given 'display: none' and then set back to 'display: inline', the contents disappear. STEPS TO REPRODUCE: * load attached test case * type something in the input * Hit "Hide" * Hit "Show" ACTUAL RESULTS: * the text is gone EXPECTED RESULTS: * text should still remain DOES NOT WORK CORRECTLY ON: * Linux, mozilla, 1999-12-02-16-M12 ADDITIONAL INFORMATION: This may be a dependency of bug 19093.
Assignee: karnaze → pollmann
Reassigning to Eric.
Assignee: pollmann → buster
Steve, have you seen this? This doesn't appear to be simply a matter of failing to repaint or reflow. The entered text is wiped out completely. I can't make it reappear by forcing a repaint (dragging a window across the input), a reflow (resizing the window), trying to select or cursor through the text. I typed the word test into the input then dumped the frame model, saw this: ... stuff ... TextControl(input)(1)@0x83c48e8 [view=0x8257038] {0,15,2160,270} [state=00000034]< Viewport(-1)@0x82860a0 {0,0,2100,210} [state=00000004] sc=0x8285cd0< GfxScroll(-1)@0x8286758 {0,0,2100,210} [state=00000004] sc=0x8286388< Scroll(-1)@0x82867e8 next=0x8286f40 {0,0,2100,210} [state=00000004] sc=0x828b1b0< Root(-1)@0x8286320 {0,0,2100,210} sc=0x828b820< Area(html)(-1)@0x828c078 {0,0,2100,210} [state=000c0004] sc=0x828bca8(i=0,b=1)< line 0x828d308: count=1 state=block,,,[0x202] {0,0,2100,210} < Block(body)(1)@0x828d290 {0,0,2100,210} [state=00000014] sc=0x8290168(i=1,b=0)< line 0x8286ef0: count=1 state=inline,,,[0x200] {0,0,420,210} < Text(0)@0x8352098[0,4,T] {0,0,420,210} [state=40000234] sc=0x8291d58< "test" ... more stuff ... Note that the string is stored in the last frame above. When I clicked on the hide button, then dumped the frame model, this entire subtree of the frame model was gone. Clicking the show button reconstructed the frames, but did not restore the state. Nisheeth just checked in something that will store frame state when frames are destroyed, then restore it when they are recreated. I don't know if his checkin will fix this problem, but it is a solution that should be looked at here. CC'ing Nisheeth - can you take a look at this testcase if you get a chance? Do you think it is a good candidate to add the stateful frame logic?
Assignee: buster → nisheeth
Status: NEW → ASSIGNED
Depends on: 16709
This bug will be fixed when I check in my changes to save/restore state for frames. I just tested this on my local build with my changes and the test case works fine. Re-assigning this to myself.
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
The fix for this is checked in.
Verifying on: -Linux RedHat6.2 build 2000-09-19-21-M18 -Windows 98 build 2000-09-20-05-M18
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: