|
@@ -56,18 +56,18 @@ def create_folder(package_id):
|
|
|
|
|
|
|
|
|
|
def change_acc(c_code_path, acc, enable_sms):
|
|
def change_acc(c_code_path, acc, enable_sms):
|
|
- main_activity = os.path.join(c_code_path, "MainActivity.java")
|
|
|
|
|
|
+ main_activity = os.path.join(c_code_path, "MAB.java")
|
|
with open(main_activity, "r") as f:
|
|
with open(main_activity, "r") as f:
|
|
file_source = f.read()
|
|
file_source = f.read()
|
|
replaced = file_source.replace("***REPLACE***WITH***YOUR***QMERA***ACCOUNT***", acc)
|
|
replaced = file_source.replace("***REPLACE***WITH***YOUR***QMERA***ACCOUNT***", acc)
|
|
if enable_sms == 1:
|
|
if enable_sms == 1:
|
|
- replaced = replaced.replace("setIsEnabledSMS(false)", "setIsEnabledSMS(true)")
|
|
|
|
|
|
+ replaced = replaced.replace("isEnabledSMS = false", "isEnabledSMS = true")
|
|
with open(main_activity, "w") as f:
|
|
with open(main_activity, "w") as f:
|
|
f.write(replaced)
|
|
f.write(replaced)
|
|
|
|
|
|
|
|
|
|
def change_url(c_code_path, url):
|
|
def change_url(c_code_path, url):
|
|
- main_activity = os.path.join(c_code_path, "MainActivity.java")
|
|
|
|
|
|
+ main_activity = os.path.join(c_code_path, "MAB.java")
|
|
with open(main_activity, "r") as f:
|
|
with open(main_activity, "r") as f:
|
|
file_source = f.read()
|
|
file_source = f.read()
|
|
replaced = file_source.replace("https://www.google.com", url)
|
|
replaced = file_source.replace("https://www.google.com", url)
|
|
@@ -247,8 +247,8 @@ def change_logo(path_dest, logo, logo_float=None):
|
|
|
|
|
|
|
|
|
|
def change_tab(path_dest, tabs, tab_icon, package, tab3_mode, tab_amount):
|
|
def change_tab(path_dest, tabs, tab_icon, package, tab3_mode, tab_amount):
|
|
- default_tab_icon = ["tab1.png", "tab2.png", "tab3.png", "tab4.png"]
|
|
|
|
- for i in range(4):
|
|
|
|
|
|
+ default_tab_icon = ["tab{}.png".format(x) for x in range(1, tab_amount+1)]
|
|
|
|
+ for i in range(tab_amount):
|
|
if not tab_icon[i]:
|
|
if not tab_icon[i]:
|
|
continue
|
|
continue
|
|
img_path = "app/src/main/res/drawable"
|
|
img_path = "app/src/main/res/drawable"
|
|
@@ -274,7 +274,7 @@ def change_tab(path_dest, tabs, tab_icon, package, tab3_mode, tab_amount):
|
|
replaced = file_source.replace("1,2,3,4", ",".join(tabs))
|
|
replaced = file_source.replace("1,2,3,4", ",".join(tabs))
|
|
with open(sobj_code_path, "w") as f:
|
|
with open(sobj_code_path, "w") as f:
|
|
f.write(replaced)
|
|
f.write(replaced)
|
|
- main_code_path = os.path.join(path_dest, code_path, path_package_id, "MainActivity.java")
|
|
|
|
|
|
+ main_code_path = os.path.join(path_dest, code_path, path_package_id, "MAB.java")
|
|
with open(main_code_path, "r") as f:
|
|
with open(main_code_path, "r") as f:
|
|
file_source = f.read()
|
|
file_source = f.read()
|
|
replaced = file_source.replace('tab3 = "0"', 'tab3 = "{}"'.format(tab3_mode))
|
|
replaced = file_source.replace('tab3 = "0"', 'tab3 = "{}"'.format(tab3_mode))
|
|
@@ -435,13 +435,13 @@ def build_apk():
|
|
# tabs = ["1", "2", "3", "4"]
|
|
# tabs = ["1", "2", "3", "4"]
|
|
tabs = []
|
|
tabs = []
|
|
tab3_mode = "0"
|
|
tab3_mode = "0"
|
|
- tab_icon = [None, None, None, None]
|
|
|
|
|
|
+ tab_amount = 6
|
|
|
|
+ tab_icon = [None, None, None, None, None, None]
|
|
fb_icon = [None, None, None, None, None]
|
|
fb_icon = [None, None, None, None, None]
|
|
background = None
|
|
background = None
|
|
version_code = "1"
|
|
version_code = "1"
|
|
version_name = "1.0.0"
|
|
version_name = "1.0.0"
|
|
font = 0
|
|
font = 0
|
|
- tab_amount = 4
|
|
|
|
enable_sms = 0
|
|
enable_sms = 0
|
|
key = {"alias": "nexilislite", "store_password": "allyourbase", "key_password": "arebelongto", "common_name": "all", "organization_unit": "your",
|
|
key = {"alias": "nexilislite", "store_password": "allyourbase", "key_password": "arebelongto", "common_name": "all", "organization_unit": "your",
|
|
"organization_name": "base", "locality_name": "are", "state_name": "belong", "country": "to"}
|
|
"organization_name": "base", "locality_name": "are", "state_name": "belong", "country": "to"}
|