Changeset 78987 in webkit


Ignore:
Timestamp:
Feb 18, 2011 2:52:57 AM (13 years ago)
Author:
Philippe Normand
Message:

2011-02-18 Philippe Normand <pnormand@igalia.com>

Unreviewed, rolling out r78979.
http://trac.webkit.org/changeset/78979
https://bugs.webkit.org/show_bug.cgi?id=53146

causes multiple crashes on GTK

  • platform/gtk/accessibility/combo-box-collapsed-selection-changed-expected.txt: Removed.
  • platform/gtk/accessibility/combo-box-collapsed-selection-changed.html: Removed.

2011-02-18 Philippe Normand <pnormand@igalia.com>

Unreviewed, rolling out r78979.
http://trac.webkit.org/changeset/78979
https://bugs.webkit.org/show_bug.cgi?id=53146

causes multiple crashes on GTK

  • accessibility/gtk/AXObjectCacheAtk.cpp: (WebCore::notifyChildrenSelectionChange): (WebCore::AXObjectCache::postPlatformNotification):
Location:
trunk
Files:
2 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r78986 r78987  
     12011-02-18  Philippe Normand  <pnormand@igalia.com>
     2
     3        Unreviewed, rolling out r78979.
     4        http://trac.webkit.org/changeset/78979
     5        https://bugs.webkit.org/show_bug.cgi?id=53146
     6
     7        causes multiple crashes on GTK
     8
     9        * platform/gtk/accessibility/combo-box-collapsed-selection-changed-expected.txt: Removed.
     10        * platform/gtk/accessibility/combo-box-collapsed-selection-changed.html: Removed.
     11
    1122011-02-18  Philippe Normand  <pnormand@igalia.com>
    213
  • trunk/Source/WebCore/ChangeLog

    r78981 r78987  
     12011-02-18  Philippe Normand  <pnormand@igalia.com>
     2
     3        Unreviewed, rolling out r78979.
     4        http://trac.webkit.org/changeset/78979
     5        https://bugs.webkit.org/show_bug.cgi?id=53146
     6
     7        causes multiple crashes on GTK
     8
     9        * accessibility/gtk/AXObjectCacheAtk.cpp:
     10        (WebCore::notifyChildrenSelectionChange):
     11        (WebCore::AXObjectCache::postPlatformNotification):
     12
    1132011-02-18  Philippe Normand  <pnormand@igalia.com>
    214
  • trunk/Source/WebCore/accessibility/gtk/AXObjectCacheAtk.cpp

    r78979 r78987  
    4343}
    4444
    45 static AccessibilityObject* getListObject(AccessibilityObject* object)
    46 {
    47     // Only list boxes and menu lists supported so far.
    48     if (!object->isListBox() && !object->isMenuList())
    49         return 0;
    50 
    51     // For list boxes the list object is just itself.
    52     if (object->isListBox())
    53         return object;
    54 
    55     // For menu lists we need to return the first accessible child,
    56     // with role MenuListPopupRole, since that's the one holding the list
    57     // of items with role MenuListOptionRole.
    58     AccessibilityObject::AccessibilityChildrenVector children = object->children();
    59     if (!children.size())
    60         return 0;
    61 
    62     AccessibilityObject* listObject = children.at(0).get();
    63     if (!listObject->isMenuListPopup())
    64         return 0;
    65 
    66     return listObject;
    67 }
    68 
    6945static void notifyChildrenSelectionChange(AccessibilityObject* object)
    7046{
     
    7450    static RefPtr<AccessibilityObject> oldFocusedObject = 0;
    7551
    76     // Only list boxes and menu lists supported so far.
    77     if (!object || !(object->isListBox() || object->isMenuList()))
     52    // Only list boxes supported so far.
     53    if (!object || !object->isListBox())
    7854        return;
    7955
     
    8258
    8359    // Find the item where the selection change was triggered from.
     60    AccessibilityObject::AccessibilityChildrenVector items = object->children();
    8461    SelectElement* select = toSelectElement(static_cast<Element*>(object->node()));
    8562    if (!select)
    8663        return;
    8764    int changedItemIndex = select->activeSelectionStartListIndex();
    88 
    89     AccessibilityObject* listObject = getListObject(object);
    90     if (!listObject)
    91         return;
    92 
    93     AccessibilityObject::AccessibilityChildrenVector items = listObject->children();
    9465    if (changedItemIndex < 0 || changedItemIndex >= static_cast<int>(items.size()))
    9566        return;
     
    133104            return;
    134105        g_signal_emit_by_name(axObject, "state-change", "checked", coreObject->isChecked());
    135     } else if (notification == AXSelectedChildrenChanged || notification == AXMenuListValueChanged) {
    136         if (notification == AXMenuListValueChanged && coreObject->isMenuList()) {
    137             g_signal_emit_by_name(axObject, "focus-event", true);
    138             g_signal_emit_by_name(axObject, "state-change", "focused", true);
    139         }
     106    } else if (notification == AXMenuListValueChanged) {
     107        if (!coreObject->isMenuList())
     108            return;
     109        g_signal_emit_by_name(axObject, "focus-event", true);
     110        g_signal_emit_by_name(axObject, "state-change", "focused", true);
     111    } else if (notification == AXSelectedChildrenChanged)
    140112        notifyChildrenSelectionChange(coreObject);
    141     }
    142113}
    143114
Note: See TracChangeset for help on using the changeset viewer.