Home
last modified time | relevance | path

Searched refs:ApplicationsState (Results 1 – 5 of 5) sorted by relevance

/aosp14/frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/applications/
H A DApplicationsStateTest.java33 private ApplicationsState.AppEntry mEntry;
37 mEntry = mock(ApplicationsState.AppEntry.class); in setUp()
45 assertThat(ApplicationsState.FILTER_GAMES.filterApp(mEntry)).isTrue(); in testGamesFilterAcceptsGameDeprecated()
52 assertThat(ApplicationsState.FILTER_GAMES.filterApp(mEntry)).isTrue(); in testGameFilterAcceptsCategorizedGame()
60 assertThat(ApplicationsState.FILTER_GAMES.filterApp(mEntry)).isTrue(); in testGameFilterAcceptsCategorizedGameAndDeprecatedIsGame()
67 assertThat(ApplicationsState.FILTER_GAMES.filterApp(mEntry)).isFalse(); in testGamesFilterRejectsNotGame()
74 assertThat(ApplicationsState.FILTER_AUDIO.filterApp(mEntry)).isTrue(); in testAudioFilterAcceptsCategorizedAudio()
81 assertThat(ApplicationsState.FILTER_AUDIO.filterApp(mEntry)).isFalse(); in testAudiosFilterRejectsNotAudio()
88 assertThat(ApplicationsState.FILTER_AUDIO.filterApp(mEntry)).isFalse(); in testAudiosFilterRejectsDefaultCategory()
123 assertThat(ApplicationsState.FILTER_PHOTOS.filterApp(mEntry)).isTrue(); in testPhotosFilterAcceptsFilter()
[all …]
/aosp14/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/applications/
H A DAppUtilsTest.java61 private ApplicationsState.AppEntry mAppEntry;
62 private ArrayList<ApplicationsState.AppEntry> mAppEntries;
139 final ApplicationsState.AppEntry appEntry = mock(ApplicationsState.AppEntry.class); in isAppInstalled_hasAppEntryWithInstalledFlag_shouldReturnTrue()
148 final ApplicationsState.AppEntry appEntry = mock(ApplicationsState.AppEntry.class); in isAppInstalled_hasAppEntryWithoutInstalledFlag_shouldReturnFalse()
154 private ApplicationsState.AppEntry createAppEntry(ApplicationInfo appInfo, int id) { in createAppEntry()
155 ApplicationsState.AppEntry appEntry = new ApplicationsState.AppEntry(mContext, appInfo, id); in createAppEntry()
161 Field field = ApplicationsState.AppEntry.class.getDeclaredField("apkFile"); in createAppEntry()
H A DApplicationsStateRoboTest.java295 mSession.rebuild(ApplicationsState.FILTER_EVERYTHING, ApplicationsState.SIZE_COMPARATOR); in testDefaultSession_isResumed_LoadsAll()
323 mSession.rebuild(ApplicationsState.FILTER_EVERYTHING, ApplicationsState.SIZE_COMPARATOR); in testDefaultSession_isPaused_NotLoadsAll()
335 mSession.rebuild(ApplicationsState.FILTER_EVERYTHING, ApplicationsState.SIZE_COMPARATOR); in testCustomSessionLoadsIconsOnly()
354 mSession.rebuild(ApplicationsState.FILTER_EVERYTHING, ApplicationsState.SIZE_COMPARATOR); in testCustomSessionLoadsSizesOnly()
372 mSession.rebuild(ApplicationsState.FILTER_EVERYTHING, ApplicationsState.SIZE_COMPARATOR); in testCustomSessionLoadsHomeOnly()
391 mSession.rebuild(ApplicationsState.FILTER_EVERYTHING, ApplicationsState.SIZE_COMPARATOR); in testCustomSessionLoadsLeanbackOnly()
423 ApplicationsState in removeAndInstall_noWorkprofile_doResumeIfNeededLocked_shouldClearEntries()
461 ApplicationsState in noAppRemoved_noWorkprofile_doResumeIfNeededLocked_shouldNotClearEntries()
519 ApplicationsState in removeProfileApp_workprofileExists_doResumeIfNeededLocked_shouldClearEntries()
593 ApplicationsState in removeOwnerApp_workprofileExists_doResumeIfNeededLocked_shouldClearEntries()
[all …]
/aosp14/frameworks/base/packages/SettingsLib/src/com/android/settingslib/applications/
H A DAppUtils.java66 public static CharSequence getLaunchByDefaultSummary(ApplicationsState.AppEntry appEntry, in getLaunchByDefaultSummary()
141 return ApplicationsState.getInstance((Application) context.getApplicationContext()) in isHiddenSystemModule()
149 return ApplicationsState.getInstance((Application) context.getApplicationContext()) in isSystemModule()
227 public static Drawable getIcon(Context context, ApplicationsState.AppEntry appEntry) { in getIcon()
262 public static Drawable getIconFromCache(ApplicationsState.AppEntry appEntry) { in getIconFromCache()
277 ArrayList<ApplicationsState.AppEntry> appEntries, int number) { in preloadTopIcons()
283 final ApplicationsState.AppEntry entry = appEntries.get(i); in preloadTopIcons()
296 public static boolean isAppInstalled(ApplicationsState.AppEntry appEntry) { in isAppInstalled()
303 private static void setAppEntryMounted(ApplicationsState.AppEntry appEntry, boolean mounted) { in setAppEntryMounted()
H A DApplicationsState.java88 public class ApplicationsState { class
102 static ApplicationsState sInstance;
107 public static ApplicationsState getInstance(Application app) { in getInstance()
112 static ApplicationsState getInstance(Application app, IPackageManager iPackageManager) { in getInstance()
115 sInstance = new ApplicationsState(app, iPackageManager); in getInstance()
203 private ApplicationsState(Application app, IPackageManager iPackageManager) { in ApplicationsState() method in ApplicationsState
2045 public boolean filterApp(ApplicationsState.AppEntry info) {