Commit Graph

319 Commits

Author SHA1 Message Date
Joachim Priesner 71a4ac73e2 comctl32: Treeview: Set visible = TRUE when deleting first visible item.
This fixes a crash when deleting the first visible item if it has
visibleOrder < 0 and thus the ISVISIBLE macro returns false
(this happens when both insertion and deletion happened while
bRedraw == false).

Signed-off-by: Joachim Priesner <joachim.priesner@web.de>
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-19 21:10:54 +09:00
Joachim Priesner 4c799937f6 comctl32: Treeview: Fix crash when deleting the first visible item while bRedraw == false.
Signed-off-by: Joachim Priesner <joachim.priesner@web.de>
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-01 21:04:42 +09:00
Joachim Priesner f0b6584da6 comctl32: Fix comments explaining visibleOrder and firstVisible.
Hopefully this clears up the confusion between a) visible as in "all
ancestors are expanded" and b) visible as in "within the part of the
tree that is displayed on the screen".

Also, the claim that firstVisible has visible order 0 was false.

Signed-off-by: Joachim Priesner <joachim.priesner@web.de>
Signed-off-by: Nikolay Sivov<nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-01 17:53:38 +09:00
Nikolay Sivov 1d19eb15d4 comctl32: Item with negative cChildren acts as if it actually had children.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-11-24 00:25:04 +09:00
Nikolay Sivov 8d0f060f3b comctl32/treeview: Use consistent format for hex values in traces.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-11-24 00:25:03 +09:00
Bruno Jesus 2f5c0b9321 comctl32: Respect an assert in TREEVIEW_RemoveAllChildren.
Signed-off-by: Bruno Jesus <00cpxxx@gmail.com>
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-11-24 00:25:02 +09:00
Nikolay Sivov 60fedd23f9 comctl32: Protect TVM_GETITEM from invalid item pointers.
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-11-05 00:03:34 +09:00
Alex Henrie ad49634bbe comctl32: Send WM_NOTIFY when expanding ancestors of the new selection. 2015-05-18 19:59:27 +09:00
Alex Henrie 36297f2cb0 comctl32: Do not send WM_NOTIFY if selecting an already-selected item. 2015-05-18 19:59:27 +09:00
Alex Henrie a0ebe244c4 comctl32: Close previously selected treeview item at common ancestor.
Also, send WM_NOTIFY mesages when collapsing the previous selection and
expanding the new one.
2015-05-18 19:59:27 +09:00
Francois Gouget c04cc70f7d comctl32: Remove unneeded NONAMELESSSTRUCT directives. 2015-03-09 22:06:23 +09:00
Nikolay Sivov a7fb6c89b3 comctl32/treeview: Send TVN_KEYDOWN in response of WM_KEYDOWN. 2014-06-11 19:15:19 +02:00
Nikolay Sivov 3f8bda94fc comctl32/treeview: Simplify sending parent WM_NOTIFY notifications. 2014-06-11 19:15:18 +02:00
Nikolay Sivov a709e3f98d comctl32/treeview: Added a test for NM_RETURN. 2014-05-12 13:51:44 +02:00
Christoph von Wittich 4cc503d164 comctl32/treeview: Notify the parent on a return key press. 2014-05-07 18:57:31 +02:00
Nikolay Sivov fe3f12335d comctl32/treeview: Restore hdc before CDDS_ITEMPOSTPAINT. 2014-04-21 11:09:51 +02:00
Andrey Gusev be367393c9 Assorted typos fixes. 2014-01-13 17:37:42 +01:00
Piotr Caban 7b1ff882d1 comctl32: Initialize treeview checkboxes in WM_PAINT when TVS_CHECKBOXES was passed during control creation. 2013-10-31 18:24:25 +01:00
Piotr Caban 40648ddfd5 comctl32: Initialize himlState list in TREEVIEW_Paint when TVS_CHECKBOXES flag is set. 2013-10-31 18:24:23 +01:00
Daniel Jelinski 0ba24895f6 comctl32: Do not rearrange treeview when collapsing already collapsed item. 2013-08-16 11:55:23 +02:00
Nikolay Sivov 6f15ca3e47 comctl32: Paint item as selected if it's TVIS_SELECTED and also focused. 2013-05-09 19:24:21 +02:00
Ken Thomases c5858c16a6 comctl32: Improve mouse wheel scrolling in treeview control.
Allow fractions of WHEEL_DELTA to scroll fractions of SPI_GETWHEELSCROLLLINES,
although still only whole lines.  Keep the remainder and apply it to next
event if in same direction.
2013-02-11 11:46:10 +01:00
Andrew Talbot 85ebbadcb0 comctl32: Indentation fix. 2012-12-17 11:47:39 +01:00
Nikolay Sivov fbd7f8813f comctl32: Fix font style when item is bold and hovered in track mode. 2012-12-11 20:45:41 +01:00
Andrew Talbot 441780b2f1 comctl32: Indentation fix. 2012-12-11 12:03:41 +01:00
Daniel Jelinski 0b6cf6e46a comctl32: Fix notifications and return value when collapsing already collapsed node. 2012-10-16 11:38:27 +02:00
Daniel Jelinski 9933f5e446 comctl32: Do not send TVN_ITEMEXPANDING when expanding item with no children. 2012-10-16 11:37:58 +02:00
Daniel Jelinski 06d284cabb comctl32: Allow expanding/collapsing treeview nodes multiple times. 2012-10-15 15:25:38 +02:00
Christian Costa 55ff254986 comctl32: Invalid format returned by NF_QUERY defaults to ANSI in treeview. 2012-09-24 16:38:16 +02:00
Michael Stefaniuc 175eaf1074 comctl32: Avoid TRUE:FALSE conditional expressions. 2012-08-13 17:29:01 +02:00
Daniel Jelinski baed448fc7 comctl32/treeview: Fix the position reported by WM_CONTEXTMENU. 2012-07-17 13:09:43 +02:00
Daniel Jelinski 067d528855 comctl32/treeview: Send WM_CONTEXTMENU only to parent window. 2012-07-17 13:09:43 +02:00
Daniel Jelinski 5e86d84337 comctl32/treeview: Inlined TREEVIEW_RButtonUp. 2012-07-17 13:09:43 +02:00
Daniel Jelinski c7212f8262 comctl32/treeview: Send WM_CONTEXTMENU everywhere, not just over items. 2012-07-17 13:09:42 +02:00
Daniel Jelinski 602dea1e12 comctl32/treeview: Fix NM_RCLICK behavior. 2012-07-17 13:09:42 +02:00
Daniel Jelinski 7e56fd38d8 comctl32/treeview: Clean up mouse tracking code. 2012-07-17 13:09:42 +02:00
Daniel Jelinski 1196aed33f comctl32: Allow label edit only if treeview style allows editing. 2012-06-07 16:26:25 +02:00
Nikolay Sivov 95a15a3482 comctl32: Make it possible to use TVM_GETITEM with item from another tree. 2012-05-22 17:44:00 +02:00
Nikolay Sivov 91fbef88bf comctl32: Never release state image list. 2012-01-30 12:04:58 +01:00
Nikolay Sivov 1bc331f31f comctl32/treeview: Free checkbox imagelist when control is about to be killed. 2011-10-03 14:39:03 -05:00
Nikolay Sivov c13bf5a58c comctl32/treeview: Set edit box text before notification and keep it after. 2011-08-22 16:14:35 +02:00
Nikolay Sivov 7445dcee05 comctl32/treeview: Remove redundant initializer (Clang). 2011-07-04 13:41:00 +02:00
Piotr Caban f831f77515 comctl32: Use vssym32.h instead of tmschema.h. 2011-06-27 15:06:49 -05:00
Nikolay Sivov bcb98d11ba comctl32/treeview: TVM_EXPAND with TVE_TOGGLE action shouldn't always notify as it does on user input. 2011-05-25 11:54:13 +02:00
Nikolay Sivov 9bdd21cad5 comctl32/treeview: Correctly draw cut items. 2011-05-23 11:17:36 +02:00
Nikolay Sivov a1f7c09b1c comctl32/treeview: Item text should be vertically aligned. 2011-05-23 11:17:24 +02:00
Nikolay Sivov 4b741e8d2f comctl32/treeview: Always draw a '+' for TVIS_EXPANDPARTIAL state. 2011-05-23 11:17:15 +02:00
Nikolay Sivov 28169c6d55 comctl32/treeview: Get rid of wine prefixed names. 2011-05-16 16:35:30 +02:00
Nikolay Sivov 7ef4546cfb comctl32/treeview: Properly update image state index when TVS_CHECKBOXES is switched on. 2011-05-16 16:35:29 +02:00
Nikolay Sivov f9b14fda02 comctl32/treeview: Store item state supplied from TVN_GETDISPINFO handler. 2011-05-16 16:35:29 +02:00