2644 |
2644 |
2645 @return programming language (string) |
2645 @return programming language (string) |
2646 """ |
2646 """ |
2647 return self.pdata["PROGLANGUAGE"][0] |
2647 return self.pdata["PROGLANGUAGE"][0] |
2648 |
2648 |
|
2649 def isPy3Project(self): |
|
2650 """ |
|
2651 Public method to check, if this project is a Python3 project. |
|
2652 |
|
2653 @return flag indicating a Python3 project (boolean) |
|
2654 """ |
|
2655 return self.pdata["PROGLANGUAGE"][0] == "Python3" |
|
2656 |
|
2657 def isPy2Project(self): |
|
2658 """ |
|
2659 Public method to check, if this project is a Python2 project. |
|
2660 |
|
2661 @return flag indicating a Python2 project (boolean) |
|
2662 """ |
|
2663 return self.pdata["PROGLANGUAGE"][0] in ["Python", "Python2"] |
|
2664 |
|
2665 def isRubyProject(self): |
|
2666 """ |
|
2667 Public method to check, if this project is a Ruby project. |
|
2668 |
|
2669 @return flag indicating a Ruby project (boolean) |
|
2670 """ |
|
2671 return self.pdata["PROGLANGUAGE"][0] == "Ruby" |
|
2672 |
2649 def getProjectSpellLanguage(self): |
2673 def getProjectSpellLanguage(self): |
2650 """ |
2674 """ |
2651 Public method to get the project's programming language. |
2675 Public method to get the project's programming language. |
2652 |
2676 |
2653 @return programming language (string) |
2677 @return programming language (string) |
3868 tbasename = os.path.splitext(tfn)[0] |
3892 tbasename = os.path.splitext(tfn)[0] |
3869 self.codeProfileAct.setEnabled( |
3893 self.codeProfileAct.setEnabled( |
3870 os.path.isfile("{0}.profile".format(basename)) or \ |
3894 os.path.isfile("{0}.profile".format(basename)) or \ |
3871 os.path.isfile("{0}.profile".format(tbasename))) |
3895 os.path.isfile("{0}.profile".format(tbasename))) |
3872 self.codeCoverageAct.setEnabled( |
3896 self.codeCoverageAct.setEnabled( |
3873 self.pdata["PROGLANGUAGE"][0] == "Python3" and \ |
3897 self.isPy3Project() and \ |
3874 (os.path.isfile("{0}.coverage".format(basename)) or \ |
3898 (os.path.isfile("{0}.coverage".format(basename)) or \ |
3875 os.path.isfile("{0}.coverage".format(tbasename)))) |
3899 os.path.isfile("{0}.coverage".format(tbasename)))) |
3876 else: |
3900 else: |
3877 self.codeProfileAct.setEnabled(False) |
3901 self.codeProfileAct.setEnabled(False) |
3878 self.codeCoverageAct.setEnabled(False) |
3902 self.codeCoverageAct.setEnabled(False) |