JBoss Tools SVN: r21603 - trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/modules.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2010-04-22 04:47:28 -0400 (Thu, 22 Apr 2010)
New Revision: 21603
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/modules/SingleDeployableFactory.java
Log:
JBIDE-5780 - completed
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/modules/SingleDeployableFactory.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/modules/SingleDeployableFactory.java 2010-04-22 08:05:53 UTC (rev 21602)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/modules/SingleDeployableFactory.java 2010-04-22 08:47:28 UTC (rev 21603)
@@ -17,12 +17,15 @@
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
+import java.util.Set;
+import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.IResourceChangeEvent;
import org.eclipse.core.resources.IResourceChangeListener;
import org.eclipse.core.resources.IResourceDelta;
import org.eclipse.core.resources.IResourceDeltaVisitor;
+import org.eclipse.core.resources.ProjectScope;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
@@ -33,6 +36,8 @@
import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Status;
import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.core.runtime.preferences.IEclipsePreferences;
+import org.eclipse.core.runtime.preferences.IScopeContext;
import org.eclipse.osgi.util.NLS;
import org.eclipse.wst.server.core.IModule;
import org.eclipse.wst.server.core.IServer;
@@ -50,6 +55,7 @@
import org.jboss.ide.eclipse.as.core.Messages;
import org.jboss.ide.eclipse.as.core.server.UnitedServerListener;
import org.jboss.ide.eclipse.as.core.server.UnitedServerListenerManager;
+import org.osgi.service.prefs.BackingStoreException;
/**
* The factory responsible for turning regular files into modules
@@ -62,6 +68,7 @@
public static final String MODULE_TYPE = "jboss.singlefile"; //$NON-NLS-1$
public static final String VERSION = "1.0"; //$NON-NLS-1$
private static final String PREFERENCE_KEY = "org.jboss.ide.eclipse.as.core.singledeployable.deployableList"; //$NON-NLS-1$
+ private static final String STORED_IN_PROJECTS_PREF_KEY = "org.jboss.ide.eclipse.as.core.singledeployable.storedInProjectKey"; //$NON-NLS-1$
private static final String DELIM = "\r"; //$NON-NLS-1$
@@ -123,6 +130,33 @@
moduleIdToModule = new HashMap<IPath, IModule>();
moduleToDelegate = new HashMap<IModule, SingleDeployableModuleDelegate>();
registerListener();
+ String storeInProjects = JBossServerCorePlugin.getDefault().getPluginPreferences().getString(STORED_IN_PROJECTS_PREF_KEY);
+ if( storeInProjects != null ) {
+ projectLoad();
+ } else {
+ legacyLoad();
+ }
+ }
+
+ protected void projectLoad() {
+ IProject[] allProjects = ResourcesPlugin.getWorkspace().getRoot().getProjects();
+ String qualifier = JBossServerCorePlugin.getDefault().getDescriptor().getUniqueIdentifier();
+ for( int i = 0; i < allProjects.length; i++) {
+ IScopeContext context = new ProjectScope(allProjects[i]);
+ IEclipsePreferences node = context.getNode(qualifier);
+ String val = node.get(PREFERENCE_KEY, ""); //$NON-NLS-1$
+ String[] paths = val.split("\n"); //$NON-NLS-1$
+ IPath tmp;
+ for( int j = 0; j < paths.length; j++ ) {
+ if( !paths[j].trim().equals("")) { //$NON-NLS-1$
+ tmp = new Path(allProjects[i].getName()).append(paths[j]);
+ addModule(tmp);
+ }
+ }
+ }
+ }
+
+ protected void legacyLoad() {
String files = JBossServerCorePlugin.getDefault().getPluginPreferences().getString(PREFERENCE_KEY);
if( files.equals("")) return; //$NON-NLS-1$
String[] files2 = files.split(DELIM);
@@ -130,6 +164,46 @@
addModule(new Path(files2[i]));
}
}
+
+ public void saveDeployableList() {
+ HashMap<String, String> map = new HashMap<String, String>();
+ IProject[] allProjects = ResourcesPlugin.getWorkspace().getRoot().getProjects();
+ for( int i = 0; i < allProjects.length; i++)
+ map.put(allProjects[i].getName(), ""); //$NON-NLS-1$
+
+ Set<IPath> allPaths = moduleIdToModule.keySet();
+ Iterator<IPath> j = allPaths.iterator();
+ IPath tmp;
+ while(j.hasNext()) {
+ tmp = j.next();
+ map.put(tmp.segment(0), map.get(tmp.segment(0)) + tmp.removeFirstSegments(1).makeRelative() + "\n"); //$NON-NLS-1$
+ }
+
+ String qualifier = JBossServerCorePlugin.getDefault().getDescriptor().getUniqueIdentifier();
+ for( int k = 0; k < allProjects.length; k++ ) {
+ IScopeContext context = new ProjectScope(allProjects[k]);
+ IEclipsePreferences node = context.getNode(qualifier);
+ if (node != null)
+ node.put(PREFERENCE_KEY, map.get(allProjects[k].getName()));
+ try {
+ node.flush();
+ } catch (BackingStoreException e) {
+ // TODO Log
+ }
+ }
+ }
+
+ /* This is not called but keeping it around for now just in case */
+ public void legacySaveDeployableList() {
+ Iterator<IPath> i = moduleIdToModule.keySet().iterator();
+ String val = ""; //$NON-NLS-1$
+ while(i.hasNext()) {
+ val += i.next().toString() + DELIM;
+ }
+ JBossServerCorePlugin.getDefault().getPluginPreferences().setValue(PREFERENCE_KEY, val);
+ JBossServerCorePlugin.getDefault().savePluginPreferences();
+ }
+
protected void registerListener() {
UnitedServerListenerManager.getDefault().addListener(new UnitedServerListener() {
@@ -176,16 +250,6 @@
return moduleIdToModule.get(path);
}
- public void saveDeployableList() {
- Iterator<IPath> i = moduleIdToModule.keySet().iterator();
- String val = ""; //$NON-NLS-1$
- while(i.hasNext()) {
- val += i.next().toString() + DELIM;
- }
- JBossServerCorePlugin.getDefault().getPluginPreferences().setValue(PREFERENCE_KEY, val);
- JBossServerCorePlugin.getDefault().savePluginPreferences();
- }
-
protected boolean addModule(IPath path) {
IResource resource = ResourcesPlugin.getWorkspace().getRoot().findMember(path);
if( resource != null && resource.exists() ) {
14 years, 8 months
JBoss Tools SVN: r21602 - branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor.
by jbosstools-commits@lists.jboss.org
Author: yzhishko
Date: 2010-04-22 04:05:53 -0400 (Thu, 22 Apr 2010)
New Revision: 21602
Modified:
branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5744 - patch is applied
Modified: branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java
===================================================================
--- branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java 2010-04-22 07:58:31 UTC (rev 21601)
+++ branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java 2010-04-22 08:05:53 UTC (rev 21602)
@@ -442,7 +442,14 @@
/*
* Container composite for editor part
*/
- cmpEdTl = new Composite(parent, SWT.NONE);
+ /*
+ * Fix for https://jira.jboss.org/jira/browse/JBIDE-5744
+ * Where is a problem with composite parent redrawing in a case
+ * cmpEdTl = new Composite (parent, SWT.NONE)
+ * P. S.: Reproducible under Win x64 on Eclipse 32
+ * see https://bugs.eclipse.org/bugs/show_bug.cgi?id=302950
+ */
+ cmpEdTl = parent;
GridLayout layoutEdTl = new GridLayout(2, false);
layoutEdTl.verticalSpacing = 0;
layoutEdTl.marginHeight = 0;
14 years, 8 months
JBoss Tools SVN: r21601 - branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor.
by jbosstools-commits@lists.jboss.org
Author: yzhishko
Date: 2010-04-22 03:58:31 -0400 (Thu, 22 Apr 2010)
New Revision: 21601
Modified:
branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-6145 - patch is applied
Modified: branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java
===================================================================
--- branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java 2010-04-22 07:55:10 UTC (rev 21600)
+++ branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java 2010-04-22 07:58:31 UTC (rev 21601)
@@ -1065,12 +1065,15 @@
IHandlerService handlerService = (IHandlerService) workbench
.getService(IHandlerService.class);
if (handlerService != null) {
+ if(sourceActivation != null) handlerService.deactivateHandler(sourceActivation);
sourceActivation = handlerService.activateHandler(
VPE_SOURCE_MAXMIN,
sourceMaxmin);
+ if(visualActivation != null) handlerService.deactivateHandler(visualActivation);
visualActivation = handlerService.activateHandler(
VPE_VISUAL_MAXMIN,
visualMaxmin);
+ if(jumpingActivation != null) handlerService.deactivateHandler(jumpingActivation);
jumpingActivation = handlerService.activateHandler(
VPE_JUMPING,
jumping);
14 years, 8 months
JBoss Tools SVN: r21600 - in branches/jbosstools-3.1.x: jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/5143 and 3 other directories.
by jbosstools-commits@lists.jboss.org
Author: yzhishko
Date: 2010-04-22 03:55:10 -0400 (Thu, 22 Apr 2010)
New Revision: 21600
Added:
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/5143/
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/5143/test.html
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/ExceptionInVPEComments_JBIDE5143.java
Modified:
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe.html/src/org/jboss/tools/vpe/html/template/HtmlCommentTemplate.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5143 patch is applied.
Added: branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/5143/test.html
===================================================================
--- branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/5143/test.html (rev 0)
+++ branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/5143/test.html 2010-04-22 07:55:10 UTC (rev 21600)
@@ -0,0 +1,10 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>Insert title here</title>
+</head>
+<body>
+ <span>Test --text</span>-->
+</body>
+</html>
\ No newline at end of file
Modified: branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
===================================================================
--- branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2010-04-21 22:59:15 UTC (rev 21599)
+++ branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2010-04-22 07:55:10 UTC (rev 21600)
@@ -19,6 +19,7 @@
import org.jboss.tools.jsf.vpe.jsf.test.jbide.ChangeMessageBundleTest_JBIDE5818;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.ContextMenuDoubleInsertionTest_JBIDE3888;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.EditFontFamilyTest_JBIDE5872;
+import org.jboss.tools.jsf.vpe.jsf.test.jbide.ExceptionInVPEComments_JBIDE5143;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.FacetProcessingTest;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE1105Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE1460Test;
@@ -216,6 +217,7 @@
suite.addTestSuite(NaturesChecker_JBIDE5701.class);
suite.addTestSuite(FacetProcessingTest.class);
suite.addTestSuite(RefreshBundles_JBIDE5460.class);
+ suite.addTestSuite(ExceptionInVPEComments_JBIDE5143.class);
// $JUnit-END$
// added by Max Areshkau
Added: branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/ExceptionInVPEComments_JBIDE5143.java
===================================================================
--- branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/ExceptionInVPEComments_JBIDE5143.java (rev 0)
+++ branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/ExceptionInVPEComments_JBIDE5143.java 2010-04-22 07:55:10 UTC (rev 21600)
@@ -0,0 +1,62 @@
+/*******************************************************************************
+ * Copyright (c) 2007-2008 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is 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
+ *
+ * Contributor:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+
+package org.jboss.tools.jsf.vpe.jsf.test.jbide;
+
+import org.eclipse.core.resources.IFile;
+import org.eclipse.swt.custom.StyledText;
+import org.eclipse.ui.IEditorInput;
+import org.eclipse.ui.part.FileEditorInput;
+import org.jboss.tools.jsf.vpe.jsf.test.JsfAllTests;
+import org.jboss.tools.jst.jsp.jspeditor.JSPMultiPageEditor;
+import org.jboss.tools.vpe.ui.test.TestUtil;
+import org.jboss.tools.vpe.ui.test.VpeTest;
+
+/**
+ *
+ * @author yzhishko
+ *
+ */
+
+public class ExceptionInVPEComments_JBIDE5143 extends VpeTest {
+
+ public ExceptionInVPEComments_JBIDE5143(String name) {
+ super(name);
+ }
+
+ public void testExceptionInVPEComments() throws Throwable {
+ setException(null);
+ IFile file = (IFile) TestUtil.getComponentPath("JBIDE/5143/test.html", //$NON-NLS-1$
+ JsfAllTests.IMPORT_PROJECT_NAME);
+ IEditorInput editorInput = new FileEditorInput(file);
+ JSPMultiPageEditor part = openEditor(editorInput);
+ TestUtil.delay(3000);
+ TestUtil.waitForIdle();
+ StyledText styledText = part.getSourceEditor().getTextViewer()
+ .getTextWidget();
+ String delimiter = styledText.getLineDelimiter();
+ int offset = styledText.getOffsetAtLine(8);
+ styledText.setCaretOffset(offset - delimiter.length() - 28);
+ styledText.insert("-"); //$NON-NLS-1$
+ TestUtil.delay(1000);
+ TestUtil.waitForIdle();
+ styledText.insert("-"); //$NON-NLS-1$
+ TestUtil.delay(1000);
+ TestUtil.waitForIdle();
+ styledText.insert("!"); //$NON-NLS-1$
+ TestUtil.delay(1000);
+ TestUtil.waitForIdle();
+ styledText.insert("<"); //$NON-NLS-1$
+ TestUtil.delay(1000);
+ TestUtil.waitForIdle();
+ }
+
+}
Modified: branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe.html/src/org/jboss/tools/vpe/html/template/HtmlCommentTemplate.java
===================================================================
--- branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe.html/src/org/jboss/tools/vpe/html/template/HtmlCommentTemplate.java 2010-04-21 22:59:15 UTC (rev 21599)
+++ branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe.html/src/org/jboss/tools/vpe/html/template/HtmlCommentTemplate.java 2010-04-22 07:55:10 UTC (rev 21600)
@@ -28,7 +28,9 @@
* Template for comment node
*/
public class HtmlCommentTemplate extends VpeAbstractTemplate {
+
+ private static final String doubleHyphen = "--"; //$NON-NLS-1$
private static final String COMMENT_STYLE = "font-style:italic; color:green"; //$NON-NLS-1$
/* (non-Javadoc)
* @see org.jboss.tools.vpe.editor.template.VpeTemplate#create(org.jboss.tools.vpe.editor.context.VpePageContext, org.w3c.dom.Node, org.mozilla.interfaces.nsIDOMDocument)
@@ -44,9 +46,21 @@
((nsIDOMElement)visualNode.queryInterface(nsIDOMElement.NS_IDOMELEMENT_IID)).appendChild(text);
} else {
- visualNode = visualDocument.createComment(sourceNode.getNodeValue());
+ visualNode = visualDocument.createComment(removeDoubleHyphens(sourceNode.getNodeValue()));
}
return new VpeCreationData(visualNode);
}
+
+ //a part of https://jira.jboss.org/jira/browse/JBIDE-5143 fix
+
+ private String removeDoubleHyphens(String value){
+ StringBuilder stringBuilder = new StringBuilder(""); //$NON-NLS-1$
+ while (value.indexOf(doubleHyphen)>-1) {
+ stringBuilder.append(value.substring(0, value.indexOf(doubleHyphen)));
+ value = value.substring(value.indexOf(doubleHyphen)+doubleHyphen.length());
+ }
+ stringBuilder.append(value);
+ return stringBuilder.toString();
+ }
}
14 years, 8 months
JBoss Tools SVN: r21599 - branches/modular_build/ws/plugins/org.jboss.tools.ws.creation.core/META-INF.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2010-04-21 18:59:15 -0400 (Wed, 21 Apr 2010)
New Revision: 21599
Modified:
branches/modular_build/ws/plugins/org.jboss.tools.ws.creation.core/META-INF/MANIFEST.MF
Log:
add org.eclipse.jem.util to manifest
Modified: branches/modular_build/ws/plugins/org.jboss.tools.ws.creation.core/META-INF/MANIFEST.MF
===================================================================
--- branches/modular_build/ws/plugins/org.jboss.tools.ws.creation.core/META-INF/MANIFEST.MF 2010-04-21 15:45:45 UTC (rev 21598)
+++ branches/modular_build/ws/plugins/org.jboss.tools.ws.creation.core/META-INF/MANIFEST.MF 2010-04-21 22:59:15 UTC (rev 21599)
@@ -11,6 +11,7 @@
org.eclipse.wst.ws,
org.eclipse.core.resources,
org.eclipse.jst.ws,
+ org.eclipse.jem.util,
org.jboss.tools.ws.core,
org.eclipse.wst.wsdl,
org.eclipse.wst.command.env.core,
14 years, 8 months
JBoss Tools SVN: r21598 - trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/standard.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2010-04-21 11:45:45 -0400 (Wed, 21 Apr 2010)
New Revision: 21598
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/standard/DefaultStandardStep.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5946
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/standard/DefaultStandardStep.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/standard/DefaultStandardStep.java 2010-04-21 15:31:43 UTC (rev 21597)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/standard/DefaultStandardStep.java 2010-04-21 15:45:45 UTC (rev 21598)
@@ -14,6 +14,7 @@
import java.util.Properties;
import org.eclipse.jface.preference.FieldEditor;
+import org.eclipse.jface.wizard.IWizard;
import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.widgets.Composite;
import org.jboss.tools.common.meta.action.XAttributeData;
@@ -51,9 +52,11 @@
attributes = null;
}
- public void setWizard(DefaultStandardWizard wizard) {
+ public void setWizard(IWizard wizard) {
super.setWizard(wizard);
- this.wizard = wizard;
+ if(wizard instanceof DefaultStandardWizard) {
+ this.wizard = (DefaultStandardWizard)wizard;
+ }
}
public void createControl(Composite parent) {
14 years, 8 months
JBoss Tools SVN: r21597 - branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2010-04-21 11:31:43 -0400 (Wed, 21 Apr 2010)
New Revision: 21597
Modified:
branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-6107 applying patch to 3.1.1
Modified: branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java
===================================================================
--- branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java 2010-04-21 15:29:06 UTC (rev 21596)
+++ branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java 2010-04-21 15:31:43 UTC (rev 21597)
@@ -1069,14 +1069,14 @@
.startActiveEditor(ActiveEditorSwitcher.ACTIVE_EDITOR_VISUAL)) {
try {
mouseUpSelectionReasonFlag = (reason & nsISelectionListener.MOUSEUP_REASON) > 0;
- if (mouseUpSelectionReasonFlag
+ if (
// commited by Dzmitrovich - experimental
// TODO check selection and if are appear errors then
// uncommented next code
- // || reason == nsISelectionListener.NO_REASON
- || reason == nsISelectionListener.KEYPRESS_REASON
- || reason == nsISelectionListener.SELECTALL_REASON
- || (reason & nsISelectionListener.MOUSEDOWN_REASON) > 0) {
+ // reason != nsISelectionListener.NO_REASON
+ reason == nsISelectionListener.KEYPRESS_REASON
+ || reason == nsISelectionListener.SELECTALL_REASON)
+ {
if (VpeDebug.PRINT_VISUAL_SELECTION_EVENT) {
System.out
.println("<<< notifySelectionChanged: " + reason); //$NON-NLS-1$
14 years, 8 months
JBoss Tools SVN: r21596 - branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/drop/treeviewer/model.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2010-04-21 11:29:06 -0400 (Wed, 21 Apr 2010)
New Revision: 21596
Modified:
branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/drop/treeviewer/model/AttributeValueResourceFactory.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5855
Modified: branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/drop/treeviewer/model/AttributeValueResourceFactory.java
===================================================================
--- branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/drop/treeviewer/model/AttributeValueResourceFactory.java 2010-04-21 15:20:42 UTC (rev 21595)
+++ branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/drop/treeviewer/model/AttributeValueResourceFactory.java 2010-04-21 15:29:06 UTC (rev 21596)
@@ -80,6 +80,8 @@
return new IDResourceElement("Validator IDs", root, pageContext, proposalType, kbQuery); //$NON-NLS-1$
} else if("seamVariables".equals(type)) { //$NON-NLS-1$
return new SeamVariablesResourceElement(editorInput, "Seam Variables", root); //$NON-NLS-1$
+ } else if(CustomProposalTypeFactory.CSSCLASS_TYPE.equals(type)) {
+ return new IDResourceElement("CSS Classes", root, pageContext, proposalType, kbQuery); //$NON-NLS-1$
}
return new UnknownAttributeValueResource(MessageFormat.format(JstUIMessages.AttributeValueResourceFactory_UnknownResourceType, type), root);
// throw new RuntimeException("Unknown resource type:" + type);
14 years, 8 months
JBoss Tools SVN: r21595 - branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/jspeditor.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2010-04-21 11:20:42 -0400 (Wed, 21 Apr 2010)
New Revision: 21595
Modified:
branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/jspeditor/JSPTextEditor.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5998
Modified: branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/jspeditor/JSPTextEditor.java
===================================================================
--- branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/jspeditor/JSPTextEditor.java 2010-04-21 15:13:19 UTC (rev 21594)
+++ branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/jspeditor/JSPTextEditor.java 2010-04-21 15:20:42 UTC (rev 21595)
@@ -66,6 +66,7 @@
import org.eclipse.ui.IActionBars;
import org.eclipse.ui.IEditorInput;
import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.editors.text.ILocationProvider;
import org.eclipse.ui.texteditor.ITextEditor;
@@ -148,6 +149,7 @@
import org.jboss.tools.jst.web.kb.taglib.IAttribute;
import org.jboss.tools.jst.web.kb.taglib.IComponent;
import org.jboss.tools.jst.web.kb.taglib.INameSpace;
+import org.jboss.tools.jst.web.kb.taglib.ITagLibrary;
import org.jboss.tools.jst.web.kb.taglib.TagLibraryManager;
import org.jboss.tools.jst.web.tld.VpeTaglibManager;
import org.jboss.tools.jst.web.tld.VpeTaglibManagerProvider;
@@ -735,7 +737,13 @@
public void runDropCommand(final String flavor, final String data) {
XModelBuffer b = XModelTransferBuffer.getInstance().getBuffer();
final XModelObject o = b == null ? null : b.source();
- Display.getDefault().asyncExec(new Runnable() {
+ /*
+ * Fixes https://jira.jboss.org/jira/browse/JBIDE-5874
+ * Display.getDefault() should always be replaced by
+ * PlatformUI.getWorkbench().getDisplay().
+ * syncExec() can hang the JBDS thus asyncExec is used.
+ */
+ PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
public void run() {
if (o != null
&& !XModelTransferBuffer.getInstance().isEnabled()) {
@@ -790,6 +798,7 @@
if(n == null && pageContext instanceof JspContextImpl) {
IRegion r = new Region(query.getOffset(), 0);
((JspContextImpl)pageContext).addNameSpace(r, new NameSpace(query.getUri(), query.getPrefix(),
+ pageContext.getResource() == null ? new ITagLibrary[0] :
TagLibraryManager.getLibraries(
pageContext.getResource().getProject(), query.getUri())));
// ((JspContextImpl)pageContext).setLibraries(processor.getTagLibraries(pageContext));
14 years, 8 months
JBoss Tools SVN: r21594 - in branches/jbosstools-3.1.x: jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064 and 3 other directories.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2010-04-21 11:13:19 -0400 (Wed, 21 Apr 2010)
New Revision: 21594
Added:
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml.xml
Modified:
branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java
branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/bundle/BundleMap.java
Log:
Applying path for https://jira.jboss.org/jira/browse/JBIDE-6064
Added: branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml
===================================================================
--- branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml (rev 0)
+++ branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml 2010-04-21 15:13:19 UTC (rev 21594)
@@ -0,0 +1,10 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:h="http://java.sun.com/jsf/html">
+
+ <ui:composition template="" id="jbide6064Test">
+ #{{
+ </ui:composition>
+</html>
Added: branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml.xml
===================================================================
--- branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml.xml (rev 0)
+++ branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/6064/jbide6064.xhtml.xml 2010-04-21 15:13:19 UTC (rev 21594)
@@ -0,0 +1,17 @@
+<tests>
+<test id="jbide6064Test">
+<DIV VPE:INCLUDE-ELEMENT="yes" STYLE="border: 1px dashed rgb(42, 127, 0);">
+<DIV>
+<SPAN CLASS="__any__tag__caption">
+ui:composition
+</SPAN>
+<SPAN CLASS="__any__tag__caption" STYLE="color: red; font-style: italic;">
+Template file is not found: ""
+</SPAN>
+</DIV>
+<SPAN CLASS="vpe-text">
+#{{
+</SPAN>
+</DIV>
+</test>
+</tests>
Modified: branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
===================================================================
--- branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2010-04-21 15:12:54 UTC (rev 21593)
+++ branches/jbosstools-3.1.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2010-04-21 15:13:19 UTC (rev 21594)
@@ -88,6 +88,7 @@
import org.jboss.tools.jsf.vpe.jsf.test.jbide.NullPointerWithStyleProperty_JBIDE5193;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.TestForUsingComponentsLibrariesWithDefaultNamespace;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.TestOpenOnForXhtmlFiles_JBIDE5577;
+import org.jboss.tools.jsf.vpe.jsf.test.jbide.UnclosedELExpressionTest;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.VpeI18nTest_JBIDE4887;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JsfJbide1467Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JsfJbide1501Test;
@@ -126,6 +127,7 @@
TestSuite suite = new TestSuite("Tests for Vpe Jsf components"); //$NON-NLS-1$
// $JUnit-BEGIN$
+ suite.addTestSuite(UnclosedELExpressionTest.class);
suite.addTestSuite(JBIDE5920Test.class);
suite.addTestSuite(RenderFacetAndInsertChildrenTest.class);
suite.addTestSuite(EditFontFamilyTest_JBIDE5872.class);
Modified: branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java
===================================================================
--- branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java 2010-04-21 15:12:54 UTC (rev 21593)
+++ branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java 2010-04-21 15:13:19 UTC (rev 21594)
@@ -526,8 +526,8 @@
// refresh job in time, so we just ignore
// this exception
}
- } catch(ClassCastException ex) {
- VpePlugin.getDefault().reportProblem(ex);
+ } catch(Exception ex) {
+ VpePlugin.getPluginLog().logError(ex);
}
getChangeEvents().remove(eventBean);
}
@@ -1512,7 +1512,9 @@
// refresh job in time, so we just ignore this
// exception
}
- } finally {
+ }catch (Exception ex){
+ VpePlugin.getPluginLog().logError(ex);
+ }finally {
if (switcher != null) {
switcher.stopActiveEditor();
}
Modified: branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/bundle/BundleMap.java
===================================================================
--- branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/bundle/BundleMap.java 2010-04-21 15:12:54 UTC (rev 21593)
+++ branches/jbosstools-3.1.x/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/bundle/BundleMap.java 2010-04-21 15:13:19 UTC (rev 21594)
@@ -439,8 +439,15 @@
}
}
if(index < i.getEndPosition()) {
- sb.append(name.substring(index, i.getEndPosition()));
- index = i.getEndPosition();
+ //fix has been added by Maksim Areshkau
+ // https://jira.jboss.org/jira/browse/JBIDE-6064
+ if(name.length()>i.getEndPosition()) {
+ sb.append(name.substring(index, i.getEndPosition()));
+ index = i.getEndPosition();
+ }else {
+ sb.append(name.substring(index, name.length()));
+ index =name.length();
+ }
}
}
sb.append(name.substring(index));
14 years, 8 months