Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Report Control
  New Posts New Posts RSS Feed - Another FocusChanging Problem
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Another FocusChanging Problem

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

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Topic: Another FocusChanging Problem
    Posted: 26 February 2010 at 5:00pm
If you have SkipGroupFocus = True and you also have something like:


Private Sub ReportControl1_FocusChanging(ByVal NewRow As XtremeReportControl.IReportRow, ByVal NewColumn As XtremeReportControl.IReportColumn, ByVal NewItem As XtremeReportControl.IReportRecordItem, Cancel As Boolean)
   Cancel = NewRow.GroupRow
End Sub


I would expect that there would be no circumstances when a group row could get focus. However, this is not the case. If the currently focused row is a child of the group row, then clicking the group row will move the focus rectangle there, and clicking it again will move the selection there.

If the currently focused row is not a child of the group row that you click, then the focus will never move there (as expected).

Demonstraton:

uploads/20100226_170023_RcFocusChanging.zip

Is it just me or is this a bug?
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
SuperMario View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 February 2004
Status: Offline
Points: 18057
Post Options Post Options   Thanks (0) Thanks(0)   Quote SuperMario Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 5:31pm
I'll look into this later...and maybe restart the marathon build...no promises to make it in 13.3 though
Back to Top
mgampi View Drop Down
Senior Member
Senior Member
Avatar

Joined: 14 July 2003
Status: Offline
Points: 1201
Post Options Post Options   Thanks (0) Thanks(0)   Quote mgampi Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 6:01pm
Hi;

I catched the same with MFC version.
See thread http://forum.codejock.com/forum_posts.asp?TID=16242
Martin

Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0
Platform: Windows 10 v 22H2 (64bit)
Language: VC++ 2022
Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 6:38pm
okay, thanks SuperMario.
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 7:11pm
I was just looking for an ugly work-around, but unfortunately, even though the focus changes on mouse-click, the MouseDown and MouseUp events don't fire :(

MouseMove doesn't fire either until the mouse is moved after clicking (in most cases this happens quickly, but not always - for example using a trackpad on a laptop, the user may click but not touch the trackpad). So a partial workaround is:


Private Sub ReportControl1_MouseMove(Button As Integer, Shift As Integer, x As Long, y As Long)
   If Me.ReportControl1.FocusedRow.GroupRow Then
      Set Me.ReportControl1.FocusedRow = Me.ReportControl1.FocusedRow.Childs(0)
   End If
End Sub


I'll keep try to find a better workaround and post results back here.

Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 7:14pm
Minor correction - MouseDown fires, but it fires *before* the focus is moved, so changing the focus there doesn't help. MouseUp does not fire.

Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 27 February 2010 at 12:19pm
There's a demo that tries to workaround the bug available here: http://forum.codejock.com/forum_posts.asp?TID=16302
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
SuperMario View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 February 2004
Status: Offline
Points: 18057
Post Options Post Options   Thanks (0) Thanks(0)   Quote SuperMario Quote  Post ReplyReply Direct Link To This Post Posted: 27 February 2010 at 11:01pm
I did look at the problem, and when trying to fix it I ran into some things that need to be considered.

How should keyboard navigation act?  How would you expand a group via keyboard if groups can't get selected?  In your example lets say group B and C is closed and focus is in a child of A, how then can I expand B or C via keyboard?  What happens if using the keyboard I then close ALL groups?

Looking at the source, the code does not handle keyboard navigation that well as it was.  I cleaned it up a bit, but I need more details on exactly how this should act before I proceed.

I have the option of allowing it selected but hiding focus rectangle and\or highlighting if needed.

Try to give me exact specifications on how the keyboard navigation should act :)  I have the mouse navigation part fixed.
Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2010 at 8:51am
Hi SuperMario,

Thanks a lot for looking into this and fixing the mouse issues around the group rows.

As for how I think the keyboard should be acting, I'll have to think about this a bit more thoroughly and get back to you shortly (I'm on my way out shortlly).

Thanks again.
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
SuperMario View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 February 2004
Status: Offline
Points: 18057
Post Options Post Options   Thanks (0) Thanks(0)   Quote SuperMario Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2010 at 10:19am
OK, thats fine.  Either way this issue will be in the next version after 13.3. If you want I can give you a custom build finished.
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.188 seconds.