Fix frameless on some version

This commit is contained in:
l 2020-08-11 08:35:10 +08:00
parent b5043508d9
commit a19eec5d6d

View File

@ -140,6 +140,9 @@ try:
if '{ frame: false, show: false' not in content:
content = content.replace(
'{ show: false', '{ frame: false, show: false')
if 'frame: false,' not in content:
content =re.sub(re.compile(r'\{(\s+)\.\.\.rect,(\s+)show: false,'), '{...rect, frame: false,show: false,', content)
print(
f' ...adding "open hidden" capabilities to {os.path.join(filepath, "app", "main", "createWindow.js")}')
content = re.sub('\\s*\\/\\* === INJECTION START === \\*\\/.*?\\/\\* === INJECTION END === \\*\\/\\s*',