Closed
Bug 143959
Opened 23 years ago
Closed 23 years ago
Prompts only work once per session
Categories
(Core :: Layout, defect, P1)
Core
Layout
Tracking
()
VERIFIED
FIXED
mozilla1.0.1
People
(Reporter: bzbarsky, Assigned: waterson)
References
()
Details
(Keywords: regression, smoketest)
Attachments
(2 files, 1 obsolete file)
4.51 KB,
patch
|
dbaron
:
review+
kinmoz
:
superreview+
|
Details | Diff | Splinter Review |
3.55 KB,
patch
|
dbaron
:
review+
kinmoz
:
superreview+
|
Details | Diff | Splinter Review |
BUILD: everything starting with linux trunk 2002-05-10-21. Works fine in linux
trunk 2002-05-10-07
STEPS TO REPRODUCE:
1) Load the URL in the "URL" field of this bug
2) Click either OK or Cancel on the first prompt
3) Try to type in the text entry field on the second prompt
EXPECTED RESULTS: Be able to type
ACTUAL RESULTS: no characters appear in the textbox
NOTES:
I have verified that reverting to a clean tree from friday morning makes the
problem go away. Applying the patch for bug 129115 the causes the problem to
reappear.
This affects at least the following prompt dialogs: prompt() from JS, Basic
Authentication for HTTP, login to mailserver for mailnews. Once a basic prompt
has been posed for any of these purposes, no prompt dialog can be typed in.
Reporter | ||
Comment 1•23 years ago
|
||
Oh, as a note the prompt _can_ be dismissed and will send the right info. It's
just that it never reflows to show the text you have typed.
Reporter | ||
Comment 2•23 years ago
|
||
*** Bug 143968 has been marked as a duplicate of this bug. ***
Is there a chance we might not be setting the reflow root frame state bit on the
textbox?
From doing a quick debug, it looks like there's a missing AppendReflowCommand()
happening in the prompt dialog.
I see this sequence when typing in an empty textfield in this bug page:
CancelReflowCommandInternal
AppendReflowCommand
CancelReflowCommandInternal
AppendReflowCommand
In the prompt case, I only see:
CancelReflowCommandInternal
AppendReflowCommand
CancelReflowCommandInternal
So by the time the editor forces a flush, there's nothing in the reflow queue.
Assignee | ||
Comment 7•23 years ago
|
||
This patch disables the dirty reflow coalescing that block frames do. (It's
really not that necessary given the way the reflow tree works, but we might as
well figure out why it broke.)
Comment 8•23 years ago
|
||
*** Bug 143700 has been marked as a duplicate of this bug. ***
Assignee | ||
Comment 9•23 years ago
|
||
Attachment 83378 [details] [diff] checked in on the trunk to get the tree open. Lowering
severity; continuing to investigate.
Severity: blocker → critical
Keywords: regression
OS: Linux → All
Priority: -- → P1
Hardware: PC → All
Target Milestone: --- → mozilla1.0.1
Comment 10•23 years ago
|
||
*** Bug 143700 has been marked as a duplicate of this bug. ***
Updated•23 years ago
|
Severity: critical → blocker
OS: All → Linux
Priority: P1 → --
Hardware: All → PC
Target Milestone: mozilla1.0.1 → ---
Comment 11•23 years ago
|
||
I think this bug affects bookmarks when you file a bookmark and create a new
folder. If you delete all of the default text of "New Folder" and then type,
you don't see anything actually print out in the text box. However, if you
click "Ok", the folder does get created with the name of whatever you typed in.
Jake
rjesup says he never even hit submit so we have no idea why Bugzilla changed
some entries. Changing them back (I hope).
Severity: blocker → critical
OS: Linux → All
Priority: -- → P1
Hardware: PC → All
Target Milestone: --- → mozilla1.0.1
Reporter | ||
Comment 13•23 years ago
|
||
Jesup likely ran into this morning's other blocker -- bug 143917
Assignee | ||
Comment 14•23 years ago
|
||
Here's the real fix. It reverts the previous change to nsBlockFrame.cpp and
fixes the problem in nsBoxLayoutState.cpp.
The change to nsBoxLayoutState.cpp is really a one-liner (although I've blown
it out of proportion by adding comments and renaming a variable for clarity's
sake). nsBoxReflowState::Unwind needs to pass the _root box_ during the
recursion, not the current frame's box.
Unwind works by recursively descending through the reflow tree to each of the
target frames. Along the way, it clears the NS_FRAME_HAS_DIRTY_CHILDREN bit for
each of the frames along the path. When if finally _does_ reach a target, it
resets the NS_FRAME_HAS_DIRTY_CHILDREN bit on the root box's frame, and then
calls MarkDirty on the target box.
MarkDirty walks back up through the box's ancestor chain until it reaches a
frame with the NS_FRAME_HAS_DIRTY_CHILDREN bit set. For each ancestor, it
re-sets the NS_FRAME_HAS_DIRTY_CHILDREN bit and does some initialization magic
to prepare the box for an impending relayout. If MarkDirty walks off the top of
the box hierarchy, then it will schedule a reflow command at the root box's
frame. Hence, the need to pass aRootBox down to the target frame, so that we
can properly initialize the relayout without scheduling another reflow command!
I suspect that we're doing more work than we need to do here, but would rather
fix this and then file another bug to investigate and optimize.
Attachment #83378 -
Attachment is obsolete: true
Comment 15•23 years ago
|
||
Attachment #83415 -
Flags: superreview+
Comment on attachment 83415 [details] [diff] [review]
a real fix.
r=dbaron, except:
1. Why don't we want to get rid of that |#if 0| block for good?
2. I really don't understand why Unwind needs to do all that work. What
happens if we don't clear the dirty bits?
Attachment #83415 -
Flags: superreview+ → review+
Attachment #83415 -
Flags: superreview+
Comment 17•23 years ago
|
||
*** Bug 144268 has been marked as a duplicate of this bug. ***
Assignee | ||
Comment 18•23 years ago
|
||
Changes checked in. I've filed bug 144306 on the first issue dbaron raised, and
bug 144308 on the second.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 19•23 years ago
|
||
Damn. Too much champagne and donuts this afternoon. I just noticed that the
`subject' line in mail doesn't update properly with these changes. Re-opening so
I can track _that_ problem down.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 20•23 years ago
|
||
Allright, it turns out that there are some cases where not all of the boxes are
marked with NS_FRAME_HAS_DIRTY_CHILDREN when a reflow is targeted at both the
root box and a box beneath the root.
Which means that my code to leave the NS_FRAME_HAS_DIRTY_CHILDREN bit untouched
after we hit a reflow target breaks, because we end up in a situation like
this:
x <-- A
o
o
x
x
x <-- B
Where `x' means the NS_FRAME_HAS_DIRTY_CHILDREN bit is set, `o' means it isn't,
and `<--' means that the frame is the target of a reflow. In this situation,
MarkDirty on frame `B' ends up being essentially a no-op, because the NS_FHDC
bit is already set.
This patch eliminates the `aClearDirtyBits' check, so we _always_ clear dirty
bits on the path to the target. This means that the hierarchy will look like
this when Unwind arrives at `B':
x <-- A
o
o
o
o
o <-- B
So, when we MarkDirty, _all_ of the ancestors back to the root will be marked
with NS_FHDC.
(I think that I was confused when I added this code: I was probably patching
around the mistage that I've corrected in patch 83415; namely, failure to pass
aRootBox down through the recursion.)
Comment on attachment 83462 [details] [diff] [review]
third time's the charm?
r=dbaron
Attachment #83462 -
Flags: review+
Comment 22•23 years ago
|
||
*** Bug 144422 has been marked as a duplicate of this bug. ***
Comment 23•23 years ago
|
||
Attachment #83462 -
Flags: superreview+
Assignee | ||
Comment 24•23 years ago
|
||
Fixed, knock on wood.
Status: REOPENED → RESOLVED
Closed: 23 years ago → 23 years ago
Resolution: --- → FIXED
Comment 25•23 years ago
|
||
verified on windows commercial build 2002-05-15-04-trunk
Status: RESOLVED → VERIFIED
Comment 26•23 years ago
|
||
It is dead ! Yes ! Hate this one ! Very good trunk build :-)
Using 2002051504 - WinXP
*** Bug 144637 has been marked as a duplicate of this bug. ***
You need to log in
before you can comment on or make changes to this bug.
Description
•