summaryrefslogtreecommitdiffstats
path: root/chrome/browser/ui
diff options
context:
space:
mode:
authorerg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-12 23:04:41 +0000
committererg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-12 23:04:41 +0000
commitc72275dc6492eed399515a341ba17641fe6c798e (patch)
treede6207a2139df8f4708b39c364180affe3dc0183 /chrome/browser/ui
parentf06b05978f9fe04dbf3ca754d8f2f01270690efe (diff)
downloadchromium_src-c72275dc6492eed399515a341ba17641fe6c798e.zip
chromium_src-c72275dc6492eed399515a341ba17641fe6c798e.tar.gz
chromium_src-c72275dc6492eed399515a341ba17641fe6c798e.tar.bz2
Revert 269892 "linux_aura: Compile ash into chrome."
Major regression in chrome-si/initializers. Reverting for now to fix. > linux_aura: Compile ash into chrome. > > Running chrome with the "--open-ash" parameter will create an ash > desktop window. Ash on Linux has some problems, but at least we're now > compiling the code into the binary. > > TODO: The applist isn't positioned correctly, and some details of the > system tray aren't correct. > > BUG=300084, 303862 > R=sky@chromium.org > > Review URL: https://codereview.chromium.org/25108005 TBR=erg@chromium.org Review URL: https://codereview.chromium.org/276773004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@269902 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/ui')
-rw-r--r--chrome/browser/ui/ash/app_list/app_list_service_ash.cc5
-rw-r--r--chrome/browser/ui/ash/chrome_shell_delegate_views.cc10
-rw-r--r--chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc2
-rw-r--r--chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc2
-rw-r--r--chrome/browser/ui/ash/screenshot_taker.cc4
-rw-r--r--chrome/browser/ui/ash/session_state_delegate_views.cc2
-rw-r--r--chrome/browser/ui/ash/session_state_delegate_views.h2
-rw-r--r--chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.h14
-rw-r--r--chrome/browser/ui/ash/user_wallpaper_delegate_win.cc (renamed from chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.cc)5
-rw-r--r--chrome/browser/ui/ash/user_wallpaper_delegate_win.h14
-rw-r--r--chrome/browser/ui/aura/chrome_browser_main_extra_parts_aura.cc23
-rw-r--r--chrome/browser/ui/libgtk2ui/gtk2_ui.cc9
-rw-r--r--chrome/browser/ui/startup/startup_browser_creator.cc2
-rw-r--r--chrome/browser/ui/views/accelerator_table_unittest.cc2
-rw-r--r--chrome/browser/ui/views/app_list/linux/app_list_linux.cc4
-rw-r--r--chrome/browser/ui/views/app_list/linux/app_list_service_linux.cc8
-rw-r--r--chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc5
-rw-r--r--chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc1
-rw-r--r--chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.cc67
-rw-r--r--chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.h3
-rw-r--r--chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_aura.cc4
-rw-r--r--chrome/browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc10
-rw-r--r--chrome/browser/ui/views/theme_image_mapper.cc (renamed from chrome/browser/ui/views/theme_image_mapper_chromeos.cc)0
-rw-r--r--chrome/browser/ui/views/theme_image_mapper_aura_win.cc (renamed from chrome/browser/ui/views/theme_image_mapper_desktop.cc)18
-rw-r--r--chrome/browser/ui/window_sizer/window_sizer_ash_uitest.cc2
-rw-r--r--chrome/browser/ui/window_sizer/window_sizer_ash_unittest.cc40
26 files changed, 58 insertions, 200 deletions
diff --git a/chrome/browser/ui/ash/app_list/app_list_service_ash.cc b/chrome/browser/ui/ash/app_list/app_list_service_ash.cc
index 58eb99b..ac1dc4f 100644
--- a/chrome/browser/ui/ash/app_list/app_list_service_ash.cc
+++ b/chrome/browser/ui/ash/app_list/app_list_service_ash.cc
@@ -65,9 +65,8 @@ AppListControllerDelegate* AppListServiceAsh::GetControllerDelegate() {
return controller_delegate_.get();
}
-// Windows and Linux Ash additionally supports a native UI. See
-// app_list_service_{win,linux}.cc.
-#if defined(OS_CHROMEOS)
+// Windows Ash additionally supports a native UI. See app_list_service_win.cc.
+#if !defined(OS_WIN)
// static
AppListService* AppListService::Get(chrome::HostDesktopType desktop_type) {
diff --git a/chrome/browser/ui/ash/chrome_shell_delegate_views.cc b/chrome/browser/ui/ash/chrome_shell_delegate_views.cc
index 3061692..3522aa5 100644
--- a/chrome/browser/ui/ash/chrome_shell_delegate_views.cc
+++ b/chrome/browser/ui/ash/chrome_shell_delegate_views.cc
@@ -22,7 +22,6 @@
#include "chrome/browser/sync/sync_error_notifier_factory_ash.h"
#include "chrome/browser/ui/ash/chrome_new_window_delegate.h"
#include "chrome/browser/ui/ash/session_state_delegate_views.h"
-#include "chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_finder.h"
#include "chrome/browser/ui/browser_list.h"
@@ -36,6 +35,7 @@
#if defined(OS_WIN)
#include "chrome/browser/ui/ash/system_tray_delegate_win.h"
+#include "chrome/browser/ui/ash/user_wallpaper_delegate_win.h"
#endif
namespace {
@@ -149,7 +149,7 @@ class EmptyAccessibilityDelegate : public ash::AccessibilityDelegate {
return ash::A11Y_ALERT_NONE;
}
- virtual base::TimeDelta PlayShutdownSound() const OVERRIDE {
+ base::TimeDelta PlayShutdownSound() const OVERRIDE {
return base::TimeDelta();
}
@@ -194,7 +194,11 @@ ash::AccessibilityDelegate* ChromeShellDelegate::CreateAccessibilityDelegate() {
}
ash::UserWallpaperDelegate* ChromeShellDelegate::CreateUserWallpaperDelegate() {
- return CreateSolidColorUserWallpaperDelegate();
+#if defined(OS_WIN)
+ return ::CreateUserWallpaperDelegate();
+#else
+ return NULL;
+#endif
}
void ChromeShellDelegate::Observe(int type,
diff --git a/chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc b/chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc
index 354ce1a..9f073ac 100644
--- a/chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc
+++ b/chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc
@@ -650,10 +650,8 @@ void ChromeLauncherController::LaunchApp(const std::string& app_id,
return;
}
-#if defined(OS_WIN)
if (LaunchedInNativeDesktop(app_id))
return;
-#endif
// The app will be created for the currently active profile.
AppLaunchParams params(profile_,
diff --git a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc
index 7a51259..887cf81 100644
--- a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc
+++ b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_unittest.cc
@@ -79,13 +79,11 @@ const char* offline_gmail_url = "https://mail.google.com/mail/mu/u";
const char* gmail_url = "https://mail.google.com/mail/u";
const char* kGmailLaunchURL = "https://mail.google.com/mail/ca";
-#if defined(OS_CHROMEOS)
// As defined in /chromeos/dbus/cryptohome_client.cc.
const char kUserIdHashSuffix[] = "-hash";
// An extension prefix.
const char kCrxAppPrefix[] = "_crx_";
-#endif
// ShelfModelObserver implementation that tracks what messages are invoked.
class TestShelfModelObserver : public ash::ShelfModelObserver {
diff --git a/chrome/browser/ui/ash/screenshot_taker.cc b/chrome/browser/ui/ash/screenshot_taker.cc
index 1864112..a94acdf 100644
--- a/chrome/browser/ui/ash/screenshot_taker.cc
+++ b/chrome/browser/ui/ash/screenshot_taker.cc
@@ -58,9 +58,7 @@ const int kScreenshotMinimumIntervalInMS = 1000;
const char kNotificationId[] = "screenshot";
-#if defined(OS_CHROMEOS)
const char kNotificationOriginUrl[] = "chrome://screenshot";
-#endif
const char kImageClipboardFormatPrefix[] = "<img src='data:image/png;base64,";
const char kImageClipboardFormatSuffix[] = "'>";
@@ -361,7 +359,6 @@ bool GetScreenshotDirectory(base::FilePath* directory) {
return true;
}
-#if defined(OS_CHROMEOS)
const int GetScreenshotNotificationTitle(
ScreenshotTakerObserver::Result screenshot_result) {
switch (screenshot_result) {
@@ -385,7 +382,6 @@ const int GetScreenshotNotificationText(
return IDS_ASH_SCREENSHOT_NOTIFICATION_TEXT_FAIL;
}
}
-#endif
} // namespace
diff --git a/chrome/browser/ui/ash/session_state_delegate_views.cc b/chrome/browser/ui/ash/session_state_delegate_views.cc
index 675a9bf..2be4389 100644
--- a/chrome/browser/ui/ash/session_state_delegate_views.cc
+++ b/chrome/browser/ui/ash/session_state_delegate_views.cc
@@ -108,7 +108,7 @@ ash::SessionStateDelegate::SessionState SessionStateDelegate::GetSessionState()
const ash::UserInfo* SessionStateDelegate::GetUserInfo(
ash::MultiProfileIndex index) const {
- return GetUserInfo(static_cast<content::BrowserContext*>(NULL));
+ return GetUserInfo(NULL);
}
const ash::UserInfo* SessionStateDelegate::GetUserInfo(
diff --git a/chrome/browser/ui/ash/session_state_delegate_views.h b/chrome/browser/ui/ash/session_state_delegate_views.h
index 3b32b29..717fa61 100644
--- a/chrome/browser/ui/ash/session_state_delegate_views.h
+++ b/chrome/browser/ui/ash/session_state_delegate_views.h
@@ -9,7 +9,6 @@
#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/observer_list.h"
-#include "ui/gfx/image/image_skia.h"
namespace ash {
class SessionStateObserver;
@@ -46,7 +45,6 @@ class SessionStateDelegate : public ash::SessionStateDelegate {
ash::SessionStateObserver* observer) OVERRIDE;
virtual void RemoveSessionStateObserver(
ash::SessionStateObserver* observer) OVERRIDE;
-
private:
DISALLOW_COPY_AND_ASSIGN(SessionStateDelegate);
};
diff --git a/chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.h b/chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.h
deleted file mode 100644
index 2634c2c..0000000
--- a/chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.h
+++ /dev/null
@@ -1,14 +0,0 @@
-// Copyright (c) 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_UI_ASH_SOLID_COLOR_USER_WALLPAPER_DELEGATE_H_
-#define CHROME_BROWSER_UI_ASH_SOLID_COLOR_USER_WALLPAPER_DELEGATE_H_
-
-namespace ash {
-class UserWallpaperDelegate;
-}
-
-ash::UserWallpaperDelegate* CreateSolidColorUserWallpaperDelegate();
-
-#endif // CHROME_BROWSER_UI_ASH_SOLID_COLOR_USER_WALLPAPER_DELEGATE_H_
diff --git a/chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.cc b/chrome/browser/ui/ash/user_wallpaper_delegate_win.cc
index f45a90a..92ce758 100644
--- a/chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.cc
+++ b/chrome/browser/ui/ash/user_wallpaper_delegate_win.cc
@@ -2,10 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "chrome/browser/ui/ash/solid_color_user_wallpaper_delegate.h"
+#include "ash/desktop_background/user_wallpaper_delegate.h"
#include "ash/desktop_background/desktop_background_controller.h"
-#include "ash/desktop_background/user_wallpaper_delegate.h"
#include "ash/shell.h"
#include "ash/wm/window_animations.h"
#include "base/basictypes.h"
@@ -87,6 +86,6 @@ class UserWallpaperDelegate : public ash::UserWallpaperDelegate {
} // namespace
-ash::UserWallpaperDelegate* CreateSolidColorUserWallpaperDelegate() {
+ash::UserWallpaperDelegate* CreateUserWallpaperDelegate() {
return new UserWallpaperDelegate();
}
diff --git a/chrome/browser/ui/ash/user_wallpaper_delegate_win.h b/chrome/browser/ui/ash/user_wallpaper_delegate_win.h
new file mode 100644
index 0000000..f83f95e
--- /dev/null
+++ b/chrome/browser/ui/ash/user_wallpaper_delegate_win.h
@@ -0,0 +1,14 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_ASH_USER_WALLPAPER_DELEGATE_WIN_H_
+#define CHROME_BROWSER_UI_ASH_USER_WALLPAPER_DELEGATE_WIN_H_
+
+namespace ash {
+class UserWallpaperDelegate;
+}
+
+ash::UserWallpaperDelegate* CreateUserWallpaperDelegate();
+
+#endif // CHROME_BROWSER_UI_ASH_USER_WALLPAPER_DELEGATE_WIN_H_
diff --git a/chrome/browser/ui/aura/chrome_browser_main_extra_parts_aura.cc b/chrome/browser/ui/aura/chrome_browser_main_extra_parts_aura.cc
index 259b073..3658a52 100644
--- a/chrome/browser/ui/aura/chrome_browser_main_extra_parts_aura.cc
+++ b/chrome/browser/ui/aura/chrome_browser_main_extra_parts_aura.cc
@@ -24,7 +24,6 @@
#include "chrome/browser/ui/libgtk2ui/gtk2_ui.h"
#include "chrome/common/pref_names.h"
#include "ui/aura/window.h"
-#include "ui/base/ime/input_method_initializer.h"
#include "ui/native_theme/native_theme_aura.h"
#include "ui/views/linux_ui/linux_ui.h"
#endif
@@ -71,12 +70,7 @@ chrome::HostDesktopType GetInitialDesktop() {
command_line->HasSwitch(switches::kViewerLaunchViaAppId)) {
return chrome::HOST_DESKTOP_TYPE_ASH;
}
-#elif defined(OS_LINUX)
- const CommandLine* command_line = CommandLine::ForCurrentProcess();
- if (command_line->HasSwitch(switches::kOpenAsh))
- return chrome::HOST_DESKTOP_TYPE_ASH;
#endif
-
return chrome::HOST_DESKTOP_TYPE_NATIVE;
}
#endif // !defined(OS_CHROMEOS) && defined(USE_ASH)
@@ -91,16 +85,10 @@ ChromeBrowserMainExtraPartsAura::~ChromeBrowserMainExtraPartsAura() {
void ChromeBrowserMainExtraPartsAura::PreEarlyInitialization() {
#if defined(USE_X11) && !defined(OS_CHROMEOS)
- if (GetInitialDesktop() != chrome::HOST_DESKTOP_TYPE_ASH) {
- // TODO(erg): Refactor this into a dlopen call when we add a GTK3 port.
- views::LinuxUI* gtk2_ui = BuildGtk2UI();
- gtk2_ui->SetNativeThemeOverride(base::Bind(&GetNativeThemeForWindow));
- views::LinuxUI::SetInstance(gtk2_ui);
- } else {
- // TODO(erg): Eventually, we'll need to somehow support IMEs in ash on
- // Linux.
- ui::InitializeInputMethodForTesting();
- }
+ // TODO(erg): Refactor this into a dlopen call when we add a GTK3 port.
+ views::LinuxUI* gtk2_ui = BuildGtk2UI();
+ gtk2_ui->SetNativeThemeOverride(base::Bind(&GetNativeThemeForWindow));
+ views::LinuxUI::SetInstance(gtk2_ui);
#endif
}
@@ -113,8 +101,7 @@ void ChromeBrowserMainExtraPartsAura::ToolkitInitialized() {
#endif
#if defined(USE_X11) && !defined(OS_CHROMEOS)
- if (GetInitialDesktop() != chrome::HOST_DESKTOP_TYPE_ASH)
- views::LinuxUI::instance()->Initialize();
+ views::LinuxUI::instance()->Initialize();
#endif
}
diff --git a/chrome/browser/ui/libgtk2ui/gtk2_ui.cc b/chrome/browser/ui/libgtk2ui/gtk2_ui.cc
index 401f3e2..2730216 100644
--- a/chrome/browser/ui/libgtk2ui/gtk2_ui.cc
+++ b/chrome/browser/ui/libgtk2ui/gtk2_ui.cc
@@ -120,17 +120,10 @@ const color_utils::HSL kDefaultTintFrameIncognitoInactive = { -1, 0.3f, 0.6f };
const color_utils::HSL kDefaultTintBackgroundTab = { -1, 0.5, 0.75 };
// A list of images that we provide while in gtk mode.
-//
-// TODO(erg): We list both the normal and *_DESKTOP versions of some of these
-// images because in some contexts, we don't go through the
-// chrome::MapThemeImage interface. That should be fixed, but tracking that
-// down is Hard.
const int kThemeImages[] = {
IDR_THEME_TOOLBAR,
IDR_THEME_TAB_BACKGROUND,
- IDR_THEME_TAB_BACKGROUND_DESKTOP,
IDR_THEME_TAB_BACKGROUND_INCOGNITO,
- IDR_THEME_TAB_BACKGROUND_INCOGNITO_DESKTOP,
IDR_FRAME,
IDR_FRAME_INACTIVE,
IDR_THEME_FRAME,
@@ -1047,10 +1040,8 @@ SkBitmap Gtk2UI::GenerateGtkThemeBitmap(int id) const {
return bitmap;
}
case IDR_THEME_TAB_BACKGROUND:
- case IDR_THEME_TAB_BACKGROUND_DESKTOP:
return GenerateTabImage(IDR_THEME_FRAME);
case IDR_THEME_TAB_BACKGROUND_INCOGNITO:
- case IDR_THEME_TAB_BACKGROUND_INCOGNITO_DESKTOP:
return GenerateTabImage(IDR_THEME_FRAME_INCOGNITO);
case IDR_FRAME:
case IDR_THEME_FRAME:
diff --git a/chrome/browser/ui/startup/startup_browser_creator.cc b/chrome/browser/ui/startup/startup_browser_creator.cc
index c7a1209..74d9db6 100644
--- a/chrome/browser/ui/startup/startup_browser_creator.cc
+++ b/chrome/browser/ui/startup/startup_browser_creator.cc
@@ -299,7 +299,7 @@ bool StartupBrowserCreator::LaunchBrowser(
chrome::HostDesktopType host_desktop_type =
chrome::HOST_DESKTOP_TYPE_NATIVE;
-#if defined(USE_ASH) && !defined(OS_CHROMEOS)
+#if defined(OS_WIN) && defined(USE_ASH)
// We want to maintain only one type of instance for now, either ASH
// or desktop.
// TODO(shrikant): Remove this code once we decide on running both desktop
diff --git a/chrome/browser/ui/views/accelerator_table_unittest.cc b/chrome/browser/ui/views/accelerator_table_unittest.cc
index d920d62..3984a38 100644
--- a/chrome/browser/ui/views/accelerator_table_unittest.cc
+++ b/chrome/browser/ui/views/accelerator_table_unittest.cc
@@ -43,7 +43,7 @@ TEST(AcceleratorTableTest, CheckDuplicatedAccelerators) {
}
}
-#if defined(OS_CHROMEOS)
+#if defined(USE_ASH) && !defined(OS_WIN)
TEST(AcceleratorTableTest, CheckDuplicatedAcceleratorsAsh) {
std::set<AcceleratorMapping, Cmp> acclerators;
const std::vector<AcceleratorMapping> accelerator_list(GetAcceleratorList());
diff --git a/chrome/browser/ui/views/app_list/linux/app_list_linux.cc b/chrome/browser/ui/views/app_list/linux/app_list_linux.cc
index 936d26d..e513121 100644
--- a/chrome/browser/ui/views/app_list/linux/app_list_linux.cc
+++ b/chrome/browser/ui/views/app_list/linux/app_list_linux.cc
@@ -90,8 +90,6 @@ void AppListLinux::MoveNearCursor(app_list::AppListView* view) {
view->SetBubbleArrow(views::BubbleBorder::FLOAT);
- AppListPositioner::ScreenEdge edge;
-#if defined(OS_LINUX) && !defined(OS_CHROMEOS)
// In the Unity desktop environment, special case SCREEN_EDGE_LEFT. It is
// always on the left side in Unity, but ShelfLocationInDisplay will not
// detect this if the shelf is hidden.
@@ -99,10 +97,10 @@ void AppListLinux::MoveNearCursor(app_list::AppListView* view) {
// applies, but we currently have no way to detect whether Gnome Shell is
// running.
views::LinuxUI* ui = views::LinuxUI::instance();
+ AppListPositioner::ScreenEdge edge;
if (ui && ui->UnityIsRunning())
edge = AppListPositioner::SCREEN_EDGE_LEFT;
else
-#endif
edge = ShelfLocationInDisplay(display);
view->SetAnchorPoint(FindAnchorPoint(view->GetPreferredSize(),
display,
diff --git a/chrome/browser/ui/views/app_list/linux/app_list_service_linux.cc b/chrome/browser/ui/views/app_list/linux/app_list_service_linux.cc
index e6df273..c4e45f0 100644
--- a/chrome/browser/ui/views/app_list/linux/app_list_service_linux.cc
+++ b/chrome/browser/ui/views/app_list/linux/app_list_service_linux.cc
@@ -8,12 +8,8 @@
#include "base/thread_task_runner_handle.h"
#include "chrome/browser/shell_integration.h"
#include "chrome/browser/shell_integration_linux.h"
-#include "chrome/browser/ui/app_list/app_list_controller_delegate.h"
#include "chrome/browser/ui/app_list/app_list_controller_delegate_views.h"
#include "chrome/browser/ui/app_list/app_list_shower_views.h"
-#include "chrome/browser/ui/app_list/app_list_view_delegate.h"
-#include "chrome/browser/ui/app_list/scoped_keep_alive.h"
-#include "chrome/browser/ui/ash/app_list/app_list_service_ash.h"
#include "chrome/browser/ui/views/app_list/linux/app_list_linux.h"
#include "content/public/browser/browser_thread.h"
#include "grit/chromium_strings.h"
@@ -84,14 +80,10 @@ void AppListServiceLinux::MoveNearCursor(app_list::AppListView* view) {
// static
AppListService* AppListService::Get(chrome::HostDesktopType desktop_type) {
- if (desktop_type == chrome::HOST_DESKTOP_TYPE_ASH)
- return AppListServiceAsh::GetInstance();
-
return AppListServiceLinux::GetInstance();
}
// static
void AppListService::InitAll(Profile* initial_profile) {
- AppListServiceAsh::GetInstance()->Init(initial_profile);
AppListServiceLinux::GetInstance()->Init(initial_profile);
}
diff --git a/chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc b/chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc
index 6de8b94..6b858b7 100644
--- a/chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc
+++ b/chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc
@@ -68,11 +68,6 @@ ChromeBrowserMainExtraPartsAsh::~ChromeBrowserMainExtraPartsAsh() {
void ChromeBrowserMainExtraPartsAsh::PreProfileInit() {
if (chrome::ShouldOpenAshOnStartup()) {
chrome::OpenAsh();
-
-#if defined(OS_LINUX) && !defined(OS_CHROMEOS)
- ash::Shell::GetInstance()->CreateShelf();
- ash::Shell::GetInstance()->ShowShelf();
-#endif
} else {
#if !defined(OS_CHROMEOS)
gfx::Screen::SetScreenTypeDelegate(new ScreenTypeDelegateWin);
diff --git a/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc
index e6c02e1..bd9dc65 100644
--- a/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc
+++ b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc
@@ -58,6 +58,7 @@ class DesktopThemeProvider : public ui::ThemeProvider {
virtual bool HasCustomImage(int id) const OVERRIDE {
return delegate_->HasCustomImage(
chrome::MapThemeImage(chrome::HOST_DESKTOP_TYPE_NATIVE, id));
+
}
virtual base::RefCountedMemory* GetRawData(
int id,
diff --git a/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.cc b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.cc
index 79915b6..49f9ae2 100644
--- a/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.cc
+++ b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.cc
@@ -4,78 +4,16 @@
#include "chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.h"
-#include "chrome/browser/themes/theme_service.h"
-#include "chrome/browser/themes/theme_service_factory.h"
-#include "chrome/browser/ui/views/frame/browser_frame.h"
-#include "chrome/browser/ui/views/frame/browser_view.h"
-#include "chrome/browser/ui/views/theme_image_mapper.h"
-
-namespace {
-
-// DesktopThemeProvider maps resource ids using MapThemeImage(). This is
-// necessary for BrowserDesktopWindowTreeHostWin so that it uses the windows
-// theme images rather than the ash theme images.
-//
-// This differs from the version in browser_desktop_window_tree_host_win.cc
-// because we need to also look up whether we're using the native theme.
-class DesktopThemeProvider : public ui::ThemeProvider {
- public:
- explicit DesktopThemeProvider(ThemeService* delegate)
- : delegate_(delegate) {
- }
-
- virtual bool UsingNativeTheme() const OVERRIDE {
- return delegate_->UsingNativeTheme();
- }
- virtual gfx::ImageSkia* GetImageSkiaNamed(int id) const OVERRIDE {
- if (delegate_->UsingNativeTheme())
- return delegate_->GetImageSkiaNamed(id);
-
- return delegate_->GetImageSkiaNamed(
- chrome::MapThemeImage(chrome::HOST_DESKTOP_TYPE_NATIVE, id));
- }
- virtual SkColor GetColor(int id) const OVERRIDE {
- return delegate_->GetColor(id);
- }
- virtual int GetDisplayProperty(int id) const OVERRIDE {
- return delegate_->GetDisplayProperty(id);
- }
- virtual bool ShouldUseNativeFrame() const OVERRIDE {
- return delegate_->ShouldUseNativeFrame();
- }
- virtual bool HasCustomImage(int id) const OVERRIDE {
- return delegate_->HasCustomImage(
- chrome::MapThemeImage(chrome::HOST_DESKTOP_TYPE_NATIVE, id));
- }
- virtual base::RefCountedMemory* GetRawData(
- int id,
- ui::ScaleFactor scale_factor) const OVERRIDE {
- return delegate_->GetRawData(id, scale_factor);
- }
-
- private:
- ThemeService* delegate_;
-
- DISALLOW_COPY_AND_ASSIGN(DesktopThemeProvider);
-};
-
-} // namespace
-
////////////////////////////////////////////////////////////////////////////////
// BrowserDesktopWindowTreeHostX11, public:
BrowserDesktopWindowTreeHostX11::BrowserDesktopWindowTreeHostX11(
views::internal::NativeWidgetDelegate* native_widget_delegate,
views::DesktopNativeWidgetAura* desktop_native_widget_aura,
- BrowserView* browser_view,
- BrowserFrame* browser_frame)
+ BrowserView* browser_view)
: DesktopWindowTreeHostX11(native_widget_delegate,
desktop_native_widget_aura),
browser_view_(browser_view) {
- scoped_ptr<ui::ThemeProvider> theme_provider(
- new DesktopThemeProvider(ThemeServiceFactory::GetForProfile(
- browser_view->browser()->profile())));
- browser_frame->SetThemeProvider(theme_provider.Pass());
}
BrowserDesktopWindowTreeHostX11::~BrowserDesktopWindowTreeHostX11() {
@@ -129,6 +67,5 @@ BrowserDesktopWindowTreeHost*
BrowserFrame* browser_frame) {
return new BrowserDesktopWindowTreeHostX11(native_widget_delegate,
desktop_native_widget_aura,
- browser_view,
- browser_frame);
+ browser_view);
}
diff --git a/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.h b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.h
index 1ed2264..d746c80 100644
--- a/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.h
+++ b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_x11.h
@@ -23,8 +23,7 @@ class BrowserDesktopWindowTreeHostX11
BrowserDesktopWindowTreeHostX11(
views::internal::NativeWidgetDelegate* native_widget_delegate,
views::DesktopNativeWidgetAura* desktop_native_widget_aura,
- BrowserView* browser_view,
- BrowserFrame* browser_frame);
+ BrowserView* browser_view);
virtual ~BrowserDesktopWindowTreeHostX11();
private:
diff --git a/chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_aura.cc b/chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_aura.cc
index dd411c7..2a4a3c6 100644
--- a/chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_aura.cc
+++ b/chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_aura.cc
@@ -19,13 +19,11 @@ namespace chrome {
BrowserNonClientFrameView* CreateBrowserNonClientFrameView(
BrowserFrame* frame, BrowserView* browser_view) {
-#if defined(USE_AURA) && !defined(OS_CHROMEOS)
+#if defined(OS_WIN)
if (browser_view->browser()->
host_desktop_type() == chrome::HOST_DESKTOP_TYPE_NATIVE) {
-#if defined(OS_WIN)
if (frame->ShouldUseNativeFrame())
return new GlassBrowserFrameView(frame, browser_view);
-#endif
return new OpaqueBrowserFrameView(frame, browser_view);
}
#endif
diff --git a/chrome/browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc b/chrome/browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc
index 71d49f4..76f2329 100644
--- a/chrome/browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc
+++ b/chrome/browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc
@@ -1503,7 +1503,7 @@ void DragSingleTabToSeparateWindowInSecondDisplayStep2(
#define MAYBE_DragSingleTabToSeparateWindowInSecondDisplay \
DISABLED_DragSingleTabToSeparateWindowInSecondDisplay
#else
-#define MAYBE_DragSingleTabToSeparateWindowInSecondDisplay \
+#define MAYBE_DragSingleTabToSeparateWindow \
DragSingleTabToSeparateWindowInSecondDisplay
#endif
// Drags from browser to a second display and releases input.
@@ -2047,7 +2047,7 @@ void CancelDragTabToWindowInSeparateDisplayStep2(
} // namespace
-#if defined(OS_CHROMEOS) || defined(OS_LINUX)
+#if defined(OS_CHROMEOS)
// TODO(sky,sad): Disabled as it fails due to resize locks with a real
// compositor. crbug.com/331924
#define MAYBE_CancelDragTabToWindowIn2ndDisplay \
@@ -2094,7 +2094,7 @@ IN_PROC_BROWSER_TEST_F(
ui_controls::LEFT, ui_controls::UP));
}
-#if defined(OS_CHROMEOS) || defined(OS_LINUX)
+#if defined(OS_CHROMEOS)
// TODO(sky,sad): Disabled as it fails due to resize locks with a real
// compositor. crbug.com/331924
#define MAYBE_CancelDragTabToWindowIn1stDisplay \
@@ -2318,7 +2318,7 @@ IN_PROC_BROWSER_TEST_P(DetachToDockedTabDragControllerTest,
#endif
-#if defined(USE_ASH) && defined(OS_CHROMEOS) // TODO(win_ash,linux_ash)
+#if defined(USE_ASH) && !defined(OS_WIN) // TODO(win_ash)
INSTANTIATE_TEST_CASE_P(TabDragging,
DetachToBrowserInSeparateDisplayTabDragControllerTest,
::testing::Values("mouse", "touch"));
@@ -2334,7 +2334,7 @@ INSTANTIATE_TEST_CASE_P(TabDragging,
INSTANTIATE_TEST_CASE_P(TabDragging,
DetachToBrowserTabDragControllerTestTouch,
::testing::Values("touch", "touch docked"));
-#elif defined(USE_ASH) && !defined(OS_LINUX) // TODO(linux_ash)
+#else
INSTANTIATE_TEST_CASE_P(TabDragging,
DetachToBrowserTabDragControllerTest,
::testing::Values("mouse"));
diff --git a/chrome/browser/ui/views/theme_image_mapper_chromeos.cc b/chrome/browser/ui/views/theme_image_mapper.cc
index 14ea061..14ea061 100644
--- a/chrome/browser/ui/views/theme_image_mapper_chromeos.cc
+++ b/chrome/browser/ui/views/theme_image_mapper.cc
diff --git a/chrome/browser/ui/views/theme_image_mapper_desktop.cc b/chrome/browser/ui/views/theme_image_mapper_aura_win.cc
index 62dda54..8ef3bb0 100644
--- a/chrome/browser/ui/views/theme_image_mapper_desktop.cc
+++ b/chrome/browser/ui/views/theme_image_mapper_aura_win.cc
@@ -14,23 +14,23 @@ int MapThemeImage(HostDesktopType desktop_type, int resource) {
switch (resource) {
case IDR_CONTENT_TOP_CENTER:
- return IDR_CONTENT_TOP_CENTER_DESKTOP;
+ return IDR_CONTENT_TOP_CENTER_WIN;
case IDR_OTR_ICON:
- return IDR_OTR_ICON_DESKTOP;
+ return IDR_OTR_ICON_WIN;
case IDR_THEME_FRAME:
- return IDR_THEME_FRAME_DESKTOP;
+ return IDR_THEME_FRAME_WIN;
case IDR_THEME_FRAME_INACTIVE:
- return IDR_THEME_FRAME_INACTIVE_DESKTOP;
+ return IDR_THEME_FRAME_INACTIVE_WIN;
case IDR_THEME_FRAME_INCOGNITO:
- return IDR_THEME_FRAME_INCOGNITO_DESKTOP;
+ return IDR_THEME_FRAME_INCOGNITO_WIN;
case IDR_THEME_FRAME_INCOGNITO_INACTIVE:
- return IDR_THEME_FRAME_INCOGNITO_INACTIVE_DESKTOP;
+ return IDR_THEME_FRAME_INCOGNITO_INACTIVE_WIN;
case IDR_THEME_TAB_BACKGROUND:
- return IDR_THEME_TAB_BACKGROUND_DESKTOP;
+ return IDR_THEME_TAB_BACKGROUND_WIN;
case IDR_THEME_TAB_BACKGROUND_INCOGNITO:
- return IDR_THEME_TAB_BACKGROUND_INCOGNITO_DESKTOP;
+ return IDR_THEME_TAB_BACKGROUND_INCOGNITO_WIN;
case IDR_THEME_TOOLBAR:
- return IDR_THEME_TOOLBAR_DESKTOP;
+ return IDR_THEME_TOOLBAR_WIN;
default:
break;
}
diff --git a/chrome/browser/ui/window_sizer/window_sizer_ash_uitest.cc b/chrome/browser/ui/window_sizer/window_sizer_ash_uitest.cc
index a688ebf..4637433 100644
--- a/chrome/browser/ui/window_sizer/window_sizer_ash_uitest.cc
+++ b/chrome/browser/ui/window_sizer/window_sizer_ash_uitest.cc
@@ -67,7 +67,7 @@ void OpenBrowserUsingShelfOnRootWindow(aura::Window* root_window) {
} // namespace
-#if !defined(OS_CHROMEOS)
+#if defined(OS_WIN)
#define MAYBE_OpenBrowserUsingShelfOnOtherDisplay DISABLED_OpenBrowserUsingShelfOnOtherDisplay
#define MAYBE_OpenBrowserUsingContextMenuOnOtherDisplay DISABLED_OpenBrowserUsingContextMenuOnOtherDisplay
#else
diff --git a/chrome/browser/ui/window_sizer/window_sizer_ash_unittest.cc b/chrome/browser/ui/window_sizer/window_sizer_ash_unittest.cc
index 4bd32d5..a33aa20 100644
--- a/chrome/browser/ui/window_sizer/window_sizer_ash_unittest.cc
+++ b/chrome/browser/ui/window_sizer/window_sizer_ash_unittest.cc
@@ -92,17 +92,9 @@ scoped_ptr<TestBrowserWindowAura> CreateTestBrowserWindow(
} // namespace
-// On desktop linux aura, we currently don't use the ash frame, breaking some
-// tests which expect ash sizes: http://crbug.com/303862
-#if defined(OS_LINUX) && !defined(OS_CHROMEOS)
-#define MAYBE_DefaultSizeCase DISABLED_DefaultSizeCase
-#else
-#define MAYBE_DefaultSizeCase DefaultSizeCase
-#endif
-
// Test that the window is sized appropriately for the first run experience
// where the default window bounds calculation is invoked.
-TEST_F(WindowSizerAshTest, MAYBE_DefaultSizeCase) {
+TEST_F(WindowSizerAshTest, DefaultSizeCase) {
#if defined(OS_WIN)
CommandLine::ForCurrentProcess()->AppendSwitch(switches::kOpenAsh);
#endif
@@ -459,16 +451,8 @@ TEST_F(WindowSizerAshTest, LastWindowOffscreenWithNonAggressiveRepositioning) {
}
}
-// On desktop linux aura, we currently don't use the ash frame, breaking some
-// tests which expect ash sizes: http://crbug.com/303862
-#if defined(OS_LINUX) && !defined(OS_CHROMEOS)
-#define MAYBE_PlaceNewWindows DISABLED_PlaceNewWindows
-#else
-#define MAYBE_PlaceNewWindows PlaceNewWindows
-#endif
-
// Test the placement of newly created windows.
-TEST_F(WindowSizerAshTest, MAYBE_PlaceNewWindows) {
+TEST_F(WindowSizerAshTest, PlaceNewWindows) {
// Create a browser which we can use to pass into the GetWindowBounds
// function.
scoped_ptr<TestingProfile> profile(new TestingProfile());
@@ -537,18 +521,10 @@ TEST_F(WindowSizerAshTest, MAYBE_PlaceNewWindows) {
}
}
-// On desktop linux aura, we currently don't use the ash frame, breaking some
-// tests which expect ash sizes: http://crbug.com/303862
-#if defined(OS_LINUX) && !defined(OS_CHROMEOS)
-#define MAYBE_PlaceNewBrowserWindowOnEmptyDesktop DISABLED_PlaceNewBrowserWindowOnEmptyDesktop
-#else
-#define MAYBE_PlaceNewBrowserWindowOnEmptyDesktop PlaceNewBrowserWindowOnEmptyDesktop
-#endif
-
// Test the placement of newly created windows on an empty desktop.
// This test supplements "PlaceNewWindows" by testing the creation of a newly
// created browser window on an empty desktop.
-TEST_F(WindowSizerAshTest, MAYBE_PlaceNewBrowserWindowOnEmptyDesktop) {
+TEST_F(WindowSizerAshTest, PlaceNewBrowserWindowOnEmptyDesktop) {
// Create a browser which we can use to pass into the GetWindowBounds
// function.
scoped_ptr<TestingProfile> profile(new TestingProfile());
@@ -719,16 +695,8 @@ TEST_F(WindowSizerAshTest, MAYBE_PlaceNewWindowsOnMultipleDisplays) {
}
}
-// On desktop linux aura, we currently don't use the ash frame, breaking some
-// tests which expect ash sizes: http://crbug.com/303862
-#if defined(OS_LINUX) && !defined(OS_CHROMEOS)
-#define MAYBE_TestShowState DISABLED_TestShowState
-#else
-#define MAYBE_TestShowState TestShowState
-#endif
-
// Test that the show state is properly returned for non default cases.
-TEST_F(WindowSizerAshTest, MAYBE_TestShowState) {
+TEST_F(WindowSizerAshTest, TestShowState) {
scoped_ptr<TestingProfile> profile(new TestingProfile());
// Creating a browser & window to play with.