Closed
Bug 307426
Opened 19 years ago
Closed 19 years ago
ensureSelectedElementIsVisible does not handle the case of no selected element
Categories
(Toolkit :: UI Widgets, defect)
Toolkit
UI Widgets
Tracking
()
VERIFIED
FIXED
mozilla1.8beta5
People
(Reporter: readams, Assigned: readams)
Details
(Keywords: fixed1.8)
Attachments
(1 file)
|
723 bytes,
patch
|
doronr
:
first-review+
mconnor
:
second-review+
mtschrep
:
approval1.8b5+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.7.10) Gecko/20050825 Firefox/1.0.6 (Ubuntu package 1.0.6) Build Identifier: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.7.10) Gecko/20050825 Firefox/1.0.6 (Ubuntu package 1.0.6) there are situations in which the code calls ensureSelectedElementIsVisible when no such element exists (such as from _refreshSelection) but this function does not handle this case. Trivial patch to be attached to simply make this function check before trying to select a null list item. Reproducible: Always
Quite certain, since with current branch builds, my xulrunner app sees lots XPCOM bad pointer complaints stemming from this. It may make sense to fix it in scrollbox rather than the XBL though; not sure of the desired semantics here. In my experience, most XPCOM object hate it when you pass null to them :-)
Updated•19 years ago
|
Attachment #195190 -
Flags: first-review+
Comment 4•19 years ago
|
||
do we need a toolkit peer review?
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Updated•19 years ago
|
Attachment #195190 -
Flags: second-review+
Updated•19 years ago
|
Flags: blocking1.8b5? → blocking1.8b5+
Updated•19 years ago
|
Assignee: nobody → readams
Status: ASSIGNED → NEW
Comment 6•19 years ago
|
||
Trunk: mozilla/toolkit/content/widgets/richlistbox.xml; new revision: 1.23;
Status: NEW → RESOLVED
Closed: 19 years ago
OS: Linux → All
Hardware: PC → All
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.8beta5
Updated•19 years ago
|
Whiteboard: [needs approval]
Updated•19 years ago
|
Attachment #195190 -
Flags: approval1.8b5?
Comment 7•19 years ago
|
||
Comment on attachment 195190 [details] [diff] [review] Add a check for a selected item in ensureSelectedItemIsVisible Per bug meeting - approved for 1.8b5.
Attachment #195190 -
Flags: approval1.8b5? → approval1.8b5+
Updated•19 years ago
|
Flags: blocking1.9a1?
Updated•19 years ago
|
Whiteboard: [needs approval]
Comment 8•19 years ago
|
||
1.8 Branch: Checking in richlistbox.xml; /cvsroot/mozilla/toolkit/content/widgets/richlistbox.xml,v <-- richlistbox.xml new revision: 1.13.2.7; previous revision: 1.13.2.6 done
Status: RESOLVED → VERIFIED
Keywords: fixed1.8
Comment 9•19 years ago
|
||
(In reply to comment #2) > Are you sure the scrollbox doesn't already take that into consideration? Just FYI: the scrollbox in fact didn't take this into consideration, which is why we got Bug 308098. The patch over there however got a little closer to where the problem actually occurred (ensureElementIsVisible got also called with a null parameter from otherwhere). This patch here won't hurt, though.
You need to log in
before you can comment on or make changes to this bug.
Description
•