riched20: ME_CheckCharOffsets() calls should only be done when tracing.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com> Signed-off-by: Huw Davies <huw@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
a60965a156
commit
14984a169a
|
@ -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,
|
||||
|
|
Loading…
Reference in New Issue