Author: pamarcelot
Date: Thu Feb 7 03:35:01 2008
New Revision: 619368
URL: http://svn.apache.org/viewvc?rev=619368&view=rev
Log:
Added AbstractWizardPage class which shares methods for all the WizardPages.
Added:
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/AbstractWizardPage.java
Modified:
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportProjectsWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsOpenLdapWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsXmlWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasForADSWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportCoreSchemasWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportProjectsWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromOpenLdapWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromXmlWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeContentWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardConnectionSelectionPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardInformationPage.java
directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewSchemaWizardPage.java
Added: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/AbstractWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/AbstractWizardPage.java?rev=619368&view=auto
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/AbstractWizardPage.java
(added)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/AbstractWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -0,0 +1,90 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+package org.apache.directory.studio.schemaeditor.view.wizards;
+
+
+import org.eclipse.jface.dialogs.DialogPage;
+import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.wizard.WizardPage;
+
+
+/**
+ * This abstract class extends {@link WizardPage} and holds common methods
+ * for all our {@link WizardPage}s.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
+ */
+public abstract class AbstractWizardPage extends WizardPage
+{
+ /**
+ * Creates a new wizard page with the given name, title, and image.
+ *
+ * @param pageName the name of the page
+ * @param title the title for this wizard page,
+ * or <code>null</code> if none
+ * @param titleImage the image descriptor for the title of this wizard page,
+ * or <code>null</code> if none
+ */
+ protected AbstractWizardPage( String pageName, String title, ImageDescriptor titleImage
)
+ {
+ super( pageName, title, titleImage );
+ }
+
+
+ /**
+ * Creates a new wizard page with the given name, and
+ * with no title or image.
+ *
+ * @param pageName the name of the page
+ */
+ protected AbstractWizardPage( String pageName )
+ {
+ super( pageName );
+ }
+
+
+ /**
+ * Displays an error message and set the page status as incomplete
+ * if the message is not null.
+ *
+ * @param message
+ * the message to display
+ */
+ protected void displayErrorMessage( String message )
+ {
+ setErrorMessage( message );
+ setPageComplete( message == null );
+ }
+
+
+ /**
+ * Displays a warning message and set the page status as complete.
+ *
+ * @param message
+ * the message to display
+ */
+ protected void displayWarningMessage( String message )
+ {
+ setErrorMessage( null );
+ setMessage( message, DialogPage.WARNING );
+ setPageComplete( true );
+ }
+}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportProjectsWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportProjectsWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportProjectsWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportProjectsWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -35,7 +35,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -64,7 +63,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ExportProjectsWizardPage extends WizardPage
+public class ExportProjectsWizardPage extends AbstractWizardPage
{
/** The selected projects */
private Project[] selectedProjects = new Project[0];
@@ -312,20 +311,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsOpenLdapWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsOpenLdapWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsOpenLdapWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsOpenLdapWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -35,7 +35,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -64,7 +63,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ExportSchemasAsOpenLdapWizardPage extends WizardPage
+public class ExportSchemasAsOpenLdapWizardPage extends AbstractWizardPage
{
/** The selected schemas */
private Schema[] selectedSchemas = new Schema[0];
@@ -284,7 +283,7 @@
displayErrorMessage( "A Schema Project must be open to export schemas as OpenLDAP
files." );
return;
}
-
+
// Schemas table
if ( schemasTableViewer.getCheckedElements().length == 0 )
{
@@ -320,20 +319,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsXmlWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsXmlWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsXmlWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasAsXmlWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -35,7 +35,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -65,7 +64,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ExportSchemasAsXmlWizardPage extends WizardPage
+public class ExportSchemasAsXmlWizardPage extends AbstractWizardPage
{
/** The selected schemas */
private Schema[] selectedSchemas = new Schema[0];
@@ -469,20 +468,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasForADSWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasForADSWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasForADSWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ExportSchemasForADSWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -35,7 +35,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -65,7 +64,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ExportSchemasForADSWizardPage extends WizardPage
+public class ExportSchemasForADSWizardPage extends AbstractWizardPage
{
/** The selected schemas */
private Schema[] selectedSchemas = new Schema[0];
@@ -469,20 +468,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportCoreSchemasWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportCoreSchemasWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportCoreSchemasWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportCoreSchemasWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -42,7 +42,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ImportCoreSchemasWizardPage extends WizardPage
+public class ImportCoreSchemasWizardPage extends AbstractWizardPage
{
// UI Fields
private CoreSchemasSelectionWidget coreSchemaSelectionWidget;
@@ -102,20 +102,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportProjectsWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportProjectsWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportProjectsWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportProjectsWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -31,7 +31,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -60,7 +59,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ImportProjectsWizardPage extends WizardPage
+public class ImportProjectsWizardPage extends AbstractWizardPage
{
// UI Fields
private Text fromDirectoryText;
@@ -304,20 +303,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromOpenLdapWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromOpenLdapWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromOpenLdapWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromOpenLdapWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -31,7 +31,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -60,7 +59,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ImportSchemasFromOpenLdapWizardPage extends WizardPage
+public class ImportSchemasFromOpenLdapWizardPage extends AbstractWizardPage
{
// UI Fields
private Text fromDirectoryText;
@@ -312,20 +311,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromXmlWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromXmlWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromXmlWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/ImportSchemasFromXmlWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -31,7 +31,6 @@
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -60,7 +59,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class ImportSchemasFromXmlWizardPage extends WizardPage
+public class ImportSchemasFromXmlWizardPage extends AbstractWizardPage
{
// UI Fields
private Text fromDirectoryText;
@@ -312,20 +311,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeContentWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeContentWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeContentWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeContentWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -37,7 +37,6 @@
import org.eclipse.jface.viewers.ComboViewer;
import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -64,7 +63,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class NewAttributeTypeContentWizardPage extends WizardPage
+public class NewAttributeTypeContentWizardPage extends AbstractWizardPage
{
/** The SchemaHandler */
private SchemaHandler schemaHandler;
@@ -321,20 +320,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -37,14 +37,12 @@
import org.apache.directory.studio.schemaeditor.model.alias.AliasesStringParser;
import org.apache.directory.studio.schemaeditor.view.dialogs.EditAliasesDialog;
import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.DialogPage;
import org.eclipse.jface.viewers.ArrayContentProvider;
import org.eclipse.jface.viewers.ComboViewer;
import org.eclipse.jface.viewers.ISelectionChangedListener;
import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -72,7 +70,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class NewAttributeTypeGeneralWizardPage extends WizardPage
+public class NewAttributeTypeGeneralWizardPage extends AbstractWizardPage
{
/** The SchemaHandler */
private SchemaHandler schemaHandler;
@@ -359,35 +357,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setMessage( null, DialogPage.WARNING );
- setErrorMessage( message );
- setPageComplete( message == null );
- }
-
-
- /**
- * Displays a warning message and set the page status as complete.
- *
- * @param message
- * the message to display
- */
- private void displayWarningMessage( String message )
- {
- setErrorMessage( null );
- setMessage( message, DialogPage.WARNING );
- setPageComplete( true );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -37,14 +37,12 @@
import org.apache.directory.studio.schemaeditor.model.alias.AliasesStringParser;
import org.apache.directory.studio.schemaeditor.view.dialogs.EditAliasesDialog;
import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.DialogPage;
import org.eclipse.jface.viewers.ArrayContentProvider;
import org.eclipse.jface.viewers.ComboViewer;
import org.eclipse.jface.viewers.ISelectionChangedListener;
import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -72,7 +70,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class NewObjectClassGeneralPageWizardPage extends WizardPage
+public class NewObjectClassGeneralPageWizardPage extends AbstractWizardPage
{
/** The SchemaHandler */
private SchemaHandler schemaHandler;
@@ -359,35 +357,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setMessage( null, DialogPage.WARNING );
- setErrorMessage( message );
- setPageComplete( message == null );
- }
-
-
- /**
- * Displays a warning message and set the page status as complete.
- *
- * @param message
- * the message to display
- */
- private void displayWarningMessage( String message )
- {
- setErrorMessage( null );
- setMessage( message, DialogPage.WARNING );
- setPageComplete( true );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardConnectionSelectionPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardConnectionSelectionPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardConnectionSelectionPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardConnectionSelectionPage.java
Thu Feb 7 03:35:01 2008
@@ -32,7 +32,6 @@
import org.eclipse.jface.viewers.ISelectionChangedListener;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
@@ -49,7 +48,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class NewProjectWizardConnectionSelectionPage extends WizardPage
+public class NewProjectWizardConnectionSelectionPage extends AbstractWizardPage
{
private ConnectionConfiguration configuration;
private ConnectionUniversalListener universalListener;
@@ -141,20 +140,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardInformationPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardInformationPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardInformationPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewProjectWizardInformationPage.java
Thu Feb 7 03:35:01 2008
@@ -22,10 +22,8 @@
import org.apache.directory.studio.schemaeditor.Activator;
import org.apache.directory.studio.schemaeditor.PluginConstants;
-import org.apache.directory.studio.schemaeditor.PluginUtils;
import org.apache.directory.studio.schemaeditor.controller.ProjectsHandler;
import org.apache.directory.studio.schemaeditor.model.ProjectType;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -33,7 +31,6 @@
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.plugin.AbstractUIPlugin;
@@ -47,7 +44,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class NewProjectWizardInformationPage extends WizardPage
+public class NewProjectWizardInformationPage extends AbstractWizardPage
{
/** The ProjectsHandler */
private ProjectsHandler projectsHandler;
@@ -94,42 +91,41 @@
}
} );
-// if ( PluginUtils.getSchemaConnectors().size() > 0 )
-// {
-// // Type Group
-// Group typeGroup = new Group( composite, SWT.NONE );
-// typeGroup.setText( "Type" );
-// typeGroup.setLayout( new GridLayout() );
-// typeGroup.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true, false, 2,
1 ) );
-//
-// typeOfflineRadio = new Button( typeGroup, SWT.RADIO );
-// typeOfflineRadio.setText( "Offline Schema" );
-// typeOfflineRadio.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true, false
) );
-// typeOnlineRadio = new Button( typeGroup, SWT.RADIO );
-// typeOnlineRadio.setText( "Online Schema from a Directory Server" );
-// typeOnlineRadio.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true, false
) );
-// }
+ // if ( PluginUtils.getSchemaConnectors().size() > 0 )
+ // {
+ // // Type Group
+ // Group typeGroup = new Group( composite, SWT.NONE );
+ // typeGroup.setText( "Type" );
+ // typeGroup.setLayout( new GridLayout() );
+ // typeGroup.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true, false,
2, 1 ) );
+ //
+ // typeOfflineRadio = new Button( typeGroup, SWT.RADIO );
+ // typeOfflineRadio.setText( "Offline Schema" );
+ // typeOfflineRadio.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true,
false ) );
+ // typeOnlineRadio = new Button( typeGroup, SWT.RADIO );
+ // typeOnlineRadio.setText( "Online Schema from a Directory Server" );
+ // typeOnlineRadio.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true,
false ) );
+ // }
-// initFields();
+ // initFields();
setControl( composite );
}
-// /**
-// * Initializes the UI Fields.
-// */
-// private void initFields()
-// {
-// if ( typeOfflineRadio != null )
-// {
-// typeOfflineRadio.setSelection( true );
-// }
-//
-// displayErrorMessage( null );
-// setPageComplete( false );
-// }
-
+ // /**
+ // * Initializes the UI Fields.
+ // */
+ // private void initFields()
+ // {
+ // if ( typeOfflineRadio != null )
+ // {
+ // typeOfflineRadio.setSelection( true );
+ // }
+ //
+ // displayErrorMessage( null );
+ // setPageComplete( false );
+ // }
/**
* This method is called when the user modifies something in the UI.
@@ -149,20 +145,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
Modified: directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewSchemaWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewSchemaWizardPage.java?rev=619368&r1=619367&r2=619368&view=diff
==============================================================================
--- directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewSchemaWizardPage.java
(original)
+++ directory/studio/trunk/studio-schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewSchemaWizardPage.java
Thu Feb 7 03:35:01 2008
@@ -23,7 +23,6 @@
import org.apache.directory.studio.schemaeditor.Activator;
import org.apache.directory.studio.schemaeditor.PluginConstants;
import org.apache.directory.studio.schemaeditor.controller.SchemaHandler;
-import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -43,7 +42,7 @@
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
* @version $Rev$, $Date$
*/
-public class NewSchemaWizardPage extends WizardPage
+public class NewSchemaWizardPage extends AbstractWizardPage
{
/** The ProjectsHandler */
private SchemaHandler schemaHandler;
@@ -122,20 +121,6 @@
}
displayErrorMessage( null );
- }
-
-
- /**
- * Displays an error message and set the page status as incomplete
- * if the message is not null.
- *
- * @param message
- * the message to display
- */
- private void displayErrorMessage( String message )
- {
- setErrorMessage( message );
- setPageComplete( message == null );
}
|