Not sure what this could be. The following code draws two circles for me:
public void draw(Canvas canvas, MapView view, boolean shadow) {
//if (!shadow) return;
Point center = new Point(canvas.getWidth() / 2, canvas.getHeight() /
2);
int radius = (int) (Math.min(canvas.getWidth(), canvas.getHeight())
* 0.4);
Paint paint = new Paint();
paint.setStyle(Paint.Style.STROKE);
paint.setStrokeWidth(3);
paint.setAntiAlias(true);
if (shadow) {
center.offset(5, 5);
paint.setARGB(255, 150, 150, 150);
}
canvas.drawCircle(center.x, center.y, radius, paint);
}
If I uncomment the "if (!shadow) return;", it draws just the gray circle.
If I change it to "if (shadow) return;", it draws just the black circle.
Steve
On Tue, Aug 17, 2010 at 6:28 AM, TreKing <[email protected]> wrote:
> On Tue, Aug 17, 2010 at 2:15 AM, oriharel <[email protected]> wrote:
>
>> the fact is when I run this code with if (!shadow) then it draws the arc.
>> but this code doesn't draw the arc.
>>
>
> Well, in THAT case, I don't know =P
> I assumed that should work, but apparently not.
> And unfortunately the Google Maps API documentation is pretty terrible, so
> it's not much help.
> Some clarification from the people that wrote the thing would be nice, but
> that's probably not going to happen.
> Searching online and playing with it are probably your best option at this
> point.
> Good luck.
>
>
> -------------------------------------------------------------------------------------------------
> TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
> transit tracking app for Android-powered devices
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<android-developers%[email protected]>
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en