Home
last modified time | relevance | path

Searched refs:getActivity (Results 1 – 25 of 255) sorted by relevance

1234567891011

/frameworks/base/core/tests/coretests/src/android/widget/touchmode/
DFocusableInTouchModeClickTest.java39 assertTrue("should start in touch mode", getActivity().getButton1().isInTouchMode()); in testPreconditions()
40 assertTrue(getActivity().getButton1().isFocused()); in testPreconditions()
45 TouchUtils.clickView(this, getActivity().getButton2()); in testClickGivesFocusNoClickFired()
47 getActivity().getButton2().isFocused()); in testClickGivesFocusNoClickFired()
49 getActivity().isB2Fired()); in testClickGivesFocusNoClickFired()
51 TouchUtils.clickView(this, getActivity().getButton2()); in testClickGivesFocusNoClickFired()
53 getActivity().isB2Fired()); in testClickGivesFocusNoClickFired()
58 TouchUtils.touchAndCancelView(this, getActivity().getButton2()); in testTapGivesFocusNoClickFired()
59 assertFalse("button shouldn't have fired click", getActivity().isB2Fired()); in testTapGivesFocusNoClickFired()
60 assertFalse("button shouldn't have focus", getActivity().getButton2().isFocused()); in testTapGivesFocusNoClickFired()
DChangeTouchModeTest.java47 assertFalse("touch mode", getActivity().isInTouchMode()); in testPreconditions()
52 assertInTouchModeAfterTap(this, getActivity().getFirstButton()); in testTouchingScreenEntersTouchMode()
53 assertTrue("touch mode", getActivity().isInTouchMode()); in testTouchingScreenEntersTouchMode()
58 assertInTouchModeAfterClick(this, getActivity().getFirstButton()); in DISABLE_testDpadDirectionLeavesTouchMode()
60 … assertNotInTouchModeAfterKey(this, KeyEvent.KEYCODE_DPAD_RIGHT, getActivity().getFirstButton()); in DISABLE_testDpadDirectionLeavesTouchMode()
61 assertFalse("touch mode", getActivity().isInTouchMode()); in DISABLE_testDpadDirectionLeavesTouchMode()
88 assertInTouchModeAfterClick(this, getActivity().getFirstButton()); in testTouchModeTrueAcrossActivites()
105 assertFalse("touch mode", getActivity().isInTouchMode()); in testTouchModeChangedInOtherActivity()
124 assertTrue("touch mode", getActivity().isInTouchMode()); in testTouchModeChangedInOtherActivity()
DTouchModeFocusableTest.java46 mEditText = getActivity().getEditText(); in setUp()
47 mButton = getActivity().getButton(); in setUp()
87 assertNull("nothing should have focus", getActivity().getCurrentFocus()); in testEnterTouchModeGivesFocusBackToFocusableInTouchMode()
89 getActivity().getLayout().hasFocus()); in testEnterTouchModeGivesFocusBackToFocusableInTouchMode()
/frameworks/base/core/tests/coretests/src/android/widget/scroll/
DButtonAboveTallInternalSelectionViewTest.java36 getActivity().getButtonAbove().isFocused()); in testPreconditions()
39 getActivity().getScrollView().getScrollY()); in testPreconditions()
41 getActivity().getIsv().getHeight() > getActivity().getScrollView().getHeight()); in testPreconditions()
44 getActivity().getIsv().getTop() > in testPreconditions()
45 getActivity().getScrollView().getScrollY()); in testPreconditions()
54 final InternalSelectionView isv = getActivity().getIsv(); in testMovingFocusDownToItemTallerThanScreenStillOnScreen()
60 getActivity().getIsv().getTop() > in testMovingFocusDownToItemTallerThanScreenStillOnScreen()
61 getActivity().getScrollView().getScrollY()); in testMovingFocusDownToItemTallerThanScreenStillOnScreen()
DScrollViewButtonsAndLabelsTest.java46 mScrollView = getActivity().getScrollView(); in setUp()
47 mLinearLayout = getActivity().getLinearLayout(); in setUp()
68 Button firstButtonOffScreen = getActivity().getButton(offScreenIndex); in testArrowScrollDownOffScreenVerticalFadingEdge()
79 offScreenIndex < getActivity().getNumButtons()); in testArrowScrollDownOffScreenVerticalFadingEdge()
98 int numGroups = getActivity().getNumButtons(); in testArrowScrollDownToBottomElementOnScreen()
99 Button lastButton = getActivity().getButton(numGroups - 1); in testArrowScrollDownToBottomElementOnScreen()
126 Button offScreenButton = getActivity().getButton(offScreenIndex); in testArrowScrollUpOffScreenVerticalFadingEdge()
153 Button topButton = getActivity().getButton(0); in testArrowScrollUpToTopElementOnScreen()
165 int numButtons = getActivity().getNumButtons(); in goToBottomButton()
166 Button lastButton = getActivity().getButton(numButtons - 1); in goToBottomButton()
[all …]
DRequestRectangleVisibleWithInternalScrollTest.java51 mTextBlob = getActivity().getTextBlob(); in setUp()
52 mScrollToBlob = getActivity().getScrollToBlob(); in setUp()
54 mScrollView = (ScrollView) getActivity().findViewById(R.id.scrollView); in setUp()
60 assertEquals(getActivity().getScrollYofBlob(), mTextBlob.getScrollY()); in testPreconditions()
/frameworks/base/core/tests/coretests/src/android/widget/listview/
DListRetainsFocusAcrossLayoutsTest.java32 getActivity().runOnUiThread(new Runnable() { in requestLayoutOnList()
34 getActivity().getListView().requestLayout(); in requestLayoutOnList()
42 getActivity().getChildOfItem(0, 0).isFocused()); in testPreconditions()
51 getActivity().getChildOfItem(0, 2).isFocused()); in testBottomButtonRetainsFocusAfterLayout()
57 getActivity().getChildOfItem(0, 2).isFocused()); in testBottomButtonRetainsFocusAfterLayout()
65 getActivity().getChildOfItem(1, 0).isFocused()); in testTopButtonOfSecondPositionRetainsFocusAfterLayout()
71 getActivity().getChildOfItem(1, 0).isFocused()); in testTopButtonOfSecondPositionRetainsFocusAfterLayout()
80 getActivity().getChildOfItem(1, 2).isFocused()); in testBottomButtonOfSecondPositionRetainsFocusAfterLayout()
86 getActivity().getChildOfItem(1, 2).isFocused()); in testBottomButtonOfSecondPositionRetainsFocusAfterLayout()
/frameworks/base/core/tests/coretests/src/android/widget/focus/
DLinearLayoutGridTest.java42 mRootView = getActivity().getRootView(); in setUp()
47 assertEquals(getActivity().getButtonAt(2, 1), in testGoDownFromMiddle()
50 getActivity().getButtonAt(1, 1), in testGoDownFromMiddle()
56 assertEquals(getActivity().getButtonAt(0, 1), in testGoUpFromMiddle()
59 getActivity().getButtonAt(1, 1), in testGoUpFromMiddle()
65 assertEquals(getActivity().getButtonAt(1, 2), in testGoRightFromMiddle()
68 getActivity().getButtonAt(1, 1), in testGoRightFromMiddle()
74 assertEquals(getActivity().getButtonAt(1, 0), in testGoLeftFromMiddle()
77 getActivity().getButtonAt(1, 1), in testGoLeftFromMiddle()
DGoneParentFocusedChildTest.java39 assertNotNull(getActivity().getLayout()); in testPreconditinos()
40 assertNotNull(getActivity().getGoneGroup()); in testPreconditinos()
41 assertNotNull(getActivity().getButton()); in testPreconditinos()
43 getActivity().getButton().hasFocus()); in testPreconditinos()
46 getActivity().getGoneGroup().getVisibility()); in testPreconditinos()
48 getActivity().isUnhandledKeyEvent()); in testPreconditinos()
54 assertTrue(getActivity().isUnhandledKeyEvent()); in testKeyEventGoesToActivity()
DHorizontalFocusSearchTest.java57 mLayout = getActivity().getLayout(); in setUp()
58 mLeftTall = getActivity().getLeftTall(); in setUp()
59 mMidShort1Top = getActivity().getMidShort1Top(); in setUp()
60 mMidShort2Bottom = getActivity().getMidShort2Bottom(); in setUp()
61 mRightTall = getActivity().getRightTall(); in setUp()
DVerticalFocusSearchTest.java70 mLayout = getActivity().getLayout(); in setUp()
71 mTopWide = getActivity().getTopWide(); in setUp()
72 mMidSkinny1Left = getActivity().getMidSkinny1Left(); in setUp()
73 mMidSkinny2Right = getActivity().getMidSkinny2Right(); in setUp()
74 mBottomWide = getActivity().getBottomWide(); in setUp()
/frameworks/base/core/tests/coretests/src/android/widget/scroll/arrowscroll/
DTallTextAboveButtonTest.java36 mScrollView = getActivity().getScrollView(); in setUp()
37 mTopText = getActivity().getContentChildAt(0); in setUp()
38 mBottomButton = getActivity().getContentChildAt(1); in setUp()
50 … + "is on screen), but " + getActivity().getScrollView().findFocus() + " does instead", in testPreconditions()
51 getActivity().getScrollView().isFocused()); in testPreconditions()
64 …assertTrue("scroll view should have focus, but " + getActivity().getScrollView().findFocus() + " d… in testGainFocusAsScrolledOntoScreen()
65 getActivity().getScrollView().isFocused()); in testGainFocusAsScrolledOntoScreen()
73 …assertTrue("scroll view should have focus, but " + getActivity().getScrollView().findFocus() + " d… in testScrollingButtonOffScreenLosesFocus()
74 getActivity().getScrollView().isFocused()); in testScrollingButtonOffScreenLosesFocus()
DShortButtonsTest.java41 mScrollView = getActivity().getScrollView(); in setUp()
47 getActivity().getButtonAt(0).getHeight() in testPreconditions()
51 getActivity().getLinearLayout().getHeight() in testPreconditions()
52 > getActivity().getScrollView().getHeight()); in testPreconditions()
57 final int numButtons = getActivity().getNumButtons(); in testScrollDownToBottomThroughButtons()
61 final Button button = getActivity().getButtonAt(i); in testScrollDownToBottomThroughButtons()
68 getActivity().getLinearLayout().getHeight() - mScrollView.getHeight(), in testScrollDownToBottomThroughButtons()
74 final int numButtons = getActivity().getNumButtons(); in testScrollFromBottomToTopThroughButtons()
76 final Button lastButton = getActivity().getButtonAt(numButtons - 1); in testScrollFromBottomToTopThroughButtons()
90 final Button button = getActivity().getButtonAt(i); in testScrollFromBottomToTopThroughButtons()
DButtonsWithTallTextViewInBetweenTest.java46 mScrollView = getActivity().getScrollView(); in setUp()
47 mTopButton = getActivity().getTopButton(); in setUp()
48 mMiddleFiller = getActivity().getMiddleFiller(); in setUp()
49 mBottomButton = getActivity().getBottomButton(); in setUp()
106 getActivity().getLinearLayout().getHeight() - mScrollView.getHeight(), in testScrollDownToBottomButton()
121 final int maxScroll = getActivity().getLinearLayout().getHeight() in testPanBottomButtonOffScreenLosesFocus()
/frameworks/base/core/tests/coretests/src/android/view/
DRunQueueTest.java34 final RunQueue activity = getActivity(); in testRunnableRan()
41 final RunQueue activity = getActivity(); in testRunnableCancelled()
48 final RunQueue activity = getActivity(); in testListenerFired()
55 final RunQueue activity = getActivity(); in testTreeObserverKilled()
DBigCacheTest.java45 final BigCache activity = getActivity(); in setUp()
58 final int max = ViewConfiguration.get(getActivity()).getScaledMaximumDrawingCacheSize(); in testDrawingCacheBelowMaximumSize()
66 final int max = ViewConfiguration.get(getActivity()).getScaledMaximumDrawingCacheSize();
73 getActivity().runOnUiThread(new Runnable() { in createCacheForView()
DIncludeTest.java39 final Include activity = getActivity(); in testIncluded()
50 final Include activity = getActivity(); in testIncludedWithLayoutParams()
63 final Include activity = getActivity(); in testIncludedWithVisibility()
72 final Include activity = getActivity(); in testIncludedWithSize()
DViewStubTest.java40 final StubbedView activity = getActivity(); in testStubbed()
49 final StubbedView activity = getActivity(); in testInflated()
60 final StubbedView activity = getActivity(); in testInflatedId()
73 final StubbedView activity = getActivity(); in testInflatedLayoutParams()
/frameworks/base/core/tests/coretests/src/android/animation/
DEventsTest.java227 getActivity().runOnUiThread(new Runnable() { in testStartCancel()
250 getActivity().runOnUiThread(new Runnable() { in testStartEnd()
273 getActivity().runOnUiThread(new Runnable() { in testStartDelayedCancel()
296 getActivity().runOnUiThread(new Runnable() { in testStartDelayedEnd()
318 getActivity().runOnUiThread(new Runnable() { in testPlayingCancel()
341 getActivity().runOnUiThread(new Runnable() { in testPlayingEnd()
365 getActivity().runOnUiThread(new Runnable() { in testPlayingDelayedCancel()
389 getActivity().runOnUiThread(new Runnable() { in testPlayingDelayedEnd()
412 getActivity().runOnUiThread(new Runnable() { in testPlayingDelayedCancelMidDelay()
439 getActivity().runOnUiThread(new Runnable() { in testPlayingDelayedEndMidDelay()
[all …]
DViewPropertyAnimatorTest.java140 final BasicAnimatorActivity activity = getActivity(); in setUp()
206 getActivity().runOnUiThread(new Runnable() { in testStartCancel()
229 getActivity().runOnUiThread(new Runnable() { in testStartDelayedCancel()
251 getActivity().runOnUiThread(new Runnable() { in testPlayingCancel()
275 getActivity().runOnUiThread(new Runnable() { in testPlayingDelayedCancel()
298 getActivity().runOnUiThread(new Runnable() { in testPlayingDelayedCancelMidDelay()
326 getActivity().runOnUiThread(new Runnable() { in testStartDoubleCancel()
350 getActivity().runOnUiThread(new Runnable() { in testStartDelayedDoubleCancel()
/frameworks/base/test-runner/src/android/test/
DActivityInstrumentationTestCase.java68 public T getActivity() { in getActivity() method in ActivityInstrumentationTestCase
69 return (T) super.getActivity(); in getActivity()
83 getActivity().finish(); in tearDown()
95 assertNotNull("activity should be launched successfully", getActivity()); in testActivityTestCaseSetUpProperly()
DActivityInstrumentationTestCase2.java96 public T getActivity() { in getActivity() method in ActivityInstrumentationTestCase2
97 Activity a = super.getActivity(); in getActivity()
163 Activity a = super.getActivity(); in tearDown()
187 getActivity(); in runTest()
/frameworks/base/core/tests/coretests/src/android/widget/listview/focus/
DListHorizontalFocusWithinItemWinsTest.java44 mListView = getActivity().getListView(); in setUp()
45 mTopLeftButton = getActivity().getTopLeftButton(); in setUp()
46 mTopRightButton = getActivity().getTopRightButton(); in setUp()
47 mBottomMiddleButton = getActivity().getBottomMiddleButton(); in setUp()
DListButtonsDiagonalAcrossItemsTest.java48 mLeftButton = getActivity().getLeftButton(); in setUp()
49 mCenterButton = getActivity().getCenterButton(); in setUp()
50 mRightButton = getActivity().getRightButton(); in setUp()
52 mListView = getActivity().getListView(); in setUp()
/frameworks/base/core/tests/coretests/src/android/widget/listview/arrowscroll/
DListWithOnItemSelectedActionTest.java36 mListView = getActivity().getListView(); in setUp()
48 getActivity().getHeaderValue()); in testPreconditions()
58 getActivity().getHeaderValue()); in testHeaderEchoesSelectionAfterMove()

1234567891011