#if defined(__WXGTK20__)
// for testing
- #define wxUSE_GENERICDATAVIEWCTRL 1
+ // #define wxUSE_GENERICDATAVIEWCTRL 1
#elif defined(__WXMAC__)
#else
#define wxUSE_GENERICDATAVIEWCTRL 1
x, item_last * m_lineHeight);
}
+ bool has_focus = (FindFocus() == this);
// redraw the background for the items which are selected/current
for (unsigned int item = item_start; item < item_last; item++)
{
if (selected || item == m_currentRow)
{
int flags = selected ? (int)wxCONTROL_SELECTED : 0;
- if (item == m_currentRow)
+ if ((item == m_currentRow) && has_focus)
flags |= wxCONTROL_CURRENT;
if (m_hasFocus)
flags |= wxCONTROL_FOCUSED;