Skip to content

Commit

Permalink
v0.1.1 | Fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
huitingyeong committed Jan 21, 2021
1 parent 5948e21 commit c919c89
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 20 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## 0.1.1
* Fix typo

## 0.1.0
* New Feature: Customizable alert message and button text

Expand Down
35 changes: 17 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,23 +43,22 @@ This method calls an alert from Dart level. Depending on the user's selection, B
```dart
import 'package:bluetooth_enable/bluetooth_enable.dart';
Future<void> customEnableBT(BuildContext context) async{
String dialogTitle = "Hey! Please give me permission to use Bluetooth!";
bool displayDialogContent = true;
String dialogContent = "This app requires Bluetooth to connect to device.";
//or
// bool displayDialogContent = false;
// String dialogContent = "";
String cancelBtnText = "Nope";
String acceptBtnText = "Sure";
double dialogRadius = 10.0;
bool barrierDismissible = true; //Enable or Disable whether dialog is dismissible on external click
Future<void> customEnableBT(BuildContext context) async {
String dialogTitle = "Hey! Please give me permission to use Bluetooth!";
bool displayDialogContent = true;
String dialogContent = "This app requires Bluetooth to connect to device.";
//or
// bool displayDialogContent = false;
// String dialogContent = "";
String cancelBtnText = "Nope";
String acceptBtnText = "Sure";
double dialogRadius = 10.0;
bool barrierDismissible = true; //
// Request to turn on Bluetooth within an app with a custom alert dialog
BluetoothEnable.customBluetoothRequest(context, dialogTitle, displayDialogContent, dialogContent, cancelBtnText, acceptBtnText, dialogRadius, barrierDismissible).then((value){
if (result == "true"){
//Bluetooth has been enabled
}
});
}
BluetoothEnable.customBluetoothRequest(context, dialogTitle, displayDialogContent, dialogContent, cancelBtnText, acceptBtnText, dialogRadius, barrierDismissible).then((result) {
if (result == "true"){
//Bluetooth has been enabled
}
});
}
```
2 changes: 1 addition & 1 deletion example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ packages:
path: ".."
relative: true
source: path
version: "0.1.0"
version: "0.1.1"
boolean_selector:
dependency: transitive
description:
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: bluetooth_enable
description: Flutter plugin to turn on bluetooth within app (Android only)
version: 0.1.0
version: 0.1.1
# authors:
# - Hui
homepage: https://github.com/huitingyeong/bluetooth_enable
Expand Down

0 comments on commit c919c89

Please sign in to comment.