android_guides icon indicating copy to clipboard operation
android_guides copied to clipboard

Defining Custom Views - getTrianglePath() allocating new Points/Path in onDraw()

Open teotigraphix opened this issue 8 years ago • 1 comments

This is a no-no and it's not caught by the compiler(IDE) because it's in a caller method.

Just some best practices, especially for a custom view guide.

(If I had the time I would fix it but just wanted to note this.)

https://github.com/codepath/android_guides/wiki/Defining-Custom-Views

teotigraphix avatar Jan 11 '18 23:01 teotigraphix

@teotigraphix Good catch 👍 , I updated the wiki page Defining-Custom-Views

DevHossamHassan avatar Jan 12 '18 17:01 DevHossamHassan