[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    Re: branches/KDE/3.5
From:       Hasso Tepper <hasso () kde ! org>
Date:       2007-01-15 10:04:15
Message-ID: 200701151204.15972.hasso () kde ! org
[Download RAW message or body]

David Faure wrote:
> On Sunday 14 January 2007 20:50, Hasso Tepper wrote:
> > +      KHTMLPart* const part = static_cast<KHTMLPart *>((KParts::ReadOnlyPart *)(*it)->m_part);
> > +      if (part->inherits("KHTMLPart"))
> 
> Static-casting and then checking the type with inherits(), looks wrong/dangerous.
> Please use 
> KHTMLPart* const part = ::qt_cast<KHTMLPart *>( (*it)->m_part );
> if (part) 
> {
> }

This was copied from KHTMLPartPrivate::setFlagRecursively(), btw.


regards,

-- 
Hasso Tepper
KDE Estonian Team

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic