[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [Subclipse-dev] resorce text decorators

From: Eugene Kuleshov <eu_at_md.pp.ru>
Date: 2005-08-21 20:14:42 CEST

Eugene Kuleshov wrote:
> Mark Phippard wrote:
>
>> > If you agree that default label value should be the same as
>> > fepository url I can look at this again.
>>
>> That makes sense to me.
>
> Great. I'll try to look at this on the weekend.
>
> BTW there is another related issue already mentioned in comments to
> http://subclipse.tigris.org/issues/show_bug.cgi?id=309 I
> Michael Valenta outlined how it can be fixed for CVS plugin at
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=98771 and it should be
> very similar in Subclipse. So, if someone would like to look at this
> please go ahead. I most likely will not have time for this till end of
> the next week.

   Here is the patch for bot issues:
- empty label when label defaulted to repo url
- refresh decorator that is using label on label change

   I've also reopened issue 309 and attached this patch there just in
case. http://subclipse.tigris.org/issues/show_bug.cgi?id=309

   Thanks.

   Eugene

Index: C:/dev/eclipse/org.tigris.subversion.subclipse.ui/src/org/tigris/subversion/subclipse/ui/decorator/SVNLightweightDecorator.java
===================================================================
--- C:/dev/eclipse/org.tigris.subversion.subclipse.ui/src/org/tigris/subversion/subclipse/ui/decorator/SVNLightweightDecorator.java (revision 1559)
+++ C:/dev/eclipse/org.tigris.subversion.subclipse.ui/src/org/tigris/subversion/subclipse/ui/decorator/SVNLightweightDecorator.java (working copy)
@@ -288,9 +288,10 @@
                                 bindings.put(SVNDecoratorConfiguration.DIRTY_FLAG, dirtyFlag);
                         }
 
- bindings.put( SVNDecoratorConfiguration.RESOURCE_LABEL, svnResource.getRepository().getLabel());
-
                         if (status.getUrlString() != null) {
+ String label = svnResource.getRepository().getLabel();
+ bindings.put( SVNDecoratorConfiguration.RESOURCE_LABEL, label == null ? status.getUrlString() : label);
+
                                 bindings.put(
                                         SVNDecoratorConfiguration.RESOURCE_URL,
                                         status.getUrlString());
Index: C:/dev/eclipse/org.tigris.subversion.subclipse.ui/src/org/tigris/subversion/subclipse/ui/properties/SVNRepositoryPropertiesPage.java
===================================================================
--- C:/dev/eclipse/org.tigris.subversion.subclipse.ui/src/org/tigris/subversion/subclipse/ui/properties/SVNRepositoryPropertiesPage.java (revision 1559)
+++ C:/dev/eclipse/org.tigris.subversion.subclipse.ui/src/org/tigris/subversion/subclipse/ui/properties/SVNRepositoryPropertiesPage.java (working copy)
@@ -32,6 +32,7 @@
 import org.tigris.subversion.subclipse.core.repo.SVNRepositories;
 import org.tigris.subversion.subclipse.ui.Policy;
 import org.tigris.subversion.subclipse.ui.SVNUIPlugin;
+import org.tigris.subversion.subclipse.ui.decorator.SVNLightweightDecorator;
 import org.tigris.subversion.subclipse.ui.dialogs.ChooseRootUrlDialog;
 import org.tigris.subversion.svnclientadapter.SVNUrl;
 
@@ -314,6 +315,9 @@
         try {
             SVNRepositories repositories = SVNProviderPlugin.getPlugin().getRepositories();
             repositories.addOrUpdateRepository(location);
+
+ SVNLightweightDecorator.refresh();
+
                 } catch (SVNException e) {
                         handle(e);
             return false;
Received on Mon Aug 22 04:14:42 2005

This is an archived mail posted to the Subclipse Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.