diff --git a/layout/generic/ScrollAnchorContainer.cpp b/layout/generic/ScrollAnchorContainer.cpp index 022185e17991..6a36ac5dd010 100644 --- a/layout/generic/ScrollAnchorContainer.cpp +++ b/layout/generic/ScrollAnchorContainer.cpp @@ -21,7 +21,15 @@ using namespace mozilla::dom; #define ANCHOR_LOG(...) -// #define ANCHOR_LOG(...) printf_stderr("ANCHOR: " __VA_ARGS__) +// #define ANCHOR_LOG(fmt, ...) \ +// printf_stderr("ANCHOR(%p, %s): " fmt, this, \ +// Frame() \ +// ->PresContext() \ +// ->Document() \ +// ->GetDocumentURI() \ +// ->GetSpecOrDefault() \ +// .get(), \ +// ##__VA_ARGS__) namespace mozilla { namespace layout { @@ -194,7 +202,7 @@ void ScrollAnchorContainer::SelectAnchor() { AUTO_PROFILER_LABEL("ScrollAnchorContainer::SelectAnchor", LAYOUT); ANCHOR_LOG( - "Selecting anchor for %p with scroll-port=%s.\n", this, + "Selecting anchor for with scroll-port=%s.\n", mozilla::ToString(mScrollFrame->GetVisualOptimalViewingRect()).c_str()); const nsStyleDisplay* disp = Frame()->StyleDisplay(); @@ -340,8 +348,8 @@ void ScrollAnchorContainer::ApplyAdjustments() { return; } - ANCHOR_LOG("Applying anchor adjustment of %d in %s for %p and anchor %p.\n", - logicalAdjustment, writingMode.DebugString(), this, mAnchorNode); + ANCHOR_LOG("Applying anchor adjustment of %d in %s with anchor %p.\n", + logicalAdjustment, writingMode.DebugString(), mAnchorNode); nsPoint physicalAdjustment; switch (writingMode.GetBlockDir()) {