Mouthful hey?
Anyway, I have a pagePanel that I dimensionally resize (append and
remove panels from), and these panels all contain instances of the
same containerControl.
When I click the + (Add Page) button, I do the following
pagePanel.Append
referenceArray.append new containerControlClass
referenceArray
(ubound
(ReferenceArray
)).embedWithinPanel
(pagePanel,pagePanel.pagecount-1,0,0,pagePanel.width,pagePanel.height)
When I close a page, I do the following
ConainerControl(referenceArray(index)).close
referenceArray.remove(index)
pagePanel.remove(index)
All works fine when adding pages. Removing pages is not so smooth.
If I remove the last page, then everything works as expected.
If I remove any other page, then every page AFTER the one I close
shows up empty. The instances still exist (mainwindow.contents) and
have the correct panelIndex property values. I simply cannot get them
to show up again. Any panels I append afterwards show up again
properly, with the "phantom" panels in the middle not showing up.
Is the pagePanel broken, or are containerControls broken? Or am I
doing something weird?
Does anyone have a simple sample project that shows this actually
working?
Cheers,
Tom Benson
QEDIT Pty Ltd
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>
|