Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect return value and type #1491

Open
wants to merge 1 commit into
base: docs
Choose a base branch
from

Conversation

iPhilip
Copy link
Contributor

@iPhilip iPhilip commented Apr 7, 2023

The documentation for this and the macros below display an incorrect return value and type. Those parts of the documentation are not accessible through this page so I added (See Proposed Changes) to the text in order to submit these proposed changes. Please ignore that string.

The type is stated as void. It should be HTREEITEM.

The Return value is stated as

None

Based on this parallel documentation page, it could/should be

The handle to the item indicates success. NULL indicates failure.

The other macros that should be corrected in a similar way are:

  1. TreeView_GetDropHilight
  2. TreeView_GetFirstVisible
  3. TreeView_GetLastVisible
  4. TreeView_GetNextItem
  5. TreeView_GetNextSelected
  6. TreeView_GetNextSibling
  7. TreeView_GetNextVisible
  8. TreeView_GetPrevSibling
  9. TreeView_GetPrevVisible
  10. TreeView_GetSelection

I hope the above makes sense and that this is the right way to submit these changes. I am still learning...

The documentation for this and the macros below show an incorrect return value and type. This part of the documentation is not accessible through this page so I added **(See Proposed Changes)** to the text in order to submit these proposed changes.

The type is stated as `void`. It should be `HTREEITEM`.
The Return value is stated as `None`. It should be `The handle to the item indicates success. **NULL** indicates failure.`

The other macros that are affected by this are:
TreeView_GetDropHilight - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getdrophilight
TreeView_GetFirstVisible - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getfirstvisible
TreeView_GetLastVisible - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getlastvisible
TreeView_GetNextItem - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getnextitem
TreeView_GetNextSelected - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getnextselected
TreeView_GetNextSibling - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getnextsibling
TreeView_GetNextVisible - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getnextvisible
TreeView_GetPrevSibling - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getprevsibling
TreeView_GetPrevVisible - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getprevvisible
TreeView_GetSelection - https://learn.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-treeview_getselection

I hope the above makes sense.
@prmerger-automator
Copy link

@iPhilip : Thanks for your contribution! The author(s) have been notified to review your proposed change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants