[gtk+/wip/baedert/box: 3/5] Fix a few css/a11y test cases



commit 1ff934b738bd7a498290d069ba80e2d8a4c002a1
Author: Timm Bäder <mail baedert org>
Date:   Mon Oct 3 17:54:51 2016 +0200

    Fix a few css/a11y test cases
    
    They were broken because of missing -icon-stock properties in GtkEntry
    and GtkButton not creating an adjustment child anymore.

 testsuite/a11y/entries.txt        |    2 +
 testsuite/a11y/entries.ui         |    4 +-
 testsuite/a11y/menu.txt           |  119 +-----------------------------------
 testsuite/a11y/menu.ui            |   81 +------------------------
 testsuite/css/nodes/buttons.nodes |   10 +--
 testsuite/css/nodes/entries.ui    |    4 +-
 6 files changed, 17 insertions(+), 203 deletions(-)
---
diff --git a/testsuite/a11y/entries.txt b/testsuite/a11y/entries.txt
index 7540854..a7bf15a 100644
--- a/testsuite/a11y/entries.txt
+++ b/testsuite/a11y/entries.txt
@@ -269,6 +269,7 @@ window1
       unnamed-GtkEntryIconAccessible-0
         "icon"
         parent: entry3
+        name: edit-undo
         state: enabled sensitive visible
         <AtkComponent>
         layer: widget
@@ -278,6 +279,7 @@ window1
       unnamed-GtkEntryIconAccessible-1
         "icon"
         parent: entry3
+        name: edit-redo
         state: enabled sensitive visible
         <AtkComponent>
         layer: widget
diff --git a/testsuite/a11y/entries.ui b/testsuite/a11y/entries.ui
index 280d3bc..f9c3444 100644
--- a/testsuite/a11y/entries.ui
+++ b/testsuite/a11y/entries.ui
@@ -57,8 +57,8 @@
           <object class="GtkEntry" id="entry3">
             <property name="text" translatable="yes">icons</property>
             <property name="visible">True</property>
-            <property name="primary-icon-stock">stock1</property>
-            <property name="secondary-icon-stock">stock2</property>
+            <property name="primary-icon-name">edit-undo</property>
+            <property name="secondary-icon-name">edit-redo</property>
           </object>
         </child>
         <child>
diff --git a/testsuite/a11y/menu.txt b/testsuite/a11y/menu.txt
index 1bcc611..2d82317 100644
--- a/testsuite/a11y/menu.txt
+++ b/testsuite/a11y/menu.txt
@@ -40,121 +40,10 @@ window1
       action 0 description: Clicks the menuitem
       action 0 keybinding: <Alt>f;<Alt>f;
       <AtkSelection>
