Bug 825096 - Fix three clang warnings in accessible/. r=surkov.

--HG--
extra : rebase_source : 5b26ed2307b240d7d7eb60a866ac33995ab654de
This commit is contained in:
Nicholas Nethercote 2013-01-01 16:49:19 -08:00
Родитель b7723e3c58
Коммит 398da72549
3 изменённых файлов: 10 добавлений и 5 удалений

Просмотреть файл

@ -1,4 +1,5 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim: set ts=2 et sw=2 tw=80: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
@ -117,10 +118,12 @@ AccReorderEvent::IsShowHideEventTarget(const Accessible* aTarget) const
{
uint32_t count = mDependentEvents.Length();
for (uint32_t index = count - 1; index < count; index--) {
if (mDependentEvents[index]->mAccessible == aTarget &&
mDependentEvents[index]->mEventType == nsIAccessibleEvent::EVENT_SHOW ||
mDependentEvents[index]->mEventType == nsIAccessibleEvent::EVENT_HIDE) {
return mDependentEvents[index]->mEventType;
if (mDependentEvents[index]->mAccessible == aTarget) {
uint32_t eventType = mDependentEvents[index]->mEventType;
if (eventType == nsIAccessibleEvent::EVENT_SHOW ||
eventType == nsIAccessibleEvent::EVENT_HIDE) {
return mDependentEvents[index]->mEventType;
}
}
}

Просмотреть файл

@ -641,7 +641,6 @@ NotificationController::CoalesceTextChangeEventsFor(AccShowEvent* aTailEvent,
void
NotificationController::CreateTextChangeEventFor(AccMutationEvent* aEvent)
{
DocAccessible* document = aEvent->GetDocAccessible();
Accessible* container = aEvent->mAccessible->Parent();
if (!container)
return;

Просмотреть файл

@ -1460,6 +1460,9 @@ nsAccessibilityService::CreateAccessibleByFrameType(nsIFrame* aFrame,
case eTextLeafType:
newAcc = new TextLeafAccessibleWrap(aContent, document);
break;
default:
MOZ_ASSERT(false);
break;
}
return newAcc.forget();