Available Methods
- setAdapter ( )
- setOnItemClickListener ( )
- INVALID_POSITION
- setLayoutParams ( )
- getCheckedItemPosition ( )
- getAdapter ( )
- getItemAtPosition ( )
- setDivider ( )
- setEmptyView ( )
- getFirstVisiblePosition ( )
- setId ( )
- addHeaderView ( )
- setChoiceMode ( )
- getLayoutParams ( )
- setOnItemLongClickListener ( )
- getChildAt ( )
- setOnScrollListener ( )
- setItemChecked ( )
- getDividerHeight ( )
- setSelection ( )
- getChildCount ( )
- setSelector ( )
- addFooterView ( )
- setDividerHeight ( )
- getCount ( )
- setCacheColorHint ( )
- setPadding ( )
- getLastVisiblePosition ( )
- setVisibility ( )
- setVerticalScrollBarEnabled ( )
- setItemsCanFocus ( )
- setScrollBarStyle ( )
- post ( )
- setFastScrollEnabled ( )
- setSelectionFromTop ( )
- setBackgroundColor ( )
- requestLayout ( )
- setFadingEdgeLength ( )
- setDrawSelectorOnTop ( )
- setClickable ( )
- setMultiChoiceModeListener ( )
- LayoutParams ( )
- CHOICE_MODE_NONE
- setOnTouchListener ( )
- getPaddingBottom ( )
- getHeight ( )
- setTranscriptMode ( )
- getPositionForView ( )
- setOnCreateContextMenuListener ( )
- setFooterDividersEnabled ( )
- isItemChecked ( )
- getVisibility ( )
- getParent ( )
- CHOICE_MODE_MULTIPLE_MODAL
- getPaddingTop ( )
- getDivider ( )
- setStackFromBottom ( )
- setVerticalFadingEdgeEnabled ( )
- getCheckedItemPositions ( )
- setOverScrollMode ( )
- CHOICE_MODE_SINGLE
- setDrawingCacheEnabled ( )
- getWidth ( )
- smoothScrollToPosition ( )
- setClipToPadding ( )
- setRecyclerListener ( )
- setTag ( )
- setScrollbarFadingEnabled ( )
- getLocationOnScreen ( )
- getContext ( )
- getId ( )
- postDelayed ( )
Related Classes
- java.io.File
- java.util.Collections
- android.os.Bundle
- android.content.Context
- android.view.View
- android.util.Log
- android.widget.TextView
- android.content.Intent
- android.view.ViewGroup
- android.app.Activity
- android.view.LayoutInflater
- android.os.Build
- android.widget.Toast
- android.widget.ImageView
- android.graphics.Color
- android.os.Handler
- android.net.Uri
- android.widget.Button
- android.text.TextUtils
- android.view.MotionEvent
- android.widget.LinearLayout
- android.support.annotation.Nullable
- android.widget.EditText
- android.content.SharedPreferences
- android.support.annotation.NonNull
Java Code Examples for android.widget.listview#getLocationOnScreen()
The following examples show how to use
android.widget.listview#getLocationOnScreen() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ListBuddiesLayout.java From UltimateAndroid with Apache License 2.0 | 6 votes |
private void findViewClicked(MotionEvent event, float eventY, ListView list) { mChildCount = list.getChildCount(); mListViewCoords = new int[2]; list.getLocationOnScreen(mListViewCoords); int x = (int) event.getRawX() - mListViewCoords[0]; int y = (int) event.getRawY() - mListViewCoords[1]; View child; for (int i = 0; i < mChildCount; i++) { child = list.getChildAt(i); child.getHitRect(mRect); if (mRect.contains(x, y)) { mDownView = child; mDownEventY = eventY; break; } } }
Example 2
Source File: ListBuddiesLayout.java From UltimateAndroid with Apache License 2.0 | 6 votes |
private void findViewClicked(MotionEvent event, float eventY, ListView list) { mChildCount = list.getChildCount(); mListViewCoords = new int[2]; list.getLocationOnScreen(mListViewCoords); int x = (int) event.getRawX() - mListViewCoords[0]; int y = (int) event.getRawY() - mListViewCoords[1]; View child; for (int i = 0; i < mChildCount; i++) { child = list.getChildAt(i); child.getHitRect(mRect); if (mRect.contains(x, y)) { mDownView = child; mDownEventY = eventY; break; } } }
Example 3
Source File: ListBuddiesLayout.java From ListBuddies with Apache License 2.0 | 6 votes |
private void findViewClicked(MotionEvent event, float eventY, ListView list) { mChildCount = list.getChildCount(); mListViewCoords = new int[2]; list.getLocationOnScreen(mListViewCoords); int x = (int) event.getRawX() - mListViewCoords[0]; int y = (int) event.getRawY() - mListViewCoords[1]; View child; for (int i = 0; i < mChildCount; i++) { child = list.getChildAt(i); child.getHitRect(mRect); if (mRect.contains(x, y)) { mDownView = child; mDownEventY = eventY; break; } } }