def mkrefs(*objs):
 allObjs = {}
 for obj in objs:
  if isinstance(obj, pg.QtCore.QObject):
   obj = qObjectTree(obj)
  else:
   obj = [obj]
  for o in obj:
   allObjs[id(o)] = o
 return map(weakref.ref, allObjs.values())

def mkrefs ( * objs ) : allObjs = { } for obj in objs : if isinstance ( obj , pg . QtCore . QObject ) : obj = qObjectTree ( obj ) else : obj = [ obj ] for o in obj : allObjs [ id ( o ) ] = o return map ( weakref . ref , allObjs . values ( ) )
return a list of weakrefs to each object in *objs .