|
Posted by Spartanicus on 12/07/37 11:48
Michael Winter <m.winter@blueyonder.co.uk> wrote:
>> http://homepage.ntlworld.com/spartanicus/temp.htm
>>
>> I've replaced the reload with an alert dialog for testing.
>
>That's the source of your problem.
Indeed it is, thanks for the explanation.
>> But there are potentially a fair number of different things that
>> media queries could be used for, it could be neigh impossible for a
>> browser to determine what action to take depending on the significant
>> number of UI actions that a user may initiate.
>
>That is a fair point, but how many of these properties will change in
>response to specific actions? Resizing the viewport will only affect the
>(min/max-) height and width properties. It needn't involve re-evaluating
>the entire style sheet, though that is a possibility.
I don't see how re-evaluating all stylesheet rules could be avoided, the
CSS rule(s) to be applied as a result of re-evaluating a media query
could for example cause changes in the cascade.
>> The author coding these functions on the other hand knows what
>> behaviour is needed, it seems reasonable to me that the author should
>> also implement the behaviour such as in this case triggering a
>> reload. After all, dynamic behaviour belongs in the Javascript
>> domain.
>
>That is also true, but as you and I both know, client-side scripts
>should be considered optional features. That notwithstanding, refreshing
>the document isn't a particularly nice solution. For simple content,
>it's not that big a deal, but it could play havoc with forms and the
>like. It would be better for the UA to deal with it as it is the UA that
>is providing the feature, not a script.
Good point, I hadn't considered forms. Another drawback I just noticed
is that it reloads from the server, I thought that I could tell the
browser to reload from it's cache by using "false" as the argument (or
by omitting the argument), but no go.
--
Spartanicus
[Back to original message]
|