Searched refs:time (Results 1 - 25 of 87) sorted by relevance

1234

/packages/apps/VideoEditor/src/com/android/videoeditor/util/
H A DStringUtils.java105 * Get a readable string displaying the time
107 * @param context The context (needed only for relative time)
108 * @param time The time
110 * @return The time string
112 public static String getTimestampAsString(Context context, long time) { argument
113 final long hours = time / 3600000;
114 time %= 3600000;
115 final long mins = time / 60000;
116 time
131 getSimpleTimestampAsString(Context context, long time) argument
148 getDurationAsString(Context context, long time) argument
[all...]
/packages/apps/Mms/src/com/android/mms/dom/smil/
H A DTimeListImpl.java44 Time time = null;
46 time = mTimes.get(index);
50 return time;
/packages/apps/Gallery2/src/com/android/gallery3d/app/
H A DControllerOverlay.java26 void onSeekMove(int time); argument
27 void onSeekEnd(int time); argument
/packages/apps/Calendar/src/com/android/calendar/month/
H A DSimpleWeekView.java77 * How many days to display at a time. Days will be displayed starting with
118 // Cache the number strings so we don't have to recompute them each time
208 * @param tz The time zone this view should reference times in
244 Time time = new Time(tz);
245 time.setJulianDay(julianMonday);
250 mDayNumbers[0] = Integer.toString(time.getWeekNumber());
261 if (time.weekDay != mWeekStart) {
262 int diff = time.weekDay - mWeekStart;
266 time.monthDay -= diff;
267 time
[all...]
H A DMonthByWeekFragment.java80 // The minimum time between requeries of the data if the db is
148 // -1 to ensure we get all day events from any time zone
152 // +1 to ensure we get all day events from any time zone
422 protected void setMonthDisplayed(Time time, boolean updateHighlight) { argument
423 super.setMonthDisplayed(time, updateHighlight);
426 if (time.year == mDesiredDay.year && time.month == mDesiredDay.month) {
431 mSelectedDay.set(time);
432 mAdapter.setSelectedDay(time);
445 controller.sendEvent(this, EventType.UPDATE_TITLE, time, tim
[all...]
/packages/apps/Gallery2/src/com/android/gallery3d/anim/
H A DAnimation.java23 // Animation calculates a value according to the current input time.
27 // 2. Then we should call start(). The actual start time is the first value
29 // 3. Each time we want to get an animation value, we call
68 public void setStartTime(long time) { argument
69 mStartTime = time;
/packages/inputmethods/PinyinIME/jni/command/
H A Dpinyinime_dictbuilder.cpp20 #include <time.h>
/packages/providers/CalendarProvider/tests/src/com/android/providers/calendar/
H A DSyncCalendarTest.java60 Time time = new Time();
61 time.setToNow();
62 long dtStart = time.toMillis(false);
63 long dtEnd = time.toMillis(false) + ONE_HOUR_IN_MILLIS;
79 Time time = new Time();
80 time.setToNow();
81 String newTitle = cursor.getString(cursor.getColumnIndex("title")) + time.toString();
107 Time time = new Time();
110 time.set(dtStart + 2 * ONE_HOUR_IN_MILLIS);
111 long newDtStart = time
[all...]
H A DCalendarSyncTestingBase.java270 Time time = new Time();
272 time.timezone = Time.TIMEZONE_UTC;
274 time.timezone = timezone;
276 mTimezone = time.timezone;
277 time.parse3339(startDate);
278 mDtstart = time.toMillis(false /* use isDst */);
279 time.parse3339(endDate);
280 mDtend = time.toMillis(false /* use isDst */);
302 Time time = new Time();
304 time
[all...]
H A DCalendarProvider2Test.java177 * start and end time, whether it is an all-day event, and so on) are
299 Time time = new Time(DEFAULT_TIMEZONE);
300 time.parse3339(startDate);
301 begin = time.toMillis(false /* use isDst */);
302 time.parse3339(endDate);
303 end = time.toMillis(false /* use isDst */);
323 Time time = new Time(DEFAULT_TIMEZONE);
324 time.parse3339(startDate);
325 begin = time.toMillis(false /* use isDst */);
326 time
[all...]
/packages/wallpapers/Basic/src/com/android/wallpaper/grass/
H A DSunCalculator.java56 * Computes the sunrise time for the given zenith at the given date.
62 * @return the sunrise time
69 * Computes the sunset time for the given zenith at the given date.
75 * @return the sunset time
81 public static int timeToHours(double time) { argument
82 int hour = (int) Math.floor(time);
83 int minute = (int) Math.round((time - hour) * 60);
90 public static int timeToMinutes(double time) { argument
91 int hour = (int) Math.floor(time);
92 int minute = (int) Math.round((time
99 timeToDayFraction(double time) argument
109 timeToString(double time) argument
[all...]
/packages/apps/Email/src/com/android/email/activity/
H A DRecentMailboxManager.java95 /** Updates the specified mailbox's touch time. Returns an async task for test only. */
129 /** Updates the last touched time for the mailbox in the background */
131 final long accountId, final long mailboxId, final long time) {
135 ensureDefaultsInitialized(accountId, time);
136 touchMailboxSynchronous(accountId, mailboxId, time);
141 private void touchMailboxSynchronous(long accountId, long mailboxId, long time) { argument
143 values.put(MailboxColumns.LAST_TOUCHED_TIME, time);
152 private synchronized void ensureDefaultsInitialized(long accountId, long time) { argument
163 touchMailboxSynchronous(accountId, mailbox, time);
130 fireAndForget( final long accountId, final long mailboxId, final long time) argument
/packages/apps/Calendar/src/com/android/calendar/widget/
H A DCalendarAppWidgetService.java95 * Update interval used when no next-update calculated, or bad trigger time in past.
109 // Suppress unnecessary logging about update time. Need to be static as this object is
354 * until some time in the future. Widen the time range that we query by
357 * in the list of events starting at midnight local time. This may fetch
364 * @param now Current system time to use for this update, possibly from
371 // Search for events from now until some time in the future
408 * Calculates and returns the next time we should push widget updates.
419 // We want to update widget when we enter/exit time range of an event.
430 Time time
[all...]
/packages/apps/Calendar/src/com/android/calendar/alerts/
H A DAlertReceiver.java166 // Format the second line which shows time and location.
168 // 1) Show time only for non-all day events
174 Time time = new Time(tz);
175 time.setToNow();
176 int today = Time.getJulianDay(time.toMillis(false), time.gmtoff);
177 time.set(startMillis);
178 int eventDay = Time.getJulianDay(time.toMillis(false), time.gmtoff);
198 // Assumes time wa
[all...]
/packages/providers/CalendarProvider/src/com/android/providers/calendar/
H A DCalendarAlarmManager.java84 * We search backward in time for event reminders that we may have missed
97 * because the device time was incorrectly in the future. This threshold
224 Time time = new Time();
225 time.set(triggerTime);
226 String timeStr = time.format(" %a, %b %d, %Y %I:%M%P");
258 Time time = new Time();
264 time.set(start);
265 String startTimeStr = time.format(" %a, %b %d, %Y %I:%M%P");
273 // should be further in the past than the point in time where
288 // Extract events from the database sorted by alarm time
[all...]
/packages/apps/QuickSearchBox/benchmarks/src/com/android/quicksearchbox/benchmarks/
H A DSourceLatency.java74 public synchronized void addTime(long time) { argument
75 mTotal += time;
91 final ElapsedTime time = new ElapsedTime();
100 time.addTime(t);
111 while (time.getCount() < count) {
118 Log.d(TAG, src + "[DONE]: " + length + " queries in " + formatTime(time.getAverage())
119 + " (average), " + formatTime(time.getTotal()) + " (total)");
123 ElapsedTime time = new ElapsedTime();
127 time.addTime(t);
129 Log.d(TAG, src + "[DONE]: " + count + " queries in " + formatTime(time
[all...]
/packages/apps/DeskClock/src/com/android/deskclock/
H A DAlarms.java152 long time = 0;
154 time = calculateAlarm(alarm);
160 values.put(Alarm.Columns.ALARM_TIME, time);
269 // If we are enabling the alarm, calculate alarm time since the time
272 long time = 0;
274 time = calculateAlarm(alarm);
276 values.put(Alarm.Columns.ALARM_TIME, time);
323 // A time of 0 indicates this is a repeating alarm, so
324 // calculate the time t
448 saveSnoozeAlert(final Context context, final int id, final long time) argument
[all...]
H A DSetAlarm.java81 mTimePref = findPreference("time");
114 long time = saveAlarm(null);
116 popAlarmSetToast(SetAlarm.this, time);
248 // If the time has been changed, enable the alarm.
267 long time;
269 time = Alarms.addAlarm(this, alarm);
274 time = Alarms.setAlarm(this, alarm);
276 return time;
/packages/apps/Calendar/src/com/android/calendar/
H A DCalendarViewAdapter.java66 // The current selected event's time, used to calculate the date and day of the week
75 private Handler mMidnightHandler = null; // Used to run a time update every midnight
77 // Updates time specific variables (time-zone, today's Julian day).
98 // Sets time specific variables and starts a thread for midnight updates
103 // Sets the time zone and today's Julian day to be used by the adapter.
107 Time time = new Time(mTimeZone);
109 time.set(now);
110 mTodayJulianDay = Time.getJulianDay(now, time.gmtoff);
119 // Set the time update
261 setTime(long time) argument
[all...]
/packages/apps/Calendar/src/com/android/calendar/agenda/
H A DAgendaListView.java115 // Calculate the time until midnight + 1 second and set the handler to
116 // do a refresh at that time.
118 Time time = new Time(mTimeZone);
119 time.set(now);
120 long runInMillis = (24 * 3600 - time.hour * 3600 - time.minute * 60 -
121 time.second + 1) * 1000;
155 Time time = new Time(mTimeZone);
156 time.set(now);
157 int todayJulianDay = Time.getJulianDay(now, time
212 goTo(Time time, long id, String searchQuery, boolean forced, boolean refreshEventInfo) argument
[all...]
H A DAgendaWindowAdapter.java58 - At rotation and launch time, the initial position is not set properly. This code is calling
298 // Static class, so the time in this toString will not reflect the
300 Time time = new Time();
302 time.setJulianDay(start);
303 time.normalize(false);
304 sb.append("Start:").append(time.toString());
305 time.setJulianDay(end);
306 time.normalize(false);
307 sb.append(" End:").append(time.toString());
499 private int findEventPositionNearestTime(Time time, lon argument
526 getAdapterInfoByTime(Time time) argument
[all...]
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
H A DDialogDetailsView.java160 double time = Double.valueOf(value);
161 if (time < 1.0f) {
162 value = String.format("1/%d", (int) (0.5f + 1 / time));
164 int integer = (int) time;
165 time -= integer;
167 if (time > 0.0001) {
168 value += String.format(" 1/%d", (int) (0.5f + 1 / time));
/packages/apps/Bluetooth/src/com/android/bluetooth/opp/
H A DBluetoothOppTransferAdapter.java121 long time = cursor.getLong(dateColumnId);
122 Date d = new Date(time);
123 CharSequence str = DateUtils.isToday(time) ? DateFormat.getTimeFormat(mContext).format(
/packages/apps/Camera/src/com/android/camera/ui/
H A DRotateImageView.java103 long time = AnimationUtils.currentAnimationTimeMillis();
104 if (time < mAnimationEndTime) {
105 int deltaTime = (int)(time - mAnimationStartTime);
/packages/apps/Email/emailcommon/src/com/android/emailcommon/service/
H A DServiceProxy.java162 long time = System.currentTimeMillis();
173 (System.currentTimeMillis() - time) + "ms");

Completed in 397 milliseconds

1234