更改提示文字

master
张萌 3 years ago
parent a642670f57
commit f0b2982229

@ -42,7 +42,7 @@ public class Blutooth {
bluetoothSetup();
searchflags = false;
disconnectflags = false;
System.out.println("初始化完成");
System.out.println("打印机蓝牙初始化完成");
}
//初始化连接监听

@ -77,6 +77,7 @@ public class DjPrinterPlugin implements FlutterPlugin, MethodCallHandler {
e.printStackTrace();
}
} else if (call.method.equals("init")) {
System.out.println("打印机初始化");
blutooth.init();
asPrint = new AsPrint();

@ -69,6 +69,10 @@ class DjPrinter {
final res = _channel.invokeMethod('startSearch');
}
bool _hasInit = false;
bool get hasInit => _hasInit;
Future<bool?> connect(String address) async {
final res = await _channel.invokeMethod('connect', {'address': address});
return res;
@ -86,6 +90,7 @@ class DjPrinter {
Future<bool?> init() async {
final res = await _channel.invokeMethod('init');
_hasInit = true;
return res;
}

Loading…
Cancel
Save