java.util.ArrayListcom.intellij.util.containers.ContainerUtil



Project JetBrains/intellij-community in file ...c.com.intellij.debugger.ui.DebuggerEditorImpl.java (2013-03-04)
@@ -41,6 +41,7 @@ import com.intellij.psi.*;
 import com.intellij.psi.search.GlobalSearchScope;
 import com.intellij.psi.util.PsiTreeUtil;
 import com.intellij.ui.ClickListener;
+import com.intellij.util.containers.ContainerUtil;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
 
@@ -49,7 +50,6 @@ import javax.swing.border.EmptyBorder;
 import java.awt.*;
 import java.awt.event.MouseEvent;
 import java.lang.ref.WeakReference;
-import java.util.ArrayList;
 import java.util.List;
 
 /**
@@ -65,7 +65,7 @@ public abstract class DebuggerEditorImpl extends CompletionEditor{
 
   private final String myRecentsId;
 
-  private final List<DocumentListener> myDocumentListeners = new ArrayList<DocumentListener>();
+  private final List<DocumentListener> myDocumentListeners = ContainerUtil.createLockFreeCopyOnWriteList();
   private Document myCurrentDocument;
   private final JLabel myChooseFactory = new JLabel();
   private WeakReference<ListPopup> myPopup;
Project JetBrains/intellij-community in file ...ramework.sm.runner.ui.SMTestRunnerResultsForm.java (2013-03-04)
@@ -36,6 +36,7 @@ import com.intellij.openapi.project.Project;
 import com.intellij.openapi.util.Disposer;
 import com.intellij.openapi.wm.IdeFocusManager;
 import com.intellij.ui.JBColor;
+import com.intellij.util.containers.ContainerUtil;
 import com.intellij.util.text.DateFormatUtil;
 import org.jetbrains.annotations.NonNls;
 import org.jetbrains.annotations.NotNull;
@@ -47,7 +48,6 @@ import javax.swing.event.TreeSelectionListener;
 import java.awt.*;
 import java.awt.event.InputEvent;
 import java.awt.event.KeyEvent;
-import java.util.ArrayList;
 import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Set;
@@ -72,7 +72,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel
   private SMTRunnerTreeBuilder myTreeBuilder;
   private final TestConsoleProperties myConsoleProperties;
 
-  private final List<EventsListener> myEventListeners = new ArrayList<EventsListener>();
+  private final List<EventsListener> myEventListeners = ContainerUtil.createLockFreeCopyOnWriteList();
 
   private PropagateSelectionHandler myShowStatisticForProxyHandler;
 
Project JetBrains/intellij-community in file ...ework.sm.runner.ui.statistics.StatisticsPanel.java (2013-03-04)
@@ -33,6 +33,7 @@ import com.intellij.ui.DoubleClickListener;
 import com.intellij.ui.PopupHandler;
 import com.intellij.ui.TableUtil;
 import com.intellij.ui.table.TableView;
+import com.intellij.util.containers.ContainerUtil;
 import org.jetbrains.annotations.NonNls;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
@@ -41,7 +42,6 @@ import javax.swing.*;
 import java.awt.event.InputEvent;
 import java.awt.event.KeyEvent;
 import java.awt.event.MouseEvent;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.List;
 
@@ -55,7 +55,7 @@ public class StatisticsPanel implements DataProvider {
   private JPanel myContentPane;
 
   private final StatisticsTableModel myTableModel;
-  private final List<PropagateSelectionHandler> myPropagateSelectionHandlers = new ArrayList<PropagateSelectionHandler>();
+  private final List<PropagateSelectionHandler> myPropagateSelectionHandlers = ContainerUtil.createLockFreeCopyOnWriteList();
   private final Project myProject;
   private final TestFrameworkRunningModel myFrameworkRunningModel;
 
Project JetBrains/intellij-community in file ...lij.cvsSupport2.application.CvsEntriesManager.java (2013-03-04)
@@ -34,6 +34,7 @@ import com.intellij.openapi.vcs.FileStatusManager;
 import com.intellij.openapi.vcs.changes.VcsDirtyScopeManager;
 import com.intellij.openapi.vfs.*;
 import com.intellij.util.ArrayUtil;
+import com.intellij.util.containers.ContainerUtil;
 import com.intellij.util.containers.HashMap;
 import com.intellij.util.containers.HashSet;
 import org.jetbrains.annotations.NotNull;
@@ -41,7 +42,6 @@ import org.jetbrains.annotations.Nullable;
 import org.netbeans.lib.cvsclient.admin.Entry;
 
 import java.io.File;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Map;
 
@@ -57,7 +57,7 @@ public class CvsEntriesManager extends VirtualFileAdapter {
 
   private static final String CVS_ADMIN_DIRECTORY_NAME = CvsUtil.CVS;
 
-  private final Collection<CvsEntriesListener> myEntriesListeners = new ArrayList<CvsEntriesListener>();
+  private final Collection<CvsEntriesListener> myEntriesListeners = ContainerUtil.createLockFreeCopyOnWriteList();
   private int myIsActive = 0;
   private final Collection<String> myFilesToRefresh = new HashSet<String>();
 
Project JetBrains/intellij-community in file ...2.config.ui.CvsRootAsStringConfigurationPanel.java (2013-03-04)
@@ -22,12 +22,12 @@ import com.intellij.cvsSupport2.ui.CvsRootChangeListener;
 import com.intellij.cvsSupport2.ui.FormUtils;
 import com.intellij.openapi.util.Ref;
 import com.intellij.ui.DocumentAdapter;
+import com.intellij.util.containers.ContainerUtil;
 
 import javax.swing.*;
 import javax.swing.event.DocumentEvent;
 import java.awt.event.ActionEvent;
 import java.awt.event.ActionListener;
-import java.util.ArrayList;
 import java.util.Collection;
 
 /**
@@ -38,7 +38,7 @@ public class CvsRootAsStringConfigurationPanel {
   private JTextField myCvsRoot;
   private JButton myEditFieldByFieldButton;
   private final Ref<Boolean> myIsUpdating;
-  private final Collection<CvsRootChangeListener> myCvsRootListeners = new ArrayList<CvsRootChangeListener>();
+  private final Collection<CvsRootChangeListener> myCvsRootListeners = ContainerUtil.createLockFreeCopyOnWriteList();
   private JPanel myPanel;
 
   public CvsRootAsStringConfigurationPanel(boolean readOnly, Ref<Boolean> isUpdating) {