Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Report Control
  New Posts New Posts RSS Feed - Shift+clicking yields incorrect selection!
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Shift+clicking yields incorrect selection!

 Post Reply Post Reply
Author
Message
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post Topic: Shift+clicking yields incorrect selection!
    Posted: 23 August 2009 at 1:43pm
Downloaded latest source (5 minutes ago). I see this erroneous behavior:
 
1
2 Click (select)
3
4
5
6 Shift+click
7
 
Now row 2-6 are selected, and focus is at position 6. If I Shift+click row 4, the selection should be 2-4 with focus at position 4, but Report Control yields a selection of 2-6 with focus set at position 4. This is wrong (you can try it in XP/Vista or similar).
 
Basically, there are only two rules for correct clicking logic...
 
The proper action when shift-clicking is:
1) Remove current selection, but remember anchor position (anchor is always included in the selection).
2) Select from anchor to clicked row.
 
When ctrl-clicking, the anchor is updated to the clicked row!
 
 
My theory: You don't update the anchor position when a selection is present?
PokerMemento - http://www.pokermemento.com/
Back to Top
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post Posted: 25 August 2009 at 3:41am
Have you looked at this?
PokerMemento - http://www.pokermemento.com/
Back to Top
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post Posted: 27 August 2009 at 11:07am
PokerMemento - http://www.pokermemento.com/
Back to Top
mdoubson View Drop Down
Senior Member
Senior Member
Avatar

Joined: 17 November 2008
Status: Offline
Points: 1705
Post Options Post Options   Thanks (0) Thanks(0)   Quote mdoubson Quote  Post ReplyReply Direct Link To This Post Posted: 28 August 2009 at 12:01am
So get related source update and build your app to check - https://forum.codejock.com/uploads/DemoVersion/ReportControlMFCUpdatedAug27.rar
 
Also look on new feature - Report Control with resizable rows - select row and you can track down row height -
 
 
Menu - Help - Header-Footer turn this mode off
Back to Top
Danlar View Drop Down
Groupie
Groupie
Avatar

Joined: 27 February 2008
Location: United States
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote Danlar Quote  Post ReplyReply Direct Link To This Post Posted: 28 August 2009 at 11:11am
With released 13.1, I was having the problem listed in another post where GetCount() was giving incorrect results ( see http://forum.codejock.com/forum_posts.asp?TID=14948 ) and I applied the ReportControlMFCUpdatedAug27.rar source update listed above to fix that problem. It now appears that applying an unmodified left click to any currently-selected row in the report does not replace the current selection, it merely changes focus.

-Dan
Back to Top
mdoubson View Drop Down
Senior Member
Senior Member
Avatar

Joined: 17 November 2008
Status: Offline
Points: 1705
Post Options Post Options   Thanks (0) Thanks(0)   Quote mdoubson Quote  Post ReplyReply Direct Link To This Post Posted: 28 August 2009 at 11:20am

The stable update ReportControlMFCUpdated.rar (SVN matched version) while ReportControlMFCUpdatedAug27.rar is current working progress

 
You right - it will be de-select all previous selection in your case and select only one row you click
Back to Top
mdoubson View Drop Down
Senior Member
Senior Member
Avatar

Joined: 17 November 2008
Status: Offline
Points: 1705
Post Options Post Options   Thanks (0) Thanks(0)   Quote mdoubson Quote  Post ReplyReply Direct Link To This Post Posted: 28 August 2009 at 1:05pm
Good - did you try to resize row's height?
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.156 seconds.