import sip

This commit is contained in:
gen2brain 2013-04-06 11:22:31 +02:00
parent 4e8b0682b4
commit 446a7955ed

10
m64py
View file

@ -19,13 +19,15 @@
import os
import sys
import signal
from optparse import OptionParser
if os.path.isdir(os.path.join(".","src")) and os.path.isfile(
os.path.join(".","setup.py")):
sys.path.append(os.path.realpath("src"))
try:
import sip
sip.setapi('QString', 2)
sip.setapi('QVariant', 2)
from PyQt4.QtGui import QApplication
from PyQt4.QtCore import Qt
except ImportError, err:
@ -50,10 +52,6 @@ LOGO += "|_| |_|\__,_| .__/ \___|_| |_|\___/ |_| |_| |_|\__,_|___/ \n"
LOGO += " |_| \n"
def main():
usage = 'usage: %prog <file>'
parser = OptionParser(usage=usage,
version="M64Py Version %s" % FRONTEND_VERSION)
try:
QApplication.setAttribute(Qt.AA_X11InitThreads)
except AttributeError:
@ -64,7 +62,7 @@ def main():
pass
app = QApplication(sys.argv)
opts, args = parser.parse_args()
from m64py.opts import opts, args
sys.stderr.write("%s\nM64Py - A frontend for Mupen64Plus version %s\n\n" % (
LOGO, FRONTEND_VERSION))
window = MainWindow((opts, args))