Skip to content
Snippets Groups Projects
Commit dd16e61b authored by akwizgran's avatar akwizgran
Browse files

Use correct request code when retrying Bluetooth connection.

parent fe6216dc
No related branches found
No related tags found
No related merge requests found
......@@ -3,6 +3,7 @@ package org.briarproject.android.invitation;
import static android.bluetooth.BluetoothAdapter.ACTION_REQUEST_DISCOVERABLE;
import static android.bluetooth.BluetoothAdapter.EXTRA_DISCOVERABLE_DURATION;
import static android.view.Gravity.CENTER;
import static org.briarproject.android.invitation.AddContactActivity.REQUEST_BLUETOOTH;
import static org.briarproject.android.util.CommonLayoutParams.WRAP_WRAP;
import org.briarproject.R;
......@@ -57,6 +58,6 @@ class CodesDoNotMatchView extends AddContactView implements OnClickListener {
public void onClick(View view) {
Intent i = new Intent(ACTION_REQUEST_DISCOVERABLE);
i.putExtra(EXTRA_DISCOVERABLE_DURATION, 120);
container.startActivityForResult(i, 0);
container.startActivityForResult(i, REQUEST_BLUETOOTH);
}
}
......@@ -3,6 +3,7 @@ package org.briarproject.android.invitation;
import static android.bluetooth.BluetoothAdapter.ACTION_REQUEST_DISCOVERABLE;
import static android.bluetooth.BluetoothAdapter.EXTRA_DISCOVERABLE_DURATION;
import static android.view.Gravity.CENTER;
import static org.briarproject.android.invitation.AddContactActivity.REQUEST_BLUETOOTH;
import static org.briarproject.android.util.CommonLayoutParams.WRAP_WRAP;
import org.briarproject.R;
......@@ -59,6 +60,6 @@ class ConnectionFailedView extends AddContactView implements OnClickListener {
public void onClick(View view) {
Intent i = new Intent(ACTION_REQUEST_DISCOVERABLE);
i.putExtra(EXTRA_DISCOVERABLE_DURATION, 120);
container.startActivityForResult(i, 0);
container.startActivityForResult(i, REQUEST_BLUETOOTH);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment