Commit 3fb14aac8bb10a9dccd74a8fc659d3594c86ed9b

Authored by YangShuai
1 parent 8274f8f2

1 修改配网相关流程提示语

config.gradle
@@ -21,7 +21,7 @@ ext { @@ -21,7 +21,7 @@ ext {
21 //编译方式 21 //编译方式
22 debug : false, 22 debug : false,
23 //版本号 23 //版本号
24 - version: "0.2.15", 24 + version: "0.2.16",
25 //Lib库前缀 25 //Lib库前缀
26 packeg : "com.cnlive.module", 26 packeg : "com.cnlive.module",
27 //Lib库名称 27 //Lib库名称
module_xiaojiaSoundBox/src/main/java/com/cnlive/strike/xiaojiaspeaker/frame/view/SelectWifiFragmentView.java
@@ -209,7 +209,7 @@ public class SelectWifiFragmentView implements MvpView { @@ -209,7 +209,7 @@ public class SelectWifiFragmentView implements MvpView {
209 if (null == getContext()) { 209 if (null == getContext()) {
210 return; 210 return;
211 } 211 }
212 - QMUITipDialogUtil.loadingDialog(getContext(), "正在连接中,请稍后...", false); 212 + QMUITipDialogUtil.loadingDialog(getContext(), "配网中,请稍后...", false);
213 213
214 } 214 }
215 215
@@ -217,8 +217,7 @@ public class SelectWifiFragmentView implements MvpView { @@ -217,8 +217,7 @@ public class SelectWifiFragmentView implements MvpView {
217 @Override 217 @Override
218 public void onConnectFail(BleDevice bleDevice, BleException exception) { 218 public void onConnectFail(BleDevice bleDevice, BleException exception) {
219 QMUITipDialogUtil.dismessDialog(); 219 QMUITipDialogUtil.dismessDialog();
220 - AlertUtil.showDeftToast(getContext(), "连接失败,请重试...");  
221 - Log.e(TAG, "onConnectFail: " + exception); 220 + AlertUtil.showDeftToast(getContext(), "连接无响应,请稍后重试");
222 } 221 }
223 222
224 // 连接成功,BleDevice即为所连接的BLE设备 223 // 连接成功,BleDevice即为所连接的BLE设备
@@ -245,14 +244,14 @@ public class SelectWifiFragmentView implements MvpView { @@ -245,14 +244,14 @@ public class SelectWifiFragmentView implements MvpView {
245 new BleWriteCallback() { 244 new BleWriteCallback() {
246 @Override 245 @Override
247 public void onWriteSuccess(int current, int total, byte[] justWrite) { 246 public void onWriteSuccess(int current, int total, byte[] justWrite) {
248 - Log.e(TAG, "onWriteSuccess: " + current + "," + total); 247 +// Log.e(TAG, "onWriteSuccess: " + current + "," + total);
249 // 发送数据到设备成功(分包发送的情况下,可以通过方法中返回的参数可以查看发送进度) 248 // 发送数据到设备成功(分包发送的情况下,可以通过方法中返回的参数可以查看发送进度)
250 } 249 }
251 250
252 @Override 251 @Override
253 public void onWriteFailure(BleException exception) { 252 public void onWriteFailure(BleException exception) {
254 Log.e(TAG, "onWriteFailure: "); 253 Log.e(TAG, "onWriteFailure: ");
255 - AlertUtil.showDeftToast(getContext(), "连接失败,请重试..."); 254 + AlertUtil.showDeftToast(getContext(), "连接无响应,请稍后重试");
256 255
257 } 256 }
258 }); 257 });
@@ -261,9 +260,8 @@ public class SelectWifiFragmentView implements MvpView { @@ -261,9 +260,8 @@ public class SelectWifiFragmentView implements MvpView {
261 260
262 @Override 261 @Override
263 public void onNotifyFailure(BleException exception) { 262 public void onNotifyFailure(BleException exception) {
264 - Log.e(TAG, "onNotifyFailure: " + exception);  
265 QMUITipDialogUtil.dismessDialog(); 263 QMUITipDialogUtil.dismessDialog();
266 - AlertUtil.showDeftToast(getContext(), "连接失败,请重试..."); 264 + AlertUtil.showDeftToast(getContext(), "连接无响应,请稍后重试");
267 } 265 }
268 266
269 @Override 267 @Override
@@ -273,7 +271,6 @@ public class SelectWifiFragmentView implements MvpView { @@ -273,7 +271,6 @@ public class SelectWifiFragmentView implements MvpView {
273 } 271 }
274 try { 272 try {
275 String result = new String(data, "UTF-8"); 273 String result = new String(data, "UTF-8");
276 - Log.e(TAG, "onCharacteristicChanged: " + result);  
277 if (result.indexOf(BlufiConstants.WIFI_LINK_OK) != -1) { 274 if (result.indexOf(BlufiConstants.WIFI_LINK_OK) != -1) {
278 isSetNetSuccess = true; 275 isSetNetSuccess = true;
279 BleManager.getInstance().stopNotify(bleDevice, BlufiConstants.UUID_WIFI_SERVICE.toString(), BlufiConstants.UUID_NOTIFY_CHARACTERISTIC.toString()); 276 BleManager.getInstance().stopNotify(bleDevice, BlufiConstants.UUID_WIFI_SERVICE.toString(), BlufiConstants.UUID_NOTIFY_CHARACTERISTIC.toString());