From a79ccd208423c0418df88a6aa7c83f468ff5cd23 Mon Sep 17 00:00:00 2001 From: Alexander Surkov Date: Wed, 8 Jun 2016 07:33:06 -0400 Subject: [PATCH] Bug 1278294 - UpdateTreeOnRemoval should use logging::TreeInfo, part2, r=yzen --- accessible/base/Logging.cpp | 3 +-- accessible/generic/DocAccessible.cpp | 13 ++----------- 2 files changed, 3 insertions(+), 13 deletions(-) diff --git a/accessible/base/Logging.cpp b/accessible/base/Logging.cpp index 7fe27ae6db06..5b10fc1a914e 100644 --- a/accessible/base/Logging.cpp +++ b/accessible/base/Logging.cpp @@ -632,7 +632,6 @@ logging::TreeInfo(const char* aMsg, uint32_t aExtraFlags, ...) MsgBegin("TREE", aMsg); } va_end(vl); - MsgEnd(); if (aExtraFlags & eStack) { @@ -646,7 +645,7 @@ logging::TreeInfo(const char* aMsg, uint32_t aExtraFlags, const char* aMsg1, Accessible* aAcc, const char* aMsg2, nsINode* aNode) { - if (IsEnabledAll(logging::eTree | logging::eVerbose)) { + if (IsEnabledAll(logging::eTree | aExtraFlags)) { MsgBegin("TREE", "%s; doc: %p", aMsg, aAcc ? aAcc->Document() : nullptr); AccessibleInfo(aMsg1, aAcc); Accessible* acc = aAcc->Document()->GetAccessible(aNode); diff --git a/accessible/generic/DocAccessible.cpp b/accessible/generic/DocAccessible.cpp index 66d87c5208a6..4495f6a4db9f 100644 --- a/accessible/generic/DocAccessible.cpp +++ b/accessible/generic/DocAccessible.cpp @@ -1856,17 +1856,8 @@ DocAccessible::UpdateTreeOnRemoval(Accessible* aContainer, nsIContent* aChildNod // If child node is not accessible then look for its accessible children. Accessible* child = GetAccessible(aChildNode); #ifdef A11Y_LOG - if (logging::IsEnabled(logging::eTree)) { - logging::MsgBegin("TREE", "process content removal"); - logging::Node("container", aContainer->GetNode()); - logging::Node("child", aChildNode); - if (child) - logging::Address("child", child); - else - logging::MsgEntry("child accessible: null"); - - logging::MsgEnd(); - } + logging::TreeInfo("process content removal", 0, + "container", aContainer, "child", aChildNode); #endif TreeMutation mt(aContainer);