[Webkit-unassigned] [Bug 122681] [GTK] Search functionality in MiniBrowser provides feedback on search fail
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Nov 25 10:39:46 PST 2013
https://bugs.webkit.org/show_bug.cgi?id=122681
--- Comment #8 from Andres Gomez Garcia <agomez at igalia.com> 2013-11-25 10:38:14 PST ---
(In reply to comment #5)
> > Tools/MiniBrowser/gtk/BrowserSearchBar.c:51
> > + if (failedSearch)
> > + gtk_css_provider_load_from_data(searchBar->cssProvider, searchBar->failStyle, -1, NULL);
> > + else
> > + gtk_css_provider_load_from_data(searchBar->cssProvider, "", -1, NULL);
Done.
> That's more of a personal preference I think, but I'd use the ternary operator here
>
> > Tools/MiniBrowser/gtk/BrowserSearchBar.c:169
> > + searchBar->failStyle = " GtkEntry#searchEntry {\n"
> > + " background-color: #ff6666;\n"
> > + "}\n";
>
> What about putting this string in one line only (no \n) and moving its definition to a global const (static const char*) up in this file, right after the priv struct?
Done.
(In reply to comment #6)
...
> Actually, I just realized that you don't need to keep the const char for failStyle in the private struct at all if you follow this advice :)
Done.
--
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