Kaydet (Commit) 0223eb2c authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Once ~SystemWindow calls ~Window, this is no longer a SystemWindow

...and hopefully it is just as fine to start this safety check at the paren,
anyway.

Change-Id: Ie3d7a1e233b9e3076a6603f2c6312d57b42b0f77
üst 5f50d959
......@@ -65,6 +65,7 @@
#include <com/sun/star/rendering/XSpriteCanvas.hpp>
#include <comphelper/processfactory.hxx>
#include <cassert>
#include <set>
#include <typeinfo>
......@@ -327,13 +328,16 @@ Window::~Window()
Application::Abort(OStringToOUString(aTempStr.makeStringAndClear(), RTL_TEXTENCODING_UTF8)); // abort in debug builds, this must be fixed!
}
Window* pMyParent = this;
Window* pMyParent = GetParent();
SystemWindow* pMySysWin = NULL;
while ( pMyParent )
{
if ( pMyParent->IsSystemWindow() )
pMySysWin = (SystemWindow*)pMyParent;
{
pMySysWin = dynamic_cast<SystemWindow *>(pMyParent);
assert(pMyParent != 0);
}
pMyParent = pMyParent->GetParent();
}
if ( pMySysWin && pMySysWin->ImplIsInTaskPaneList( this ) )
......@@ -349,13 +353,16 @@ Window::~Window()
if( mpWindowImpl->mbIsInTaskPaneList )
{
Window* pMyParent = this;
Window* pMyParent = GetParent();
SystemWindow* pMySysWin = NULL;
while ( pMyParent )
{
if ( pMyParent->IsSystemWindow() )
pMySysWin = (SystemWindow*)pMyParent;
{
pMySysWin = dynamic_cast<SystemWindow *>(pMyParent);
assert(pMyParent != 0);
}
pMyParent = pMyParent->GetParent();
}
if ( pMySysWin && pMySysWin->ImplIsInTaskPaneList( this ) )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment