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

Unified Diff: ash/shell.cc

Issue 2271373002: mash: Port mojo:ash_sysui's ContextMenuMus to mojo:ash. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments Created 4 years, 4 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 | « ash/shell.h ('k') | ash/shell/shell_delegate_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shell.cc
diff --git a/ash/shell.cc b/ash/shell.cc
index 33ced2ef402428d468238c8a9cf622420793486a..689c6853eb9950f68becadcf4b34193537e43401 100644
--- a/ash/shell.cc
+++ b/ash/shell.cc
@@ -31,6 +31,7 @@
#include "ash/common/system/locale/locale_notification_controller.h"
#include "ash/common/system/status_area_widget.h"
#include "ash/common/system/tray/system_tray_delegate.h"
+#include "ash/common/wallpaper/wallpaper_delegate.h"
#include "ash/common/wm/maximize_mode/maximize_mode_controller.h"
#include "ash/common/wm/maximize_mode/maximize_mode_window_manager.h"
#include "ash/common/wm/mru_window_tracker.h"
@@ -39,7 +40,6 @@
#include "ash/common/wm_shell.h"
#include "ash/desktop_background/desktop_background_controller.h"
#include "ash/desktop_background/desktop_background_view.h"
-#include "ash/desktop_background/user_wallpaper_delegate.h"
#include "ash/display/cursor_window_controller.h"
#include "ash/display/display_configuration_controller.h"
#include "ash/display/display_manager.h"
@@ -901,8 +901,6 @@ void Shell::Init(const ShellInitParams& init_params) {
// This controller needs to be set before SetupManagedWindowMode.
desktop_background_controller_.reset(
new DesktopBackgroundController(blocking_pool_));
- user_wallpaper_delegate_.reset(
- wm_shell_->delegate()->CreateUserWallpaperDelegate());
session_state_delegate_.reset(
wm_shell_->delegate()->CreateSessionStateDelegate());
@@ -941,12 +939,10 @@ void Shell::Init(const ShellInitParams& init_params) {
audio_a11y_controller_.reset(new chromeos::AudioA11yController);
#endif // defined(OS_CHROMEOS)
- // It needs to be created after RootWindowController has been created
- // (which calls OnWindowResized has been called, otherwise the
- // widget will not paint when restoring after a browser crash. Also it needs
- // to be created after InitSecondaryDisplays() to initialize the wallpapers in
- // the correct size.
- user_wallpaper_delegate_->InitializeWallpaper();
+ // Initialize the wallpaper after the RootWindowController has been created,
+ // otherwise the widget will not paint when restoring after a browser crash.
+ // Also, initialize after display initialization to ensure correct sizing.
+ wm_shell_->wallpaper_delegate()->InitializeWallpaper();
if (cursor_manager_) {
if (initially_hide_cursor_)
« no previous file with comments | « ash/shell.h ('k') | ash/shell/shell_delegate_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698