Mercurial > projects > dwt-mac
comparison dwt/graphics/Image.d @ 8:a9ab4c738ed8
Fix: instanceof
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Wed, 27 Aug 2008 14:32:39 +0200 |
parents | e831403a80a9 |
children | b9226997409c |
comparison
equal
deleted
inserted
replaced
7:e831403a80a9 | 8:a9ab4c738ed8 |
---|---|
545 * | 545 * |
546 * @see #hashCode | 546 * @see #hashCode |
547 */ | 547 */ |
548 public bool equals (Object object) { | 548 public bool equals (Object object) { |
549 if (object is this) return true; | 549 if (object is this) return true; |
550 if (!(object instanceof Image)) return false; | 550 if (!( null !is cast(Image)object )) return false; |
551 Image image = cast(Image)object; | 551 Image image = cast(Image)object; |
552 return device is image.device && handle is image.handle && | 552 return device is image.device && handle is image.handle && |
553 transparentPixel is image.transparentPixel; | 553 transparentPixel is image.transparentPixel; |
554 } | 554 } |
555 | 555 |