Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(572)

Unified Diff: ui/app_list/views/app_list_view.cc

Issue 220873002: Revert of Add a whole-app-list unit test. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/app_list/views/app_list_view.h ('k') | ui/app_list/views/app_list_view_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/views/app_list_view.cc
diff --git a/ui/app_list/views/app_list_view.cc b/ui/app_list/views/app_list_view.cc
index 20075fc137261b980612e6eedcd174099e388378..a66f34b2311ec1b6bbf7fe955f00969da3456ec0 100644
--- a/ui/app_list/views/app_list_view.cc
+++ b/ui/app_list/views/app_list_view.cc
@@ -50,8 +50,7 @@
namespace {
-// For UMA and testing. If non-null, triggered when the app list is painted.
-base::Closure g_next_paint_callback;
+void (*g_next_paint_callback)();
// The margin from the edge to the speech UI.
const int kSpeechUIMargin = 12;
@@ -200,9 +199,9 @@
void AppListView::Paint(gfx::Canvas* canvas) {
views::BubbleDelegateView::Paint(canvas);
- if (!g_next_paint_callback.is_null()) {
- g_next_paint_callback.Run();
- g_next_paint_callback.Reset();
+ if (g_next_paint_callback) {
+ g_next_paint_callback();
+ g_next_paint_callback = NULL;
}
}
@@ -244,7 +243,7 @@
}
// static
-void AppListView::SetNextPaintCallback(const base::Closure& callback) {
+void AppListView::SetNextPaintCallback(void (*callback)()) {
g_next_paint_callback = callback;
}
« no previous file with comments | « ui/app_list/views/app_list_view.h ('k') | ui/app_list/views/app_list_view_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698