java.lang.IllegalStateException: caused by targetIndex == -1

GitHub | stay4cold | 6 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    GitHub comment 2#242675996

    GitHub | 6 months ago | stay4cold
    java.lang.IllegalStateException: caused by targetIndex == -1

    Root Cause Analysis

    1. java.lang.IllegalStateException

      caused by targetIndex == -1

      at com.heaven7.android.dragflowlayout.DragFlowLayout$InternalItemHelper.onRemoveView()
    2. com.heaven7.android
      AlertWindowHelper$DragTouchListener.onTouch
      1. com.heaven7.android.dragflowlayout.DragFlowLayout$InternalItemHelper.onRemoveView(DragFlowLayout.java:616)
      2. com.heaven7.android.dragflowlayout.DragFlowLayout.removeView(DragFlowLayout.java:470)
      3. com.heaven7.android.dragflowlayout.DefaultDragCallback.removeFromParent(DefaultDragCallback.java:79)
      4. com.heaven7.android.dragflowlayout.DefaultDragCallback.onRemoveView(DefaultDragCallback.java:72)
      5. com.heaven7.android.dragflowlayout.DragFlowLayout$InternalItemHelper.dispatchViewRemove(DragFlowLayout.java:585)
      6. com.heaven7.android.dragflowlayout.DragFlowLayout$InternalItemHelper.onRemoveView(DragFlowLayout.java:628)
      7. com.heaven7.android.dragflowlayout.DragFlowLayout.removeView(DragFlowLayout.java:470)
      8. com.heaven7.android.dragflowlayout.DragFlowLayout.processOverlap(DragFlowLayout.java:371)
      9. com.heaven7.android.dragflowlayout.DragFlowLayout.access$200(DragFlowLayout.java:29)
      10. com.heaven7.android.dragflowlayout.DragFlowLayout$2.onMove(DragFlowLayout.java:89)
      11. com.heaven7.android.dragflowlayout.AlertWindowHelper$DragTouchListener.onTouch(AlertWindowHelper.java:131)
      11 frames
    3. Android Platform
      ViewGroup.dispatchTouchEvent
      1. android.view.View.dispatchTouchEvent(View.java:8657)
      2. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2517)
      3. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2161)
      3 frames
    4. com.heaven7.android
      DragFlowLayout.onTouchEvent
      1. com.heaven7.android.dragflowlayout.DragFlowLayout.onTouchEvent(DragFlowLayout.java:504)
      1 frame
    5. Android Platform
      ViewGroup.dispatchTouchEvent
      1. android.view.View.dispatchTouchEvent(View.java:8668)
      2. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2517)
      3. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2161)
      4. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      5. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      6. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      7. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      8. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      9. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      10. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      11. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      12. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      13. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      14. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      15. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      16. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      17. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      18. android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2523)
      19. android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2175)
      19 frames
    6. Android
      PhoneWindow.superDispatchTouchEvent
      1. com.android.internal.policy.impl.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:2514)
      2. com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1785)
      2 frames
    7. Android Platform
      Activity.dispatchTouchEvent
      1. android.app.Activity.dispatchTouchEvent(Activity.java:2807)
      1 frame
    8. Android v7
      WindowCallbackWrapper.dispatchTouchEvent
      1. android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
      1 frame
    9. Android
      PhoneWindow$DecorView.dispatchTouchEvent
      1. com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:2471)
      1 frame
    10. Android Platform
      ViewRootImpl$AsyncInputStage.apply
      1. android.view.View.dispatchPointerEvent(View.java:8874)
      2. android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4729)
      3. android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4587)
      4. android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4086)
      5. android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4139)
      6. android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4105)
      7. android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:4242)
      8. android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4113)
      9. android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:4299)
      9 frames