1193 pixName = "fileResource" |
1193 pixName = "fileResource" |
1194 elif self.isProjectFile(): |
1194 elif self.isProjectFile(): |
1195 pixName = "fileProject" |
1195 pixName = "fileProject" |
1196 elif self.isMultiProjectFile(): |
1196 elif self.isMultiProjectFile(): |
1197 pixName = "fileMultiProject" |
1197 pixName = "fileMultiProject" |
|
1198 # TODO: delegate to the plugin |
1198 elif self.isIdlFile(): |
1199 elif self.isIdlFile(): |
1199 pixName = "fileIDL" |
1200 pixName = "fileIDL" |
1200 self._populated = False |
1201 self._populated = False |
1201 self._lazyPopulation = True |
1202 self._lazyPopulation = True |
1202 self._moduleName = os.path.basename(finfo) |
1203 self._moduleName = os.path.basename(finfo) |
|
1204 # TODO: delegate to the plugin |
1203 elif self.isProtobufFile(): |
1205 elif self.isProtobufFile(): |
1204 pixName = "protobuf" |
1206 pixName = "protobuf" |
1205 self._populated = False |
1207 self._populated = False |
1206 self._lazyPopulation = True |
1208 self._lazyPopulation = True |
1207 self._moduleName = os.path.basename(finfo) |
1209 self._moduleName = os.path.basename(finfo) |
1237 self._filename = os.path.abspath(finfo) |
1239 self._filename = os.path.abspath(finfo) |
1238 self.itemData[0] = os.path.basename(finfo) |
1240 self.itemData[0] = os.path.basename(finfo) |
1239 if ( |
1241 if ( |
1240 self.isPython3File() |
1242 self.isPython3File() |
1241 or self.isRubyFile() |
1243 or self.isRubyFile() |
|
1244 # TODO: delegate to the plugin |
1242 or self.isIdlFile() |
1245 or self.isIdlFile() |
|
1246 # TODO: delegate to the plugin |
1243 or self.isProtobufFile() |
1247 or self.isProtobufFile() |
1244 ): |
1248 ): |
1245 self._dirName = os.path.dirname(finfo) |
1249 self._dirName = os.path.dirname(finfo) |
1246 self._moduleName = os.path.basename(finfo) |
1250 self._moduleName = os.path.basename(finfo) |
1247 |
1251 |
1366 @return flag indicating an eric project file |
1370 @return flag indicating an eric project file |
1367 @rtype bool |
1371 @rtype bool |
1368 """ |
1372 """ |
1369 return self.fileext in (".emj", ".e4m", ".e5m") |
1373 return self.fileext in (".emj", ".e4m", ".e5m") |
1370 |
1374 |
|
1375 # TODO: delegate to the plugin |
1371 def isIdlFile(self): |
1376 def isIdlFile(self): |
1372 """ |
1377 """ |
1373 Public method to check, if this file is a CORBA IDL file. |
1378 Public method to check, if this file is a CORBA IDL file. |
1374 |
1379 |
1375 @return flag indicating a CORBA IDL file |
1380 @return flag indicating a CORBA IDL file |
1376 @rtype bool |
1381 @rtype bool |
1377 """ |
1382 """ |
1378 return self.fileext == ".idl" |
1383 return self.fileext == ".idl" |
1379 |
1384 |
|
1385 # TODO: delegate to the plugin |
1380 def isProtobufFile(self): |
1386 def isProtobufFile(self): |
1381 """ |
1387 """ |
1382 Public method to check, if this file is a Google Protocol Buffer file. |
1388 Public method to check, if this file is a Google Protocol Buffer file. |
1383 |
1389 |
1384 @return flag indicating a protobuf file |
1390 @return flag indicating a protobuf file |