Re: [EGIT PATCH 01/11] Add support code to handle plugin property changes
- From
Shawn O. Pearce <spearce@spearce.org>
- Date
- Feb 5, 2009, 15:53 UTC
- Message-ID
- <20090205155337.GH26880@spearce.org>
- In-Reply-To
- <1233795618-20249-2-git-send-email-torarnv@gmail.com>
Tor Arne Vestbø <torarnv@gmail.com> wrote:
Show 13 quoted lines
> diff --git a/org.spearce.egit.ui/src/org/spearce/egit/ui/Activator.java b/org.spearce.egit.ui/src/org/spearce/egit/ui/Activator.java
> index fced643..d4a9e8e 100644
> --- a/org.spearce.egit.ui/src/org/spearce/egit/ui/Activator.java
> +++ b/org.spearce.egit.ui/src/org/spearce/egit/ui/Activator.java
> @@ -44,9 +48,24 @@
> * This is a plugin singleton mostly controlling logging.
> */
> public class Activator extends AbstractUIPlugin {
> +
> + /**
> + * The one and only instance
> + */
> private static Activator plugin;What does this field do? I don't see it referenced anywhere...
Show 5 quoted lines
> /** > + * Property listeners for plugin specific events > + */ > + private static List<IPropertyChangeListener> propertyChangeListeners = > + new ArrayList<IPropertyChangeListener>(5);
None of these list accesses are thread-safe. Are we certain they call will come from a single thread, e.g. the SWT event thread? Or do we need to put synchronized protection in here?
-- Shawn.