<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_REOPENED "
   title="REOPENED - AX: Force allow user zoom"
   href="https://bugs.webkit.org/show_bug.cgi?id=155056#c42">Comment # 42</a>
              on <a class="bz_bug_link 
          bz_status_REOPENED "
   title="REOPENED - AX: Force allow user zoom"
   href="https://bugs.webkit.org/show_bug.cgi?id=155056">bug 155056</a>
              from <span class="vcard"><a class="email" href="mailto:simon.fraser&#64;apple.com" title="Simon Fraser (smfr) &lt;simon.fraser&#64;apple.com&gt;"> <span class="fn">Simon Fraser (smfr)</span></a>
</span></b>
        <pre>Comment on <span class=""><a href="attachment.cgi?id=273458&amp;action=diff" name="attach_273458" title="patch">attachment 273458</a> <a href="attachment.cgi?id=273458&amp;action=edit" title="patch">[details]</a></span>
patch

View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=273458&amp;action=review">https://bugs.webkit.org/attachment.cgi?id=273458&amp;action=review</a>

<span class="quote">&gt; Source/WebCore/page/ViewportConfiguration.h:93
&gt; -    double maximumScale() const { return m_configuration.maximumScale; }
&gt; +    double maximumScale() const { return m_forceAlwaysUserScalable ? forceAlwaysUserScalableMaximumScale : m_configuration.maximumScale; }</span >

This solution doesn't prevent a page from saying minScale=10, maxScale=10 to avoid scalability.

Also, the various default configurations have maxScale=5. Why did you choose 10?

<span class="quote">&gt; Source/WebCore/testing/Internals.cpp:213
&gt; +SOFT_LINK_LIBRARY(libAccessibility)
&gt; +SOFT_LINK(libAccessibility, _AXSSetForceAllowWebScaling, void, (Boolean scalable), (scalable))</span >

Can we just hard link?

<span class="quote">&gt; Source/WebCore/testing/Internals.cpp:3534
&gt; +void Internals::setViewportForceAlwaysUserScalable(bool scalable)
&gt; +{
&gt; +#if PLATFORM(IOS) &amp;&amp; __IPHONE_OS_VERSION_MIN_REQUIRED &gt;= 100000
&gt; +    _AXSSetForceAllowWebScaling(scalable);
&gt; +#else
&gt; +    UNUSED_PARAM(scalable);
&gt; +#endif
&gt; +}</span >

You need to reset this at the end of every test that changes it. There's a mechanism to do that.

<span class="quote">&gt; Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm:131
&gt; +    forceAlwaysUserScalable |= _AXSForceAllowWebScaling();</span >

It's a shame that we have a WebPreference key or this, but you're bypassing that. Should we remove the key, or should the default value of that key be overridden by _AXSForceAllowWebScaling()?

<span class="quote">&gt; Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm:140
&gt; +#if __IPHONE_OS_VERSION_MIN_REQUIRED &gt;= 100000
&gt; +    CFNotificationCenterAddObserver(CFNotificationCenterGetLocalCenter(), this, forceAlwaysUserScalableChangedCallback, kAXSAllowForceWebScalingEnabledNotification, 0, CFNotificationSuspensionBehaviorDeliverImmediately);
&gt; +#endif</span >

This soft link of kAXSAllowForceWebScalingEnabledNotification is going to cause a performance hit for everyone on iOS. Can we just hard link?

Does the CFNotificationCenterAddObserver have to happen here in WebPage? Lots of other notifications happen in WKWebView. Does it have to happen right at platformInitialize time?</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>