Improvements to built app (OSX)

This commit is contained in:
Skyler Lehmkuhl 2012-01-14 21:01:12 -05:00
parent adeb066a94
commit 0e469e0c91
2 changed files with 6 additions and 5 deletions

View File

@ -6,7 +6,7 @@
import os import os
#Uncomment to build on OS X #Uncomment to build on OS X
import objc, AppKit import objc, AppKit, cPickle
#SVLGUI - my custom GUI wrapper to abstract the GUI #SVLGUI - my custom GUI wrapper to abstract the GUI
import svlgui import svlgui
@ -162,8 +162,8 @@ def run_file(self=None):
global root global root
print "RUNNING" print "RUNNING"
root.descendItem().activelayer.frames[root.descendItem().activelayer.currentframe].actions = MainWindow.scriptwindow.text root.descendItem().activelayer.frames[root.descendItem().activelayer.currentframe].actions = MainWindow.scriptwindow.text
open("test.sc", "w").write(create_sc(root)) open(os.getenv('HOME')+"/test.sc", "w").write(create_sc(root))
svlgui.execute("swfc/swfc_"+svlgui.PLATFORM+" test.sc -o test.swf") svlgui.execute("swfc/swfc_"+svlgui.PLATFORM+" "+os.getenv('HOME')+"/test.sc -o "+os.getenv('HOME')+"/test.swf")
#TODO: Make this cross-platform compatible #TODO: Make this cross-platform compatible
logloc = os.getenv('HOME')+"/Library/Preferences/Macromedia/Flash Player/Logs/flashlog.txt" logloc = os.getenv('HOME')+"/Library/Preferences/Macromedia/Flash Player/Logs/flashlog.txt"
try: try:

View File

@ -25,13 +25,13 @@ if sys.platform == 'darwin':
app=[mainscript], app=[mainscript],
# Cross-platform applications generally expect sys.argv to # Cross-platform applications generally expect sys.argv to
# be used for opening files. # be used for opening files.
options=dict(py2app=dict(argv_emulation=True, options=dict(py2app=dict(argv_emulation=False,
plist=dict( plist=dict(
#CFBundleDocumentTypes= , #CFBundleDocumentTypes= ,
CFBundleIdentifyer='org.lightningbeam.lightningbeam', CFBundleIdentifyer='org.lightningbeam.lightningbeam',
#LSPrefersPPC=True, #LSPrefersPPC=True,
), ),
resources=["media","gpl.txt"], resources=["media","gpl.txt","swfc"],
iconfile="Lightningbeam.icns" iconfile="Lightningbeam.icns"
)), )),
) )
@ -39,6 +39,7 @@ elif sys.platform == 'win32':
extra_options = dict( extra_options = dict(
setup_requires=['py2exe'], setup_requires=['py2exe'],
app=[mainscript], app=[mainscript],
options=dict(py2app=dict(resources=["media","gpl.txt","swfc"],)),
) )
else: else:
extra_options = dict( extra_options = dict(