Skip to content

Commit

Permalink
Merge branch 'v0.17.x_bugfix'
Browse files Browse the repository at this point in the history
  • Loading branch information
S1artie committed Jan 30, 2019
2 parents 0b9ea75 + 02ef90e commit 2808ff7
Show file tree
Hide file tree
Showing 6 changed files with 263 additions and 22 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
/*******************************************************************************
* Copyright (c) 2013 Rene Schneider, GEBIT Solutions GmbH 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
*******************************************************************************/
package de.gebit.integrity.eclipse.views;

import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.dialogs.IInputValidator;
import org.eclipse.jface.dialogs.InputDialog;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Shell;

/**
*
*
* @author Rene Schneider - initial API and implementation
*
*/
public class ConnectDialog extends InputDialog {

/**
* Whether auto-retry was chosen.
*/
private boolean autoRetryEnabled;

/**
* @param parentShell
* @param aDialogTitle
* @param aDialogMessage
* @param anInitialValue
* @param aValidator
*/
public ConnectDialog(Shell aParentShell, String anInitialValue, IInputValidator aValidator) {
super(aParentShell, "Connect to test runner", "Please enter the hostname or IP address to connect to",
anInitialValue, null);
}

@Override
protected void createButtonsForButtonBar(Composite aParent) {
super.createButtonsForButtonBar(aParent);

createButton(aParent, IDialogConstants.RETRY_ID, "OK (retry)", false);
}

@Override
protected void buttonPressed(int aButtonId) {
if (aButtonId == IDialogConstants.RETRY_ID) {
autoRetryEnabled = true;
super.buttonPressed(IDialogConstants.OK_ID);
} else {
super.buttonPressed(aButtonId);
}
}

public boolean isAutoRetryEnabled() {
return autoRetryEnabled;
}

}
Loading

0 comments on commit 2808ff7

Please sign in to comment.