eric6/Project/Project.py

branch
jsonfiles
changeset 8020
eddc8c3d3f9e
parent 8011
630a173cb137
child 8025
aaad60a23960
equal deleted inserted replaced
8019:5fb467ac4233 8020:eddc8c3d3f9e
957 """ 957 """
958 if self.pfile is None: 958 if self.pfile is None:
959 return 959 return
960 960
961 fn1, ext = os.path.splitext(os.path.basename(self.pfile)) 961 fn1, ext = os.path.splitext(os.path.basename(self.pfile))
962 fn = os.path.join(self.getProjectManagementDir(), '{0}.eqj'.format(fn1)) 962 fn = os.path.join(self.getProjectManagementDir(),
963 '{0}.eqj'.format(fn1))
963 if os.path.exists(fn): 964 if os.path.exists(fn):
964 # try the new JSON based format first 965 # try the new JSON based format first
965 self.__userProjectFile.readFile(fn) 966 self.__userProjectFile.readFile(fn)
966 else: 967 else:
967 # try the old XML based format second 968 # try the old XML based format second
4037 self.actions.append(self.userPropsAct) 4038 self.actions.append(self.userPropsAct)
4038 4039
4039 self.filetypesAct = E5Action( 4040 self.filetypesAct = E5Action(
4040 self.tr('Filetype Associations'), 4041 self.tr('Filetype Associations'),
4041 self.tr('Filetype Associations...'), 0, 0, 4042 self.tr('Filetype Associations...'), 0, 0,
4042 self, 'project_filetype_associatios') 4043 self, 'project_filetype_associations')
4043 self.filetypesAct.setStatusTip( 4044 self.filetypesAct.setStatusTip(
4044 self.tr('Show the project filetype associations')) 4045 self.tr('Show the project file type associations'))
4045 self.filetypesAct.setWhatsThis(self.tr( 4046 self.filetypesAct.setWhatsThis(self.tr(
4046 """<b>Filetype Associations...</b>""" 4047 """<b>Filetype Associations...</b>"""
4047 """<p>This shows a dialog to edit the file type associations of""" 4048 """<p>This shows a dialog to edit the file type associations of"""
4048 """ the project. These associations determine the type""" 4049 """ the project. These associations determine the type"""
4049 """ (source, form, interface, protocol or others) with a""" 4050 """ (source, form, interface, protocol or others) with a"""
4055 self.actions.append(self.filetypesAct) 4056 self.actions.append(self.filetypesAct)
4056 4057
4057 self.lexersAct = E5Action( 4058 self.lexersAct = E5Action(
4058 self.tr('Lexer Associations'), 4059 self.tr('Lexer Associations'),
4059 self.tr('Lexer Associations...'), 0, 0, 4060 self.tr('Lexer Associations...'), 0, 0,
4060 self, 'project_lexer_associatios') 4061 self, 'project_lexer_associations')
4061 self.lexersAct.setStatusTip(self.tr( 4062 self.lexersAct.setStatusTip(self.tr(
4062 'Show the project lexer associations (overriding defaults)')) 4063 'Show the project lexer associations (overriding defaults)'))
4063 self.lexersAct.setWhatsThis(self.tr( 4064 self.lexersAct.setWhatsThis(self.tr(
4064 """<b>Lexer Associations...</b>""" 4065 """<b>Lexer Associations...</b>"""
4065 """<p>This shows a dialog to edit the lexer associations of""" 4066 """<p>This shows a dialog to edit the lexer associations of"""

eric ide

mercurial