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

Side by Side Diff: chrome/browser/ui/panels/detached_panel_browsertest.cc

Issue 368163004: Reenable most panel interactive_ui_tests on Linux (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/message_loop/message_loop.h" 5 #include "base/message_loop/message_loop.h"
6 #include "chrome/browser/ui/panels/base_panel_browser_test.h" 6 #include "chrome/browser/ui/panels/base_panel_browser_test.h"
7 #include "chrome/browser/ui/panels/detached_panel_collection.h" 7 #include "chrome/browser/ui/panels/detached_panel_collection.h"
8 #include "chrome/browser/ui/panels/native_panel.h" 8 #include "chrome/browser/ui/panels/native_panel.h"
9 #include "chrome/browser/ui/panels/panel.h" 9 #include "chrome/browser/ui/panels/panel.h"
10 #include "chrome/browser/ui/panels/panel_manager.h" 10 #include "chrome/browser/ui/panels/panel_manager.h"
(...skipping 23 matching lines...) Expand all
34 // the top if the stacking mode is enabled. 34 // the top if the stacking mode is enabled.
35 if (!PanelManager::IsPanelStackingEnabled()) 35 if (!PanelManager::IsPanelStackingEnabled())
36 EXPECT_EQ(bounds.y(), panel->GetBounds().y()); 36 EXPECT_EQ(bounds.y(), panel->GetBounds().y());
37 EXPECT_EQ(bounds.width(), panel->GetBounds().width()); 37 EXPECT_EQ(bounds.width(), panel->GetBounds().width());
38 EXPECT_EQ(bounds.height(), panel->GetBounds().height()); 38 EXPECT_EQ(bounds.height(), panel->GetBounds().height());
39 EXPECT_FALSE(panel->IsAlwaysOnTop()); 39 EXPECT_FALSE(panel->IsAlwaysOnTop());
40 40
41 EXPECT_TRUE(panel_testing->IsButtonVisible(panel::CLOSE_BUTTON)); 41 EXPECT_TRUE(panel_testing->IsButtonVisible(panel::CLOSE_BUTTON));
42 // The minimize button will not be shown on some Linux desktop environment 42 // The minimize button will not be shown on some Linux desktop environment
43 // that does not support system minimize. 43 // that does not support system minimize.
44 if (PanelManager::CanUseSystemMinimize()) 44 if (PanelManager::CanUseSystemMinimize() &&
45 PanelManager::IsPanelStackingEnabled()) {
45 EXPECT_TRUE(panel_testing->IsButtonVisible(panel::MINIMIZE_BUTTON)); 46 EXPECT_TRUE(panel_testing->IsButtonVisible(panel::MINIMIZE_BUTTON));
46 else 47 } else {
47 EXPECT_FALSE(panel_testing->IsButtonVisible(panel::MINIMIZE_BUTTON)); 48 EXPECT_FALSE(panel_testing->IsButtonVisible(panel::MINIMIZE_BUTTON));
49 }
48 EXPECT_FALSE(panel_testing->IsButtonVisible(panel::RESTORE_BUTTON)); 50 EXPECT_FALSE(panel_testing->IsButtonVisible(panel::RESTORE_BUTTON));
49 51
50 EXPECT_EQ(panel::RESIZABLE_ALL, panel->CanResizeByMouse()); 52 EXPECT_EQ(panel::RESIZABLE_ALL, panel->CanResizeByMouse());
51 53
52 EXPECT_EQ(panel::ALL_ROUNDED, panel_testing->GetWindowCornerStyle()); 54 EXPECT_EQ(panel::ALL_ROUNDED, panel_testing->GetWindowCornerStyle());
53 55
54 Panel::AttentionMode expected_attention_mode = 56 Panel::AttentionMode expected_attention_mode =
55 static_cast<Panel::AttentionMode>(Panel::USE_PANEL_ATTENTION | 57 static_cast<Panel::AttentionMode>(Panel::USE_PANEL_ATTENTION |
56 Panel::USE_SYSTEM_ATTENTION); 58 Panel::USE_SYSTEM_ATTENTION);
57 EXPECT_EQ(expected_attention_mode, panel->attention_mode()); 59 EXPECT_EQ(expected_attention_mode, panel->attention_mode());
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 247
246 // Panel should not be shown on full-screen mode. 248 // Panel should not be shown on full-screen mode.
247 EXPECT_FALSE(panel_testing->IsWindowVisible()); 249 EXPECT_FALSE(panel_testing->IsWindowVisible());
248 250
249 // Panel should become visible when leaving full-screen mode. 251 // Panel should become visible when leaving full-screen mode.
250 mock_display_settings_provider()->EnableFullScreenMode(false); 252 mock_display_settings_provider()->EnableFullScreenMode(false);
251 EXPECT_TRUE(panel_testing->IsWindowVisible()); 253 EXPECT_TRUE(panel_testing->IsWindowVisible());
252 254
253 PanelManager::GetInstance()->CloseAll(); 255 PanelManager::GetInstance()->CloseAll();
254 } 256 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/panels/panel_browsertest.cc » ('j') | chrome/browser/ui/panels/panel_browsertest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698