Change:
<!-- Do Not Delete This! bugreporttemplate --<!-- Please read our Rules of Conduct: --<!-- Read our guide about submitting issues: --<!-- Search existing issues to avoid creating duplicates. --<!-- Test using the latest Insiders build to see if your issue has already been fixed: --<!-- Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. --<!-- Launch with to check. --Does this issue occur when all extensions are disabled?: Yes/No <!-- If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. --<!-- Issues caused by an extension need to be reported directly to the extension publisher. The 'Help Report Issue' dialog can assist with this. --- VS Code Version: 1.92.1 OS Version: Linux Mint Cinnamon 21.2, Windows 11 Steps to Reproduce: a folder with at least two files on one file in the Explorer, then click on another click -Compare selected Actual behavior: The diff view shows the second file on the left side and the first file on the right. Expected behavior: The diff view shows the first file on the left side and the second file on the right. This was the behavior in previous versions.
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.92.1. Please try upgrading to the latest version and checking whether this issue remains. Happy Coding!
Checked that the issue is still present with 1.92.1 and updated the original issue.
I think this was an intentional change. I just asked some colleagues, they would also expect the first selected file to be on the left. However, I wonder if that is because we read from left to right. Someone who reads from right to left might expect the other order. I think one fundamental issue about diffing two (not directly related) files is that the diff editor always assumes the left one is the "original" (changes in red) and the right one is the "modified" (changes in green) version. This also means that applying a change from modified to original is called "revert". This semantic does not hold when just comparing two files where none is newer/older. Another practical implication is that when the inline diff is turned on, unchanged lines are from "modified" and can be edited.
A quick search indicated that most languages are read from left to right, so I'm doubtful if this was a reason for the change. If there really is a use case for reversing the original and modified side, a settings option would be good. I agree with the semantics issue of diffing two files that are not directly related. But I admit that I have never even noticed it, I just read the red and green parts as differences and it was all I needed.
That is not the reason for the change, but it means that when someone expects the second file to appear right, this is probably because they read from left to right, and not because they assume the second file is the modified one and the first the original. However, VS Code always shows the modified file to the right. When ignoring right and left, if two files are selected, it would be reasonable to assume that the first file is the modified (primary) one (which just happens to be shown to the right). I do understand the confusion though.
I find the old behaviour also quite reasonable, where the first selected file is the original and the second selected file is the modified version (first file =selected first, later file =selected later). But I guess that comes down to personal preference.
reversing the order for the time being and waiting to see if there is any reaction from the community
I find this change really irritating. I have been using vscode in my project for several years and use Compare Selected to compare my reference file with my test (actual) file. In all the time I have been using it the first selected file was on the left. I just updated vscode and now it is on the right. I don't see any good reason for this change. It seems less logical.

Discussion:
if (resources.length === 2) { return editorService.openEditor({ <del> original: { resource: resources[1] }, modified: { resource: resources[0] }, </del> <ins> original: { resource: resources[0] }, modified: { resource: resources[1] }, </ins> options: { pinned: true } }); }