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

Unified Diff: ui/aura/env.h

Issue 2714763002: Change FocusSynchronizer to maintain active focus client and window. (Closed)
Patch Set: fix crash in aura_test_helper tear down Created 3 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
Index: ui/aura/env.h
diff --git a/ui/aura/env.h b/ui/aura/env.h
index f843ca05ff1bc3979b5d2867ef6802eb429d864d..3c213f16d3980509747d9f5447c1d55008f34415 100644
--- a/ui/aura/env.h
+++ b/ui/aura/env.h
@@ -21,11 +21,6 @@ class ContextFactoryPrivate;
class PlatformEventSource;
}
namespace aura {
-
-namespace client {
-class FocusClient;
-}
-
namespace test {
class EnvTestHelper;
}
@@ -101,17 +96,7 @@ class AURA_EXPORT Env : public ui::EventTarget, public base::SupportsUserData {
void SetWindowTreeClient(WindowTreeClient* window_tree_client);
bool HasWindowTreeClient() const { return window_tree_client_ != nullptr; }
- // Sets the active FocusClient and the window the FocusClient is associated
- // with. |window| is not necessarily the window that actually has focus.
- // |window| may be null, which indicates all windows share a FocusClient.
- void SetActiveFocusClient(client::FocusClient* focus_client,
- Window* focus_client_root);
- client::FocusClient* active_focus_client() { return active_focus_client_; }
- Window* active_focus_client_root() { return active_focus_client_root_; }
-
private:
- class ActiveFocusClientWindowObserver;
-
friend class test::EnvTestHelper;
friend class MusMouseLocationUpdater;
friend class Window;
@@ -130,8 +115,6 @@ class AURA_EXPORT Env : public ui::EventTarget, public base::SupportsUserData {
// Invoked by WindowTreeHost when it is activated. Notifies observers.
void NotifyHostActivated(WindowTreeHost* host);
- void OnActiveFocusClientWindowDestroying();
-
// Overridden from ui::EventTarget:
bool CanAcceptEvent(const ui::Event& event) override;
ui::EventTarget* GetParentTarget() override;
@@ -160,11 +143,6 @@ class AURA_EXPORT Env : public ui::EventTarget, public base::SupportsUserData {
ui::ContextFactory* context_factory_;
ui::ContextFactoryPrivate* context_factory_private_;
- Window* active_focus_client_root_ = nullptr;
- client::FocusClient* active_focus_client_ = nullptr;
- std::unique_ptr<ActiveFocusClientWindowObserver>
- active_focus_client_window_observer_;
-
DISALLOW_COPY_AND_ASSIGN(Env);
};

Powered by Google App Engine
This is Rietveld 408576698