Small fixes.
This commit is contained in:
parent
0dce5b7538
commit
39413f81c1
|
@ -425,7 +425,7 @@ static void CBPaintText(LPHEADCOMBO lphc, HDC32 hdc)
|
||||||
|
|
||||||
if( lphc->wState & CBF_EDIT )
|
if( lphc->wState & CBF_EDIT )
|
||||||
{
|
{
|
||||||
if( CB_HASSTRINGS(lphc) ) SetWindowText32A( lphc->hWndEdit, pText );
|
if( CB_HASSTRINGS(lphc) ) SetWindowText32A( lphc->hWndEdit, pText ? pText : "" );
|
||||||
if( lphc->wState & CBF_FOCUSED )
|
if( lphc->wState & CBF_FOCUSED )
|
||||||
SendMessage32A( lphc->hWndEdit, EM_SETSEL32, 0, (LPARAM)(-1));
|
SendMessage32A( lphc->hWndEdit, EM_SETSEL32, 0, (LPARAM)(-1));
|
||||||
}
|
}
|
||||||
|
@ -491,7 +491,7 @@ static void CBPaintText(LPHEADCOMBO lphc, HDC32 hdc)
|
||||||
{
|
{
|
||||||
ExtTextOut32A( hDC, rect.left + 1, rect.top + 1,
|
ExtTextOut32A( hDC, rect.left + 1, rect.top + 1,
|
||||||
ETO_OPAQUE | ETO_CLIPPED, &rect,
|
ETO_OPAQUE | ETO_CLIPPED, &rect,
|
||||||
(pText) ? pText : "" , size, NULL );
|
pText ? pText : "" , size, NULL );
|
||||||
if(lphc->wState & CBF_FOCUSED && !(lphc->wState & CBF_DROPPED))
|
if(lphc->wState & CBF_FOCUSED && !(lphc->wState & CBF_DROPPED))
|
||||||
DrawFocusRect32( hDC, &rect );
|
DrawFocusRect32( hDC, &rect );
|
||||||
}
|
}
|
||||||
|
@ -504,7 +504,8 @@ static void CBPaintText(LPHEADCOMBO lphc, HDC32 hdc)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
HeapFree( GetProcessHeap(), 0, pText );
|
if (pText)
|
||||||
|
HeapFree( GetProcessHeap(), 0, pText );
|
||||||
}
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
|
|
|
@ -262,7 +262,7 @@ TAB_InsertItem (WND *wndPtr, WPARAM32 wParam, LPARAM lParam)
|
||||||
/* post insert copy */
|
/* post insert copy */
|
||||||
if (iItem < infoPtr->uNumItem - 1) {
|
if (iItem < infoPtr->uNumItem - 1) {
|
||||||
memcpy (&infoPtr->items[iItem+1], &oldItems[iItem],
|
memcpy (&infoPtr->items[iItem+1], &oldItems[iItem],
|
||||||
(infoPtr->uNumItem - iItem) * sizeof(TAB_ITEM));
|
(infoPtr->uNumItem - iItem - 1) * sizeof(TAB_ITEM));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1001,6 +1001,11 @@ BOOL32 WINAPI HeapFree(
|
||||||
flags &= HEAP_NO_SERIALIZE;
|
flags &= HEAP_NO_SERIALIZE;
|
||||||
flags |= heapPtr->flags;
|
flags |= heapPtr->flags;
|
||||||
if (!(flags & HEAP_NO_SERIALIZE)) HeapLock( heap );
|
if (!(flags & HEAP_NO_SERIALIZE)) HeapLock( heap );
|
||||||
|
if (!ptr)
|
||||||
|
{
|
||||||
|
WARN(heap, "(%08x,%08lx,%08lx): asked to free NULL\n",
|
||||||
|
heap, flags, (DWORD)ptr );
|
||||||
|
}
|
||||||
if (!ptr || !HeapValidate( heap, HEAP_NO_SERIALIZE, ptr ))
|
if (!ptr || !HeapValidate( heap, HEAP_NO_SERIALIZE, ptr ))
|
||||||
{
|
{
|
||||||
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
|
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
|
||||||
|
|
Loading…
Reference in New Issue