[webkit-changes] [WebKit/WebKit] eaa47e: Web Inspector: Infos and Debugs buttons don't appe...
Qianlang Chen
noreply at github.com
Mon Mar 11 11:32:09 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: eaa47ea7c85e3ae6230a3edb05f98821b59e6978
https://github.com/WebKit/WebKit/commit/eaa47ea7c85e3ae6230a3edb05f98821b59e6978
Author: Qianlang Chen <qianlangchen at apple.com>
Date: 2024-03-11 (Mon, 11 Mar 2024)
Changed paths:
M Source/WebInspectorUI/UserInterface/Views/LogContentView.js
Log Message:
-----------
Web Inspector: Infos and Debugs buttons don't appear in Console tab until new console messages are displayed
rdar://122923625
https://bugs.webkit.org/show_bug.cgi?id=268881
Reviewed by Devin Rousso.
The original code hides the Infos and Debugs scope bar items until
the console receives the first message coming a non-default channel.
Make it so that the Infos and Debugs buttons' visibility syncs with
with whether there are messages with those two levels respectively,
regardless of what channels the messages came from.
Call the Infos and Debugs buttons "conditionally visible" and make a
group for their IDs. This way the code controlling their visibility
becomes more extendable.
Also clean up some unused dead code near the primary changes.
* Source/WebInspectorUI/UserInterface/Views/LogContentView.js:
(WI.LogContentView.prototype._scopeFromMessageLevel):
- The levels Infos and Debugs no longer depend on
_hasNonDefaultLogChannelMessage.
(WI.LogContentView.prototype._messageAdded):
(WI.LogContentView.prototype._logCleared):
(WI.LogContentView.prototype._scopeBarSelectionDidChange):
(WI.LogContentView.prototype._showOrHideConditionallyVisibleScopeBarItemsAsNeeded):
- Show or hide the conditionally-visible buttons as needed.
(WI.LogContentView):
- In the constructor, hide the newly created Infos and Debugs buttons
if they're unselected.
(WI.LogContentView.prototype._messageSourceBarSelectionDidChange):
(WI.LogContentView.prototype._scopeBarSelectionDidChange):
- Clean up unused local variable `items`.
Canonical link: https://commits.webkit.org/275914@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list