Revision 2758

tmp/org.txm.searchengine.cqp.rcp/src/org/txm/searchengine/cqp/rcp/dialogs/ExportCorpusDialog.java (revision 2758)
85 85
	}
86 86
	
87 87
	@Override
88
	protected Control createButtonBar(Composite parent) {
89
		Control c = super.createButtonBar(parent);
90
		getButton(IDialogConstants.OK_ID).setEnabled(false);
91
		return c;
92
	}
93
	
94
	@Override
95 88
	protected Control createDialogArea(Composite parent) {
96 89
		Composite comp = (Composite) super.createDialogArea(parent);
97 90
		
......
122 115
				String path = dialog.open();
123 116
				if (path != null) {
124 117
					textField.setText(path);
125
					getButton(IDialogConstants.OK_ID).setEnabled(true);
118
					getButton(IDialogConstants.OK_ID).setEnabled(new File(path).getParentFile().exists());
126 119
				}
127
				else {
128
					getButton(IDialogConstants.OK_ID).setEnabled(false);
129
				}
130 120
			}
131 121
			
132 122
			@Override

Also available in: Unified diff