summaryrefslogtreecommitdiff
path: root/virtManager/addhardware.py
diff options
context:
space:
mode:
authorCole Robinson <crobinso@redhat.com>2020-09-21 21:14:35 -0400
committerCole Robinson <crobinso@redhat.com>2020-09-21 22:11:17 -0400
commit9a5ab50b51499d9b8e982de2d7a827074c481d22 (patch)
tree7333c97c37a2a963685f4c7cd0eb9d03fe8b9425 /virtManager/addhardware.py
parente5a51f637411b4b2efc789fdef99eb4860ac3b9f (diff)
downloadvirt-manager-9a5ab50b51499d9b8e982de2d7a827074c481d22.tar.gz
gfxdetails: Use a single 'changed' signal
And absord device building from addhardware. This moves all the knowledge to gfxdetails, which saves sprinkling it around in other places Signed-off-by: Cole Robinson <crobinso@redhat.com>
Diffstat (limited to 'virtManager/addhardware.py')
-rw-r--r--virtManager/addhardware.py18
1 files changed, 2 insertions, 16 deletions
diff --git a/virtManager/addhardware.py b/virtManager/addhardware.py
index 8d814eab..eaf27248 100644
--- a/virtManager/addhardware.py
+++ b/virtManager/addhardware.py
@@ -9,7 +9,7 @@ import traceback
from gi.repository import Gtk
from virtinst import (DeviceChannel, DeviceConsole,
- DeviceController, DeviceDisk, DeviceGraphics, DeviceHostdev,
+ DeviceController, DeviceDisk, DeviceHostdev,
DeviceInput, DeviceInterface, DevicePanic, DeviceParallel,
DeviceRedirdev, DeviceRng, DeviceSerial, DeviceSmartcard,
DeviceSound, DeviceTpm, DeviceVideo, DeviceVsock, DeviceWatchdog)
@@ -1481,21 +1481,7 @@ class vmmAddHardware(vmmGObjectUI):
return dev
def _build_graphics(self):
- (gtype, port, listen,
- addr, passwd, gl, rendernode) = self._gfxdetails.get_values()
- dev = DeviceGraphics(self.conn.get_backend())
- dev.type = gtype
- dev.passwd = passwd
- dev.gl = gl
- dev.rendernode = rendernode
-
- if not listen or listen == "none":
- dev.listen = "none"
- else:
- dev.listen = addr
- dev.port = port
-
- return dev
+ return self._gfxdetails.build_device()
def _build_sound(self):
smodel = uiutil.get_list_selection(self.widget("sound-model"))