Fix some pylint

This commit is contained in:
Cole Robinson 2011-04-09 21:56:05 -04:00
parent dc054e05a9
commit aa15d2d4a0
4 changed files with 8 additions and 6 deletions

View File

@ -871,7 +871,7 @@ class vmmConnection(vmmGObject):
return
vobj = self.get_nodedev(name)
mediadev = vmmMediaDevice.mediadev_from_nodedev(self, vobj)
mediadev = vmmMediaDevice.mediadev_from_nodedev(vobj)
if not mediadev:
return

View File

@ -40,7 +40,7 @@ class vmmMediaDevice(vmmGObject):
}
@staticmethod
def mediadev_from_nodedev(conn, dev):
def mediadev_from_nodedev(dev):
nodedev = dev.get_virtinst_obj()
if nodedev.device_type != "storage":

View File

@ -18,9 +18,6 @@
# MA 02110-1301 USA.
#
import gobject
import logging
import virtinst
from virtManager.libvirtobject import vmmLibvirtObject
@ -42,6 +39,12 @@ class vmmNodeDevice(vmmLibvirtObject):
def _XMLDesc(self, flags):
return self._backend.XMLDesc(flags)
def get_name(self):
return self.name
def is_active(self):
return True
def get_virtinst_obj(self):
if not self._virtinst_obj:
self._virtinst_obj = virtinst.NodeDeviceParser.parse(

View File

@ -22,7 +22,6 @@ import logging
import os
import statvfs
import libvirt
import gtk
import virtinst