Status: New
Owner: ----
Labels: Type-Defect Priority-Medium
New issue 102 by
james.ke...@wishabi.com: CSS Property Editor Pane - Race
Condition
https://code.google.com/p/chromedevtools/issues/detail?id=102
Chrome 38.0.2125.104 dev tools.
There is a race condition between user entered text and code completion
when using the CSS property editor pane. On my machine, the code
completions are returning before '_applyFreeFlowStyleTextEditTimer' fires.
I noticed the issue when adding a new property to an element and after
hitting 'enter' the property was disappearing (extremely frustrating!).
Debugging it showed that when I was hitting enter an error was being
returned from 'CSS.setPropertyText' saying that the range was not valid.
The range was not valid because the editor pane's internal state thought
the auto-completed style was applied, when it had been overwritten by the
user input (which is usually shorter, hence the bad range).
Bug was most likely introduced when the semi=colon part of the CSS style
was made a fixture instead of part of the auto-completion suffix. You can
see there is a check for that case
@ 'WebInspector.StylePropertyTreeElement._applyFreeFlowStyleTextEdit'
(valueText.indexOf(";") === -1). (Sorry I don't have un-minified source
ready).
But that check would only protect the internal state, it would not fix the
actual race condition! Really 100ms for '_applyFreeFlowStyleTextEditTimer'
is simply too long.
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings