Bug 280499 [CSS] AbstractCSSSWTEngineImpl shouldn't get display for current thread
The constructor AbstractCSSSWTEngineImpl(Display, boolean) is passed in a display. However, it also does: new CSSSWTApplyStylesListener(Display.findDisplay(Thread .currentThread()), this); I don't see why it shouldn't use the display passed in.
bundles/org.eclipse.e4.ui.css.swt/src/org/eclipse/e4/ui/css/swt/engine/AbstractCSSSWTEngineImpl.java
/*******************************************************************************
 * Copyright (c) 2008 Angelo Zerr and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     Angelo Zerr <angelo.zerr@gmail.com> - initial API and implementation
 *     IBM Corporation
 *******************************************************************************/
package org.eclipse.e4.ui.css.swt.engine;
import org.eclipse.e4.ui.css.core.impl.engine.CSSEngineImpl;
import org.eclipse.e4.ui.css.core.resources.IResourcesRegistry;
import org.eclipse.e4.ui.css.swt.dom.SWTElementProvider;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTColorConverterImpl;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTCursorConverterImpl;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTFontConverterImpl;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTFontDataConverterImpl;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTGradientConverterImpl;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTImageConverterImpl;
import org.eclipse.e4.ui.css.swt.properties.converters.CSSValueSWTRGBConverterImpl;
import org.eclipse.e4.ui.css.swt.resources.SWTResourcesRegistry;
import org.eclipse.e4.ui.css.swt.selectors.DynamicPseudoClassesSWTActiveHandler;
import org.eclipse.e4.ui.css.swt.selectors.DynamicPseudoClassesSWTButtonSelectedHandler;
import org.eclipse.e4.ui.css.swt.selectors.DynamicPseudoClassesSWTFocusHandler;
import org.eclipse.e4.ui.css.swt.selectors.DynamicPseudoClassesSWTHoverHandler;
import org.eclipse.swt.widgets.Display;
/**
 * CSS SWT Engine implementation which configure CSSEngineImpl to apply styles