Bug 77209 - [IDE] Add lock icon to read-only files in package explorer
Summary: [IDE] Add lock icon to read-only files in package explorer
Status: RESOLVED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: IDE (show other bugs)
Version: 3.1   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard: haspatch
Keywords:
Depends on:
Blocks:
 
Reported: 2004-10-28 12:23 EDT by Dustin Callaway CLA
Modified: 2009-10-01 09:36 EDT (History)
3 users (show)

See Also:


Attachments
patch_readonly_decorator.diff (5.15 KB, patch)
2006-07-22 01:35 EDT, Benjamin Muskalla CLA
no flags Details | Diff
org.eclipse.ui.ide/icons/full/ovr16/readonly_ovr.gif (64 bytes, image/gif)
2006-07-22 01:36 EDT, Benjamin Muskalla CLA
no flags Details
patch_readonly_decorator_no_npe.diff (3.44 KB, patch)
2006-07-25 10:55 EDT, Benjamin Muskalla CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dustin Callaway CLA 2004-10-28 12:23:00 EDT
It would be very helpful to display a small lock icon next to read-only files
shown in the package explorer (as well as next to the filename in the editor
tab). This is very useful when used in conjunction with a version control system
since it provides an visual cue as to which files are checked-in (flagged as
read-only) and checked out (writable). In addition, the lock icon should
automatically refresh so that if a file is checked out using an external version
control client, it should recognize this change and remove the lock icon for
that file. This is one simple feature from IntelliJ IDEA that I really miss.

Another useful feature that is somewhat related would be to allow the user to
simply double-click the "Read-Only" or "Writable" text in the status bar in
order to toggle a file's read/write status (rather than having to go into the
file's properties to do this).
Comment 1 Dirk Baeumer CLA 2004-10-29 07:03:35 EDT
This should be implemented by a label decorator to make sure we see the
information in all views (resource navigator, ...) . 

May be it can be incoopertated into the CVS label decorator.

Moving to Platform/UI.
Comment 2 Michael Van Meekeren CLA 2004-10-29 11:45:59 EDT
ccing Tod.  Do we have label decorators on resources that could be augmented
with this support?  I don't think CVS cares whether a file is readonly or not so
not sure I agree with Dirk on that one.
Comment 3 Tod Creasey CLA 2004-10-29 11:58:03 EDT
We don't supply any decorators right now so someone would have to write a new 
one or add to an existing one.
Comment 4 Benjamin Muskalla CLA 2006-07-22 01:35:02 EDT
Created attachment 46675 [details]
patch_readonly_decorator.diff

Added new decorator to org.eclipse.ui.ide
Comment 5 Benjamin Muskalla CLA 2006-07-22 01:36:19 EDT
Created attachment 46676 [details]
org.eclipse.ui.ide/icons/full/ovr16/readonly_ovr.gif

Please forgive me, it's only to show the functionality.

I think there are more talented people than me out there to create such an overlay-icon :-)
Comment 6 Benjamin Muskalla CLA 2006-07-25 10:55:09 EDT
Created attachment 46758 [details]
patch_readonly_decorator_no_npe.diff

Under some circumstances, you got an NPE because getResourceAttributes can also return null. Added null-check
Comment 7 Dani Megert CLA 2006-09-13 03:04:28 EDT
Note that second feature from comment 0 is covered by bug 66970.
Comment 8 Benjamin Muskalla CLA 2006-10-02 13:38:26 EDT
Just want to note that there is something ;)
Comment 9 Tod Creasey CLA 2007-06-25 16:15:42 EDT
We won't be including this in the SDK but feel free to contribute a plug-in for it via the community.