def normPath(pathName): result = '' if pathName != '': if (sys.platform == 'win32'): result = str(QtCore.QDir(pathName).absolutePath()) else: result = os.path.normpath(str(pathName)) return result
def __init__(self, dirName): # self.dirName = dirName self.libdir = QtCore.QDir(dirName) self.model = QtGui.QStandardItemModel() self.parentItem = self.model.invisibleRootItem() print '>> NodeLibrary: libdir = %s' % dirName self.liblevel = '' self.scanLibDir()