virtManager: Remove disk format/driver_type UI
This was proposed here: https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html """ * disk: storage format: this was from before the days when we storage-ified everything and we could get the disk format wrong, telling qemu it has a raw image when it's qcow2. shouldn't be needed anymore for normal virt usage """ Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
parent
1066867583
commit
79fe886ac8
|
@ -228,7 +228,6 @@ class Details(uiutils.UITestCase):
|
|||
tab.find("Shareable:", "check box").click()
|
||||
tab.find("Readonly:", "check box").click()
|
||||
tab.find("Advanced options", "toggle button").click_expander()
|
||||
tab.find("Storage format:", "text").text = "vmdk"
|
||||
tab.find("Disk bus:", "text").text = "usb"
|
||||
tab.find("Performance options", "toggle button").click_expander()
|
||||
tab.find("IO mode:", "text").text = "threads"
|
||||
|
|
|
@ -187,7 +187,6 @@ class Console(uiutils.UITestCase):
|
|||
win.find("SCSI Disk 1", "table cell").click()
|
||||
tab = win.find("disk-tab", None)
|
||||
uiutils.check_in_loop(lambda: tab.showing)
|
||||
self.assertTrue(tab.find("Storage format:", "text").text == "qcow2")
|
||||
win.find("config-remove").click()
|
||||
delete = self.app.root.find_fuzzy("Delete", "frame")
|
||||
delete.find_fuzzy("Delete", "button").click()
|
||||
|
|
|
@ -3077,86 +3077,6 @@
|
|||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="box15">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<property name="spacing">6</property>
|
||||
<child>
|
||||
<object class="GtkEntry" id="disk-format">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<signal name="changed" handler="on_disk_format_changed" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="disk-format-warn">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="spacing">3</property>
|
||||
<child>
|
||||
<object class="GtkImage" id="image2">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="stock">gtk-dialog-warning</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label34">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes"><small>Changing this will not change the disk image format, it only tells libvirt about the existing image format. </small></property>
|
||||
<property name="use_markup">True</property>
|
||||
<property name="wrap">True</property>
|
||||
<property name="max_width_chars">30</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label30">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">start</property>
|
||||
<property name="margin_top">4</property>
|
||||
<property name="margin_bottom">4</property>
|
||||
<property name="label" translatable="yes">Storage forma_t:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">disk-format</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label66">
|
||||
<property name="visible">True</property>
|
||||
|
|
|
@ -62,7 +62,6 @@ from ..xmleditor import vmmXMLEditor
|
|||
EDIT_DISK_DISCARD,
|
||||
EDIT_DISK_DETECT_ZEROES,
|
||||
EDIT_DISK_BUS,
|
||||
EDIT_DISK_FORMAT,
|
||||
EDIT_DISK_SGIO,
|
||||
EDIT_DISK_PATH,
|
||||
EDIT_DISK_PR,
|
||||
|
@ -101,7 +100,7 @@ from ..xmleditor import vmmXMLEditor
|
|||
|
||||
EDIT_FS,
|
||||
|
||||
EDIT_HOSTDEV_ROMBAR) = range(1, 56)
|
||||
EDIT_HOSTDEV_ROMBAR) = range(1, 55)
|
||||
|
||||
|
||||
# Columns in hw list model
|
||||
|
@ -501,7 +500,6 @@ class vmmDetails(vmmGObjectUI):
|
|||
"on_disk_discard_combo_changed": lambda *x: self.enable_apply(x, EDIT_DISK_DISCARD),
|
||||
"on_disk_detect_zeroes_combo_changed": lambda *x: self.enable_apply(x, EDIT_DISK_DETECT_ZEROES),
|
||||
"on_disk_bus_combo_changed": lambda *x: self.enable_apply(x, EDIT_DISK_BUS),
|
||||
"on_disk_format_changed": self.disk_format_changed,
|
||||
"on_disk_sgio_entry_changed": lambda *x: self.enable_apply(x, EDIT_DISK_SGIO),
|
||||
"on_disk_pr_checkbox_toggled": lambda *x: self.enable_apply(x, EDIT_DISK_PR),
|
||||
|
||||
|
@ -1399,10 +1397,6 @@ class vmmDetails(vmmGObjectUI):
|
|||
|
||||
|
||||
# Disk callbacks
|
||||
def disk_format_changed(self, ignore):
|
||||
self.widget("disk-format-warn").show()
|
||||
self.enable_apply(EDIT_DISK_FORMAT)
|
||||
|
||||
def _disk_source_browse_clicked_cb(self, src):
|
||||
disk = self.get_hw_row()[HW_LIST_COL_DEVICE]
|
||||
if disk.is_floppy():
|
||||
|
@ -1729,9 +1723,6 @@ class vmmDetails(vmmGObjectUI):
|
|||
kwargs["detect_zeroes"] = uiutil.get_list_selection(
|
||||
self.widget("disk-detect-zeroes"))
|
||||
|
||||
if self.edited(EDIT_DISK_FORMAT):
|
||||
kwargs["driver_type"] = self.widget("disk-format").get_text()
|
||||
|
||||
if self.edited(EDIT_DISK_SGIO):
|
||||
sgio = uiutil.get_list_selection(self.widget("disk-sgio"))
|
||||
kwargs["sgio"] = sgio
|
||||
|
@ -2264,7 +2255,6 @@ class vmmDetails(vmmGObjectUI):
|
|||
io = disk.driver_io
|
||||
discard = disk.driver_discard
|
||||
detect_zeroes = disk.driver_detect_zeroes
|
||||
driver_type = disk.driver_type or ""
|
||||
|
||||
size = "-"
|
||||
if path:
|
||||
|
@ -2309,9 +2299,6 @@ class vmmDetails(vmmGObjectUI):
|
|||
uiutil.set_list_selection(self.widget("disk-detect-zeroes"),
|
||||
detect_zeroes)
|
||||
|
||||
self.widget("disk-format").set_text(driver_type)
|
||||
self.widget("disk-format-warn").hide()
|
||||
|
||||
vmmAddHardware.populate_disk_bus_combo(self.vm, devtype,
|
||||
self.widget("disk-bus").get_model())
|
||||
uiutil.set_list_selection(self.widget("disk-bus"), bus)
|
||||
|
|
|
@ -658,7 +658,7 @@ class vmmDomain(vmmLibvirtObject):
|
|||
path=_SENTINEL, readonly=_SENTINEL,
|
||||
shareable=_SENTINEL, removable=_SENTINEL, cache=_SENTINEL,
|
||||
io=_SENTINEL, discard=_SENTINEL, detect_zeroes=_SENTINEL,
|
||||
driver_type=_SENTINEL, bus=_SENTINEL, addrstr=_SENTINEL,
|
||||
bus=_SENTINEL, addrstr=_SENTINEL,
|
||||
sgio=_SENTINEL, managed_pr=_SENTINEL):
|
||||
xmlobj = self._make_xmlobj_to_define()
|
||||
editdev = self._lookup_device_to_define(xmlobj, devobj, do_hotplug)
|
||||
|
@ -711,8 +711,6 @@ class vmmDomain(vmmLibvirtObject):
|
|||
editdev.driver_discard = discard or None
|
||||
if detect_zeroes != _SENTINEL:
|
||||
editdev.driver_detect_zeroes = detect_zeroes or None
|
||||
if driver_type != _SENTINEL:
|
||||
editdev.driver_type = driver_type or None
|
||||
|
||||
if sgio != _SENTINEL:
|
||||
editdev.sgio = sgio or None
|
||||
|
|
Loading…
Reference in New Issue