[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[virt-tools-list] [virt-manager PATCH v2 1/3] add button to remove cpu feature



From: Chen Hanxiao <chenhanxiao cn fujitsu com>

If we click button 'Copy host CPU Configuration',
we can hardly get rid of it or delete them manually.
This patch will add a button
named 'Clear CPU Configuration' to do this,
if we want to use the default CPU or host cpu config
could not start VM.

Signed-off-by: Chen Hanxiao <chenhanxiao cn fujitsu com>
---
v2: amend huge button issue

 ui/details.ui | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/ui/details.ui b/ui/details.ui
index 88ad9e1..05cfdb9 100644
--- a/ui/details.ui
+++ b/ui/details.ui
@@ -437,7 +437,6 @@
                   </object>
                   <packing>
                     <property name="expand">False</property>
-                    <property name="homogeneous">False</property>
                   </packing>
                 </child>
                 <child>
@@ -750,7 +749,6 @@
                                           <object class="GtkAlignment" id="alignment14">
                                             <property name="visible">True</property>
                                             <property name="can_focus">False</property>
-                                            <property name="hexpand">False</property>
                                             <child>
                                               <placeholder/>
                                             </child>
@@ -2096,6 +2094,7 @@
                                               <object class="GtkHBox" id="hbox25">
                                                 <property name="visible">True</property>
                                                 <property name="can_focus">False</property>
+                                                <property name="spacing">20</property>
                                                 <child>
                                                   <object class="GtkButton" id="cpu-copy-host">
                                                     <property name="label" translatable="yes">Copy host CPU configuration</property>
@@ -2115,15 +2114,24 @@
                                                     <property name="visible">True</property>
                                                     <property name="can_focus">False</property>
                                                     <child>
-                                                      <placeholder/>
+                                                      <object class="GtkButton" id="cpu-clear">
+                                                        <property name="label" translatable="yes">Clear CPU configuration</property>
+                                                        <property name="visible">True</property>
+                                                        <property name="can_focus">True</property>
+                                                        <property name="receives_default">True</property>
+                                                        <signal name="clicked" handler="on_cpu_clear_clicked" swapped="no"/>
+                                                      </object>
                                                     </child>
                                                   </object>
                                                   <packing>
-                                                    <property name="expand">True</property>
+                                                    <property name="expand">False</property>
                                                     <property name="fill">True</property>
                                                     <property name="position">1</property>
                                                   </packing>
                                                 </child>
+                                                <child>
+                                                  <placeholder/>
+                                                </child>
                                               </object>
                                               <packing>
                                                 <property name="left_attach">1</property>
-- 
1.8.2.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]