45 |
45 |
46 appendStderr = pyqtSignal(str) |
46 appendStderr = pyqtSignal(str) |
47 showMenu = pyqtSignal(str, QMenu) |
47 showMenu = pyqtSignal(str, QMenu) |
48 |
48 |
49 RCFilenameFormatPython = "{0}_rc.py" |
49 RCFilenameFormatPython = "{0}_rc.py" |
50 RCFilenameFormatRuby = "{0}_rc.rb" |
|
51 |
50 |
52 def __init__(self, project, projectBrowser, parent=None): |
51 def __init__(self, project, projectBrowser, parent=None): |
53 """ |
52 """ |
54 Constructor |
53 Constructor |
55 |
54 |
773 dirname, filename = os.path.split(ofn) |
772 dirname, filename = os.path.split(ofn) |
774 if self.project.getProjectLanguage() == "Python3": |
773 if self.project.getProjectLanguage() == "Python3": |
775 self.compiledFile = os.path.join( |
774 self.compiledFile = os.path.join( |
776 dirname, self.RCFilenameFormatPython.format(filename) |
775 dirname, self.RCFilenameFormatPython.format(filename) |
777 ) |
776 ) |
778 elif self.project.getProjectLanguage() == "Ruby": |
|
779 self.compiledFile = os.path.join( |
|
780 dirname, self.RCFilenameFormatRuby.format(filename) |
|
781 ) |
|
782 |
777 |
783 args.append(fn) |
778 args.append(fn) |
784 self.compileProc.finished.connect(self.__compileQRCDone) |
779 self.compileProc.finished.connect(self.__compileQRCDone) |
785 self.compileProc.readyReadStandardOutput.connect(self.__readStdout) |
780 self.compileProc.readyReadStandardOutput.connect(self.__readStdout) |
786 self.compileProc.readyReadStandardError.connect(self.__readStderr) |
781 self.compileProc.readyReadStandardError.connect(self.__readStderr) |
961 ifn = os.path.join(self.project.ppath, fn) |
956 ifn = os.path.join(self.project.ppath, fn) |
962 if self.project.getProjectLanguage() == "Python3": |
957 if self.project.getProjectLanguage() == "Python3": |
963 dirname, filename = os.path.split(os.path.splitext(ifn)[0]) |
958 dirname, filename = os.path.split(os.path.splitext(ifn)[0]) |
964 ofn = os.path.join( |
959 ofn = os.path.join( |
965 dirname, self.RCFilenameFormatPython.format(filename) |
960 dirname, self.RCFilenameFormatPython.format(filename) |
966 ) |
|
967 elif self.project.getProjectLanguage() == "Ruby": |
|
968 dirname, filename = os.path.split(os.path.splitext(ifn)[0]) |
|
969 ofn = os.path.join( |
|
970 dirname, self.RCFilenameFormatRuby.format(filename) |
|
971 ) |
961 ) |
972 else: |
962 else: |
973 return |
963 return |
974 if ( |
964 if ( |
975 not os.path.exists(ofn) |
965 not os.path.exists(ofn) |