import os
import shutil
import sys
-
-xwalk_dir = os.path.dirname(os.path.abspath(__file__))
+import tempfile
def CopyToPathWithName(root, name, final_path, rename):
if name == '':
def CopyDrawables(image_dict, orientation, sanitized_name, name, app_root):
- drawable = os.path.join(xwalk_dir, sanitized_name, 'res', 'drawable')
+ drawable = os.path.join(tempfile.gettempdir(), sanitized_name, 'res',
+ 'drawable')
if orientation == 'landscape':
drawable = drawable + '-land'
elif orientation == 'portrait':
orientation,
sanitized_name,
app_root):
- background_path = os.path.join(xwalk_dir, sanitized_name, 'res',
+ background_path = os.path.join(tempfile.gettempdir(), sanitized_name, 'res',
'drawable', 'launchscreen_bg.xml')
if not os.path.isfile(background_path):
print('Error: launchscreen_bg.xml is missing in the build tool.')