blob: 97a381757799ca1d8f332c526daffce0119b0818 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2018 Agence spatiale canadienne / Canadian Space Agency
* 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:
<<<<<<< HEAD
* Pierre Allard - initial API and implementation
* Regent L'Archeveque
*
=======
* Pierre Allard,
* Regent L'Archeveque - initial API and implementation
*
>>>>>>> refs/heads/eclipse_pa
* SPDX-License-Identifier: EPL-1.0
*
*******************************************************************************/
package org.eclipse.apogy.common.io.jinput.ui.composites;
import org.eclipse.apogy.common.io.jinput.Activator;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Event;
import org.eclipse.swt.widgets.Listener;
public class RefreshCommandComposite extends Composite {
public RefreshCommandComposite(Composite parent, int style) {
super(parent, style);
Button btnRefresh = new Button(this, SWT.NONE);
btnRefresh.setBounds(0, 0, 137, 29);
btnRefresh.setText("Refresh controllers");
btnRefresh.addListener(SWT.Selection, new Listener() {
@Override
public void handleEvent(Event event) {
Activator.getEControllerEnvironment().refresh();
}
});
}
}