Closed peller closed 11 years ago
I don't know the code well, but i would think we'd only want to remove the workingcopy and not the saved file also. I'll take a look after lunch.
Quick thought, to investigate: is there a difference (particularly in server calls) between the above and taking an existing file, making changes, clicking on close, and don't save changes?
yeah, two bugs:
I couldn't reproduce this. When I open an existing file (not creating a new one), I see the file open, it gets a dirty bit, but when it finishes loading the dirty bit is removed. Closing the file does not bring up a dialog.
Can you explain the exact steps you took? Did you see this on maqetta-test?
In talking with @peller, he says it's when an editor was open from a previous session with dirty bit on. So, I tried to reproduce that scenario in various ways:
resetWorkbenchState=1
(because of #3955), then restarted the server and returned to Maqetta. No editors were open. I double-clicked on my dirty file, it came up dirty. I clicked on the (x) close icon, clicked on "discard" => editor was closed, and original file was still visible in Files palette. (Which at surface level is proper behavior.)My best guess about what @peller is seeing is that his file was never saved, so the server only had a file1.html.workingcopy and, because the Save button had never been clicked on that file, there was no file1.html file on the server.
That or a bug which we haven't been able to characterize.
Note however that I did find a bug while fooling around: #3956
@peller - can we close this?
@jhpedemonte yes, it was on the test machine. It was content that was migrated over from the main server, so I'm not sure exactly what the state was, but apparently it did have a working copy / dirty bit on it.
yeah, sorry, close until I have a better idea what it was I saw
probably a dup of many dirty bit bugs, but wanted to make sure it's logged
open an HTML file. it gets a dirty bit close the file you get prompted because it thinks the file is dirty. say ok, you really want to close it with unsaved changes. the editor disappears and the file is removed from the filesystem.
@billreed63 @JonFerraiolo @jhpedemonte