Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When receiving, enable Bluetooth automatically if not enabled already #132

Open
bzzrak opened this issue Feb 4, 2024 · 1 comment
Open
Labels
area::Receive Receive area::UI-UX App user interface good first issue Good for newcomers type::feature-request New feature or request

Comments

@bzzrak
Copy link

bzzrak commented Feb 4, 2024

When I want to receive a file, I need to turn BT on in advance. It would be nice if the app did this by itself

@ShortDevelopment ShortDevelopment added type::feature-request New feature or request area::UI-UX App user interface area::Receive Receive labels Feb 8, 2024
@ShortDevelopment ShortDevelopment added the good first issue Good for newcomers label Mar 23, 2024
@ShortDevelopment
Copy link
Member

Similar to the code in SendActivity

android/src/SendActivity.cs

Lines 209 to 214 in 92ef4de

if (remoteSystem.Endpoint.TransportType == CdpTransportType.Rfcomm &&
_cdp.TryGetTransport<BluetoothTransport>()?.Handler.IsEnabled == false)
{
StartActivityForResult(new Intent(BluetoothAdapter.ActionRequestEnable), 42);
throw new TaskCanceledException("Bluetooth is disabled");
}

a check should be implemented in the ReceiveActivity
void InitializeCDP()


Ideally, the app would wait for the result and continue instead of showing an error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area::Receive Receive area::UI-UX App user interface good first issue Good for newcomers type::feature-request New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants