r69316 changed userScalable from a float to a bool. However, userScalable is initialized from an enum in the constructor, and the enum value is ValueAuto (-1). This produces a compiler warning and probably isn't doing what we want. third_party/WebKit/WebCore/dom/ViewportArguments.h(78) : warning C4305: 'initializing' : truncation from '' to 'bool'
Created attachment 77358 [details] Patch
I don't really know what I'm doing so please review carefully. But I figure -1 is also true so this should be the same thing(?).
Well ValueAuto means that it is unset and thus will use the default (which might depend on some of the other values). I guess the most right thing is to make userScalable a float and convert it to true or false in the compute* method. For instance if I set min-scale = 1.0 and max-scale = 1.0, it is basically not scalable, but I guess the iPhone might still consider it scalable, as it affects more than just the scale change. From docs: Setting user-scalable to no also prevents a webpage from scrolling when entering text in an input field.
Kenneth, what do you think of the patch I uploaded? It at least doesn't change the current behavior of the code. I'm reluctant to try to change the semantics of userScalable since I don't really understand what it means or how it's used.
(In reply to comment #4) > Kenneth, what do you think of the patch I uploaded? It at least doesn't change the current behavior of the code. I'm reluctant to try to change the semantics of userScalable since I don't really understand what it means or how it's used. It is fine, as you said it should give the correct behavior. Thanks for doing this.
Comment on attachment 77358 [details] Patch Clearing flags on attachment: 77358 Committed r74610: <http://trac.webkit.org/changeset/74610>
All reviewed patches have been landed. Closing bug.