All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.albertus82.jface.closeable.CloseableDevice Maven / Gradle / Ivy

Go to download

Java SWT/JFace Utility Library including a Preferences Framework, Lightweight HTTP Server and macOS support.

There is a newer version: 20.1.0
Show newest version
package io.github.albertus82.jface.closeable;

import java.io.Closeable;

import org.eclipse.swt.graphics.Device;

public class CloseableDevice implements Closeable {

	private final T device;

	public CloseableDevice(final T device) {
		this.device = device;
	}

	public T getDevice() {
		return device;
	}

	@Override
	public void close() {
		if (device != null) {
			device.dispose();
		}
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy