Bug Report B223451
Visible to All Users
Duplicate

We have closed this ticket because another page addresses its subject:

Core - Redesign ListViewAutoCommitController and WinDetailViewController to customize them properly

UI.Win - TreeList focus is restored incorrectly after canceling changes in ListViewAndDetailView mode

created 13 years ago

I noticed some strange behaviour using a TreeList in MasterDetailView.
After applying some changes in the DetailView of an existing object and a mouseclick
on a different node in the ListView a messagebox is displayed ( save yes/no, or abort ).
When I press 'save yes' the result is as expected, the changed object ist persisted,
the clicked node is focused in ListView and shown in DetailView.
When I Press 'save no' I would expect a similar behaviour with the only difference that the changed
object is not persisted. However in this case the results are not predictable : the clicked node does not
receive the focus and the DetailView does not display the selected node-object. In some cases the DetailView
shows an object other than the clicked-node-object.
To reproduce this effect you can use the following scenario :
TreeList :
   P1
      P11
   P2
      P21
1.Example :
- Make P21 active, all nodes expanded
- change some data of P21 in DetailView
- click on P11
- confirm the message with 'save no'
- result :
     TreeList is collapsed to
        P1
        P2 ( <- focued )
           P21
     DetailView shows object P2
2.Example :
- Make P11 active, all nodes expanded
- change some data of P11 in DetailView
- click on P21
- confirm the message with 'save no'
- result :
     TreeList is collapsed to
        P1
          P11
        P2
     DetailView does not show an object
Thanks
Johann

Comments (1)
Dennis Garavsky (DevExpress) 13 years ago

    Hello Johann,
    Thank you for the report. We have researched this problem and come to the conclusion that there is no good and safe solution (without introducing breaking changes) in the current version.
    We would like to improve this situation as part of the Core - Redesign ListViewAutoCommitController and WinDetailViewController to customize them properly suggestion. Although there can be a possible fix within our treelist editor code (the treeList_FocusedNodeChanged method of TreeListEditor), we think that it is more appropriate to refactor the WinDetailViewController class that causes this behavior. Please let us know if this problem is urgent for you and you need to have a temporarily solution for it.
    Thanks,
    Dennis

    Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

    Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.