6

I have to remove unused imports in my project. Previously i was using eclipse but now i work on STS.

In STS "CTRL + SHIFT + o" is not working to remove unused imports.

Youcef LAIDANI
  • 55,661
  • 15
  • 90
  • 140
Devram Kandhare
  • 771
  • 2
  • 8
  • 20
  • For above shortcut resulted in GPU details being popped. So what worked for me is -> https://community.amd.com/thread/227221 – nanosoft Mar 21 '20 at 16:46

1 Answers1

7

This is a bug of the Spring IDE, I've had it myself in the past.

  1. Go to Window -> Preferences -> General -> Keys
  2. Order by Binding
  3. Search for / Scroll to the Ctrl + Shift + O bindings
  4. Unbind all commands with the binding Ctrl + Shift + O except the command Organize Imports
  5. Set When to Editing Java Source
  6. Apply, OK, and you should be good to go

General -> Keys

Impulse The Fox
  • 2,638
  • 2
  • 27
  • 52
  • 1
    Weird. I have the exact same settings, but it still doesn't work. I notice that if I remove the binding, I can't set it back to Ctrl+Shift+O (other letters work). – Jesse Dec 14 '17 at 18:49
  • 1
    For above shortcut resulted in GPU details being popped. So what worked for me is -> https://community.amd.com/thread/227221.You need to go to Gaming > Global Settings > Performance Monitoring > Toggle Performance Logging Hotkey You will see this is bound to Ctrl + Shift + O (so the shortcut is used - just buried). To remove the shortcut (not an obvious process at all!) you need to click the Toggle Performance Logging Hotkey button, it will then ask to enter your hotkey, you then press delete - that is Del (not backspace, not esc or anything else - the Del key). – nanosoft Mar 21 '20 at 16:47