mirror of
https://github.com/python/cpython.git
synced 2024-11-26 11:24:40 +08:00
Patch by Ronald Oussoren: if there's a .lproj in the extras list also
check whether it contains a .nib, and do the Cocoa song and dance if it does.
This commit is contained in:
parent
0a9d7559e8
commit
94caa78ebf
@ -322,7 +322,16 @@ def process_common_macho(template, progress, code, rsrcname, destname, is_update
|
||||
<string>%s</string>
|
||||
<key>NSPrincipalClass</key>
|
||||
<string>NSApplication</string>""" % nibname
|
||||
|
||||
elif o[-6:] == '.lproj':
|
||||
files = os.listdir(o)
|
||||
for f in files:
|
||||
if f[-4:] == '.nib':
|
||||
nibname = os.path.split(f)[1][:-4]
|
||||
cocoainfo = """
|
||||
<key>NSMainNibFile</key>
|
||||
<string>%s</string>
|
||||
<key>NSPrincipalClass</key>
|
||||
<string>NSApplication</string>""" % nibname
|
||||
|
||||
plistname = os.path.join(template, 'Contents', 'Resources', 'Applet-Info.plist')
|
||||
plistdata = open(plistname).read()
|
||||
|
Loading…
Reference in New Issue
Block a user