Title: [232545] trunk/Source/WebKit
- Revision
- 232545
- Author
- [email protected]
- Date
- 2018-06-06 09:36:12 -0700 (Wed, 06 Jun 2018)
Log Message
attenuationFactor should be in range [0,1]
https://bugs.webkit.org/show_bug.cgi?id=186320
rdar://problem/40821456
Patch by Jeremy Jones <[email protected]> on 2018-06-06
Reviewed by Jer Noble.
If attenuationFactor is outside of this range it can cause false positives.
* UIProcess/ios/fullscreen/FullscreenTouchSecheuristic.cpp:
(WebKit::FullscreenTouchSecheuristic::attenuationFactor):
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (232544 => 232545)
--- trunk/Source/WebKit/ChangeLog 2018-06-06 16:32:26 UTC (rev 232544)
+++ trunk/Source/WebKit/ChangeLog 2018-06-06 16:36:12 UTC (rev 232545)
@@ -1,3 +1,16 @@
+2018-06-06 Jeremy Jones <[email protected]>
+
+ attenuationFactor should be in range [0,1]
+ https://bugs.webkit.org/show_bug.cgi?id=186320
+ rdar://problem/40821456
+
+ Reviewed by Jer Noble.
+
+ If attenuationFactor is outside of this range it can cause false positives.
+
+ * UIProcess/ios/fullscreen/FullscreenTouchSecheuristic.cpp:
+ (WebKit::FullscreenTouchSecheuristic::attenuationFactor):
+
2018-06-06 Tim Horton <[email protected]>
Move animated resize into the layer tree transaction, and make it asynchronous
Modified: trunk/Source/WebKit/UIProcess/ios/fullscreen/FullscreenTouchSecheuristic.cpp (232544 => 232545)
--- trunk/Source/WebKit/UIProcess/ios/fullscreen/FullscreenTouchSecheuristic.cpp 2018-06-06 16:32:26 UTC (rev 232544)
+++ trunk/Source/WebKit/UIProcess/ios/fullscreen/FullscreenTouchSecheuristic.cpp 2018-06-06 16:36:12 UTC (rev 232545)
@@ -78,7 +78,7 @@
double FullscreenTouchSecheuristic::attenuationFactor(Seconds delta)
{
double normalizedTimeDelta = delta / m_rampDownSpeed;
- return normalizedTimeDelta * m_weight;
+ return std::max(std::min(normalizedTimeDelta * m_weight, 1.0), 0.0);
}
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes