mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 19:35:51 +00:00
Bug 195355 listBoxObject.getRowCount() returns wrong value r=varga sr=bienvenu
This commit is contained in:
parent
775215ff0d
commit
82d9c1aaa2
@ -1259,7 +1259,8 @@ nsListBoxBodyFrame::ListBoxInsertFrames(nsIFrame* aPrevFrame, nsIFrame* aFrameLi
|
||||
void
|
||||
nsListBoxBodyFrame::OnContentInserted(nsIPresContext* aPresContext, nsIContent* aChildContent)
|
||||
{
|
||||
++mRowCount;
|
||||
if (mRowCount >= 0)
|
||||
++mRowCount;
|
||||
|
||||
nsIPresShell *shell = aPresContext->PresShell();
|
||||
// The RDF content builder will build content nodes such that they are all
|
||||
@ -1299,7 +1300,8 @@ nsListBoxBodyFrame::OnContentInserted(nsIPresContext* aPresContext, nsIContent*
|
||||
void
|
||||
nsListBoxBodyFrame::OnContentRemoved(nsIPresContext* aPresContext, nsIFrame* aChildFrame, PRInt32 aIndex)
|
||||
{
|
||||
--mRowCount;
|
||||
if (mRowCount >= 0)
|
||||
--mRowCount;
|
||||
|
||||
if (!aChildFrame) {
|
||||
// The row we are removing is out of view, so we need to try to
|
||||
|
Loading…
Reference in New Issue
Block a user