netlist: Revive portgroup UI

I removed Portgroup UI in 4c3c53f773 release 3.0.0, but there's been
a steady stream of requests to bring it back. It seems it's commonly
used with some certain openvswitch config.

Maint burden isn't too bad. Let's bring it back

Fixes: https://github.com/virt-manager/virt-manager/issues/169

Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
Cole Robinson
2022-01-25 15:52:04 -05:00
parent c6bf106dd3
commit 6c3b5def81
7 changed files with 139 additions and 41 deletions

View File

@@ -1,51 +1,52 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Generated with glade 3.36.0 -->
<!-- Generated with glade 3.38.2 -->
<interface>
<requires lib="gtk+" version="3.22"/>
<!-- n-columns=2 n-rows=5 -->
<object class="GtkGrid" id="net-source-box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="row_spacing">6</property>
<property name="column_spacing">6</property>
<property name="can-focus">False</property>
<property name="row-spacing">6</property>
<property name="column-spacing">6</property>
<child>
<object class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="hexpand">False</property>
<property name="label" translatable="yes">De_vice name:</property>
<property name="use_underline">True</property>
<property name="mnemonic_widget">net-manual-source</property>
<property name="use-underline">True</property>
<property name="mnemonic-widget">net-manual-source</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">2</property>
<property name="left-attach">0</property>
<property name="top-attach">2</property>
</packing>
</child>
<child>
<object class="GtkEntry" id="net-manual-source">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can-focus">True</property>
<property name="halign">start</property>
<property name="hexpand">True</property>
<signal name="changed" handler="on_net_bridge_name_changed" swapped="no"/>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">2</property>
<property name="left-attach">1</property>
<property name="top-attach">2</property>
</packing>
</child>
<child>
<object class="GtkBox" id="net-macvtap-warn-box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="hexpand">False</property>
<property name="spacing">6</property>
<child>
<object class="GtkImage" id="image2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="stock">gtk-dialog-warning</property>
</object>
<packing>
@@ -57,12 +58,12 @@
<child>
<object class="GtkLabel" id="label19">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="label" translatable="yes">&lt;small&gt;In most configurations, macvtap does not work for host to guest network communication.&lt;/small&gt;</property>
<property name="use_markup">True</property>
<property name="use-markup">True</property>
<property name="wrap">True</property>
<property name="max_width_chars">35</property>
<property name="max-width-chars">35</property>
</object>
<packing>
<property name="expand">False</property>
@@ -72,15 +73,15 @@
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">3</property>
<property name="left-attach">0</property>
<property name="top-attach">4</property>
<property name="width">2</property>
</packing>
</child>
<child>
<object class="GtkComboBox" id="net-source">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="hexpand">False</property>
<signal name="changed" handler="on_net_source_changed" swapped="no"/>
@@ -91,20 +92,20 @@
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">1</property>
<property name="left-attach">0</property>
<property name="top-attach">1</property>
<property name="width">2</property>
</packing>
</child>
<child>
<object class="GtkBox" id="net-default-warn-box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="spacing">6</property>
<child>
<object class="GtkImage" id="image1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="stock">gtk-dialog-warning</property>
</object>
<packing>
@@ -116,12 +117,12 @@
<child>
<object class="GtkLabel" id="label2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="label" translatable="yes">&lt;small&gt;Failed to find a suitable default network.&lt;/small&gt;</property>
<property name="use_markup">True</property>
<property name="use-markup">True</property>
<property name="wrap">True</property>
<property name="max_width_chars">35</property>
<property name="max-width-chars">35</property>
</object>
<packing>
<property name="expand">False</property>
@@ -131,21 +132,55 @@
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
<property name="left-attach">0</property>
<property name="top-attach">0</property>
<property name="width">2</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="label3">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="hexpand">False</property>
<property name="label" translatable="yes">_Portgroup:</property>
<property name="use-underline">True</property>
<property name="mnemonic-widget">net-portgroup</property>
</object>
<packing>
<property name="left-attach">0</property>
<property name="top-attach">3</property>
</packing>
</child>
<child>
<object class="GtkComboBox" id="net-portgroup">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="hexpand">True</property>
<property name="has-entry">True</property>
<signal name="changed" handler="on_net_portgroup_changed" swapped="no"/>
<child internal-child="entry">
<object class="GtkEntry" id="combobox-entry2">
<property name="can-focus">True</property>
</object>
</child>
</object>
<packing>
<property name="left-attach">1</property>
<property name="top-attach">3</property>
</packing>
</child>
</object>
<object class="GtkLabel" id="net-source-label">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="can-focus">False</property>
<property name="halign">end</property>
<property name="valign">start</property>
<property name="margin_top">3</property>
<property name="margin_bottom">3</property>
<property name="margin-top">3</property>
<property name="margin-bottom">3</property>
<property name="label" translatable="yes">_Network source:</property>
<property name="use_underline">True</property>
<property name="mnemonic_widget">net-source</property>
<property name="use-underline">True</property>
<property name="mnemonic-widget">net-source</property>
</object>
</interface>