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

Side by Side Diff: chrome/browser/memory/tab_manager_delegate_chromeos.cc

Issue 2502413005: Use aura::WindowProperty for title and name strings. (Closed)
Patch Set: Update comment Created 4 years, 1 month 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "chrome/browser/memory/tab_manager_delegate_chromeos.h" 5 #include "chrome/browser/memory/tab_manager_delegate_chromeos.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <map> 10 #include <map>
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 const uint32_t kMinVersionForKillProcess = 1; 66 const uint32_t kMinVersionForKillProcess = 1;
67 67
68 aura::client::ActivationClient* GetActivationClient() { 68 aura::client::ActivationClient* GetActivationClient() {
69 if (!ash::Shell::HasInstance()) 69 if (!ash::Shell::HasInstance())
70 return nullptr; 70 return nullptr;
71 return aura::client::GetActivationClient(ash::Shell::GetPrimaryRootWindow()); 71 return aura::client::GetActivationClient(ash::Shell::GetPrimaryRootWindow());
72 } 72 }
73 73
74 // Checks if a window renders ARC apps. 74 // Checks if a window renders ARC apps.
75 bool IsArcWindow(aura::Window* window) { 75 bool IsArcWindow(aura::Window* window) {
76 if (!window || window->name() != kExoShellSurfaceWindowName) 76 if (!window || window->GetName() != kExoShellSurfaceWindowName)
77 return false; 77 return false;
78 std::string application_id = exo::ShellSurface::GetApplicationId(window); 78 std::string application_id = exo::ShellSurface::GetApplicationId(window);
79 return base::StartsWith(application_id, kArcProcessNamePrefix, 79 return base::StartsWith(application_id, kArcProcessNamePrefix,
80 base::CompareCase::SENSITIVE); 80 base::CompareCase::SENSITIVE);
81 } 81 }
82 82
83 bool IsArcMemoryManagementEnabled() { 83 bool IsArcMemoryManagementEnabled() {
84 return base::FeatureList::IsEnabled(features::kArcMemoryManagement); 84 return base::FeatureList::IsEnabled(features::kArcMemoryManagement);
85 } 85 }
86 86
(...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after
747 } 747 }
748 priority += priority_increment; 748 priority += priority_increment;
749 } 749 }
750 750
751 if (oom_scores_to_change.size()) 751 if (oom_scores_to_change.size())
752 GetDebugDaemonClient()->SetOomScoreAdj( 752 GetDebugDaemonClient()->SetOomScoreAdj(
753 oom_scores_to_change, base::Bind(&OnSetOomScoreAdj)); 753 oom_scores_to_change, base::Bind(&OnSetOomScoreAdj));
754 } 754 }
755 755
756 } // namespace memory 756 } // namespace memory
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698