mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1223258 - Fix -Wunreachable-code warnings in widget. r=masayuki
widget/tests/TestAppShellSteadyState.cpp:397:5: warning: code will never be executed [-Wunreachable-code] widget\widgetutils.cpp(95) : warning C4702: unreachable code widget\mouseevents.h(97) : warning C4702: unreachable code widget\textevents.h(492) : warning C4702: unreachable code
This commit is contained in:
parent
18028bbae1
commit
44d581458a
@ -94,7 +94,6 @@ public:
|
||||
virtual WidgetEvent* Duplicate() const override
|
||||
{
|
||||
MOZ_CRASH("WidgetMouseEventBase must not be most-subclass");
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
/// The possible related target
|
||||
|
@ -489,7 +489,6 @@ public:
|
||||
NS_ASSERTION(!IsAllowedToDispatchDOMEvent(),
|
||||
"WidgetQueryContentEvent needs to support Duplicate()");
|
||||
MOZ_CRASH("WidgetQueryContentEvent doesn't support Duplicate()");
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void InitForQueryTextContent(uint32_t aOffset, uint32_t aLength,
|
||||
|
@ -92,7 +92,6 @@ nsIntRect RotateRect(nsIntRect aRect,
|
||||
aRect.height, aRect.width);
|
||||
default:
|
||||
MOZ_CRASH("Unknown rotation");
|
||||
return aRect;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -391,8 +391,7 @@ Test4Internal(nsIAppShell* aAppShell)
|
||||
#ifndef XP_WIN
|
||||
// Not sure how to test on other platforms.
|
||||
return false;
|
||||
#endif
|
||||
|
||||
#else
|
||||
nsCOMPtr<nsIAppShellService> appService =
|
||||
do_GetService(NS_APPSHELLSERVICE_CONTRACTID);
|
||||
if (!appService) {
|
||||
@ -437,6 +436,7 @@ Test4Internal(nsIAppShell* aAppShell)
|
||||
}
|
||||
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user