Search in sources :

Example 16 with LLOfButtons2

use of android.widget.layout.linear.LLOfButtons2 in project android_frameworks_base by ResurrectionRemix.

the class ChangeTouchModeTest method testTouchModeFalseAcrossActivites.

@MediumTest
public void testTouchModeFalseAcrossActivites() throws Exception {
    getInstrumentation().waitForIdleSync();
    LLOfButtons2 otherActivity = null;
    try {
        otherActivity = launchActivity("com.android.frameworks.coretests", LLOfButtons2.class, null);
        assertNotNull(otherActivity);
        assertFalse(otherActivity.isInTouchMode());
    } finally {
        if (otherActivity != null) {
            otherActivity.finish();
        }
    }
}
Also used : LLOfButtons2(android.widget.layout.linear.LLOfButtons2) MediumTest(android.test.suitebuilder.annotation.MediumTest)

Example 17 with LLOfButtons2

use of android.widget.layout.linear.LLOfButtons2 in project android_frameworks_base by crdroidandroid.

the class ChangeTouchModeTest method testTouchModeChangedInOtherActivity.

@LargeTest
public void testTouchModeChangedInOtherActivity() throws Exception {
    assertFalse("touch mode", getActivity().isInTouchMode());
    LLOfButtons2 otherActivity = null;
    try {
        otherActivity = launchActivity("com.android.frameworks.coretests", LLOfButtons2.class, null);
        assertNotNull(otherActivity);
        assertFalse(otherActivity.isInTouchMode());
        assertInTouchModeAfterClick(this, otherActivity.getFirstButton());
        assertTrue(otherActivity.isInTouchMode());
    } finally {
        if (otherActivity != null) {
            otherActivity.finish();
        }
    }
    // need to wait for async update back to window to occur
    Thread.sleep(200);
    assertTrue("touch mode", getActivity().isInTouchMode());
}
Also used : LLOfButtons2(android.widget.layout.linear.LLOfButtons2) LargeTest(android.test.suitebuilder.annotation.LargeTest)

Example 18 with LLOfButtons2

use of android.widget.layout.linear.LLOfButtons2 in project android_frameworks_base by crdroidandroid.

the class ChangeTouchModeTest method testTouchModeTrueAcrossActivites.

@LargeTest
public void testTouchModeTrueAcrossActivites() throws Exception {
    assertInTouchModeAfterClick(this, getActivity().getFirstButton());
    LLOfButtons2 otherActivity = null;
    try {
        otherActivity = launchActivity("com.android.frameworks.coretests", LLOfButtons2.class, null);
        assertNotNull(otherActivity);
        assertTrue(otherActivity.isInTouchMode());
    } finally {
        if (otherActivity != null) {
            otherActivity.finish();
        }
    }
}
Also used : LLOfButtons2(android.widget.layout.linear.LLOfButtons2) LargeTest(android.test.suitebuilder.annotation.LargeTest)

Aggregations

LLOfButtons2 (android.widget.layout.linear.LLOfButtons2)18 LargeTest (android.test.suitebuilder.annotation.LargeTest)12 MediumTest (android.test.suitebuilder.annotation.MediumTest)6