mirror of
https://github.com/roytam1/palemoon27.git
synced 2026-05-26 14:30:27 +00:00
1d0f42f44e
- Bug 1182960 (part 1) - Use nsTHashtable::Iterator in toolkit/components/telemetry/. r=mak. (ac5c34f3c) - Bug 1182960 (part 1) - Use nsTHashtable::Iterator in toolkit/components/telemetry/. r=mak. (79ea05add) - Bug 1182960 (part 2) - Use nsTHashtable::Iterator in toolkit/components/places/. r=mak. (5a059ff2d) - Bug 1182408 - Part 1: Move permission key checks out of loop. r=ehsan (a646bbe2e) - Bug 1182408 - Part 2: Use nsTHashTable::Iterator in nsPermissionManager. r=ehsan (02fe874ca) - Bug 1182408 - Part 3: Use nsTHashTable::Iterator in mozPersonalDictionary. r=ehsan (27c2dc15a) - Bug 1182961 (part 4, attempt 2) - Use nsTHashtable::Iterator in CacheFileHandles. r=michal. (79059d3e9) - Bug 1155169 - Avoid restoring the same cookie twice if the previous version of the cookie is not stale; r=jdmv (1353ef2d0) - Bug 1182961 (part 5, attempt 2) - Use nsTHashtable::Iterator in nsCookieService. r=michal. (0574f8e65) - Bug 1169880 - Recompute image visibility on a timer if layout or style flushes have occurred. r=tn (badefadbf) - Bug 1179939 - Avoid crash if we destroy the pres context during flushing style or layout. r=roc (9047cb706) - Bug 1182962 (part 3) - Use nsTHashtable::Iterator in gfxPlatformFontList. r=jdaggett. (73fb6b761) - Bug 1168299 - Break out style struct memory usage reporting from pres-shell. r=njn (aa29834de) - Bug 1182963 - Use nsTHashTable::Iterator in nsPresArena. r=njn (c4a24e5d7) - Bug 990974 - Slightly change how the caret clip works. r=roc Instead of looking at the caret's rect and determining whether we should clip it to the real content box clip or not at all, we just always clip it, but to a slightly bigger rect. In the cases that the caret was completely visible before, it'll still be completely visible with this change. However, in the cases that we did decide to clip before this patch, the result can be slightly different now: Before this patch, whenever the caret was partially clipped, it was partially clipped to the true content clip rect, but with this patch, the caret can be partially clipped to the slightly larger clip rect. (f62879687) - Bug 990974 - When using display ports, don't clip the painted contents to the content box clip. r=roc (26482c741) - Bug 990974 - Add a flag to ComputeFrameMetrics so that a different clip can be returned for the caret and non-caret content. r=roc (0d6027caa) - Bug 990974 - Give PaintedLayerDataTree a generic way of restricting a PaintedLayer to exactly one display item. r=roc (9f59f5bff) - Bug 990974 - Treat carets in async scrolled scrollframes differently from non-caret content. r=roc (ffdb9b629) - Bug 1141089 - Add more asserts for DisplayItemData, trying to catch whether we're accessing deleted instances. r=roc (e70921c98) - Bug 1178745 - Move some code around. r=roc (cd1ea1cf1) - Bug 1178745 - Respect scroll clips when flattening. r=roc (05621c6b7) - Bug 1073219 - Use a simple RAII struct instead of nsRefPtr to manage mLayerCount for MaskLayerImageKey. r=dholbert (eb78205ef) - Bug 1178745 - Add an nsIScrollableFrame API for getting the scroll clip. r=roc (a95a34deb)
96 lines
2.5 KiB
C++
96 lines
2.5 KiB
C++
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
|
|
/* 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/. */
|
|
|
|
#ifndef nsArenaMemoryStats_h
|
|
#define nsArenaMemoryStats_h
|
|
|
|
#include "mozilla/Assertions.h"
|
|
#include "mozilla/PodOperations.h"
|
|
|
|
class nsTabSizes {
|
|
public:
|
|
enum Kind {
|
|
DOM, // DOM stuff.
|
|
Style, // Style stuff.
|
|
Other // Everything else.
|
|
};
|
|
|
|
nsTabSizes() { mozilla::PodZero(this); }
|
|
|
|
void add(Kind kind, size_t n)
|
|
{
|
|
switch (kind) {
|
|
case DOM: mDom += n; break;
|
|
case Style: mStyle += n; break;
|
|
case Other: mOther += n; break;
|
|
default: MOZ_CRASH("bad nsTabSizes kind");
|
|
}
|
|
}
|
|
|
|
size_t mDom;
|
|
size_t mStyle;
|
|
size_t mOther;
|
|
};
|
|
|
|
#define FRAME_ID_STAT_FIELD(classname) mArena##classname
|
|
|
|
struct nsArenaMemoryStats {
|
|
#define FOR_EACH_SIZE(macro) \
|
|
macro(Other, mLineBoxes) \
|
|
macro(Style, mRuleNodes) \
|
|
macro(Style, mStyleContexts) \
|
|
macro(Style, mStyleStructs) \
|
|
macro(Other, mOther)
|
|
|
|
nsArenaMemoryStats()
|
|
:
|
|
#define ZERO_SIZE(kind, mSize) mSize(0),
|
|
FOR_EACH_SIZE(ZERO_SIZE)
|
|
#undef ZERO_SIZE
|
|
#define FRAME_ID(classname) FRAME_ID_STAT_FIELD(classname)(),
|
|
#include "nsFrameIdList.h"
|
|
#undef FRAME_ID
|
|
dummy()
|
|
{}
|
|
|
|
void addToTabSizes(nsTabSizes *sizes) const
|
|
{
|
|
#define ADD_TO_TAB_SIZES(kind, mSize) sizes->add(nsTabSizes::kind, mSize);
|
|
FOR_EACH_SIZE(ADD_TO_TAB_SIZES)
|
|
#undef ADD_TO_TAB_SIZES
|
|
#define FRAME_ID(classname) \
|
|
sizes->add(nsTabSizes::Other, FRAME_ID_STAT_FIELD(classname));
|
|
#include "nsFrameIdList.h"
|
|
#undef FRAME_ID
|
|
}
|
|
|
|
size_t getTotalSize() const
|
|
{
|
|
size_t total = 0;
|
|
#define ADD_TO_TOTAL_SIZE(kind, mSize) total += mSize;
|
|
FOR_EACH_SIZE(ADD_TO_TOTAL_SIZE)
|
|
#undef ADD_TO_TOTAL_SIZE
|
|
#define FRAME_ID(classname) \
|
|
total += FRAME_ID_STAT_FIELD(classname);
|
|
#include "nsFrameIdList.h"
|
|
#undef FRAME_ID
|
|
return total;
|
|
}
|
|
|
|
#define DECL_SIZE(kind, mSize) size_t mSize;
|
|
FOR_EACH_SIZE(DECL_SIZE)
|
|
#undef DECL_SIZE
|
|
#define FRAME_ID(classname) size_t FRAME_ID_STAT_FIELD(classname);
|
|
#include "nsFrameIdList.h"
|
|
#undef FRAME_ID
|
|
int dummy; // present just to absorb the trailing comma from FRAME_ID in the
|
|
// constructor
|
|
|
|
#undef FOR_EACH_SIZE
|
|
};
|
|
|
|
#endif // nsArenaMemoryStats_h
|