/developers/build/prebuilts/gradle/MediaBrowserService/Application/src/main/java/com/example/android/mediasession/service/ |
D | MusicService.java | 193 public void onPlaybackStateChange(PlaybackStateCompat state) { in onPlaybackStateChange() argument 195 mSession.setPlaybackState(state); in onPlaybackStateChange() 198 switch (state.getState()) { in onPlaybackStateChange() 200 mServiceManager.moveServiceToStartedState(state); in onPlaybackStateChange() 203 mServiceManager.updateNotificationForPause(state); in onPlaybackStateChange() 206 mServiceManager.moveServiceOutOfStartedState(state); in onPlaybackStateChange() 213 private void moveServiceToStartedState(PlaybackStateCompat state) { in moveServiceToStartedState() argument 216 mPlayback.getCurrentMedia(), state, getSessionToken()); in moveServiceToStartedState() 228 private void updateNotificationForPause(PlaybackStateCompat state) { in updateNotificationForPause() argument 232 mPlayback.getCurrentMedia(), state, getSessionToken()); in updateNotificationForPause() [all …]
|
/developers/build/prebuilts/gradle/MediaBrowserService/Application/src/main/java/com/example/android/mediasession/ui/ |
D | MediaSeekBar.java | 108 public void onPlaybackStateChanged(PlaybackStateCompat state) { in onPlaybackStateChanged() argument 109 super.onPlaybackStateChanged(state); in onPlaybackStateChanged() 117 final int progress = state != null in onPlaybackStateChanged() 118 ? (int) state.getPosition() in onPlaybackStateChanged() 125 if (state != null && state.getState() == PlaybackStateCompat.STATE_PLAYING) { in onPlaybackStateChanged() 126 final int timeToEnd = (int) ((getMax() - progress) / state.getPlaybackSpeed()); in onPlaybackStateChanged()
|
/developers/samples/android/media/MediaBrowserService/Application/src/main/java/com/example/android/mediasession/ui/ |
D | MediaSeekBar.java | 108 public void onPlaybackStateChanged(PlaybackStateCompat state) { in onPlaybackStateChanged() argument 109 super.onPlaybackStateChanged(state); in onPlaybackStateChanged() 117 final int progress = state != null in onPlaybackStateChanged() 118 ? (int) state.getPosition() in onPlaybackStateChanged() 125 if (state != null && state.getState() == PlaybackStateCompat.STATE_PLAYING) { in onPlaybackStateChanged() 126 final int timeToEnd = (int) ((getMax() - progress) / state.getPlaybackSpeed()); in onPlaybackStateChanged()
|
/developers/samples/android/media/MediaBrowserService/Application/src/main/java/com/example/android/mediasession/service/ |
D | MusicService.java | 236 public void onPlaybackStateChange(PlaybackStateCompat state) { in onPlaybackStateChange() argument 238 mSession.setPlaybackState(state); in onPlaybackStateChange() 241 switch (state.getState()) { in onPlaybackStateChange() 243 mServiceManager.moveServiceToStartedState(state); in onPlaybackStateChange() 246 mServiceManager.updateNotificationForPause(state); in onPlaybackStateChange() 249 mServiceManager.moveServiceOutOfStartedState(state); in onPlaybackStateChange() 256 private void moveServiceToStartedState(PlaybackStateCompat state) { in moveServiceToStartedState() argument 259 mPlayback.getCurrentMedia(), state, getSessionToken()); in moveServiceToStartedState() 271 private void updateNotificationForPause(PlaybackStateCompat state) { in updateNotificationForPause() argument 275 mPlayback.getCurrentMedia(), state, getSessionToken()); in updateNotificationForPause() [all …]
|
/developers/samples/android/media/MediaRouter/Application/src/main/java/com/example/android/mediarouter/player/ |
D | PlaylistItem.java | 54 public void setState(int state) { in setState() argument 55 mPlaybackState = state; in setState() 116 String state[] = { in toString() local 128 + state[mPlaybackState] + "] " + mUri.toString(); in toString()
|
/developers/build/prebuilts/gradle/MediaRouter/Application/src/main/java/com/example/android/mediarouter/player/ |
D | PlaylistItem.java | 54 public void setState(int state) { in setState() argument 55 mPlaybackState = state; in setState() 116 String state[] = { in toString() local 128 + state[mPlaybackState] + "] " + mUri.toString(); in toString()
|
/developers/build/prebuilts/gradle/AutoBackupForApps/Application/src/main/java/com/example/android/autobackupsample/ |
D | Utils.java | 30 String state = Environment.getExternalStorageState(); in isExternalStorageAvailable() local 31 if (!Environment.MEDIA_MOUNTED.equals(state)) { in isExternalStorageAvailable()
|
/developers/samples/android/content/AutoBackupForApps/Application/src/main/java/com/example/android/autobackupsample/ |
D | Utils.java | 30 String state = Environment.getExternalStorageState(); in isExternalStorageAvailable() local 31 if (!Environment.MEDIA_MOUNTED.equals(state)) { in isExternalStorageAvailable()
|
/developers/build/prebuilts/gradle/BatchStepSensor/Application/src/main/java/com/example/android/batchstepsensor/cardstream/ |
D | StreamRetentionFragment.java | 32 public void storeCardStream(CardStreamState state) { in storeCardStream() argument 33 mState = state; in storeCardStream()
|
D | CardStreamFragment.java | 228 public void restoreState(CardStreamState state, OnCardClickListener callback) { in restoreState() argument 230 for (Card c : state.hiddenCards) { in restoreState() 236 final HashSet<String> dismissibleCards = state.dismissibleCards; in restoreState() 239 for (Card c : state.visibleCards) { in restoreState() 247 final String firstShown = state.shownTag; in restoreState()
|
/developers/build/prebuilts/gradle/WearSpeakerSample/wear/src/main/java/com/example/android/wearable/speaker/ |
D | MainActivity.java | 100 public void onUIStateChanged(UIAnimation.UIState state) { in onUIStateChanged() argument 101 Log.d(TAG, "UI State is: " + state); in onUIStateChanged() 102 if (mUiState == state) { in onUIStateChanged() 105 switch (state) { in onUIStateChanged() 108 mUiState = state; in onUIStateChanged() 113 mUiState = state; in onUIStateChanged() 139 mUiState = state; in onUIStateChanged() 146 mUiState = state; in onUIStateChanged() 151 mUiState = state; in onUIStateChanged() 156 mUiState = state; in onUIStateChanged()
|
D | UIAnimation.java | 195 UIState(int state) { in UIState() argument 196 mState = state; in UIState() 199 static UIState getUIState(int state) { in getUIState() argument 201 if (uiState.mState == state) { in getUIState() 210 void onUIStateChanged(UIState state); in onUIStateChanged() argument
|
/developers/samples/android/wearable/wear/WearSpeakerSample/wear/src/main/java/com/example/android/wearable/speaker/ |
D | MainActivity.java | 101 public void onUIStateChanged(UIAnimation.UIState state) { in onUIStateChanged() argument 102 Log.d(TAG, "UI State is: " + state); in onUIStateChanged() 103 if (mUiState == state) { in onUIStateChanged() 106 switch (state) { in onUIStateChanged() 109 mUiState = state; in onUIStateChanged() 114 mUiState = state; in onUIStateChanged() 140 mUiState = state; in onUIStateChanged() 147 mUiState = state; in onUIStateChanged() 152 mUiState = state; in onUIStateChanged() 157 mUiState = state; in onUIStateChanged()
|
D | UIAnimation.java | 195 UIState(int state) { in UIState() argument 196 mState = state; in UIState() 199 static UIState getUIState(int state) { in getUIState() argument 201 if (uiState.mState == state) { in getUIState() 210 void onUIStateChanged(UIState state); in onUIStateChanged() argument
|
/developers/build/prebuilts/gradle/BatchStepSensor/Application/src/main/java/com/example/android/batchstepsensor/ |
D | MainActivity.java | 72 CardStreamState state = mRetentionFragment.getCardStream(); in onCreate() local 77 mCardStreamFragment.restoreState(state, clickListener); in onCreate() 92 CardStreamState state = getCardStream().dumpState(); in onSaveInstanceState() local 93 mRetentionFragment.storeCardStream(state); in onSaveInstanceState()
|
/developers/build/templates/CardStream/_MODULE_/src/template/java/_PACKAGE_/ |
D | MainActivity.java.ftl | 70 // If the retention fragment already existed, we need to pull some state. 71 // pull state out 72 CardStreamState state = mRetentionFragment.getCardStream(); 77 mCardStreamFragment.restoreState(state, clickListener); 92 CardStreamState state = getCardStream().dumpState(); 93 mRetentionFragment.storeCardStream(state);
|
/developers/samples/android/connectivity/wifidirect/DirectP2P/Application/src/main/java/com/example/android/wifidirectp2p/ |
D | WiFiDirectBroadcastReceiver.java | 62 int state = intent.getIntExtra(WifiP2pManager.EXTRA_WIFI_STATE, -1); in onReceive() local 63 if (state == WifiP2pManager.WIFI_P2P_STATE_ENABLED) { in onReceive() 71 Log.d(MainActivity.TAG, "P2P state changed - " + state); in onReceive()
|
/developers/build/prebuilts/gradle/MediaBrowserService/Application/src/main/java/com/example/android/mediasession/service/notifications/ |
D | MediaNotificationManager.java | 116 @NonNull PlaybackStateCompat state, in getNotification() argument 118 boolean isPlaying = state.getState() == PlaybackStateCompat.STATE_PLAYING; in getNotification() 121 buildNotification(state, token, isPlaying, description); in getNotification() 125 private NotificationCompat.Builder buildNotification(@NonNull PlaybackStateCompat state, in buildNotification() argument 163 if ((state.getActions() & PlaybackStateCompat.ACTION_SKIP_TO_PREVIOUS) != 0) { in buildNotification() 170 if ((state.getActions() & PlaybackStateCompat.ACTION_SKIP_TO_NEXT) != 0) { in buildNotification()
|
/developers/samples/android/media/MediaBrowserService/Application/src/main/java/com/example/android/mediasession/service/notifications/ |
D | MediaNotificationManager.java | 116 @NonNull PlaybackStateCompat state, in getNotification() argument 118 boolean isPlaying = state.getState() == PlaybackStateCompat.STATE_PLAYING; in getNotification() 121 buildNotification(state, token, isPlaying, description); in getNotification() 125 private NotificationCompat.Builder buildNotification(@NonNull PlaybackStateCompat state, in buildNotification() argument 163 if ((state.getActions() & PlaybackStateCompat.ACTION_SKIP_TO_PREVIOUS) != 0) { in buildNotification() 170 if ((state.getActions() & PlaybackStateCompat.ACTION_SKIP_TO_NEXT) != 0) { in buildNotification()
|
/developers/build/prebuilts/gradle/PictureInPicture/app/src/main/java/com/example/android/pictureinpicture/ |
D | MediaSessionPlaybackActivity.java | 149 int state = in initializeMediaSession() local 154 state, in initializeMediaSession() 250 @PlaybackStateCompat.State int state, int position, int mediaId) { in updatePlaybackState() 252 updatePlaybackState(state, actions, position, mediaId); in updatePlaybackState() 256 @PlaybackStateCompat.State int state, long playbackActions, int position, int mediaId) { in updatePlaybackState() 261 .setState(state, position, 1.0f); in updatePlaybackState()
|
/developers/build/prebuilts/gradle/PictureInPicture/kotlinApp/app/src/main/java/com/example/android/pictureinpicture/ |
D | MediaSessionPlaybackActivity.kt | 144 val state = if (mMovieView.isPlaying) in <lambda>() constant 149 state, in <lambda>() 234 @PlaybackStateCompat.State state: Int, in <lambda>() 238 updatePlaybackState(state, actions, position, mediaId) in <lambda>() 242 @PlaybackStateCompat.State state: Int, in <lambda>() 249 .setState(state, position.toLong(), 1.0f) in <lambda>()
|
/developers/samples/android/media/PictureInPicture/kotlinApp/app/src/main/java/com/example/android/pictureinpicture/ |
D | MediaSessionPlaybackActivity.kt | 144 val state = if (mMovieView.isPlaying) in <lambda>() constant 149 state, in <lambda>() 234 @PlaybackStateCompat.State state: Int, in <lambda>() 238 updatePlaybackState(state, actions, position, mediaId) in <lambda>() 242 @PlaybackStateCompat.State state: Int, in <lambda>() 249 .setState(state, position.toLong(), 1.0f) in <lambda>()
|
/developers/samples/android/media/PictureInPicture/app/src/main/java/com/example/android/pictureinpicture/ |
D | MediaSessionPlaybackActivity.java | 149 int state = in initializeMediaSession() local 154 state, in initializeMediaSession() 250 @PlaybackStateCompat.State int state, int position, int mediaId) { in updatePlaybackState() 252 updatePlaybackState(state, actions, position, mediaId); in updatePlaybackState() 256 @PlaybackStateCompat.State int state, long playbackActions, int position, int mediaId) { in updatePlaybackState() 261 .setState(state, position, 1.0f); in updatePlaybackState()
|
/developers/samples/android/wearable/wear/WearComplicationProvidersTestSuite/Wearable/src/main/java/com/example/android/wearable/wear/wearcomplicationproviderstestsuite/ |
D | SmallImageProviderService.java | 45 int state = in onComplicationUpdate() local 51 switch (state % 2) { in onComplicationUpdate()
|
/developers/build/prebuilts/gradle/WearComplicationProvidersTestSuite/Wearable/src/main/java/com/example/android/wearable/wear/wearcomplicationproviderstestsuite/ |
D | LargeImageProviderService.java | 50 int state = in onComplicationUpdate() local 56 switch (state % 2) { in onComplicationUpdate()
|