Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortle2008-10-27 02:07:43 +0000
committertle2008-10-27 02:07:43 +0000
commit23d34dff043c93319f11a781ce2335adca038af0 (patch)
tree056c0d613d683f2c3bd34715416bdf16770bc1a9 /jpa/plugins
parentfa17b2531e9e0fc28593834fdcfe4663fcfc73cf (diff)
downloadwebtools.dali-23d34dff043c93319f11a781ce2335adca038af0.tar.gz
webtools.dali-23d34dff043c93319f11a781ce2335adca038af0.tar.xz
webtools.dali-23d34dff043c93319f11a781ce2335adca038af0.zip
Added EclipseLink General tab
Diffstat (limited to 'jpa/plugins')
-rw-r--r--jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/general/PersistenceXmlGeneralTab.java82
1 files changed, 82 insertions, 0 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/general/PersistenceXmlGeneralTab.java b/jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/general/PersistenceXmlGeneralTab.java
new file mode 100644
index 0000000000..ded8dc9495
--- /dev/null
+++ b/jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/general/PersistenceXmlGeneralTab.java
@@ -0,0 +1,82 @@
+/*******************************************************************************
+ * Copyright (c) 2007, 2008 Oracle. 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.
+ *
+ * Contributors:
+ * Oracle - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.jpt.eclipselink.ui.internal.general;
+
+import org.eclipse.jpt.eclipselink.core.internal.context.general.GeneralProperties;
+import org.eclipse.jpt.eclipselink.ui.internal.EclipseLinkUiMessages;
+import org.eclipse.jpt.ui.WidgetFactory;
+import org.eclipse.jpt.ui.details.JpaPageComposite;
+import org.eclipse.jpt.ui.internal.widgets.FormPane;
+import org.eclipse.jpt.utility.model.value.PropertyValueModel;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Composite;
+
+/**
+ * PersistenceXmlGeneralTab
+ */
+public class PersistenceXmlGeneralTab
+ extends FormPane<GeneralProperties>
+ implements JpaPageComposite
+{
+ // ********** constructors/initialization **********
+ public PersistenceXmlGeneralTab(
+ PropertyValueModel<GeneralProperties> subjectHolder,
+ Composite parent,
+ WidgetFactory widgetFactory) {
+
+ super(subjectHolder, parent, widgetFactory);
+ }
+
+ @Override
+ protected void initializeLayout(Composite container) {
+ new EclipseLinkGeneralComposite(this, container);
+ }
+
+ // ********** JpaPageComposite implementation **********
+ public String getHelpID() {
+ return null;
+ }
+
+ public Image getPageImage() {
+ return null;
+ }
+
+ public String getPageText() {
+ return EclipseLinkUiMessages.PersistenceXmlGeneralTab_title;
+ }
+
+ // ********** Layout **********
+ @Override
+ protected Composite addContainer(Composite parent) {
+ GridLayout layout = new GridLayout(1, true);
+ layout.marginHeight = 0;
+ layout.marginWidth = 0;
+ layout.marginTop = 0;
+ layout.marginLeft = 0;
+ layout.marginBottom = 0;
+ layout.marginRight = 0;
+ layout.verticalSpacing = 15;
+ Composite container = this.addPane(parent, layout);
+ this.updateGridData(container);
+ return container;
+ }
+
+ private void updateGridData(Composite container) {
+ GridData gridData = new GridData();
+ gridData.grabExcessHorizontalSpace = true;
+ gridData.grabExcessVerticalSpace = true;
+ gridData.horizontalAlignment = SWT.FILL;
+ gridData.verticalAlignment = SWT.FILL;
+ container.setLayoutData(gridData);
+ }
+}

Back to the top