-      imagemenuitem1
-        "menu item"
-        parent: menuitem1
-        index: 0
-        name: New
-        state: enabled selectable sensitive visible
-        toolkit: gtk
-        <AtkComponent>
-        layer: popup
-        alpha: 1
-        <AtkAction>
-        action 0 name: click
-        action 0 description: Clicks the menuitem
-        action 0 keybinding: n;<Alt>f:n;
-        <AtkSelection>
-      imagemenuitem2
-        "menu"
-        parent: menuitem1
-        index: 1
-        name: Open
-        state: enabled selectable sensitive visible
-        toolkit: gtk
-        <AtkComponent>
-        layer: popup
-        alpha: 1
-        <AtkAction>
-        action 0 name: click
-        action 0 description: Clicks the menuitem
-        action 0 keybinding: o;<Alt>f:o;
-        <AtkSelection>
-        radiomenuitem1
-          "radio menu item"
-          parent: imagemenuitem2
-          index: 0
-          name: One
-          member-of: radiomenuitem3
-                     radiomenuitem2
-                     radiomenuitem1
-          state: checked enabled selectable sensitive visible
-          toolkit: gtk
-          <AtkComponent>
-          layer: popup
-          alpha: 1
-          <AtkAction>
-          action 0 name: click
-          action 0 description: Clicks the menuitem
-          <AtkSelection>
-        radiomenuitem2
-          "radio menu item"
-          parent: imagemenuitem2
-          index: 1
-          name: Two
-          member-of: radiomenuitem3
-                     radiomenuitem2
-                     radiomenuitem1
-          state: enabled selectable sensitive visible
-          toolkit: gtk
-          <AtkComponent>
-          layer: popup
-          alpha: 1
-          <AtkAction>
-          action 0 name: click
-          action 0 description: Clicks the menuitem
-          <AtkSelection>
-        radiomenuitem3
-          "radio menu item"
-          parent: imagemenuitem2
-          index: 2
-          name: Three
-          member-of: radiomenuitem3
-                     radiomenuitem2
-                     radiomenuitem1
-          state: enabled selectable sensitive visible
-          toolkit: gtk
-          <AtkComponent>
-          layer: popup
-          alpha: 1
-          <AtkAction>
-          action 0 name: click
-          action 0 description: Clicks the menuitem
-          <AtkSelection>
-      imagemenuitem3
-        "menu item"
-        parent: menuitem1
-        index: 2
-        name: Save
-        state: enabled selectable sensitive visible
-        toolkit: gtk
-        <AtkComponent>
-        layer: popup
-        alpha: 1
-        <AtkAction>
-        action 0 name: click
-        action 0 description: Clicks the menuitem
-        action 0 keybinding: s;<Alt>f:s;
-        <AtkSelection>
-      imagemenuitem4
-        "menu item"
-        parent: menuitem1
-        index: 3
-        name: Save As
-        state: enabled selectable sensitive visible
-        toolkit: gtk
-        <AtkComponent>
-        layer: popup
-        alpha: 1
-        <AtkAction>
-        action 0 name: click
-        action 0 description: Clicks the menuitem
-        action 0 keybinding: a;<Alt>f:a;
-        <AtkSelection>
       separatormenuitem1
         "separator"
         parent: menuitem1
-        index: 4
+        index: 0
         state: enabled selectable sensitive visible
         toolkit: gtk
         <AtkComponent>
@@ -165,7 +54,7 @@ window1
       checkmenuitem1
         "check menu item"
         parent: menuitem1
-        index: 5
+        index: 1
         name: awesome
         state: selectable sensitive visible indeterminate
         toolkit: gtk
@@ -179,7 +68,7 @@ window1
       separatormenuitem2
         "separator"
         parent: menuitem1
-        index: 6
+        index: 2
         state: enabled selectable sensitive visible
         toolkit: gtk
         <AtkComponent>
@@ -190,7 +79,7 @@ window1
       imagemenuitem5
         "menu item"
         parent: menuitem1
-        index: 7
+        index: 3
         name: Quit
         state: enabled selectable sensitive visible
         toolkit: gtk
diff --git a/testsuite/a11y/menu.ui b/testsuite/a11y/menu.ui
index d4509c2..c551e08 100644
--- a/testsuite/a11y/menu.ui
+++ b/testsuite/a11y/menu.ui
@@ -19,81 +19,6 @@
                 <property name="visible">True</property>
                 <property name="can_focus">False</property>
                 <child>
