Status

()

RESOLVED FIXED
17 years ago
17 years ago

People

(Reporter: n-baxley, Assigned: jst)

Tracking

Trunk
x86
All
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment)

(Reporter)

Description

17 years ago
You can't change the rows and cols property of a given frameset.  The given url
is an example that should change the size of a frameset after telling you which
frameset you are altering.  It is working on the proper frameset since the alert
is using the frameset objects ID.  This example works fine in IE 5.5.

Comment 1

17 years ago
Browser, not engine ---> DOM Level 0. Here is the key function involved:

<html><head><title>Untitled</title>
<script language="JavaScript1.2">

function setFrameRows(framesetID, newRowsString)
{
  //alert(framesetID + ":" + newRowsString);
  frameset = top.document.getElementById(framesetID)
  alert("Trying to resize " + frameset.id);
  frameset.rows = newRowsString;
}

</script>
</head>

<body>

<a href="#Shrink" onclick="setFrameRows('FramesetLeft', '*, 50');">Minimize</a>
<a href="#Shrink" onclick="setFrameRows('FramesetLeft', '50%, *');">Restore</a>

</body></html>
Assignee: rogerl → jst
Component: JavaScript Engine → DOM Level 0
QA Contact: pschwartau → desale

Comment 2

17 years ago
Confirming reported behavior with Mozilla trunk binary 20020317xx.
Nothing happens when you click the links. No errors in JS Console.

Note: this testcase also does not work in NN4.7. Is this IE-only syntax?
Status: UNCONFIRMED → NEW
Ever confirmed: true

Comment 3

17 years ago
The DOM Level 1 does define a rows and cols attribute on the HTMLFrameSetElement
interface. See
http://www.w3.org/TR/REC-DOM-Level-1/level-one-html.html#ID-43829095.   It
doesn't say if it is writeable or not though.  I assume that the addressing on
the Frameset element is correct since you can pull the ID from it.

Comment 4

17 years ago
cc'ing Boris, jkeiser, because I think they'd be interested in this -

Comment 5

17 years ago
I've updated the above test page
(http://www.baxleys.org/Mozilla/Frames/resizeframeset.html) to show the rows
value before and after the change.  It appears to be changing the value, but the
screen is not being updated (redrawn?).  Here is the function as it stands now:

function setFrameRows(framesetID, newRowsString) {
   frameset = top.document.getElementById(framesetID)
   alert("Original frameset rows value for " + frameset.id + "=" + frameset.rows);
   frameset.rows = newRowsString;
   alert("New frameset rows value for " + frameset.id + "=" + frameset.rows);
}
Yes, in the code, we do not do anything when you change the rows or cols
attributes.  We don't want to do a reframe because currently, frames will end up
reloading their document on reframe (this is true after jst's landing as well, I
believe).
OS: Windows 2000 → All

Comment 7

17 years ago
see also bug 48422, bug 63980, and bug 69347. I can't really figure out whether
there's a dup in there, but I thought it might be interesting.
hmm, methinks I may be wrong, and someone else is catching the cols/rows change.

Comment 9

17 years ago
nsHTMLFrameSetElement.cpp
204 if ((aAttribute == nsHTMLAtoms::rows) ||
205 (aAttribute == nsHTMLAtoms::cols)) {
206 aHint = NS_STYLE_HINT_FRAMECHANGE;
207 }

Comment 10

17 years ago
Created attachment 93717 [details]
with body.rows frames resize but frameset seems to crash
Fixed by bug 48422 being fixed.
Status: NEW → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.