Home
last modified time | relevance | path

Searched refs:millis (Results 1 – 25 of 30) sorted by relevance

12

/packages/apps/DocumentsUI/src/com/android/documentsui/util/
DFormatUtils.java44 public static String formatDuration(long millis) { in formatDuration() argument
46 if (millis >= DateUtils.HOUR_IN_MILLIS) { in formatDuration()
48 (int) ((millis + DateUtils.HOUR_IN_MILLIS / 2) / DateUtils.HOUR_IN_MILLIS); in formatDuration()
50 } else if (millis >= DateUtils.MINUTE_IN_MILLIS) { in formatDuration()
52 (int) ((millis + DateUtils.MINUTE_IN_MILLIS / 2) / DateUtils.MINUTE_IN_MILLIS); in formatDuration()
56 (int) ((millis + DateUtils.SECOND_IN_MILLIS / 2) / DateUtils.SECOND_IN_MILLIS); in formatDuration()
/packages/apps/Calendar/src/com/android/calendar/
DUtils.java486 long millis = intent.getLongExtra(EXTRA_EVENT_BEGIN_TIME, -1); in timeFromIntentInMillis() local
487 if (millis == -1 && data != null && data.isHierarchical()) { in timeFromIntentInMillis()
491 millis = Long.valueOf(data.getLastPathSegment()); in timeFromIntentInMillis()
498 if (millis <= 0) { in timeFromIntentInMillis()
499 millis = System.currentTimeMillis(); in timeFromIntentInMillis()
501 return millis; in timeFromIntentInMillis()
514 long millis = time.toMillis(true); in formatMonthYear() local
515 return formatDateRange(context, millis, millis, flags); in formatMonthYear()
1267 public static String getDayOfWeekString(int julianDay, int todayJulianDay, long millis, in getDayOfWeekString() argument
1274 mTZUtils.formatDateRange(context, millis, millis, flags).toString()); in getDayOfWeekString()
[all …]
DAllInOneActivity.java259 long millis = parseViewAction(intent); in onNewIntent() local
260 if (millis == -1) { in onNewIntent()
261 millis = Utils.timeFromIntentInMillis(intent); in onNewIntent()
263 if (millis != -1 && mViewEventId == -1 && mController != null) { in onNewIntent()
265 time.set(millis); in onNewIntent()
908 long millis = time.toMillis(true); in updateSecondaryTitleFields() local
916 Utils.formatDateRange(this, millis, millis, flags))).append(" ").append( in updateSecondaryTitleFields()
925 DateUtils.MINUTE_IN_MILLIS - (millis % DateUtils.MINUTE_IN_MILLIS)); in updateSecondaryTitleFields()
/packages/apps/Car/libs/car-media-common/src/com/android/car/media/common/playback/
DPlaybackProgress.java76 private static String formatTime(long millis, boolean showHours) { in formatTime() argument
77 long hours = TimeUnit.MILLISECONDS.toHours(millis); in formatTime()
78 long minutes = TimeUnit.MILLISECONDS.toMinutes(millis) % TimeUnit.HOURS.toMinutes(1); in formatTime()
79 long seconds = TimeUnit.MILLISECONDS.toSeconds(millis) % TimeUnit.MINUTES.toSeconds(1); in formatTime()
/packages/apps/Calendar/tests/src/com/android/calendar/
DWeekNumberTest.java211 long millis = test.date.toMillis(false /* use isDst */); in testAll() local
213 String output = DateUtils.formatDateTime(mContext, millis, flags); in testAll()
223 long millis = test.date.toMillis(false /* use isDst */); in testAll() local
225 String output = DateUtils.formatDateTime(mContext, millis, flags); in testAll()
/packages/apps/Calendar/src/com/android/calendar/widget/
DCalendarAppWidgetProvider.java136 long millis = time.toMillis(true); in performUpdate() local
139 final String date = Utils.formatDateRange(context, millis, millis, in performUpdate()
153 .setData(Uri.parse("content://com.android.calendar/time/" + millis)); in performUpdate()
DCalendarAppWidgetModel.java408 long millis = recycle.setJulianDay(julianDay); in populateDayInfo() local
414 Utils.formatDateRange(mContext, millis, millis, flags).toString()); in populateDayInfo()
417 label = Utils.formatDateRange(mContext, millis, millis, flags); in populateDayInfo()
/packages/apps/Dialer/java/com/android/voicemail/impl/transcribe/
DTranscriptionTask.java165 long millis = (1L << retryCount) * 1000; in backoff() local
166 sleep(millis); in backoff()
169 protected static void sleep(long millis) { in sleep() argument
171 Thread.sleep(millis); in sleep()
/packages/apps/TV/src/com/android/tv/util/
DUtils.java352 public static int getRoundOffMinsFromMs(long millis) { in getRoundOffMinsFromMs() argument
354 return (int) TimeUnit.MILLISECONDS.toMinutes(millis + HALF_MINUTE_MS); in getRoundOffMinsFromMs()
501 public static long getLastMillisecondOfDay(long millis) { in getLastMillisecondOfDay() argument
503 calendar.setTime(new Date(millis)); in getLastMillisecondOfDay()
512 public static long getFirstMillisecondOfDay(long millis) { in getFirstMillisecondOfDay() argument
514 calendar.setTime(new Date(millis)); in getFirstMillisecondOfDay()
/packages/apps/DocumentsUI/src/com/android/documentsui/inspector/
DMediaView.java105 int millis = tags.getInt(MediaMetadata.METADATA_KEY_DURATION); in showAudioData() local
106 table.put(R.string.metadata_duration, DateUtils.formatElapsedTime(millis / 1000)); in showAudioData()
126 int millis = tags.getInt(MediaMetadata.METADATA_KEY_DURATION); in showVideoData() local
127 table.put(R.string.metadata_duration, DateUtils.formatElapsedTime(millis / 1000)); in showVideoData()
/packages/apps/Calendar/src/com/android/calendar/month/
DSimpleDayPickerFragment.java397 long millis = mTempTime.normalize(true); in goTo() local
401 Time.getJulianDay(millis, mTempTime.gmtoff), mFirstDayOfWeek); in goTo()
442 millis = mFirstDayOfMonth.normalize(true); in goTo()
445 Time.getJulianDay(millis, mFirstDayOfMonth.gmtoff), mFirstDayOfWeek); in goTo()
DSimpleWeekView.java537 Long millis = hover.toMillis(true); in onHoverEvent() local
538 String date = Utils.formatDateRange(context, millis, millis, in onHoverEvent()
DSimpleWeeksAdapter.java167 long millis = mSelectedDay.normalize(true); in setSelectedDay() local
169 Time.getJulianDay(millis, mSelectedDay.gmtoff), mFirstDayOfWeek); in setSelectedDay()
DMonthByWeekAdapter.java123 long millis = mSelectedDay.normalize(true); in setSelectedDay() local
125 Time.getJulianDay(millis, mSelectedDay.gmtoff), mFirstDayOfWeek); in setSelectedDay()
DMonthWeekEventsView.java1068 Long millis = hover.toMillis(true); in onHoverEvent() local
1069 String date = Utils.formatDateRange(context, millis, millis, in onHoverEvent()
/packages/apps/Car/Media/src/com/android/car/media/
DPlaybackFragment.java460 int millis = expanding ? res.getInteger(R.integer.control_bar_expand_anim_duration) : in initPlaybackControls() local
469 ViewUtils.showViewAnimated(mControlBarScrim, millis); in initPlaybackControls()
473 ViewUtils.hideViewAnimated(mControlBarScrim, millis); in initPlaybackControls()
480 ViewUtils.hideViewAnimated(view, millis); in initPlaybackControls()
482 ViewUtils.showViewAnimated(view, millis); in initPlaybackControls()
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/testcommon/
DActivityLifecycleWaiter.java52 public void waitForStage(long millis) throws InterruptedException { in waitForStage() argument
54 mLatch.await(millis, TimeUnit.MILLISECONDS); in waitForStage()
/packages/apps/Car/Dialer/src/com/android/car/dialer/ui/common/
DUiCallLogLiveData.java227 private String getRelativeTime(long millis) { in getRelativeTime() argument
228 boolean validTimestamp = millis > 0; in getRelativeTime()
231 millis, System.currentTimeMillis(), DateUtils.MINUTE_IN_MILLIS, in getRelativeTime()
/packages/apps/DocumentsUI/src/com/android/documentsui/picker/
DPickResult.java78 public void setPickStartTime(long millis) { in setPickStartTime() argument
79 mPickStartTime = millis; in setPickStartTime()
/packages/apps/Settings/src/com/android/settings/vpn2/
DVpnSettings.java159 long millis = System.currentTimeMillis(); in onOptionsItemSelected() local
160 while (mLegacyVpnPreferences.containsKey(Long.toHexString(millis))) { in onOptionsItemSelected()
161 ++millis; in onOptionsItemSelected()
163 VpnProfile profile = new VpnProfile(Long.toHexString(millis)); in onOptionsItemSelected()
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/vpn2/
DVpnSettings.java159 long millis = System.currentTimeMillis(); in onOptionsItemSelected() local
160 while (mLegacyVpnPreferences.containsKey(Long.toHexString(millis))) { in onOptionsItemSelected()
161 ++millis; in onOptionsItemSelected()
163 VpnProfile profile = new VpnProfile(Long.toHexString(millis)); in onOptionsItemSelected()
/packages/apps/TV/src/com/android/tv/guide/
DGuideUtils.java41 static int convertMillisToPixel(long millis) { in convertMillisToPixel() argument
42 return (int) (millis * sWidthPerHour / TimeUnit.HOURS.toMillis(1)); in convertMillisToPixel()
/packages/apps/Gallery2/src/com/android/gallery3d/app/
DTimeBar.java250 protected String stringForTime(long millis) { in stringForTime() argument
251 int totalSeconds = (int) millis / 1000; in stringForTime()
/packages/apps/Dialer/java/com/android/dialer/app/voicemail/
DVoicemailPlaybackLayout.java361 private String formatAsMinutesAndSeconds(int millis) { in formatAsMinutesAndSeconds() argument
362 int seconds = millis / 1000; in formatAsMinutesAndSeconds()
/packages/apps/Dialer/java/com/android/dialer/voicemail/listui/
DNewVoicemailMediaPlayerView.java668 private String formatAsMinutesAndSeconds(int millis) { in formatAsMinutesAndSeconds() argument
669 int seconds = millis / 1000; in formatAsMinutesAndSeconds()

12