Bug 226408 - [message editor]Properties editor needs to handle external files more gracefully
Summary: [message editor]Properties editor needs to handle external files more gracefully
Status: NEW
Alias: None
Product: Babel
Classification: Technology
Component: Plugins (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Pascal Essiembre CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-04-09 22:24 EDT by Remy Suen CLA
Modified: 2013-02-22 15:33 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Remy Suen CLA 2008-04-09 22:24:48 EDT
1. File > Open...
2. Select a .properties file that isn't in a project managed by the workspace.
3. The editor opens with an error saying 'Could not open the editor: Invalid input: Must be IFileEditorInput'.

I think we can improve on this error message. Unless the user has done some plug-in development before, they are not going to know what this error message means.

Ideally, we should not be failing as the editor should be able to open properties file that aren't managed by the workspace. Sure a lot of the quirks like markers probably won't work, but it's still better than editing it in a plain old text editor.
Comment 1 Alexej Strelzow CLA 2013-02-22 15:33:48 EST
Default File Association for *.properties is the Messages Editor!
If it's not, it works. But before giving up so quickly, I'd like to propose an idea:

I would say, we have to check the PreferenceStore, if the MessagesEditor is default for *.properties-Files (Platform.getPreferencesService().getString(...)) 
Then use this: http://help.eclipse.org/indigo/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Fguide%2FwrkAdv_retarget.htm
to react differently, then Eclipse is reacting now. Maybe we can open it successfully?