Don't switch file in current tab/pane when jumping to location
| Originator: | guuglhopf | ||
| Number: | rdar://11540455 | Date Originated: | 26-May-2012 01:00 PM |
| Status: | Open | Resolved: | |
| Product: | Mac OS X SDK | Product Version: | 4.3.2 |
| Classification: | UI/Usability | Reproducible: | Always |
Summary: Xcode has many occasions where it needs to show me a certain line of my code, e.g. when I use "Jump to Definition" or from the debugger. If the line to jump to is not in the file that is currently in the active tab and the leftmost pane, Xcode will open the corresponding file in the active tab and the leftmost pane. It would be more convenient and more respectful of the layout I have created if Xcode would instead merely bring to the front the tab that already has the file open. Steps to Reproduce: This issue manifests itself in all cases when Xcode needs to jump to a certain line in a certain file that is not currently open in the leftmost pane of the current tab. Three examples: ### Example 1: "Jump to Definition" when target file is already open in Assistant Editor pane 1. Open an Xcode project with a source file and a header file. 2. Open the source file in the left pane and open the assistant editor in the "Counterpart" mode to show the header file 3. Right click a function definition in the source file and select "Jump to Definition" (this should actually read "Jump to Declaration", but that's another bug) ### Example 2: "Jump to Definition" when target file is already open in another tab 1. Open an Xcode project with a source file and a header file. 2. Open the source file in one tab and open the header file in a different tab. 3. Right click a function definition in the source file and select "Jump to Definition" (this should actually read "Jump to Declaration", but that's another bug) ### Example 3: "Jump to breakpoint" when target file is already open in another tab 1. Open an Xcode project with a source file and a header file. 2. Open the source file in one tab and open the header file in a different tab. 3. Bring the tab with the source file to the front and add a breakpoint. 4. Bring the tab with the header file to the front. 5. Run the program in the debugger. Expected Results: Xcode switches to the the tab of the target file and jumps to the target line Actual Results: Xcode opens the target file in the current tab and jumps to the target line. As a result, I have the same file open in two tabs now. Regression: Notes: I have listed only three examples that are most relevant to myself, but the behavior is also wrong in any other case where Xcode needs to jump to a certain line in another file than the frontmost.
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!