<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body><span class="vcard"><a class="email" href="mailto:simon.fraser@apple.com" title="Simon Fraser (smfr) <simon.fraser@apple.com>"> <span class="fn">Simon Fraser (smfr)</span></a>
</span> changed
<a class="bz_bug_link
bz_status_NEW "
title="NEW - Use _NSScrollingPredominantAxisFilter for wheel event filtering on Mac"
href="https://bugs.webkit.org/show_bug.cgi?id=147320">bug 147320</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Attachment #259483 Flags</td>
<td>review?
</td>
<td>review-
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - Use _NSScrollingPredominantAxisFilter for wheel event filtering on Mac"
href="https://bugs.webkit.org/show_bug.cgi?id=147320#c15">Comment # 15</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - Use _NSScrollingPredominantAxisFilter for wheel event filtering on Mac"
href="https://bugs.webkit.org/show_bug.cgi?id=147320">bug 147320</a>
from <span class="vcard"><a class="email" href="mailto:simon.fraser@apple.com" title="Simon Fraser (smfr) <simon.fraser@apple.com>"> <span class="fn">Simon Fraser (smfr)</span></a>
</span></b>
<pre>Comment on <span class=""><a href="attachment.cgi?id=259483&action=diff" name="attach_259483" title="Patch">attachment 259483</a> <a href="attachment.cgi?id=259483&action=edit" title="Patch">[details]</a></span>
Patch
View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=259483&action=review">https://bugs.webkit.org/attachment.cgi?id=259483&action=review</a>
<span class="quote">> Source/WebCore/page/WheelEventDeltaFilter.cpp:34
> + : m_currentFilteredDelta(0, 0)</span >
No need to initialize FloatSize.
<span class="quote">> Source/WebCore/page/WheelEventDeltaFilter.cpp:44
> + , m_deltaTracker(WheelEventDeltaTracker())</span >
No need to explicitly call zero-argument constructor.
<span class="quote">> Source/WebCore/page/WheelEventDeltaFilter.h:50
> +class WheelEventDeltaFilterPlatformInvariant final : public WheelEventDeltaFilter {</span >
"PlatformInvariant" seems like naming overkill. Maybe BasicWheelEventDeltaFilter
<span class="quote">> Source/WebCore/page/WheelEventDeltaFilter.h:60
> + WheelEventDeltaTracker m_deltaTracker;</span >
Why does WheelEventDeltaTracker exist independently from this class? Can it just be merged into this?
<span class="quote">> Source/WebCore/page/mac/WheelEventDeltaFilterMac.mm:31
> +#import <AppKit/NSScrollingInputFilter_Private.h></span >
This will need some SPI header stuff.
<span class="quote">> Source/WebCore/page/mac/WheelEventDeltaFilterMac.mm:83
> +bool WheelEventDeltaFilterMac::isFilteringDeltas() const
> +{
> + return m_isFilteringDeltas;
> +}
> +
> +FloatSize WheelEventDeltaFilterMac::filteredDelta() const
> +{
> + return m_currentFilteredDelta;
> +}
> +
> +FloatSize WheelEventDeltaFilterMac::filteredVelocity() const
> +{
> + return m_currentFilteredVelocity;
> +}</span >
These could all be inline.
<span class="quote">> Source/WebKit2/WebProcess/WebPage/EventDispatcher.cpp:66
> +#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101100
> + , m_recentWheelEventDeltaFilter(std::make_unique<WheelEventDeltaFilterMac>())
> +#else
> + , m_recentWheelEventDeltaFilter(std::make_unique<WheelEventDeltaFilterPlatformInvariant>())
> +#endif</span >
Shame to see all this here. Maybe add static WheelEventDeltaFilter::create() which is implemented per-platform.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>