summaryrefslogtreecommitdiffstats
path: root/cc/managed_memory_policy.h
blob: eba13c316a2532be398c2b6b35844203757375e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// Copyright 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef managed_memory_policy_h
#define managed_memory_policy_h

#include "base/basictypes.h"

namespace cc {

struct ManagedMemoryPolicy {
    ManagedMemoryPolicy(size_t bytesLimitWhenVisible);
    ManagedMemoryPolicy(size_t bytesLimitWhenVisible,
                        int priorityCutoffWhenVisible,
                        size_t bytesLimitWhenNotVisible,
                        int priorityCutoffWhenNotVisible);
    bool operator==(const ManagedMemoryPolicy&) const;
    bool operator!=(const ManagedMemoryPolicy&) const;

    size_t bytesLimitWhenVisible;
    int priorityCutoffWhenVisible;
    size_t bytesLimitWhenNotVisible;
    int priorityCutoffWhenNotVisible;
};

}  // namespace cc

#endif