Commit 765bd749 authored by Qiang Xu's avatar Qiang Xu Committed by Commit Bot

cros: remove ash-enable-display-move-window-accels flag

Feature is landed in M66. Now we can remove the flag in M69.

Bug: 778438
Test: manual
Cq-Include-Trybots: luci.chromium.try:closure_compilation
Change-Id: Icd56cda2c4cd61677f4724c11ccf4b946eae24ae
Reviewed-on: https://chromium-review.googlesource.com/1113077Reviewed-by: default avatarSteven Bennetts <stevenjb@chromium.org>
Reviewed-by: default avatarMitsuru Oshima <oshima@chromium.org>
Commit-Queue: Qiang Xu <warx@google.com>
Cr-Commit-Position: refs/heads/master@{#570284}
parent 32c040d6
......@@ -9,7 +9,6 @@
#include <array>
#include "ash/accessibility/accessibility_controller.h"
#include "ash/public/cpp/ash_features.h"
#include "ash/shell.h"
#include "ash/wm/mru_window_tracker.h"
#include "ash/wm/window_util.h"
......@@ -47,8 +46,6 @@ aura::Window* GetTargetWindow() {
} // namespace
bool CanHandleMoveActiveWindowBetweenDisplays() {
if (!features::IsDisplayMoveWindowAccelsEnabled())
return false;
display::DisplayManager* display_manager = Shell::Get()->display_manager();
// Accelerators to move window between displays on unified desktop mode and
// mirror mode is disabled.
......
......@@ -8,7 +8,6 @@
#include "ash/accelerators/accelerator_table.h"
#include "ash/accessibility/accessibility_controller.h"
#include "ash/accessibility/test_accessibility_controller_client.h"
#include "ash/public/cpp/ash_features.h"
#include "ash/root_window_controller.h"
#include "ash/screen_util.h"
#include "ash/shelf/shelf_constants.h"
......@@ -20,7 +19,6 @@
#include "ash/wm/wm_event.h"
#include "base/command_line.h"
#include "base/macros.h"
#include "base/test/scoped_feature_list.h"
#include "ui/aura/test/test_windows.h"
#include "ui/display/display.h"
#include "ui/display/display_layout.h"
......@@ -69,24 +67,7 @@ void PerformMoveWindowAccel() {
} // namespace
class DisplayMoveWindowUtilTest : public AshTestBase {
protected:
DisplayMoveWindowUtilTest() = default;
~DisplayMoveWindowUtilTest() override = default;
// AshTestBase:
void SetUp() override {
// Explicitly enable the display move window accels feature for the tests.
scoped_feature_list_.InitAndEnableFeature(
features::kDisplayMoveWindowAccels);
AshTestBase::SetUp();
}
private:
base::test::ScopedFeatureList scoped_feature_list_;
DISALLOW_COPY_AND_ASSIGN(DisplayMoveWindowUtilTest);
};
using DisplayMoveWindowUtilTest = AshTestBase;
TEST_F(DisplayMoveWindowUtilTest, SingleDisplay) {
aura::Window* window =
......
......@@ -27,11 +27,9 @@ class PersistentWindowControllerTest : public AshTestBase {
// AshTestBase:
void SetUp() override {
// Explicitly enable persistent window bounds and displays move window
// accels features for the tests.
scoped_feature_list_.InitWithFeatures(
{features::kPersistentWindowBounds, features::kDisplayMoveWindowAccels},
{});
// Explicitly enable persistent window bounds feature for the tests.
scoped_feature_list_.InitAndEnableFeature(
features::kPersistentWindowBounds);
AshTestBase::SetUp();
}
......
......@@ -10,9 +10,6 @@
namespace ash {
namespace features {
const base::Feature kDisplayMoveWindowAccels{"DisplayMoveWindowAccels",
base::FEATURE_ENABLED_BY_DEFAULT};
const base::Feature kDockedMagnifier{"DockedMagnifier",
base::FEATURE_ENABLED_BY_DEFAULT};
......@@ -50,10 +47,6 @@ const base::Feature kTrilinearFiltering{"TrilinearFiltering",
const base::Feature kViewsLogin{"ViewsLogin", base::FEATURE_ENABLED_BY_DEFAULT};
bool IsDisplayMoveWindowAccelsEnabled() {
return base::FeatureList::IsEnabled(kDisplayMoveWindowAccels);
}
bool IsDockedMagnifierEnabled() {
return base::FeatureList::IsEnabled(kDockedMagnifier);
}
......
......@@ -11,11 +11,6 @@
namespace ash {
namespace features {
// Enables the keyboard shortcut to move active window between displays.
// TODO(warx): Remove this after the feature is fully launched.
// https://crbug.com/773749.
ASH_PUBLIC_EXPORT extern const base::Feature kDisplayMoveWindowAccels;
// Enables the docked (a.k.a. picture-in-picture) magnifier.
// TODO(afakhry): Remove this after the feature is fully launched.
// https://crbug.com/709824.
......@@ -69,8 +64,6 @@ ASH_PUBLIC_EXPORT extern const base::Feature kTrilinearFiltering;
// Enables views login.
ASH_PUBLIC_EXPORT extern const base::Feature kViewsLogin;
ASH_PUBLIC_EXPORT bool IsDisplayMoveWindowAccelsEnabled();
ASH_PUBLIC_EXPORT bool IsDockedMagnifierEnabled();
ASH_PUBLIC_EXPORT bool IsKeyboardShortcutViewerEnabled();
......
......@@ -59,7 +59,6 @@ ASH_PUBLIC_EXPORT extern const char kShowWebUiLogin[];
ASH_PUBLIC_EXPORT extern const char kSuppressMessageCenterPopups[];
ASH_PUBLIC_EXPORT extern const char kTouchscreenUsableWhileScreenOff[];
ASH_PUBLIC_EXPORT bool IsDisplayMoveWindowAccelsEnabled();
ASH_PUBLIC_EXPORT bool IsSidebarEnabled();
ASH_PUBLIC_EXPORT bool IsTrilinearFilteringEnabled();
ASH_PUBLIC_EXPORT bool IsUsingViewsLock();
......
......@@ -3515,11 +3515,6 @@ const FeatureEntry kFeatureEntries[] = {
FEATURE_VALUE_TYPE(features::kStopInBackground)},
#if defined(OS_CHROMEOS)
{"ash-enable-display-move-window-accels",
flag_descriptions::kAshEnableDisplayMoveWindowAccelsName,
flag_descriptions::kAshEnableDisplayMoveWindowAccelsDescription, kOsCrOS,
FEATURE_VALUE_TYPE(ash::features::kDisplayMoveWindowAccels)},
{"ash-enable-keyboard-shortcut-viewer",
flag_descriptions::kAshEnableKeyboardShortcutViewerName,
flag_descriptions::kAshEnableKeyboardShortcutViewerDescription, kOsCrOS,
......
......@@ -289,15 +289,6 @@ function isVoiceInteractionEnabled() {
return loadTimeData.getBoolean('voiceInteractionEnabled');
}
/**
* Tests if accelerators for moving window between displays are enabled.
* @return {boolean} True if accelerators for moving window between displays
* feature is enabled.
*/
function isDisplayMoveWindowAccelsEnabled() {
return loadTimeData.getBoolean('displayMoveWindowAccelsEnabled');
}
/**
* Converts a single hex number to a character.
* @param {string} hex Hexadecimal string.
......@@ -615,14 +606,6 @@ function update(modifiers, normModifiers) {
if (shortcutId == 'keyboardOverlayToggleDictation')
continue;
if ((shortcutId == 'keyboardOverlayMoveWindowToBelowDisplay' ||
shortcutId == 'keyboardOverlayMoveWindowToLeftDisplay' ||
shortcutId == 'keyboardOverlayMoveWindowToRightDisplay' ||
shortcutId == 'keyboardOverlayMoveWindowToAboveDisplay') &&
!isDisplayMoveWindowAccelsEnabled()) {
continue;
}
if (shortcutId) {
classes.push('is-shortcut');
classes.push('keyboard-overlay-shortcut-key-background');
......
......@@ -8,7 +8,6 @@
#include <memory>
#include "ash/public/cpp/ash_features.h"
#include "ash/shell.h"
#include "base/bind.h"
#include "base/bind_helpers.h"
......@@ -341,8 +340,6 @@ content::WebUIDataSource* CreateKeyboardOverlayUIHTMLSource(Profile* profile) {
TopRowKeysAreFunctionKeys(profile));
source->AddBoolean("voiceInteractionEnabled",
chromeos::switches::IsVoiceInteractionEnabled());
source->AddBoolean("displayMoveWindowAccelsEnabled",
ash::features::IsDisplayMoveWindowAccelsEnabled());
source->AddBoolean("keyboardOverlayUsesLayout2",
ui::DeviceUsesKeyboardLayout2());
ash::Shell* shell = ash::Shell::Get();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment