|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectandroid.content.Context
android.content.ContextWrapper
android.view.ContextThemeWrapper
android.app.Activity
de.unikassel.android.sdcframework.app.scheduler.SDCFSchedulerActivity
public final class SDCFSchedulerActivity
Scheduler for the the SDCF weekly time schedule.
Field Summary | |
---|---|
private Button |
btnAdd
The add entry button. |
private Button |
btnSave
The add save schedule button. |
private static int |
EDIT_OLD_ENTRY
Constant to request changes for an existing schedule entry. |
private WeekdayScheduleEntry |
editedEntry
Currently edited entry. |
private Map<View,WeekdaySchedule> |
mapView2Schedule
The view to weekday schedule mapping. |
private ApplicationPreferenceManager |
prefManager
The preference manager |
private static int |
REQUEST_NEW_ENTRY
Constant to request a new schedule entry. |
private WeeklySchedule |
schedule
The schedule. |
Fields inherited from class android.app.Activity |
---|
DEFAULT_KEYS_DIALER, DEFAULT_KEYS_DISABLE, DEFAULT_KEYS_SEARCH_GLOBAL, DEFAULT_KEYS_SEARCH_LOCAL, DEFAULT_KEYS_SHORTCUT, FOCUSED_STATE_SET, RESULT_CANCELED, RESULT_FIRST_USER, RESULT_OK |
Constructor Summary | |
---|---|
SDCFSchedulerActivity()
Constructor |
Method Summary | |
---|---|
protected void |
addNewEntry(Intent data)
Method to create a new entry from intent data. |
private boolean |
deleteEntry(AdapterView.AdapterContextMenuInfo info)
Delete entry context menu handler. |
protected void |
deleteEntry(WeekdayScheduleEntry entry)
Method to delete an entry. |
private boolean |
editEntry(AdapterView.AdapterContextMenuInfo info)
Edit entry context menu handler. |
private Map.Entry<View,WeekdaySchedule> |
getWeekdayScheduleEntry(String val)
Method to request weekday entry value for a string description value. |
protected WeeklySchedule |
loadSchedule()
Does load the schedule from the service preferences. |
protected void |
onActivityResult(int requestCode,
int resultCode,
Intent data)
|
private boolean |
onAddEntry()
Handler for add entry. |
private boolean |
onClearSchedule()
Method to save a schedule and leave |
boolean |
onContextItemSelected(MenuItem item)
|
protected void |
onCreate(Bundle savedInstanceState)
|
void |
onCreateContextMenu(ContextMenu menu,
View v,
ContextMenu.ContextMenuInfo menuInfo)
|
boolean |
onCreateOptionsMenu(Menu menu)
|
protected void |
onDestroy()
|
private boolean |
onEditEntry(WeekdayScheduleEntry entry)
Handler for edit entry. |
boolean |
onOptionsItemSelected(MenuItem item)
|
protected void |
onPause()
|
boolean |
onPrepareOptionsMenu(Menu menu)
|
protected void |
onResume()
|
private boolean |
onSaveSchedule()
Method to save a schedule and leave |
protected void |
refreshView()
Method to update button states |
void |
setSchedule(WeeklySchedule newSchedule)
|
Methods inherited from class android.view.ContextThemeWrapper |
---|
attachBaseContext, getTheme, setTheme |
Methods inherited from class android.content.Context |
---|
getString, getString, getText, obtainStyledAttributes, obtainStyledAttributes, obtainStyledAttributes, obtainStyledAttributes |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final int REQUEST_NEW_ENTRY
private static final int EDIT_OLD_ENTRY
private WeeklySchedule schedule
private final Map<View,WeekdaySchedule> mapView2Schedule
private WeekdayScheduleEntry editedEntry
private final ApplicationPreferenceManager prefManager
private Button btnAdd
private Button btnSave
Constructor Detail |
---|
public SDCFSchedulerActivity()
Method Detail |
---|
protected void onCreate(Bundle savedInstanceState)
onCreate
in class Activity
public void setSchedule(WeeklySchedule newSchedule)
newSchedule
- the new schedule to setprotected void refreshView()
protected WeeklySchedule loadSchedule()
public boolean onCreateOptionsMenu(Menu menu)
onCreateOptionsMenu
in class Activity
public boolean onPrepareOptionsMenu(Menu menu)
onPrepareOptionsMenu
in class Activity
public boolean onOptionsItemSelected(MenuItem item)
onOptionsItemSelected
in class Activity
private boolean onClearSchedule()
private boolean onSaveSchedule()
private boolean onAddEntry()
private boolean onEditEntry(WeekdayScheduleEntry entry)
entry
- the entry to wedit
protected void onActivityResult(int requestCode, int resultCode, Intent data)
onActivityResult
in class Activity
protected void addNewEntry(Intent data)
data
- the intent data to create new entry fromprivate Map.Entry<View,WeekdaySchedule> getWeekdayScheduleEntry(String val)
val
- the value to get an entry for
protected void onDestroy()
onDestroy
in class Activity
protected void onResume()
onResume
in class Activity
protected void onPause()
onPause
in class Activity
public void onCreateContextMenu(ContextMenu menu, View v, ContextMenu.ContextMenuInfo menuInfo)
onCreateContextMenu
in interface View.OnCreateContextMenuListener
onCreateContextMenu
in class Activity
public boolean onContextItemSelected(MenuItem item)
onContextItemSelected
in class Activity
private boolean deleteEntry(AdapterView.AdapterContextMenuInfo info)
info
- the context menu info
protected void deleteEntry(WeekdayScheduleEntry entry)
entry
- the entry to deleteprivate boolean editEntry(AdapterView.AdapterContextMenuInfo info)
info
- the context menu info
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |