2851 dlg = FiletypeAssociationDialog(self) |
2851 dlg = FiletypeAssociationDialog(self) |
2852 if dlg.exec() == QDialog.Accepted: |
2852 if dlg.exec() == QDialog.Accepted: |
2853 dlg.transferData() |
2853 dlg.transferData() |
2854 self.setDirty(True) |
2854 self.setDirty(True) |
2855 self.__reorganizeFiles() |
2855 self.__reorganizeFiles() |
2856 |
2856 |
|
2857 def getFiletypeAssociations(self, associationType): |
|
2858 """ |
|
2859 Public method to get the list of file type associations for |
|
2860 the given association type. |
|
2861 |
|
2862 @param associationType type of the association (one of FORMS, |
|
2863 INTERFACES, OTHERS, PROTOCOLS, RESOURCES, SOURCES or |
|
2864 TRANSLATIONS) |
|
2865 @type str |
|
2866 @return list of file patterns for the given type |
|
2867 @rtype list of str |
|
2868 """ |
|
2869 return [assoc for assoc in self.pdata["FILETYPES"] |
|
2870 if self.pdata["FILETYPES"][assoc] == associationType] |
|
2871 |
2857 def __showLexerAssociations(self): |
2872 def __showLexerAssociations(self): |
2858 """ |
2873 """ |
2859 Private slot to display the lexer association dialog. |
2874 Private slot to display the lexer association dialog. |
2860 """ |
2875 """ |
2861 from .LexerAssociationDialog import LexerAssociationDialog |
2876 from .LexerAssociationDialog import LexerAssociationDialog |