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

Side by Side Diff: components/memory_pressure/memory_pressure_listener.h

Issue 1548113002: Switch to standard integer types in components/, part 2 of 4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: gn Created 4 years, 12 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
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 // MemoryPressureListener provides static APIs for handling memory pressure on 5 // MemoryPressureListener provides static APIs for handling memory pressure on
6 // platforms that have such signals (Android, ChromeOS, Mac and Windows). When 6 // platforms that have such signals (Android, ChromeOS, Mac and Windows). When
7 // such signals are received the app will try to discard buffers that aren't 7 // such signals are received the app will try to discard buffers that aren't
8 // deemed essential (individual modules will implement their own policy). 8 // deemed essential (individual modules will implement their own policy).
9 9
10 #ifndef COMPONENTS_MEMORY_PRESSURE_MEMORY_PRESSURE_LISTENER_H_ 10 #ifndef COMPONENTS_MEMORY_PRESSURE_MEMORY_PRESSURE_LISTENER_H_
11 #define COMPONENTS_MEMORY_PRESSURE_MEMORY_PRESSURE_LISTENER_H_ 11 #define COMPONENTS_MEMORY_PRESSURE_MEMORY_PRESSURE_LISTENER_H_
12 12
13 #include "base/base_export.h" 13 #include "base/base_export.h"
14 #include "base/basictypes.h"
15 #include "base/callback.h" 14 #include "base/callback.h"
15 #include "base/macros.h"
16 #include "build/build_config.h"
16 17
17 // ChromeOS and Linux operating systems will be added to this as they are 18 // ChromeOS and Linux operating systems will be added to this as they are
18 // implemented. 19 // implemented.
19 #if defined(OS_WIN) 20 #if defined(OS_WIN)
20 #define MEMORY_PRESSURE_IS_POLLING 21 #define MEMORY_PRESSURE_IS_POLLING
21 #endif 22 #endif
22 23
23 namespace memory_pressure { 24 namespace memory_pressure {
24 25
25 // To start listening, create a new instance, passing a callback to a 26 // To start listening, create a new instance, passing a callback to a
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 void Notify(MemoryPressureLevel memory_pressure_level); 84 void Notify(MemoryPressureLevel memory_pressure_level);
84 85
85 MemoryPressureCallback callback_; 86 MemoryPressureCallback callback_;
86 87
87 DISALLOW_COPY_AND_ASSIGN(MemoryPressureListener); 88 DISALLOW_COPY_AND_ASSIGN(MemoryPressureListener);
88 }; 89 };
89 90
90 } // namespace memory_pressure 91 } // namespace memory_pressure
91 92
92 #endif // COMPONENTS_MEMORY_PRESSURE_MEMORY_PRESSURE_LISTENER_H_ 93 #endif // COMPONENTS_MEMORY_PRESSURE_MEMORY_PRESSURE_LISTENER_H_
OLDNEW
« no previous file with comments | « components/memory_pressure/memory_pressure_calculator.h ('k') | components/memory_pressure/memory_pressure_stats_collector.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698