소스 검색

返回值

JianXin 1 년 전
부모
커밋
8c86f61dec
1개의 변경된 파일7개의 추가작업 그리고 2개의 파일을 삭제
  1. 7 2
      android/app/src/main/java/com/example/smartledz_wifi_test/MainActivity.java

+ 7 - 2
android/app/src/main/java/com/example/smartledz_wifi_test/MainActivity.java

@@ -98,9 +98,14 @@ public class MainActivity extends FlutterActivity {
                 throw new RuntimeException(e);
             }
             EventChannelPlugin.getInstance().sendEventData(response.toString());
-//            wifiList.add(wifi);
         }
-
+        response = new JSONObject();
+        try {
+            response.put("cmd","scanComplete");
+        } catch (JSONException e) {
+            throw new RuntimeException(e);
+        }
+        EventChannelPlugin.getInstance().sendEventData(response.toString());
 
     }