Commit 25671496 authored by surkov.alexander@gmail.com's avatar surkov.alexander@gmail.com
Browse files

Bustage fix of bug 386978

parent 2efa01e7
Loading
Loading
Loading
Loading
+13 −1
Original line number Diff line number Diff line
@@ -41,7 +41,7 @@
interface nsIAccessible;
interface nsIAccessibleEvent;

[uuid(96518e2e-b142-4b5d-9324-0fa5ba4f8bab)]
[uuid(817ae493-b238-4fbc-a623-d20ed81eebcd)]
interface nsPIAccessible : nsISupports
{
  /**
@@ -69,6 +69,18 @@ interface nsPIAccessible : nsISupports
   */
  void invalidateChildren();

  /**
   * Fire accessible event.
   *
   * @param aEvent - DOM event
   * @param aTarget - target of DOM event
   * @param aData - additional information for accessible event.
   *
   * XXX: eventually this method will be removed (see bug 377022)
   */
  void fireToolkitEvent(in unsigned long aEvent, in nsIAccessible aTarget,
                        in voidPtr aData);

  /**
   * Fire accessible event.
   */
+15 −0
Original line number Diff line number Diff line
@@ -2007,6 +2007,21 @@ PRBool nsAccessible::IsNodeRelevant(nsIDOMNode *aNode)
  return aNode == relevantNode;
}

NS_IMETHODIMP
nsAccessible::FireToolkitEvent(PRUint32 aEvent, nsIAccessible *aTarget,
                               void * aData)
{
  // Don't fire event for accessible that has been shut down.
  if (!mWeakShell)
    return NS_ERROR_FAILURE;

  nsCOMPtr<nsIAccessibleEvent> accEvent =
    new nsAccEvent(aEvent, aTarget, aData);
  NS_ENSURE_TRUE(accEvent, NS_ERROR_OUT_OF_MEMORY);

  return FireAccessibleEvent(accEvent);
}

NS_IMETHODIMP
nsAccessible::FireAccessibleEvent(nsIAccessibleEvent *aEvent)
{