Bug 896251 - Make nsEvent::{refPoint, lastRefPoint} LayoutDeviceIntPoints; r=smaug+kats
This commit is contained in:
@@ -476,16 +476,18 @@ nsRangeFrame::GetValueAtEventPoint(nsGUIEvent* aEvent)
|
||||
}
|
||||
Decimal range = maximum - minimum;
|
||||
|
||||
nsIntPoint absPoint;
|
||||
LayoutDeviceIntPoint absPoint;
|
||||
if (aEvent->eventStructType == NS_TOUCH_EVENT) {
|
||||
MOZ_ASSERT(static_cast<nsTouchEvent*>(aEvent)->touches.Length() == 1,
|
||||
"Unexpected number of touches");
|
||||
absPoint = static_cast<nsTouchEvent*>(aEvent)->touches[0]->mRefPoint;
|
||||
absPoint = LayoutDeviceIntPoint::FromUntyped(
|
||||
static_cast<nsTouchEvent*>(aEvent)->touches[0]->mRefPoint);
|
||||
} else {
|
||||
absPoint = aEvent->refPoint;
|
||||
}
|
||||
nsPoint point =
|
||||
nsLayoutUtils::GetEventCoordinatesRelativeTo(aEvent, absPoint, this);
|
||||
nsLayoutUtils::GetEventCoordinatesRelativeTo(aEvent,
|
||||
LayoutDeviceIntPoint::ToUntyped(absPoint), this);
|
||||
|
||||
if (point == nsPoint(NS_UNCONSTRAINEDSIZE, NS_UNCONSTRAINEDSIZE)) {
|
||||
// We don't want to change the current value for this error state.
|
||||
|
||||
Reference in New Issue
Block a user