Author: dmaliarevich
Date: 2009-10-09 11:31:44 -0400 (Fri, 09 Oct 2009)
New Revision: 18013
Modified:
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/preferences/VpeEditorPreferencesPage.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-4975, Setting up the correct preference page
size.
Modified:
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/preferences/VpeEditorPreferencesPage.java
===================================================================
---
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/preferences/VpeEditorPreferencesPage.java 2009-10-09
15:30:34 UTC (rev 18012)
+++
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/preferences/VpeEditorPreferencesPage.java 2009-10-09
15:31:44 UTC (rev 18013)
@@ -11,13 +11,13 @@
package org.jboss.tools.vpe.editor.preferences;
import org.eclipse.jface.preference.PreferenceDialog;
+import org.eclipse.swt.SWT;
import org.eclipse.ui.IWorkbenchPreferencePage;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.dialogs.PreferencesUtil;
import org.jboss.tools.common.model.ui.preferences.TabbedPreferencesPage;
public class VpeEditorPreferencesPage extends TabbedPreferencesPage implements
IWorkbenchPreferencePage {
-
public static final String ID = "org.jboss.tools.vpe.editor"; //$NON-NLS-1$
public VpeEditorPreferencesPage() {
@@ -29,10 +29,16 @@
PreferenceDialog prefsdlg = PreferencesUtil.createPreferenceDialogOn(
PlatformUI.getWorkbench().getDisplay().getActiveShell(),
- ID, new String[] {
- ID }, null);
-
+ ID, new String[] { ID }, null);
+ /*
+ *
https://jira.jboss.org/jira/browse/JBIDE-4975
+ * Setting up the correct preference page size.
+ * Without specifying any preferred size
+ * the default constrained Shell bounds are used,
+ * which are not always optimal.
+ */
+ prefsdlg.getShell().setSize(prefsdlg.getShell().computeSize(SWT.DEFAULT,
SWT.DEFAULT));
prefsdlg.open();
}
-
+
}
\ No newline at end of file