-                  <object class="GtkMenuItem" id="imagemenuitem1">
-                    <property name="label" translatable="yes">_New</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="use_underline">True</property>
-                  </object>
-                </child>
-                <child>
-                  <object class="GtkMenuItem" id="imagemenuitem2">
-                    <property name="label" translatable="yes">_Open</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="use_underline">True</property>
-                    <child type="submenu">
-                      <object class="GtkMenu" id="menu4">
-                        <property name="visible">True</property>
-                        <property name="can_focus">False</property>
-                        <child>
-                          <object class="GtkRadioMenuItem" id="radiomenuitem1">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="use_action_appearance">False</property>
-                            <property name="label" translatable="yes">One</property>
-                            <property name="use_underline">True</property>
-                            <property name="active">True</property>
-                            <property name="draw_as_radio">True</property>
-                          </object>
-                        </child>
-                        <child>
-                          <object class="GtkRadioMenuItem" id="radiomenuitem2">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="use_action_appearance">False</property>
-                            <property name="label" translatable="yes">Two</property>
-                            <property name="use_underline">True</property>
-                            <property name="draw_as_radio">True</property>
-                            <property name="group">radiomenuitem1</property>
-                          </object>
-                        </child>
-                        <child>
-                          <object class="GtkRadioMenuItem" id="radiomenuitem3">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="use_action_appearance">False</property>
-                            <property name="label" translatable="yes">Three</property>
-                            <property name="use_underline">True</property>
-                            <property name="draw_as_radio">True</property>
-                            <property name="group">radiomenuitem1</property>
-                          </object>
-                        </child>
-                      </object>
-                    </child>
-                  </object>
-                </child>
-                <child>
-                  <object class="GtkMenuItem" id="imagemenuitem3">
-                    <property name="label" translatable="yes">_Save</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="use_underline">True</property>
-                  </object>
-                </child>
-                <child>
-                  <object class="GtkImageMenuItem" id="imagemenuitem4">
-                    <property name="label" translatable="yes">Save _As</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="use_underline">True</property>
-                  </object>
-                </child>
-                <child>
                   <object class="GtkSeparatorMenuItem" id="separatormenuitem1">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
@@ -151,7 +76,7 @@
                   </object>
                 </child>
                 <child>
-                  <object class="GtkImageMenuItem" id="imagemenuitem7">
+                  <object class="GtkMenuItem" id="imagemenuitem7">
                     <property name="label" translatable="yes">_Copy</property>
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
@@ -160,7 +85,7 @@
                   </object>
                 </child>
                 <child>
-                  <object class="GtkImageMenuItem" id="imagemenuitem8">
+                  <object class="GtkMenuItem" id="imagemenuitem8">
                     <property name="label" translatable="yes">_Paste</property>
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
@@ -169,7 +94,7 @@
                   </object>
                 </child>
                 <child>
-                  <object class="GtkImageMenuItem" id="imagemenuitem9">
+                  <object class="GtkMenuItem" id="imagemenuitem9">
                     <property name="label" translatable="yes">_Delete</property>
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
diff --git a/testsuite/css/nodes/buttons.nodes b/testsuite/css/nodes/buttons.nodes
index 418a132..217166f 100644
--- a/testsuite/css/nodes/buttons.nodes
+++ b/testsuite/css/nodes/buttons.nodes
@@ -19,10 +19,8 @@
     button.text-button:dir(ltr)
       label:dir(ltr)
     button.image-button:dir(ltr)
-      widget:dir(ltr)
-        box.horizontal:dir(ltr)
-          image:dir(ltr)
+      box.horizontal:dir(ltr)
+        image:dir(ltr)
     button.image-button:dir(ltr)
-      widget:dir(ltr)
-        box.horizontal:dir(ltr)
-          image:dir(ltr)
+      box.horizontal:dir(ltr)
+        image:dir(ltr)
diff --git a/testsuite/css/nodes/entries.ui b/testsuite/css/nodes/entries.ui
index 3d4e4ee..c6fa1e8 100644
--- a/testsuite/css/nodes/entries.ui
+++ b/testsuite/css/nodes/entries.ui
@@ -58,8 +58,8 @@
           <object class="GtkEntry" id="entry3">
             <property name="text" translatable="yes">icons</property>
             <property name="visible">True</property>
-            <property name="primary-icon-stock">stock1</property>
-            <property name="secondary-icon-stock">stock2</property>
+            <property name="primary-icon-name">edit-copy</property>
+            <property name="secondary-icon-name">edit-paste</property>
           </object>
         </child>
         <child>


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