The best way to do this is below but not for all Android Version So use 2nd or third method specified below
ViewTreeObserver vto = mExpandableListView.getViewTreeObserver();
vto.addOnGlobalLayoutListener(new OnGlobalLayoutListener() {
@Override
public void onGlobalLayout() {
mExpandableListView.setIndicatorBounds(mExpandableListView.getRight()- 40, mExpandableListView.getWidth());
}
});
or this:
@Override
public void onWindowFocusChanged(boolean hasFocus) {
super.onWindowFocusChanged(hasFocus);
mExpandableListView.setIndicatorBounds(mExpandableListView.getRight()- 40, mExpandableListView.getWidth());
}
will move that indicator to right of list view even on device and on tab also.
or you can do this in a postdelayed thread.
(new Handler()).post(new Runnable() {
@Override
public void run() {
mExpandableListView.setIndicatorBounds(mExpandableListView.getRight()- 40, mExpandableListView.getWidth());
}
});