any editor. open a file. if you try to click open file again, you will be in the folder the file lives in. if you close data studio and reload it when that editor comes up, if you open file again, it will not be in the folder that the current file exist in. This happens in query analyzer when you change database server. any time the editor is somehow re-established it seems to lose the folder location
This is in version 11 as well.
I am not sure how to reproduce the test case mentioned by Ivan.
But I am sure that if I have N editors opened (any editor; either editor embedded in Query Analyzer or Text/Html/Xml... text editors, etc), and each of these editors has a file opened which resides in N different directories; then after ADS is restarted, and tabs are restored, clicking the Open icon in each tab won't display the directory to which the current file belongs.
I briefly reviewed ADS source, it has something to do with the CEditorPanelView::lastFolder data member. If we can update this data member after a tab is restored, the problem described above should be gone. One way to do this is to modify CEditorPanelView::doOpen(File, CTreeNode, String) method, and add a call to setLastForlder(file) after setFile(file) (line #1256). However, since CEditorPanelView::doOpen(File, CTreeNode, String) is called by quite a few places, not sure whether adding setLastFolder(file) would cause a side effect or not. Need to do some more study.
Issue #7688 |
Closed |
Completion |
No due date |
No fixed build |
No time estimate |
I am not sure how to reproduce the test case mentioned by Ivan.
But I am sure that if I have N editors opened (any editor; either editor embedded in Query Analyzer or Text/Html/Xml... text editors, etc), and each of these editors has a file opened which resides in N different directories; then after ADS is restarted, and tabs are restored, clicking the Open icon in each tab won't display the directory to which the current file belongs.
I briefly reviewed ADS source, it has something to do with the CEditorPanelView::lastFolder data member. If we can update this data member after a tab is restored, the problem described above should be gone. One way to do this is to modify CEditorPanelView::doOpen(File, CTreeNode, String) method, and add a call to setLastForlder(file) after setFile(file) (line #1256). However, since CEditorPanelView::doOpen(File, CTreeNode, String) is called by quite a few places, not sure whether adding setLastFolder(file) would cause a side effect or not. Need to do some more study.