Closed Anutim closed 3 months ago
It is there only when focused.
Even then, I'd want it gone.
Also, that's not true. I struggle with finding a way to consistently reproduce this, but occasionally it enter some weird kinda state, where it keeps 'focusing' itself, but won't unfocus until I properly focus the URL bar again. However, once it's entered this weird kinda state, it just keeps 'focusing' itself on random tasks until I restart the browser.
Also when I say 'focusing', I don't mean it enters a state where I have the actual URL input field focused. No caret appears etc, just the blue outline.
We probably won't be doing many UI changes going forward except for ones related to removals due to safebrowsing, etc.
If you make your own builds I've been using this change to remove the ring:
--- a/chrome/browser/ui/views/location_bar/location_bar_view.cc
+++ b/chrome/browser/ui/views/location_bar/location_bar_view.cc
@@ -195,19 +195,6 @@ LocationBarView::LocationBarView(Browser
is_popup_mode_(is_popup_mode) {
set_suppress_default_focus_handling();
if (!is_popup_mode_) {
- views::FocusRing::Install(this);
- views::FocusRing::Get(this)->SetHasFocusPredicate(
- base::BindRepeating([](const View* view) {
- const auto* v = views::AsViewClass<LocationBarView>(view);
- CHECK(v);
- // Show focus ring when the Omnibox is visibly focused and the popup
- // is closed.
- return v->omnibox_view_->model()->is_caret_visible() &&
- !v->GetOmniboxPopupView()->IsOpen();
- }));
- views::FocusRing::Get(this)->SetOutsetFocusRingDisabled(true);
- views::InstallPillHighlightPathGenerator(this);
-
#if BUILDFLAG(IS_MAC)
geolocation_permission_observation_.Observe(
device::GeolocationSystemPermissionManager::GetInstance());
I'll need to set aside some time in the future to update the contrib repo and add that change as well.
Oh, unfortunate.
And I don't make/intend to make my own builds, but thanks for the share anyway.
Description
Hide the blue outline when the URL bar has focus.
Who's implementing?
The problem
For quite a while now, this has been built into Chromium and isn't styleable afaik.
Possible solutions
Implement a flag to disable it. I'm sorry if this is outside the scope of the project, just really bothers me so thought I'd ask.
Alternatives
No response
Additional context
No response