Community
Participate
Working Groups
I'm coding an Eclipse plugin right now and while doing this I tend to use the following method quite alot: MessageDialog.openInformation() One very annoying thing that I've noticed is the following. Suppose MessageDialog has not previously been used in the current source file. Now I type: MessageDialog. And wait for the content assist features, however it never appears. Thus I press the CTRL-SHIFT-O keys to force Eclipse to understand, but still nothing. Instead it's whining about my syntax error. Thus I cant finish the line because I need content assist, and Eclipse wont give me content assist until I finish the line. Thus, I'm stuck in an annoying catch 22 situation. I typically sort to typing this instead: MessageDialog a; And then press CTRL-SHIFT-O, get the import line. and the erase the " a;" part and type in my "." again. This is very very annoying and lot's of unecessary work. Why can't you please make Eclipse understand that SOMETHING. might be a someone about to call a static method (and thus organize imports should work in this situation). Please I can't live with an omnipresent CTRL-SHIFT-O feature, it's sooo nice. Thanks for your time.
Have you try first to complete before the final '.'? I mean, type "MessageDia" and then complete, does it work (ie. complete to "MessageDialog")? If so, then append the dot and complete again... Perhaps completion works better now, doesn't it? If this does not help, please provide a sample of source in which completion does not work, thanks
Your method works, but IMHO typing "MessageDialog." and then pressing CTRL- SHIFT-O is more natural and Eclipse should support both ways.
Move to JDT/UI for comments on Ctrl-Shift-O behavior enhancement...
*** This bug has been marked as a duplicate of 44627 ***