Added user interface for NDA logging (menu in data log manager)
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
package="uk.org.openseizuredetector"
|
package="uk.org.openseizuredetector"
|
||||||
android:versionCode="113"
|
android:versionCode="113"
|
||||||
android:versionName="4.0.8b">
|
android:versionName="4.0.8c">
|
||||||
<!-- android:allowBackup="false" -->
|
<!-- android:allowBackup="false" -->
|
||||||
<uses-permission android:name="android.permission.BLUETOOTH" />
|
<uses-permission android:name="android.permission.BLUETOOTH" />
|
||||||
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
|
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
|
||||||
|
|||||||
@@ -92,8 +92,10 @@ public class LogManager {
|
|||||||
static private SQLiteDatabase mOsdDb = null; // SQLite Database for data and log entries.
|
static private SQLiteDatabase mOsdDb = null; // SQLite Database for data and log entries.
|
||||||
private RemoteLogTimer mRemoteLogTimer;
|
private RemoteLogTimer mRemoteLogTimer;
|
||||||
private boolean mLogNDA;
|
private boolean mLogNDA;
|
||||||
private NDATimer mNDATimer;
|
public NDATimer mNDATimer;
|
||||||
private long mNDATimerStartTime;
|
private long mNDATimerStartTime; // milliseconds
|
||||||
|
public double mNDATimeRemaining; // hours
|
||||||
|
public double mNDALogPeriodHours = 24.0; // hours
|
||||||
private static Context mContext;
|
private static Context mContext;
|
||||||
private OsdUtil mUtil;
|
private OsdUtil mUtil;
|
||||||
public static WebApiConnection mWac;
|
public static WebApiConnection mWac;
|
||||||
@@ -1095,7 +1097,7 @@ public class LogManager {
|
|||||||
// We set the timer to timeout after the event duration, so that we record all data
|
// We set the timer to timeout after the event duration, so that we record all data
|
||||||
// without a gap.
|
// without a gap.
|
||||||
mNDATimer =
|
mNDATimer =
|
||||||
new NDATimer(mEventDuration * 1000, 1000);
|
new NDATimer(mEventDuration * 1000, 1000, mNDALogPeriodHours);
|
||||||
mNDATimer.start();
|
mNDATimer.start();
|
||||||
|
|
||||||
// If we do not have a stored start time for NDA logging, set it to current time
|
// If we do not have a stored start time for NDA logging, set it to current time
|
||||||
@@ -1109,12 +1111,18 @@ public class LogManager {
|
|||||||
mNDATimerStartTime = timeNow.toMillis(true);
|
mNDATimerStartTime = timeNow.toMillis(true);
|
||||||
SharedPreferences.Editor editor = SP.edit();
|
SharedPreferences.Editor editor = SP.edit();
|
||||||
editor.putLong("NDATimerStartTime", mNDATimerStartTime);
|
editor.putLong("NDATimerStartTime", mNDATimerStartTime);
|
||||||
|
editor.putBoolean("LogNDA", true);
|
||||||
editor.apply();
|
editor.apply();
|
||||||
}
|
}
|
||||||
|
Time timeNow = new Time(Time.getCurrentTimezone());
|
||||||
|
timeNow.setToNow();
|
||||||
|
long tNow = timeNow.toMillis(true);
|
||||||
|
long tDiffMillis = (tNow - mNDATimerStartTime);
|
||||||
|
mNDATimeRemaining = mNDALogPeriodHours - tDiffMillis / (3600.*1000.);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Cancel the Normal Daily Actity Log timer
|
* Cancel the Normal Daily Actity Log timer
|
||||||
*/
|
*/
|
||||||
@@ -1126,6 +1134,22 @@ public class LogManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void disableNDATimer() {
|
||||||
|
SharedPreferences SP = PreferenceManager
|
||||||
|
.getDefaultSharedPreferences(mContext);
|
||||||
|
SharedPreferences.Editor editor = SP.edit();
|
||||||
|
editor.putBoolean("LogNDA", false);
|
||||||
|
editor.apply();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void enableNDATimer() {
|
||||||
|
SharedPreferences SP = PreferenceManager
|
||||||
|
.getDefaultSharedPreferences(mContext);
|
||||||
|
SharedPreferences.Editor editor = SP.edit();
|
||||||
|
editor.putBoolean("LogNDA", true);
|
||||||
|
editor.apply();
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Start the timer that will Auto Prune the database
|
* Start the timer that will Auto Prune the database
|
||||||
*/
|
*/
|
||||||
@@ -1246,11 +1270,10 @@ public class LogManager {
|
|||||||
* Log Normal Daily Activities periodically.
|
* Log Normal Daily Activities periodically.
|
||||||
*/
|
*/
|
||||||
private class NDATimer extends CountDownTimer {
|
private class NDATimer extends CountDownTimer {
|
||||||
// FIXME - NDA Log Period hard coded!
|
double mNDALogPeriodHours = 0;
|
||||||
private double mNDALogPeriodHours = 24.0;
|
public NDATimer(long startTime, long interval, double logPeriod) {
|
||||||
|
|
||||||
public NDATimer(long startTime, long interval) {
|
|
||||||
super(startTime, interval);
|
super(startTime, interval);
|
||||||
|
mNDALogPeriodHours = logPeriod;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -1262,12 +1285,14 @@ public class LogManager {
|
|||||||
public void onFinish() {
|
public void onFinish() {
|
||||||
Log.d(TAG, "mNDATimer - onFinish - Recording a Normal Daily Activity Event");
|
Log.d(TAG, "mNDATimer - onFinish - Recording a Normal Daily Activity Event");
|
||||||
createNDAEvent();
|
createNDAEvent();
|
||||||
// Check if we have been logging NDA events for more than the set limit.
|
// Check if we have been logging NDA events for more than the set limit. If it has, we disable it
|
||||||
|
// and set the start time to zero so it is re-set next time NDA logging is enabled.
|
||||||
Time timeNow = new Time(Time.getCurrentTimezone());
|
Time timeNow = new Time(Time.getCurrentTimezone());
|
||||||
timeNow.setToNow();
|
timeNow.setToNow();
|
||||||
long tNow = timeNow.toMillis(true);
|
long tNow = timeNow.toMillis(true);
|
||||||
long tDiffMillis = (tNow - mNDATimerStartTime);
|
long tDiffMillis = (tNow - mNDATimerStartTime);
|
||||||
double tDiffHrs = tDiffMillis / (3600.*1000.);
|
double tDiffHrs = tDiffMillis / (3600.*1000.);
|
||||||
|
mNDATimeRemaining = mNDALogPeriodHours - tDiffHrs;
|
||||||
if (tDiffHrs >= mNDALogPeriodHours) {
|
if (tDiffHrs >= mNDALogPeriodHours) {
|
||||||
Log.i(TAG, "mNDATimer - onFinish - NDA logging period completed - switching off NDA Logging");
|
Log.i(TAG, "mNDATimer - onFinish - NDA logging period completed - switching off NDA Logging");
|
||||||
SharedPreferences SP = PreferenceManager
|
SharedPreferences SP = PreferenceManager
|
||||||
|
|||||||
@@ -61,6 +61,7 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
private Integer mUiTimerPeriodFast = 2000; // 2 seconds - we use fast updating while UI is blank and we are waiting for first data
|
private Integer mUiTimerPeriodFast = 2000; // 2 seconds - we use fast updating while UI is blank and we are waiting for first data
|
||||||
private Integer mUiTimerPeriodSlow = 60000; // 60 seconds - once data has been received and UI populated we only update once per minute.
|
private Integer mUiTimerPeriodSlow = 60000; // 60 seconds - once data has been received and UI populated we only update once per minute.
|
||||||
private boolean mUpdateSysLog = true;
|
private boolean mUpdateSysLog = true;
|
||||||
|
private Menu mMenu;
|
||||||
//private Integer UI_MODE_LOCAL = 0;
|
//private Integer UI_MODE_LOCAL = 0;
|
||||||
//private Integer UI_MODE_SHARED = 1;
|
//private Integer UI_MODE_SHARED = 1;
|
||||||
//private Integer mUiMode = UI_MODE_SHARED;
|
//private Integer mUiMode = UI_MODE_SHARED;
|
||||||
@@ -117,6 +118,9 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
CheckBox includeWarningsCb =
|
CheckBox includeWarningsCb =
|
||||||
(CheckBox) findViewById(R.id.include_warnings_cb);
|
(CheckBox) findViewById(R.id.include_warnings_cb);
|
||||||
includeWarningsCb.setOnCheckedChangeListener(onIncludeWarningsCb);
|
includeWarningsCb.setOnCheckedChangeListener(onIncludeWarningsCb);
|
||||||
|
CheckBox includeNDACb =
|
||||||
|
(CheckBox) findViewById(R.id.include_nda_cb);
|
||||||
|
includeNDACb.setOnCheckedChangeListener(onIncludeNDACb);
|
||||||
|
|
||||||
ListView lv = (ListView) findViewById(R.id.eventLogListView);
|
ListView lv = (ListView) findViewById(R.id.eventLogListView);
|
||||||
lv.setOnItemClickListener(onEventListClick);
|
lv.setOnItemClickListener(onEventListClick);
|
||||||
@@ -133,6 +137,7 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
Log.i(TAG, "onCreateOptionsMenu()");
|
Log.i(TAG, "onCreateOptionsMenu()");
|
||||||
getMenuInflater().inflate(R.menu.log_manager_activity_menu, menu);
|
getMenuInflater().inflate(R.menu.log_manager_activity_menu, menu);
|
||||||
MenuCompat.setGroupDividerEnabled(menu, true);
|
MenuCompat.setGroupDividerEnabled(menu, true);
|
||||||
|
this.mMenu = menu;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -196,8 +201,10 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
private void initialiseServiceConnection() {
|
private void initialiseServiceConnection() {
|
||||||
mLm = mConnection.mSdServer.mLm;
|
mLm = mConnection.mSdServer.mLm;
|
||||||
startUiTimer(mUiTimerPeriodFast);
|
startUiTimer(mUiTimerPeriodFast);
|
||||||
|
|
||||||
final CheckBox includeWarningsCb = (CheckBox) findViewById(R.id.include_warnings_cb);
|
final CheckBox includeWarningsCb = (CheckBox) findViewById(R.id.include_warnings_cb);
|
||||||
getRemoteEvents(includeWarningsCb.isChecked());
|
final CheckBox includeNDACb = (CheckBox) findViewById(R.id.include_nda_cb);
|
||||||
|
getRemoteEvents(includeWarningsCb.isChecked(), includeNDACb.isChecked());
|
||||||
ProgressBar pb = (ProgressBar)findViewById(R.id.remoteAccessPb);
|
ProgressBar pb = (ProgressBar)findViewById(R.id.remoteAccessPb);
|
||||||
pb.setIndeterminate(true);
|
pb.setIndeterminate(true);
|
||||||
pb.setVisibility(View.VISIBLE);
|
pb.setVisibility(View.VISIBLE);
|
||||||
@@ -217,7 +224,7 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void getRemoteEvents(boolean includeWarnings) {
|
private void getRemoteEvents(boolean includeWarnings, boolean includeNDA) {
|
||||||
mRemoteEventsList = null; // clear existing data
|
mRemoteEventsList = null; // clear existing data
|
||||||
// Retrieve events from remote database
|
// Retrieve events from remote database
|
||||||
mLm.mWac.getEvents((JSONObject remoteEventsObj) -> {
|
mLm.mWac.getEvents((JSONObject remoteEventsObj) -> {
|
||||||
@@ -267,10 +274,11 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
eventHashMap.put("type", typeStr);
|
eventHashMap.put("type", typeStr);
|
||||||
eventHashMap.put("subType", subType);
|
eventHashMap.put("subType", subType);
|
||||||
eventHashMap.put("desc", desc);
|
eventHashMap.put("desc", desc);
|
||||||
if (osdAlarmState!=1 | includeWarnings) {
|
if ((osdAlarmState!=1 | includeWarnings) &&
|
||||||
|
(osdAlarmState!=6 | includeNDA)) {
|
||||||
mRemoteEventsList.add(eventHashMap);
|
mRemoteEventsList.add(eventHashMap);
|
||||||
} else {
|
} else {
|
||||||
Log.v(TAG,"getRemoteEvents - skipping warning");
|
Log.v(TAG,"getRemoteEvents - skipping warning or NDA record");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Log.v(TAG, "getRemoteEvents() - set mRemoteEventsList(). Updating UI");
|
Log.v(TAG, "getRemoteEvents() - set mRemoteEventsList(). Updating UI");
|
||||||
@@ -301,6 +309,9 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
TextView tv2 = (TextView) findViewById(R.id.num_local_datapoints_tv);
|
TextView tv2 = (TextView) findViewById(R.id.num_local_datapoints_tv);
|
||||||
tv2.setText(String.format("%d", datapointsCount));
|
tv2.setText(String.format("%d", datapointsCount));
|
||||||
});
|
});
|
||||||
|
TextView tv3 = (TextView)findViewById(R.id.nda_time_remaining_tv);
|
||||||
|
tv3.setText(String.format("%.1f hrs",mLm.mNDATimeRemaining));
|
||||||
|
Log.d(TAG,"mNDATimeRemaining = "+String.format("%.1f hrs",mLm.mNDATimeRemaining));
|
||||||
} else {
|
} else {
|
||||||
stopUpdating = false;
|
stopUpdating = false;
|
||||||
}
|
}
|
||||||
@@ -366,6 +377,7 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
stopUiTimer();
|
stopUiTimer();
|
||||||
//startUiTimer(mUiTimerPeriodSlow);
|
//startUiTimer(mUiTimerPeriodSlow);
|
||||||
}
|
}
|
||||||
|
|
||||||
} //updateUi();
|
} //updateUi();
|
||||||
|
|
||||||
public void onRadioButtonClicked(View view) {
|
public void onRadioButtonClicked(View view) {
|
||||||
@@ -444,6 +456,55 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
} catch (Exception ex) {
|
} catch (Exception ex) {
|
||||||
Log.i(TAG, "exception starting settings activity " + ex.toString());
|
Log.i(TAG, "exception starting settings activity " + ex.toString());
|
||||||
}
|
}
|
||||||
|
return true;
|
||||||
|
case R.id.start_stop_nda:
|
||||||
|
Log.i(TAG,"start/stop NDA");
|
||||||
|
if (mConnection.mSdServer.mLogNDA) {
|
||||||
|
new AlertDialog.Builder(this)
|
||||||
|
.setTitle(R.string.stop_nda_logging_dialog_title)
|
||||||
|
.setMessage(R.string.stop_nda_logging_dialog_meassage)
|
||||||
|
.setIcon(android.R.drawable.ic_dialog_alert)
|
||||||
|
.setPositiveButton(android.R.string.yes, new DialogInterface.OnClickListener() {
|
||||||
|
public void onClick(DialogInterface dialog, int whichButton) {
|
||||||
|
mLm.disableNDATimer();
|
||||||
|
MenuItem startStopNDAMenuItem = mMenu.findItem(R.id.start_stop_nda);
|
||||||
|
startStopNDAMenuItem.setTitle(R.string.start_nda_menu_title);
|
||||||
|
mUtil.stopServer();
|
||||||
|
// Wait 0.1 second to give the server chance to shutdown, then re-start it
|
||||||
|
new Handler().postDelayed(new Runnable() {
|
||||||
|
public void run() {
|
||||||
|
mUtil.startServer();
|
||||||
|
}
|
||||||
|
}, 100);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.setNegativeButton(android.R.string.no, null)
|
||||||
|
.show();
|
||||||
|
|
||||||
|
} else {
|
||||||
|
new AlertDialog.Builder(this)
|
||||||
|
.setTitle(R.string.start_nda_logging_dialog_title)
|
||||||
|
.setMessage(R.string.start_nda_logging_dialog_meassage)
|
||||||
|
.setIcon(android.R.drawable.ic_dialog_alert)
|
||||||
|
.setPositiveButton(android.R.string.yes, new DialogInterface.OnClickListener() {
|
||||||
|
public void onClick(DialogInterface dialog, int whichButton) {
|
||||||
|
mLm.enableNDATimer();
|
||||||
|
MenuItem startStopNDAMenuItem = mMenu.findItem(R.id.start_stop_nda);
|
||||||
|
startStopNDAMenuItem.setTitle(R.string.stop_nda_menu_title);
|
||||||
|
mUtil.stopServer();
|
||||||
|
// Wait 0.1 second to give the server chance to shutdown, then re-start it
|
||||||
|
new Handler().postDelayed(new Runnable() {
|
||||||
|
public void run() {
|
||||||
|
mUtil.startServer();
|
||||||
|
}
|
||||||
|
}, 100);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.setNegativeButton(android.R.string.no, null)
|
||||||
|
.show();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
case R.id.action_mark_unknown:
|
case R.id.action_mark_unknown:
|
||||||
Log.i(TAG, "action_mark_unknown");
|
Log.i(TAG, "action_mark_unknown");
|
||||||
@@ -542,6 +603,16 @@ public class LogManagerControlActivity extends AppCompatActivity {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
CompoundButton.OnCheckedChangeListener onIncludeNDACb =
|
||||||
|
new CompoundButton.OnCheckedChangeListener() {
|
||||||
|
@Override
|
||||||
|
public void onCheckedChanged(CompoundButton compoundButton, boolean b) {
|
||||||
|
Log.v(TAG, "onIncludeNDACb");
|
||||||
|
initialiseServiceConnection();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
AdapterView.OnItemClickListener onEventListClick =
|
AdapterView.OnItemClickListener onEventListClick =
|
||||||
new AdapterView.OnItemClickListener() {
|
new AdapterView.OnItemClickListener() {
|
||||||
public void onItemClick(AdapterView<?> adapter, View v, int position, long id) {
|
public void onItemClick(AdapterView<?> adapter, View v, int position, long id) {
|
||||||
|
|||||||
@@ -49,6 +49,25 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="000" />
|
android:text="000" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/NDATimeRemaining" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/nda_time_remaining_tv"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="000" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
<RadioGroup xmlns:android="http://schemas.android.com/apk/res/android"
|
<RadioGroup xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@@ -80,22 +99,23 @@
|
|||||||
</RadioGroup>
|
</RadioGroup>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:visibility="visible"
|
|
||||||
android:id="@+id/shared_data_ll"
|
android:id="@+id/shared_data_ll"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical"
|
||||||
|
android:visibility="visible">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="fill_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/remote_database"
|
android:text="@string/remote_database"
|
||||||
android:textAppearance="?android:attr/textAppearanceLarge" />
|
android:textAppearance="?android:attr/textAppearanceLarge" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="fill_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/check_seizures_message"
|
android:text="@string/check_seizures_message" />
|
||||||
/>
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@@ -112,24 +132,36 @@
|
|||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/authenticate" />
|
android:text="@string/authenticate" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/refresh_button"
|
android:id="@+id/refresh_button"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/refreshBtn" />
|
android:text="@string/refreshBtn" />
|
||||||
<ProgressBar
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:id="@+id/remoteAccessPb" />
|
|
||||||
|
|
||||||
|
<ProgressBar
|
||||||
|
android:id="@+id/remoteAccessPb"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
<CheckBox
|
<CheckBox
|
||||||
android:id="@+id/include_warnings_cb"
|
android:id="@+id/include_warnings_cb"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/include_warnings">
|
android:text="@string/include_warnings"></CheckBox>
|
||||||
</CheckBox>
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/include_nda_cb"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/include_nda"></CheckBox>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<ListView
|
<ListView
|
||||||
android:id="@+id/remoteEventsLv"
|
android:id="@+id/remoteEventsLv"
|
||||||
@@ -141,11 +173,11 @@
|
|||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:visibility="gone"
|
|
||||||
android:id="@+id/local_data_ll"
|
android:id="@+id/local_data_ll"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical"
|
||||||
|
android:visibility="gone">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="fill_parent"
|
||||||
@@ -161,11 +193,11 @@
|
|||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:visibility="gone"
|
|
||||||
android:id="@+id/syslog_ll"
|
android:id="@+id/syslog_ll"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical"
|
||||||
|
android:visibility="gone">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="fill_parent"
|
||||||
|
|||||||
@@ -27,5 +27,12 @@
|
|||||||
app:showAsAction="never|withText"
|
app:showAsAction="never|withText"
|
||||||
android:title="@string/data_sharing_log_in" />
|
android:title="@string/data_sharing_log_in" />
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/start_stop_nda"
|
||||||
|
android:enabled="true"
|
||||||
|
android:icon="@drawable/ic_action_settings"
|
||||||
|
app:showAsAction="never|withText"
|
||||||
|
android:title="@string/start_nda" />
|
||||||
|
|
||||||
</group>
|
</group>
|
||||||
</menu>
|
</menu>
|
||||||
|
|||||||
@@ -312,7 +312,7 @@
|
|||||||
<string name="title_activity_authenticate">Log in to OpenSeizureDetector Data Sharing</string>
|
<string name="title_activity_authenticate">Log in to OpenSeizureDetector Data Sharing</string>
|
||||||
<string name="logout">Log Out</string>
|
<string name="logout">Log Out</string>
|
||||||
<string name="logged_in_with_token">Logged in to\nData Sharing</string>
|
<string name="logged_in_with_token">Logged in to\nData Sharing</string>
|
||||||
<string name="local_database">Logged Data Manager</string>
|
<string name="local_database">Data Sharing Manager</string>
|
||||||
<string name="remote_database">Shared Data</string>
|
<string name="remote_database">Shared Data</string>
|
||||||
<string name="num_local_events">Number of Events Stored on Phone: </string>
|
<string name="num_local_events">Number of Events Stored on Phone: </string>
|
||||||
<string name="num_local_datapoints">"Number of Datapoints Stored on Phone: "</string>
|
<string name="num_local_datapoints">"Number of Datapoints Stored on Phone: "</string>
|
||||||
@@ -441,4 +441,15 @@
|
|||||||
<string name="LogNDASummary">Continuously log data to the data sharing system to provide background \'normal daily activity\' data to help reduce false alarms.</string>
|
<string name="LogNDASummary">Continuously log data to the data sharing system to provide background \'normal daily activity\' data to help reduce false alarms.</string>
|
||||||
<string name="LogNDATitle">Log Normal Daily Activities (NDA)</string>
|
<string name="LogNDATitle">Log Normal Daily Activities (NDA)</string>
|
||||||
<string name="NDATimerStartTimeParseError">Error Parsing NDATimerStartTime</string>
|
<string name="NDATimerStartTimeParseError">Error Parsing NDATimerStartTime</string>
|
||||||
|
<string name="include_nda">Include NDA</string>
|
||||||
|
<string name="start_nda">Start NDA Logging</string>
|
||||||
|
<string name="stop_nda">Stop NDA Logging</string>
|
||||||
|
<string name="stop_nda_logging_dialog_title">Stop NDA Logging?</string>
|
||||||
|
<string name="stop_nda_logging_dialog_meassage">Stop Normal Daily Activity (NDA) Logging?</string>
|
||||||
|
<string name="start_nda_logging_dialog_title">Start NDA Logging?</string>
|
||||||
|
<string name="start_nda_logging_dialog_meassage">Start Normal Daily Activity (NDA) Logging (will stop automatically after 24 hours)?</string>
|
||||||
|
<string name="NDATimeRemaining">"NDA Logging Time Remaining (hours): "</string>
|
||||||
|
<string name="stop_nda_menu_title">Stop NDA</string>
|
||||||
|
<string name="start_nda_menu_title">Start NDA</string>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
Reference in New Issue
Block a user