This commit is contained in:
Harald Hoyer 2017-04-27 16:27:31 +02:00
parent 9f7836f4f2
commit 01250ee86b
4 changed files with 6 additions and 16 deletions

View file

@ -94,8 +94,6 @@ public class BluetoothChatService extends Service {
mNM = (NotificationManager)getSystemService(NOTIFICATION_SERVICE); mNM = (NotificationManager)getSystemService(NOTIFICATION_SERVICE);
// Display a notification about us starting. We put an icon in the status bar.
showNotification();
} }
boolean startIConsole() { boolean startIConsole() {
@ -260,7 +258,7 @@ public class BluetoothChatService extends Service {
// Start the thread to manage the connection and perform transmissions // Start the thread to manage the connection and perform transmissions
mConnectedThread = new ConnectedThread(socket); mConnectedThread = new ConnectedThread(socket);
mConnectedThread.start(); mConnectedThread.start();
showNotification();
// Send the name of the connected device back to the UI Activity // Send the name of the connected device back to the UI Activity
Message msg = mHandler.obtainMessage(Constants.MESSAGE_DEVICE_NAME); Message msg = mHandler.obtainMessage(Constants.MESSAGE_DEVICE_NAME);
Bundle bundle = new Bundle(); Bundle bundle = new Bundle();

View file

@ -23,10 +23,8 @@
android:id="@+id/title_paired_devices" android:id="@+id/title_paired_devices"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="#666"
android:paddingLeft="5dp" android:paddingLeft="5dp"
android:text="@string/title_paired_devices" android:text="@string/title_paired_devices"
android:textColor="#fff"
android:visibility="gone" android:visibility="gone"
/> />
@ -42,10 +40,8 @@
android:id="@+id/title_new_devices" android:id="@+id/title_new_devices"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="#666"
android:paddingLeft="5dp" android:paddingLeft="5dp"
android:text="@string/title_other_devices" android:text="@string/title_other_devices"
android:textColor="#fff"
android:visibility="gone" android:visibility="gone"
/> />

View file

@ -16,14 +16,12 @@
--> -->
<resources> <resources>
<string name="app_name">iConsole</string> <string name="app_name">OpeniConsole</string>
<string name="intro_message"> <string name="intro_message">
<![CDATA[ <![CDATA[
This application connects to an iConsole+ mount unit for fitness devices. This application connects to an iConsole+ mount unit for fitness devices.
]]> ]]>
</string> </string>
</resources> </resources>

View file

@ -18,7 +18,7 @@
<!-- BluetoothChat --> <!-- BluetoothChat -->
<string name="not_connected">You are not connected to a device</string> <string name="not_connected">You are not connected to a device</string>
<string name="bt_not_enabled_leaving">Bluetooth was not enabled. Leaving Bluetooth Chat.</string> <string name="bt_not_enabled_leaving">Bluetooth was not enabled. Leaving OpeniConsole.</string>
<string name="title_connecting">connecting...</string> <string name="title_connecting">connecting...</string>
<string name="title_connected_to">connected to <xliff:g id="device_name">%1$s</xliff:g></string> <string name="title_connected_to">connected to <xliff:g id="device_name">%1$s</xliff:g></string>
<string name="title_not_connected">not connected</string> <string name="title_not_connected">not connected</string>
@ -33,9 +33,6 @@
<string name="button_scan">Scan for devices</string> <string name="button_scan">Scan for devices</string>
<!-- Options Menu --> <!-- Options Menu -->
<string name="secure_connect">Connect a device - Secure</string>
<string name="insecure_connect">Connect a device - Insecure</string>
<string name="discoverable">Make discoverable</string>
<string name="start">Start</string> <string name="start">Start</string>
<string name="stop">Stop</string> <string name="stop">Stop</string>
<string name="disconnect">Disconnect</string> <string name="disconnect">Disconnect</string>
@ -48,7 +45,8 @@
<string name="heart_n0">0</string> <string name="heart_n0">0</string>
<string name="power_n0_0_w">0.0</string> <string name="power_n0_0_w">0.0</string>
<string name="level">Level</string> <string name="level">Level</string>
<string name="local_service_started">iConsole Bluetooth active</string> <string name="local_service_started">OpeniConsole Bluetooth active</string>
<string name="local_service_label">OpeniConsole</string> <string name="local_service_label">OpeniConsole</string>
<string name="secure_connect">Connect to iConsole</string>
</resources> </resources>