yayan 1 rok pred
rodič
commit
2a82e23dda

+ 1 - 0
.gitignore

@@ -15,6 +15,7 @@ migrate_working_dir/
 *.ipr
 *.iws
 .idea/
+.gradle/
 
 # The .vscode folder contains launch configuration and tasks you configure in
 # VS Code which you may wish to be included in version control, so this line

+ 1 - 0
NexilisSampleCode/app/src/main/java/com/example/nexilissamplecodeburger/MainActivity.java

@@ -27,6 +27,7 @@ public class MainActivity extends AppCompatActivity {
 
         //SMS
         //EMAIL
+        //SMARTBOT
         
         /*************************************
          Connect to our server with your nexilis.io Account, and implement the required Callback.

+ 1 - 0
NexilisSampleCodeFlutter-Android/android/app/src/main/java/com/example/paliolitesamplecodeflutter/MainActivity.java

@@ -32,6 +32,7 @@ public class MainActivity extends FlutterActivity {
 
         //SMS
         //EMAIL
+        //SMARTBOT
 
         /*************************************
          Connect to our server with your newuniverse.io Account, and implement the required Callback.

+ 1 - 0
NexilisSampleCodeIonic-Android/android/app/src/main/java/com/example/paliolitesamplecodeionic/MainActivity.java

@@ -25,6 +25,7 @@ public class MainActivity extends BridgeActivity {
 
     //SMS
     //EMAIL
+    //SMARTBOT
 
     /*************************************
      Connect to our server with your newuniverse.io Account, and implement the required Callback.

+ 1 - 0
NexilisSampleCodeReact-Android/android/app/src/main/java/com/paliolitesamplecode/MainActivity.java

@@ -51,6 +51,7 @@ public class MainActivity extends ReactActivity {
 
         //SMS
         //EMAIL
+        //SMARTBOT
 
         /*************************************
          Connect to our server with your newuniverse.io Account, and implement the required Callback.

+ 25 - 6
main.py

@@ -198,6 +198,11 @@ def change(platform: str, mode: str, path_dest: str, features: dict, security: d
                         f.write(indented_str(2, "API.setEnabledEmail(true);"))
                     else:
                         f.write(indented_str(2, "// API.setEnabledEmail(true);"))
+                elif "//SMARTBOT" in line:
+                    if features["smartbot"]["status"]:
+                        f.write(indented_str(2, "API.setEnabledSmartBot(true);"))
+                    else:
+                        f.write(indented_str(2, "// API.setEnabledSmartBot(true);"))
                 elif "//BREAK" in line:
                     if mode == "floating":
                         f.write("}")
@@ -503,6 +508,11 @@ def change(platform: str, mode: str, path_dest: str, features: dict, security: d
                         f.write(indented_str(2, "API.setEnabledEmail(true);"))
                     else:
                         f.write(indented_str(2, "// API.setEnabledEmail(true);"))
+                elif "//SMARTBOT" in line:
+                    if features["smartbot"]["status"]:
+                        f.write(indented_str(2, "API.setEnabledSmartBot(true);"))
+                    else:
+                        f.write(indented_str(2, "// API.setEnabledSmartBot(true);"))
                 elif "//FLOATING" in line:
                     if mode == "floating":
                         f.write(indented_str(6, "ArrayList<FloatingButton> fb = new ArrayList<>();"))
@@ -725,6 +735,11 @@ def change(platform: str, mode: str, path_dest: str, features: dict, security: d
                         f.write(indented_str(2, "API.setEnabledEmail(true);", spaces=2))
                     else:
                         f.write(indented_str(2, "// API.setEnabledEmail(true);", spaces=2))
+                elif "//SMARTBOT" in line:
+                    if features["smartbot"]["status"]:
+                        f.write(indented_str(2, "API.setEnabledSmartBot(true);"))
+                    else:
+                        f.write(indented_str(2, "// API.setEnabledSmartBot(true);"))
                 elif "//FLOATING" in line:
                     if mode == "floating":
                         f.write(indented_str(6, "ArrayList<FloatingButton> fb = new ArrayList<>();", spaces=2))
@@ -1112,6 +1127,11 @@ def change(platform: str, mode: str, path_dest: str, features: dict, security: d
                         f.write(indented_str(2, "API.setEnabledEmail(true);"))
                     else:
                         f.write(indented_str(2, "// API.setEnabledEmail(true);"))
+                elif "//SMARTBOT" in line:
+                    if features["smartbot"]["status"]:
+                        f.write(indented_str(2, "API.setEnabledSmartBot(true);"))
+                    else:
+                        f.write(indented_str(2, "// API.setEnabledSmartBot(true);"))
                 elif "//FLOATING" in line:
                     if mode == "floating":
                         f.write(indented_str(6, "ArrayList<FloatingButton> fb = new ArrayList<>();"))
@@ -1664,27 +1684,21 @@ def build_project():
         mode = "burger"
         feature_dict = {
             "im": {
-                "android_name": "action_chats",
                 "status": False
             },
             "cc": {
-                "android_name": "action_cc",
                 "status": False
             },
             "call": {
-                "android_name": "action_call",
                 "status": False
             },
             "ls": {
-                "android_name": "action_ls",
                 "status": False
             },
             "settings": {
-                "android_name": "action_settings",
                 "status": False
             },
             "nc": {
-                "android_name": "action_nc",
                 "status": False
             },
             "sms": {
@@ -1693,6 +1707,9 @@ def build_project():
             "email": {
                 "status": False
             },
+            "smartbot": {
+                "status": False
+            }
         }
         security_dict = {
             "malware": False,
@@ -1722,6 +1739,8 @@ def build_project():
                 feature_dict["sms"]["status"] = request.form["feature_sms"] == "1"
             if "feature_email" in request.form:
                 feature_dict["email"]["status"] = request.form["feature_email"] == "1"
+            if "feature_smartbot" in request.form:
+                feature_dict["smartbot"]["status"] = request.form["feature_smartbot"] == "1"
             if "feature_settings" in request.form:
                 feature_dict["settings"]["status"] = request.form["feature_settings"] == "1"
             if "security_malware" in request.form: