Commit 14984a16 authored by Sergio Gómez Del Real's avatar Sergio Gómez Del Real Committed by Alexandre Julliard

riched20: ME_CheckCharOffsets() calls should only be done when tracing.

parent a60965a1
......@@ -103,6 +103,9 @@ void ME_CheckCharOffsets(ME_TextEditor *editor)
ME_DisplayItem *p = editor->pBuffer->pFirst;
int ofs = 0, ofsp = 0;
if (!TRACE_ON(richedit_check))
return;
TRACE_(richedit_check)("Checking begin\n");
if(TRACE_ON(richedit_lists))
{
......@@ -238,8 +241,7 @@ void ME_JoinRuns(ME_TextEditor *editor, ME_DisplayItem *p)
ME_Remove(pNext);
ME_DestroyDisplayItem(pNext);
ME_UpdateRunFlags(editor, &p->member.run);
if(TRACE_ON(richedit_check))
ME_CheckCharOffsets(editor);
ME_CheckCharOffsets(editor);
}
/******************************************************************************
......
......@@ -23,7 +23,6 @@
#include "editor.h"
WINE_DEFAULT_DEBUG_CHANNEL(richedit);
WINE_DECLARE_DEBUG_CHANNEL(richedit_check);
/*
* Unsolved problems:
......@@ -140,8 +139,7 @@ static ME_DisplayItem *split_run_extents(ME_WrapContext *wc, ME_DisplayItem *ite
ME_Cursor cursor = {wc->pPara, item, nVChar};
assert(item->member.run.nCharOfs != -1);
if(TRACE_ON(richedit_check))
ME_CheckCharOffsets(editor);
ME_CheckCharOffsets(editor);
run = &item->member.run;
......@@ -160,8 +158,7 @@ static ME_DisplayItem *split_run_extents(ME_WrapContext *wc, ME_DisplayItem *ite
run2->pt.x = run->pt.x+run->nWidth;
run2->pt.y = run->pt.y;
if(TRACE_ON(richedit_check))
ME_CheckCharOffsets(editor);
ME_CheckCharOffsets(editor);
TRACE("After split: %s(%d, %d), %s(%d, %d)\n",
debugstr_run( run ), run->pt.x, run->pt.y,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment