Old 18th June 2006, 01:55   #1
RobertStrong
Junior Member
 
Join Date: Jan 2006
Posts: 22
Components page accessibility

The treeview doesn't send accessibility events for checked / unchecked which I believe is due to it not having the TVS_CHECKBOXES style. I've set this in the ui resource for the treeview in order to get the events but then the checkbox images are incorrect when clicking on the checkbox itself though it does work fine when clicking on the text, etc. I'd just use checkboxes but I'd like to keep the selected item description functionality. Any help with this would be appreciated.

Thanks,
Ronert
RobertStrong is offline   Reply With Quote
Old 18th June 2006, 09:59   #2
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
.onSelChanged function is called when a checkbox is checked or unchecked.

-Stu
Afrow UK is offline   Reply With Quote
Old 18th June 2006, 10:11   #3
RobertStrong
Junior Member
 
Join Date: Jan 2006
Posts: 22
I tried using .onSelChange along with SectionSetFlags, SectionGetFlags, etc. to come up with a workaround without any joy. I also tried using WM_KEYDOWN 32 to send a spacebar keypress along with a few other methods. SectionGetFlags returns unselected while the checkbox displays the selected image and the dark gray selected image when it is selected.

One option may be to force the correct image for the TVITEM in .onSelChange but I'm not sure if I should even go down that path... seems a bit painful and may just not be possible. Any ideas of which route would be simplest to take?

Robert
RobertStrong is offline   Reply With Quote
Old 18th June 2006, 12:30   #4
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
As far as I can see you haven't really explained what you want to do.

-Stu
Afrow UK is offline   Reply With Quote
Old 18th June 2006, 20:34   #5
RobertStrong
Junior Member
 
Join Date: Jan 2006
Posts: 22
Hey Stu,

From the original post:
"The treeview doesn't send accessibility events for checked / unchecked which I believe is due to it not having the TVS_CHECKBOXES style."

I would like the treeview's checkbox state to work with screen readers. Currently a screen reader is unable to tell a visually imparied person whether the checkbox is checked or unchecked or for that matter that there is a checkbox.

I can get the state in a screen reader by modifying the ui resource and adding TVS_CHECKBOXES to the treeview's style. This then breaks the display of the checkbox checked state when clicking on the checkbox itself.

My second post describes some possible hacks to workaround the bug and that I was unable to fix the display of the image by using .onSelChange, etc.

Robert
RobertStrong is offline   Reply With Quote
Old 30th June 2006, 08:01   #6
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
The problem is that those aren't really checkboxes. Those are just images of checkboxes. TVS_CHECKBOXES is not available on older versions of Windows and so images are used for compatibility. This also allows easily customizing the checkbox image.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 30th June 2006, 15:54   #7
RobertStrong
Junior Member
 
Join Date: Jan 2006
Posts: 22
Do you have any pointers as to what would need to be modified in order to use TVS_CHECKBOXES or perhaps a way to work around this?
RobertStrong is offline   Reply With Quote
Old 30th June 2006, 17:35   #8
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Way too much code in Source\exehead\Ui.c, exec.c and components.c. A workaround would probably be manually implementing IAccessible for the control.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump