Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 178744 - [misc] Editor opened upon an out of sync resource should allow for refresh action
Summary: [misc] Editor opened upon an out of sync resource should allow for refresh ac...
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 3.3   Edit
Hardware: PC All
: P3 enhancement (vote)
Target Milestone: 3.3 M7   Edit
Assignee: Platform-Text-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-03-22 05:27 EDT by Maxime Daniel CLA
Modified: 2007-04-12 06:33 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maxime Daniel CLA 2007-03-22 05:27:22 EDT
I20070320-0010

Scenario:
- create new file test.txt in project P;
- edit it;
- leave Eclipse;
- touch test.txt;
- launch Eclipse;
- answer 'No' to the 'File Changed' prompt;
- you get your editor to display 'Resource is out of sync...';
- while refreshing it from the Navigator is easy, I found no means to refresh the resource from the editor itself, which I find non intuitive.

Note: that behavior is somewhat general and other scenarios enable to display the file contents instead of the 'Resource is out of sync...' disclaimer, for which a contextual menu is available, but that menu has no refresh item.

Checked behavior for Linux and XP.
Comment 1 Dani Megert CLA 2007-03-22 05:44:36 EDT
Right. We should at least retarget File > Refresh (F5). Putting more work into this like adding a button or a context menu is overkill as the user was explicitly asked previously and he chose 'No'.
Comment 2 Maxime Daniel CLA 2007-03-22 06:10:00 EDT
Retargeting F5 will be welcome. 

However, despite the fact that it is more work, I would still consider that adding a bit more would be a bless. The truth is that users would never deliberately pursue actions that would lead them to have a useless editor opened on the out of sync disclaimer. 
[I find the 'keep previous contents' scenario a bit stretched, but this may happen (followed by an optional override of the disk contents).]
The only two reasons I see to reach the out of sync disclaimer are the following:
- hast/mistake; the user does not read the message or simply hits the wrong button;
- doubt; presented with an unexpected dialog, the user takes the safer path (do not reload, keeping both images).
In both cases, once the sole contents you get are the disclaimer, your only reasonable choice is to refresh. And the means to do that should be obvious, prominent and seamless.
I agree that then some users (and I will be happy to be one these) will remember that you've added F5. But others won't know it and will have to fuss around before getting the thing fixed. (I also agree that quite a few users will refresh the whole project or workspace, but...).

Note that this also questions the out of sync disclaimer itself. If we cannot present usable contents, then we might be better off loading them anyway. But I assume that this design point has merits that have been debated elsewhere.
Comment 3 Dani Megert CLA 2007-03-22 06:13:21 EDT
>Note that this also questions the out of sync disclaimer itself. If we cannot
>present usable contents, then we might be better off loading them anyway. But I
>assume that this design point has merits that have been debated elsewhere.
This is the way Eclipse SDK does it everwhere (e.g. when you execute an action that modifies files). If all agree to always silently ignore the out of sync in the far future then the editor will do as well ;-)
Comment 4 Dani Megert CLA 2007-04-12 06:33:28 EDT
Fixed in HEAD.
Available in builds > N20070412-0010.