Guest User

Untitled

a guest
Jul 16th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. 05-03 10:07:12.803: ERROR/AndroidRuntime(14042): FATAL EXCEPTION: Thread-9
  2.  
  3. 05-03 10:07:12.803: ERROR/AndroidRuntime(14042): java.lang.NullPointerException
  4.  
  5. 05-03 10:07:12.803: ERROR/AndroidRuntime(14042): at android.graphics.Canvas.throwIfRecycled(Canvas.java:954)
  6.  
  7. 05-03 10:07:12.803: ERROR/AndroidRuntime(14042): at android.graphics.Canvas.drawBitmap(Canvas.java:980)
  8.  
  9. 05-03 10:07:12.803: ERROR/AndroidRuntime(14042): at com.the.line.Panel.onDraw(Panel.java:59)
  10.  
  11. canvas.drawBitmap(kangoo, 10, 10, null);
  12.  
  13. 05-03 10:07:12.803: ERROR/AndroidRuntime(14042): at com.the.line.CanvasThread.run(CanvasThread.java:28)
  14.  
  15. _panel.onDraw(c);
  16.  
  17. private static void throwIfRecycled(Bitmap bitmap) {
  18. if (bitmap.isRecycled()) {
  19. throw new RuntimeException(
  20. "Canvas: trying to use a recycled bitmap " + bitmap);
  21. }
  22. }
  23.  
  24. Bitmap kangoo = BitmapFactory.decodeResource(getResources(),
  25. R.drawable.kangoo);
Add Comment
Please, Sign In to add comment