News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

listview not refreshing...

Started by dacid, September 13, 2008, 09:04:12 AM

Previous topic - Next topic

dacid

project.rc


CONTROL "",5000,"SysListView32",WS_CHILD|WS_VISIBLE|WS_BORDER|WS_TABSTOP|LVS_ALIGNLEFT|LVS_REPORT,5,14,339,105



project.asm


goes correctly to try:

.ELSEIF uMsg == WM_SIZE
.IF wParam == SIZE_MINIMIZED
invoke ShowWindow,hWnd,NULL ; SW_HIDE
invoke UpdateWindow,hWnd
.ENDIF

return from tray:

.ELSEIF uMsg==WM_SHELLNOTIFY
.IF wParam==IDI_TRAY
.IF lParam==WM_RBUTTONDOWN
invoke GetCursorPos,ADDR pt
invoke SetForegroundWindow,hWnd
invoke TrackPopupMenu,hPopupMenu,TPM_RIGHTALIGN,pt.x,pt.y,NULL,hWnd,NULL
.ELSEIF lParam==WM_LBUTTONDBLCLK
invoke ShowWindow,hWnd,SW_RESTORE
invoke SetForegroundWindow,hWnd
invoke UpdateWindow,hWnd
.ENDIF
.ENDIF



I attach a image that shows the problem...

[attachment deleted by admin]

fearless

The code you have posted looks fine, i have pretty much the same code for my traybar routines. I do recall having a similar issue with the listview when it would not draw the scrollbar correctly when scrolling, and i found out this was due to the listview being slightly bigger than the dialog window i had it on (or that it didnt like it being the exact same size, so had to nudge the size/width/height by -1) - something like that, but it did interfere with the redrawing of the listview.

One thing i dont have is the UpdateWindow call - i dont seem to need it.

Here is the rc ref of mine:
CONTROL "",IDC_LISTVIEW,"SysListView32",0x5001020D,12,88,296,46,0x00000200

Might be worth posting your entire project so that it can be examined further
Ć’earless

dacid

Fixed with "InvalidateRect". Thx for reply!