Search in sources :

Example 1 with ImageSearch

use of org.eclipse.linuxtools.docker.ui.wizards.ImageSearch in project linuxtools by eclipse.

the class RunImageMainTab method onSearchImage.

private SelectionListener onSearchImage() {
    return SelectionListener.widgetSelectedAdapter(e -> {
        final ImageSearch imageSearchWizard = new ImageSearch(RunImageMainTab.this.model.getSelectedConnection(), RunImageMainTab.this.model.getSelectedImageName(), new RegistryInfo(AbstractRegistry.DOCKERHUB_REGISTRY, true));
        final boolean completed = CommandUtils.openWizard(imageSearchWizard, getShell());
        if (completed) {
            model.setSelectedImageName(imageSearchWizard.getSelectedImage());
        }
    });
}
Also used : ImageSearch(org.eclipse.linuxtools.docker.ui.wizards.ImageSearch) RegistryInfo(org.eclipse.linuxtools.internal.docker.core.RegistryInfo)

Example 2 with ImageSearch

use of org.eclipse.linuxtools.docker.ui.wizards.ImageSearch in project linuxtools by eclipse.

the class ImagePullPage method onSearchImage.

/**
 * Opens the {@link ImageSearch} dialog with current image name pre-filled.
 *
 * @return
 */
private SelectionListener onSearchImage() {
    return SelectionListener.widgetSelectedAdapter(e -> {
        final ImageSearch imageSearchWizard = new ImageSearch(ImagePullPage.this.connection, ImagePullPage.this.getModel().getSelectedImageName(), ImagePullPage.this.getModel().getSelectedRegistry());
        final boolean completed = CommandUtils.openWizard(imageSearchWizard, getShell());
        if (completed) {
            ImagePullPage.this.getModel().setSelectedImageName(imageSearchWizard.getSelectedImage());
        }
    });
}
Also used : ImageSearch(org.eclipse.linuxtools.docker.ui.wizards.ImageSearch)

Example 3 with ImageSearch

use of org.eclipse.linuxtools.docker.ui.wizards.ImageSearch in project linuxtools by eclipse.

the class ImageRunSelectionPage method onSearchImage.

private SelectionListener onSearchImage() {
    return SelectionListener.widgetSelectedAdapter(e -> {
        final ImageSearch imageSearchWizard = new ImageSearch(ImageRunSelectionPage.this.model.getSelectedConnection(), ImageRunSelectionPage.this.model.getSelectedImageName(), new RegistryInfo(AbstractRegistry.DOCKERHUB_REGISTRY, true));
        final boolean completed = CommandUtils.openWizard(imageSearchWizard, getShell());
        if (completed) {
            model.setSelectedImageName(imageSearchWizard.getSelectedImage());
        }
    });
}
Also used : ImageSearch(org.eclipse.linuxtools.docker.ui.wizards.ImageSearch) RegistryInfo(org.eclipse.linuxtools.internal.docker.core.RegistryInfo)

Aggregations

ImageSearch (org.eclipse.linuxtools.docker.ui.wizards.ImageSearch)3 RegistryInfo (org.eclipse.linuxtools.internal.docker.core.RegistryInfo)2