mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-01-13 13:17:57 +03:00
create: Only show PXE warning if user actually selects PXE
This commit is contained in:
parent
29d91305f7
commit
2a970f6252
@ -938,6 +938,7 @@ class vmmCreate(vmmGObjectUI):
|
|||||||
src = self.window.get_widget("config-netdev")
|
src = self.window.get_widget("config-netdev")
|
||||||
idx = src.get_active()
|
idx = src.get_active()
|
||||||
show_pxe_warn = True
|
show_pxe_warn = True
|
||||||
|
pxe_install = (self.get_config_install_page() == INSTALL_PAGE_PXE)
|
||||||
|
|
||||||
if not idx < 0:
|
if not idx < 0:
|
||||||
row = src.get_model()[idx]
|
row = src.get_model()[idx]
|
||||||
@ -949,7 +950,7 @@ class vmmCreate(vmmGObjectUI):
|
|||||||
(ntype == virtinst.VirtualNetworkInterface.TYPE_VIRTUAL and
|
(ntype == virtinst.VirtualNetworkInterface.TYPE_VIRTUAL and
|
||||||
not obj.can_pxe())))
|
not obj.can_pxe())))
|
||||||
|
|
||||||
self.set_net_warn(show_pxe_warn,
|
self.set_net_warn(show_pxe_warn and pxe_install,
|
||||||
_("Network selection does not support PXE"), False)
|
_("Network selection does not support PXE"), False)
|
||||||
|
|
||||||
def hv_changed(self, src):
|
def hv_changed(self, src):
|
||||||
|
Loading…
Reference in New Issue
Block a user