mirror of
https://github.com/servo/servo.git
synced 2025-06-17 04:44:28 +00:00
This will allow reporting of memory usage by FreeType instances, which are measured in the MiBs for LayoutWorker threads. This change also makes FreeType allocations happen with jemalloc instead of the system malloc, which is a good thing. Finally, the change documents some dubiousness involving FontContextHandle.
23 lines
593 B
Rust
23 lines
593 B
Rust
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
use util::mem::HeapSizeOf;
|
|
|
|
#[derive(Clone)]
|
|
pub struct FontContextHandle {
|
|
ctx: ()
|
|
}
|
|
|
|
impl FontContextHandle {
|
|
// this is a placeholder until NSFontManager or whatever is bound in here.
|
|
pub fn new() -> FontContextHandle {
|
|
FontContextHandle { ctx: () }
|
|
}
|
|
}
|
|
|
|
impl HeapSizeOf for FontContextHandle {
|
|
fn heap_size_of_children(&self) -> usize {
|
|
0
|
|
}
|
|
}
|