[haiku-commits] r38086 - haiku/trunk/src/servers/app/drawing/Painter

  • From: pulkomandy@xxxxxxxxxxxxxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 13 Aug 2010 15:18:36 +0200 (CEST)

Author: pulkomandy
Date: 2010-08-13 15:18:36 +0200 (Fri, 13 Aug 2010)
New Revision: 38086
Changeset: http://dev.haiku-os.org/changeset/38086

Modified:
   haiku/trunk/src/servers/app/drawing/Painter/Painter.cpp
Log:
CID 1556 : wrong cast type.


Modified: haiku/trunk/src/servers/app/drawing/Painter/Painter.cpp
===================================================================
--- haiku/trunk/src/servers/app/drawing/Painter/Painter.cpp     2010-08-13 
12:59:43 UTC (rev 38085)
+++ haiku/trunk/src/servers/app/drawing/Painter/Painter.cpp     2010-08-13 
13:18:36 UTC (rev 38086)
@@ -903,7 +903,7 @@
        if (gradient.GetType() == BGradient::TYPE_LINEAR
                && (fDrawingMode == B_OP_COPY || fDrawingMode == B_OP_OVER)) {
                const BGradientLinear* linearGradient
-                       = dynamic_cast<const BGradientLinear*>(&gradient);
+                       = static_cast<const BGradientLinear*>(&gradient);
                if (linearGradient->Start().x == linearGradient->End().x
                        // TODO: Remove this second check once the optimized 
method
                        // handled "upside down" gradients as well...


Other related posts: