[interfacekit] Re: BRect implementation

On 2003-10-15 at 16:59:31 [+0200], burton666@xxxxxxxxx wrote:
> ---------- Initial Header -----------
> 
> >From      : interfacekit-bounce@xxxxxxxxxxxxx
> To          : "interfacekit" interfacekit@xxxxxxxxxxxxx
> Cc          :
> Date      : Wed, 15 Oct 2003 13:40:33 +0200
> Subject : [interfacekit] BRect implementation
> 
> > I guess you already know that our current BRect implementation has a 
> > serious flaw
> > (BRect::Intersects() return false if one rect completely contains the 
> > other
> > one). I guess it's time to fix it. This is the code: blablabla. Can I 
> > commit
> > it ?
>                                                  ^^^^^^
> Whoops! this "blablabla" isn't exactly the code I wanted to put there... I 
> guess I should re-read my emails before sending them ;P
> I hope that no one felt offended by that :)
> 
> The code should look like:
> 
> bool
> BRect::Intersects(BRect rect)
> {
>   if !(rect.left > right || rect.right < left || rect.top > bottom || 
>   rect.bottom < top)
>       return true;
>   return false;
> }

Looks good.

CU, Ingo

Other related posts: