Update ToolbarButton's icon by itself
Previously, ToolbarButtons' icons were updated by ToolbarView.
But ToolbarButton can handle it by itself.
From now on, ToolbarButton will call UpdateIcon() ,which is a virtual
method for children classes to decide their icons, when it's needed.
e.g. When it's added to widget, theme was changed, or touch ui
mode was changed.
TODO: we might be able to do similar things for other children views
and remove ToolbarView::Loadimages().
Bug: 1048901
Change-Id: Ia8403a48d3b7efb94df83738d113ee06c31f1258
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2253600
Commit-Queue: Sang Woo Ko <sangwoo108@chromium.org>
Reviewed-by: Peter Kasting <pkasting@chromium.org>
Cr-Commit-Position: refs/heads/master@{#788928}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.