Re: listview: fix alignment tests
Dimitrie O. Paun wrote:
ChangeLog Use the LVCFMT_{LEFT,RIGHT,CENTER} enumeration flags properly.
/* set text alignment (leftmost column must be left-aligned) */ - if (nColumn == 0 || lpColumn->fmt & LVCFMT_LEFT) + if (nColumn == 0 || (lpColumn->fmt & LVCFMT_JUSTIFYMASK) == LVCFMT_LEFT) lphdi->fmt |= HDF_LEFT;
HDF_LEFT is also 0, so should we get rid of the first check, and only check for LVCFMT_RIGHT and LVCFMT_CENTER?
if (lpColumn->fmt & LVCFMT_BITMAP_ON_RIGHT)
-- Dimi.
Cheers, Paul.
On Fri, Jan 14, 2005 at 11:32:56AM +0100, Paul Vriens wrote:
HDF_LEFT is also 0, so should we get rid of the first check, and only check for LVCFMT_RIGHT and LVCFMT_CENTER?
Yes, you could remove it, but it will save nothing and will make the code harder to read. gcc most like optimizes it out anyway. Let's leave it in. -- Dimi.
participants (2)
-
Dimitrie O. Paun -
Paul Vriens