List of usage examples for android.widget TimePicker getId
@IdRes @ViewDebug.CapturedViewProperty public int getId()
From source file:com.atlas.mars.weatherradar.ActivitySetting.java
@Override public void onTimeChanged(TimePicker view, int hourOfDay, int minute) { switch (view.getId()) { case R.id.timePickerFrom: if (isInitTimeFrom) { textViewFrom.setText("" + hourOfDay + ":" + getMinutes(minute)); fromMin = minute;/* w w w . j a va 2 s. c o m*/ fromHour = hourOfDay; } isInitTimeFrom = true; break; case R.id.timePickerTo: if (isInitTimeTo) { textViewTo.setText("" + hourOfDay + ":" + getMinutes(minute)); toMin = minute; toHour = hourOfDay; } isInitTimeTo = true; break; } Log.d(TAG, "" + hourOfDay + ":" + minute); }