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

Side by Side Diff: components/html_viewer/discardable_memory_allocator.h

Issue 1099303002: Move html_viewer from mojo/services to components. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 8 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 #ifndef MOJO_SERVICES_HTML_VIEWER_DISCARDABLE_MEMORY_ALLOCATOR_H_ 5 #ifndef COMPONENTS_HTML_VIEWER_DISCARDABLE_MEMORY_ALLOCATOR_H_
6 #define MOJO_SERVICES_HTML_VIEWER_DISCARDABLE_MEMORY_ALLOCATOR_H_ 6 #define COMPONENTS_HTML_VIEWER_DISCARDABLE_MEMORY_ALLOCATOR_H_
7 7
8 #include <list> 8 #include <list>
9 9
10 #include "base/memory/discardable_memory_allocator.h" 10 #include "base/memory/discardable_memory_allocator.h"
11 11
12 namespace html_viewer { 12 namespace html_viewer {
13 13
14 // A discarable memory allocator which will unallocate chunks on new 14 // A discarable memory allocator which will unallocate chunks on new
15 // allocations. 15 // allocations.
16 class DiscardableMemoryAllocator : public base::DiscardableMemoryAllocator { 16 class DiscardableMemoryAllocator : public base::DiscardableMemoryAllocator {
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 51
52 // A linked list of unlocked allocated chunks so that the tail is most 52 // A linked list of unlocked allocated chunks so that the tail is most
53 // recently accessed chunks. 53 // recently accessed chunks.
54 std::list<OwnedMemoryChunk*> live_unlocked_chunks_; 54 std::list<OwnedMemoryChunk*> live_unlocked_chunks_;
55 55
56 DISALLOW_COPY_AND_ASSIGN(DiscardableMemoryAllocator); 56 DISALLOW_COPY_AND_ASSIGN(DiscardableMemoryAllocator);
57 }; 57 };
58 58
59 } // namespace html_viewer 59 } // namespace html_viewer
60 60
61 #endif // MOJO_SERVICES_HTML_VIEWER_DISCARDABLE_MEMORY_ALLOCATOR_H_ 61 #endif // COMPONENTS_HTML_VIEWER_DISCARDABLE_MEMORY_ALLOCATOR_H_
OLDNEW
« no previous file with comments | « components/html_viewer/blink_url_request_type_converters.cc ('k') | components/html_viewer/discardable_memory_allocator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698