[Webkit-unassigned] [Bug 96733] Web Inspector: Display Named Flows in the Tabbed Pane of the "CSS Named Flows" Drawer

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Sep 17 06:03:19 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=96733





--- Comment #6 from Alexander Pavlov (apavlov) <apavlov at chromium.org>  2012-09-17 06:03:47 PST ---
(In reply to comment #5)
> (In reply to comment #4)
> > (From update of attachment 164280 [details] [details])
> > View in context: https://bugs.webkit.org/attachment.cgi?id=164280&action=review
> > > Source/WebCore/inspector/front-end/CSSNamedFlowView.js:76
> > > +        WebInspector.domAgent.removeEventListener(WebInspector.DOMAgent.Events.DocumentUpdated, treeOutline._elementsTreeUpdater._documentUpdated, treeOutline._elementsTreeUpdater);
> > 
> > Why is this necessary? The corresponding entry will stick around even after a page navigation?
> > 
> > > Source/WebCore/inspector/front-end/CSSNamedFlowView.js:139
> > > +        regionTreeElement.tooltip = WebInspector.UIString("Region is " + newRegionOverset + ".");
> >
> 
> I removed the DocumentUpdated event listener so that the ElementsTreeOutline does not change the rootDOMNode to the root of a new document. On DocumentUpdated I reset all the flows.

OK, get it.

> > Perhaps having className suffix be a word in the message text is not a good idea. It's better to have a choice, something like
> > var oversetText = newRegionOverset === "foo" ? WebInspector.UIString("bar") : WebInspector.UIString("baz"); // or something more complicated, but you get the idea,
> > and then do:
> > regionTreeElement.tooltip = WebInspector.UIString("Region is %s.", oversetText);
> > 
> > This way, you will have separate messages for "Region is %s.", "bar", and "baz" in localizedStrings.js, and it will be possible to easily build the target message in any natural language.
> I don't exactly understand what you meant here (the use cases).

As discussed on IRC, using _the same_ string as a protocol field enum value, CSS class, and a user message is _very_ brittle. You should have a map from the enum values into user-readable overset-type strings.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list