JBoss Tools SVN: r3638 - in trunk/as/plugins/org.jboss.ide.eclipse.as.ui: jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2007-09-14 16:11:55 -0400 (Fri, 14 Sep 2007)
New Revision: 3638
Added:
trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/JMXViewProvider.java
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml
Log:
Added: trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/JMXViewProvider.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/JMXViewProvider.java (rev 0)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/JMXViewProvider.java 2007-09-14 20:11:55 UTC (rev 3638)
@@ -0,0 +1,371 @@
+package org.jboss.ide.eclipse.as.ui.views.server.providers;
+
+import java.io.IOException;
+import java.lang.reflect.Constructor;
+import java.lang.reflect.Method;
+import java.security.Principal;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Properties;
+import java.util.Set;
+
+import javax.management.MBeanServerConnection;
+import javax.management.MalformedObjectNameException;
+import javax.management.ObjectInstance;
+import javax.management.ObjectName;
+import javax.naming.InitialContext;
+
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.jface.viewers.ITreeContentProvider;
+import org.eclipse.jface.viewers.LabelProvider;
+import org.eclipse.jface.viewers.Viewer;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.widgets.Display;
+import org.eclipse.wst.server.core.IServer;
+import org.eclipse.wst.server.core.IServerLifecycleListener;
+import org.eclipse.wst.server.core.IServerListener;
+import org.eclipse.wst.server.core.ServerCore;
+import org.eclipse.wst.server.core.ServerEvent;
+import org.jboss.ide.eclipse.as.core.extensions.jmx.JMXClassLoaderRepository;
+import org.jboss.ide.eclipse.as.core.util.ServerConverter;
+import org.jboss.ide.eclipse.as.ui.views.server.extensions.JBossServerViewExtension;
+import org.jboss.ide.eclipse.as.ui.views.server.extensions.ServerViewProvider;
+
+public class JMXViewProvider extends JBossServerViewExtension {
+ protected static final Object LOADING = new Object();
+
+ protected JMXServerLifecycleListener lcListener;
+ protected JMXServerListener serverListener;
+ protected JMXTreeContentProvider contentProvider;
+ protected JMXLabelProvider labelProvider;
+ protected IServer server;
+ protected JMXModel model;
+ public JMXViewProvider() {
+ model = new JMXModel();
+
+ // make sure we know about server events
+ serverListener = new JMXServerListener();
+ lcListener = new JMXServerLifecycleListener();
+ ServerCore.addServerLifecycleListener(lcListener);
+ IServer[] servers = ServerCore.getServers();
+ for( int i = 0; i < servers.length; i++ ) {
+ servers[i].addServerListener(serverListener);
+ }
+ }
+
+ protected class JMXServerLifecycleListener implements IServerLifecycleListener {
+ public void serverAdded(IServer server) {
+ server.addServerListener(serverListener);
+ }
+ public void serverChanged(IServer server) {
+ }
+ public void serverRemoved(IServer server) {
+ server.removeServerListener(serverListener);
+ JMXClassLoaderRepository.getDefault().
+ removeConcerned(server, model);
+ }
+ }
+
+
+ protected class JMXServerListener implements IServerListener {
+ public void serverChanged(ServerEvent event) {
+ if((event.getKind() & ServerEvent.SERVER_CHANGE) != 0) {
+ if((event.getKind() & ServerEvent.STATE_CHANGE) != 0) {
+ if( event.getState() == IServer.STATE_STARTED) {
+ JMXClassLoaderRepository.getDefault().
+ addConcerned(event.getServer(), model);
+ } else {
+ JMXClassLoaderRepository.getDefault().
+ removeConcerned(event.getServer(), model);
+ }
+ }
+ }
+ }
+ }
+
+ public ITreeContentProvider getContentProvider() {
+ if( contentProvider == null )
+ contentProvider = new JMXTreeContentProvider();
+ return contentProvider;
+ }
+ public LabelProvider getLabelProvider() {
+ if( labelProvider == null )
+ labelProvider = new JMXLabelProvider();
+ return labelProvider;
+ }
+
+ class JMXLabelProvider extends LabelProvider {
+ public String getText(Object obj) {
+ if( obj instanceof JMXDomain )
+ return ((JMXDomain)obj).getName();
+ if( obj instanceof JMXBean) {
+ return ((JMXBean)obj).getName().substring(((JMXBean)obj).getDomain().length()+1);
+ }
+ if( obj == LOADING )
+ return "loading...";
+ return "not sure yet";
+ }
+ public Image getImage(Object obj) {
+ return null;
+ }
+
+ }
+
+ public class JMXTreeContentProvider implements ITreeContentProvider {
+
+ public Object[] getChildren(Object parentElement) {
+ if( parentElement instanceof ServerViewProvider ) {
+ if( server == null ) return new Object[]{};
+ if( server.getServerState() != IServer.STATE_STARTED ) {
+ model.clearModel(server);
+ return new Object[]{};
+ }
+ JMXDomain[] domains = model.getModel(server).getDomains();
+ if( domains == null ) {
+ loadChildren(parentElement);
+ return new Object[]{LOADING};
+ }
+ return domains;
+ }
+ if( parentElement instanceof JMXDomain ) {
+ JMXBean[] beans = ((JMXDomain)parentElement).getBeans();
+ if( beans == null ) {
+ loadChildren(parentElement);
+ return new Object[]{LOADING};
+ }
+ return beans;
+ }
+ return new Object[0];
+ }
+ public Object getParent(Object element) {
+ return null; // unused
+ }
+ public boolean hasChildren(Object element) {
+ return true; // always true?
+ }
+ public Object[] getElements(Object inputElement) {
+ return null; // unused here
+ }
+ public void dispose() {
+ }
+ public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
+ if( oldInput != newInput ) {
+ server = (IServer)newInput;
+ }
+ }
+
+ protected void loadChildren(final Object parent) {
+ new Thread() {
+ public void run() {
+ if( parent instanceof ServerViewProvider )
+ model.getModel(server).loadDomains();
+ else if( parent instanceof JMXDomain )
+ ((JMXDomain)parent).loadBeans();
+ else if( parent instanceof JMXBean )
+ ((JMXBean)parent).getName(); // temp
+
+ Display.getDefault().asyncExec(new Runnable() {
+ public void run() {
+ refreshViewer(parent);
+ }
+ });
+ }
+ }.start();
+ }
+
+ }
+
+
+
+
+
+
+ protected class JMXModel {
+ protected HashMap<String, JMXModelRoot> root;
+ public JMXModel() {
+ root = new HashMap<String, JMXModelRoot>();
+ }
+ public JMXModelRoot getModel(IServer server) {
+ if( root.get(server.getId()) == null ) {
+ JMXModelRoot serverRoot = new JMXModelRoot(server);
+ root.put(server.getId(), serverRoot);
+ }
+ return root.get(server.getId());
+ }
+ public void clearModel(IServer server) {
+ root.remove(server.getId());
+ }
+ }
+
+ protected static class JMXModelRoot {
+ protected IServer server;
+ protected JMXDomain[] domains = null;
+ public JMXModelRoot(IServer server) {
+ this.server = server;
+ }
+ public JMXDomain[] getDomains() {
+ return domains;
+ }
+ protected void loadDomains() {
+ JMXRunnable run = new JMXRunnable() {
+ public void run(MBeanServerConnection connection) {
+ try {
+ String[] domainNames = connection.getDomains();
+ JMXDomain[] domains = new JMXDomain[domainNames.length];
+ for( int i = 0; i < domainNames.length; i++ ) {
+ domains[i] = new JMXDomain(server, domainNames[i]);
+ }
+ JMXModelRoot.this.domains = domains;
+ } catch( IOException ioe ) {
+ JMXModelRoot.this.domains = new JMXDomain[0];
+ }
+ }
+ };
+ JMXSafeRunner.run(server, run);
+ }
+ }
+
+ protected static class JMXDomain {
+ protected String name;
+ protected IServer server;
+ public JMXBean[] mbeans = null;
+ public JMXDomain(IServer server, String name) {
+ this.server = server;
+ this.name = name;
+ }
+ public String getName() { return name; }
+ public JMXBean[] getBeans() {
+ return mbeans;
+ }
+ protected void loadBeans() {
+ // etc
+ JMXRunnable run = new JMXRunnable() {
+ public void run(MBeanServerConnection connection) {
+ try {
+ String query = name + ":*";
+ Set s = connection.queryMBeans(new ObjectName(name + ":*"), null);
+ Iterator i = s.iterator();
+ JMXBean[] beans = new JMXBean[s.size()];
+ int count = 0;
+ while(i.hasNext()) {
+ ObjectInstance tmp = (ObjectInstance)i.next();
+ beans[count++] = new JMXBean(server, tmp);
+ }
+ mbeans = beans;
+ } catch( MalformedObjectNameException mone) {
+ } catch (IOException e) {
+ }
+ }
+ };
+ JMXSafeRunner.run(server, run);
+ }
+ }
+
+ protected static class JMXBean {
+ protected String domain;
+ protected String name;
+ protected String clazz;
+ protected IServer server;
+ public JMXBean(IServer server, ObjectInstance instance) {
+ this.server = server;
+ this.domain = instance.getObjectName().getDomain();
+ this.clazz = instance.getClassName();
+ this.name = instance.getObjectName().getCanonicalName();
+ }
+ public String getDomain() {
+ return domain;
+ }
+ public String getName() {
+ return name;
+ }
+ public String getClazz() {
+ return clazz;
+ }
+ public IServer getServer() {
+ return server;
+ }
+
+ }
+
+ protected interface JMXRunnable {
+ public void run(MBeanServerConnection connection);
+ }
+ protected static class JMXSafeRunner {
+ public static void run(IServer s, JMXRunnable r) {
+ ClassLoader currentLoader = Thread.currentThread().getContextClassLoader();
+ ClassLoader newLoader = JMXClassLoaderRepository.getDefault().getClassLoader(s);
+ Thread.currentThread().setContextClassLoader(newLoader);
+ InitialContext ic = null;
+ try {
+ setCredentials(s);
+ Properties p = getProperties(s);
+ ic = new InitialContext(p);
+ Object obj = ic.lookup("jmx/invoker/RMIAdaptor");
+ ic.close();
+ if (obj instanceof MBeanServerConnection) {
+ MBeanServerConnection connection = (MBeanServerConnection) obj;
+ r.run(connection);
+ }
+ } catch( Exception e ) {
+ }
+ Thread.currentThread().setContextClassLoader(currentLoader);
+ }
+ protected static Properties getProperties(IServer s) {
+ int port = ServerConverter.getJBossServer(s).getJNDIPort();
+
+ Properties props = new Properties();
+ props.put("java.naming.factory.initial",
+ "org.jnp.interfaces.NamingContextFactory");
+ props.put("java.naming.factory.url.pkgs",
+ "org.jboss.naming:org.jnp.interfaces");
+ props.put("java.naming.provider.url", "jnp://"
+ + s.getHost() + ":" + port);
+ return props;
+ }
+
+ protected static void setCredentials(IServer s) {
+ Exception temp = null;
+ try {
+ ILaunchConfiguration lc = s.getLaunchConfiguration(true,
+ new NullProgressMonitor());
+ // get user from the IServer, but override with launch
+ // configuration
+ String user = ServerConverter.getJBossServer(s).getUsername();
+
+ // get password from the IServer, but override with launch
+ // configuration
+ String pass = ServerConverter.getJBossServer(s).getPassword();
+
+ // get our methods
+ Class simplePrincipal = Thread.currentThread()
+ .getContextClassLoader().loadClass(
+ "org.jboss.security.SimplePrincipal");
+ Class securityAssoc = Thread.currentThread()
+ .getContextClassLoader().loadClass(
+ "org.jboss.security.SecurityAssociation");
+ securityAssoc.getMethods(); // force-init the methods since the
+ // class hasn't been initialized yet.
+
+ Constructor newSimplePrincipal = simplePrincipal
+ .getConstructor(new Class[] { String.class });
+ Object newPrincipalInstance = newSimplePrincipal
+ .newInstance(new Object[] { user });
+
+ // set the principal
+ Method setPrincipalMethod = securityAssoc.getMethod(
+ "setPrincipal", new Class[] { Principal.class });
+ setPrincipalMethod.invoke(null,
+ new Object[] { newPrincipalInstance });
+
+ // set the credential
+ Method setCredentialMethod = securityAssoc.getMethod(
+ "setCredential", new Class[] { Object.class });
+ setCredentialMethod.invoke(null, new Object[] { pass });
+ } catch (Exception e) {}
+ }
+
+
+ }
+
+}
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml 2007-09-14 20:10:53 UTC (rev 3637)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml 2007-09-14 20:11:55 UTC (rev 3638)
@@ -163,6 +163,12 @@
id="org.jboss.ide.eclipse.as.ui.InactiveExtensionsProvider"
name="Inactive Categories"
providerClass="org.jboss.ide.eclipse.as.ui.views.server.providers.InactiveExtensionViewProvider"/>
+<!-- <ViewProvider
+ description="A clone of the JMX view in the web browser"
+ id="org.jboss.ide.eclipse.as.ui.JMXProvider"
+ name="JMX Console"
+ providerClass="org.jboss.ide.eclipse.as.ui.views.server.providers.JMXViewProvider">
+ </ViewProvider>-->
</extension>
<!--
<extension
17 years, 3 months
JBoss Tools SVN: r3637 - trunk/as/plugins/org.jboss.ide.eclipse.as.core/META-INF.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2007-09-14 16:10:53 -0400 (Fri, 14 Sep 2007)
New Revision: 3637
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF
Log:
Moved JMX Classloader and credentialing to another class for re-use.
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF 2007-09-14 20:10:01 UTC (rev 3636)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF 2007-09-14 20:10:53 UTC (rev 3637)
@@ -25,6 +25,7 @@
org.jboss.ide.eclipse.as.core.extensions.archives,
org.jboss.ide.eclipse.as.core.extensions.descriptors,
org.jboss.ide.eclipse.as.core.extensions.events,
+ org.jboss.ide.eclipse.as.core.extensions.jmx,
org.jboss.ide.eclipse.as.core.extensions.polling,
org.jboss.ide.eclipse.as.core.modules,
org.jboss.ide.eclipse.as.core.publishers,
17 years, 3 months
JBoss Tools SVN: r3636 - in trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions: jmx and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2007-09-14 16:10:01 -0400 (Fri, 14 Sep 2007)
New Revision: 3636
Added:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXClassLoaderRepository.java
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXUtil.java
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java
Log:
Moved JMX Classloader and credentialing to another class for re-use.
Added: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXClassLoaderRepository.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXClassLoaderRepository.java (rev 0)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXClassLoaderRepository.java 2007-09-14 20:10:01 UTC (rev 3636)
@@ -0,0 +1,115 @@
+package org.jboss.ide.eclipse.as.core.extensions.jmx;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.net.URLClassLoader;
+import java.util.ArrayList;
+import java.util.HashMap;
+
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.wst.server.core.IRuntime;
+import org.eclipse.wst.server.core.IServer;
+
+/**
+ * A repository for classloaders that relate to servers,
+ * specifically jmx. It basically loads teh jboss-clientall.jar.
+ *
+ *
+ * @author Rob Stryker
+ *
+ */
+public class JMXClassLoaderRepository {
+ protected static JMXClassLoaderRepository instance;
+ public static JMXClassLoaderRepository getDefault() {
+ if( instance == null ) {
+ instance = new JMXClassLoaderRepository();
+ }
+ return instance;
+ }
+
+ protected HashMap<String, ClassLoader> idToLoader;
+ protected HashMap<String, ArrayList<Object>> idToConcerned;
+ protected JMXClassLoaderRepository() {
+ idToLoader = new HashMap<String, ClassLoader>();
+ idToConcerned = new HashMap<String, ArrayList<Object>>();
+ }
+
+ /**
+ * Add a concerned citizen to the list of said citizens.
+ * These are people who may at any time ask to access
+ * the classloader.
+ *
+ * @param server
+ * @param concerned
+ */
+ public void addConcerned(IServer server, Object concerned) {
+ ArrayList<Object> list = idToConcerned.get(server.getId());
+ if( list == null ) {
+ list = new ArrayList<Object>();
+ idToConcerned.put(server.getId(), list);
+ }
+ if( !list.contains(concerned))
+ list.add(concerned);
+ }
+
+ /**
+ * Removes an element from the list of concerned citizens.
+ * If no one cares about this server any longer, remove
+ * its classloader cache and forget about it.
+ *
+ * @param server
+ * @param concerned
+ */
+ public void removeConcerned(IServer server, Object concerned) {
+ ArrayList<Object> list = idToConcerned.get(server.getId());
+ if( list != null ) {
+ list.remove(concerned);
+ if( list.size() == 0 ) {
+ idToConcerned.remove(server.getId());
+ idToLoader.remove(server.getId());
+ }
+ }
+ }
+
+ /**
+ * Get the classloader for some server.
+ * If there are 0 concerned citizens, null should be returned.
+ * @param server
+ * @return
+ */
+ public ClassLoader getClassLoader(IServer server) {
+ ClassLoader loader = idToLoader.get(server.getId());
+ if( loader == null && anyoneCares(server)) {
+ loadClassLoader(server);
+ }
+ return idToLoader.get(server.getId());
+ }
+
+ /**
+ * Actually create and store the classloader
+ * @param s
+ */
+ protected void loadClassLoader(IServer s) {
+ try {
+ IRuntime rt = s.getRuntime();
+ IPath loc = rt.getLocation();
+ URL url = loc.append("client").append("jbossall-client.jar")
+ .toFile().toURI().toURL();
+ URLClassLoader loader = new URLClassLoader(new URL[] { url, },
+ Thread.currentThread().getContextClassLoader());
+ idToLoader.put(s.getId(), loader);
+ } catch (MalformedURLException murle) {
+ }
+ }
+
+ /**
+ * Are there any concerned citizens for this server?
+ * @param server
+ * @return
+ */
+ protected boolean anyoneCares(IServer server) {
+ ArrayList<Object> list = idToConcerned.get(server.getId());
+ if( list != null && list.size() > 0 ) return true;
+ return false;
+ }
+}
Added: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXUtil.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXUtil.java (rev 0)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/jmx/JMXUtil.java 2007-09-14 20:10:01 UTC (rev 3636)
@@ -0,0 +1,104 @@
+package org.jboss.ide.eclipse.as.core.extensions.jmx;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.security.Principal;
+import java.util.Properties;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.wst.server.core.IServer;
+import org.jboss.ide.eclipse.as.core.util.ServerConverter;
+
+/**
+ * Utility class
+ * @author Rob Stryker
+ *
+ */
+public class JMXUtil {
+
+
+ /**
+ * In the current thread, set the credentials from some server
+ * @param server
+ */
+ public static void setCredentials(IServer server) throws CredentialException {
+ Exception temp = null;
+ try {
+ ILaunchConfiguration lc = server.getLaunchConfiguration(true,
+ new NullProgressMonitor());
+ // get user from the IServer, but override with launch configuration
+ String user = ServerConverter.getJBossServer(server).getUsername();
+
+ // get password from the IServer, but override with launch configuration
+ String pass = ServerConverter.getJBossServer(server).getPassword();
+
+ // get our methods
+ Class simplePrincipal = Thread.currentThread()
+ .getContextClassLoader().loadClass(
+ "org.jboss.security.SimplePrincipal");
+ Class securityAssoc = Thread.currentThread()
+ .getContextClassLoader().loadClass(
+ "org.jboss.security.SecurityAssociation");
+ securityAssoc.getMethods(); // force-init the methods since the
+ // class hasn't been initialized yet.
+
+ Constructor newSimplePrincipal = simplePrincipal
+ .getConstructor(new Class[] { String.class });
+ Object newPrincipalInstance = newSimplePrincipal
+ .newInstance(new Object[] { user });
+
+ // set the principal
+ Method setPrincipalMethod = securityAssoc.getMethod(
+ "setPrincipal", new Class[] { Principal.class });
+ setPrincipalMethod.invoke(null,
+ new Object[] { newPrincipalInstance });
+
+ // set the credential
+ Method setCredentialMethod = securityAssoc.getMethod(
+ "setCredential", new Class[] { Object.class });
+ setCredentialMethod.invoke(null, new Object[] { pass });
+ } catch (CoreException e) {
+ temp = e;
+ } catch (ClassNotFoundException e) {
+ temp = e;
+ } catch (SecurityException e) {
+ temp = e;
+ } catch (NoSuchMethodException e) {
+ temp = e;
+ } catch (IllegalArgumentException e) {
+ temp = e;
+ } catch (InstantiationException e) {
+ temp = e;
+ } catch (IllegalAccessException e) {
+ temp = e;
+ } catch (InvocationTargetException e) {
+ temp = e;
+ }
+ if( temp != null )
+ throw new CredentialException(temp);
+ }
+
+ public static class CredentialException extends Exception {
+ private static final long serialVersionUID = 1L;
+ protected Exception wrapped;
+ public CredentialException(Exception wrapped) {
+ this.wrapped = wrapped;
+ }
+ public Exception getWrapped() { return wrapped; }
+ }
+
+ public static Properties getDefaultProperties(IServer server) {
+ int port = ServerConverter.getJBossServer(server).getJNDIPort();
+ Properties props = new Properties();
+ props.put("java.naming.factory.initial",
+ "org.jnp.interfaces.NamingContextFactory");
+ props.put("java.naming.factory.url.pkgs",
+ "org.jboss.naming:org.jnp.interfaces");
+ props.put("java.naming.provider.url", "jnp://"
+ + server.getHost() + ":" + port);
+ return props;
+ }
+}
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java 2007-09-14 18:41:21 UTC (rev 3635)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java 2007-09-14 20:10:01 UTC (rev 3636)
@@ -25,9 +25,6 @@
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLClassLoader;
import java.security.Principal;
import java.util.Date;
import java.util.Properties;
@@ -38,18 +35,20 @@
import javax.management.MBeanServerConnection;
import javax.management.MalformedObjectNameException;
import javax.management.ObjectName;
+import javax.management.OperationsException;
import javax.management.ReflectionException;
import javax.naming.CommunicationException;
import javax.naming.InitialContext;
import javax.naming.NamingException;
import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.wst.server.core.IRuntime;
import org.eclipse.wst.server.core.IServer;
import org.jboss.ide.eclipse.as.core.extensions.events.EventLogModel.EventLogTreeItem;
+import org.jboss.ide.eclipse.as.core.extensions.jmx.JMXClassLoaderRepository;
+import org.jboss.ide.eclipse.as.core.extensions.jmx.JMXUtil;
+import org.jboss.ide.eclipse.as.core.extensions.jmx.JMXUtil.CredentialException;
import org.jboss.ide.eclipse.as.core.server.IServerStatePoller;
import org.jboss.ide.eclipse.as.core.server.internal.PollThread;
import org.jboss.ide.eclipse.as.core.util.ServerConverter;
@@ -85,22 +84,14 @@
private class PollerRunnable implements Runnable {
public void run() {
- ClassLoader currentLoader = Thread.currentThread()
- .getContextClassLoader();
- ClassLoader twiddleLoader = getClassLoader();
+ JMXClassLoaderRepository.getDefault().addConcerned(server, this);
+ ClassLoader currentLoader = Thread.currentThread().getContextClassLoader();
+ ClassLoader twiddleLoader = JMXClassLoaderRepository.getDefault().getClassLoader(server);
if( pollingException != null ) {done = true; return;}
if (twiddleLoader != null) {
- int port = ServerConverter.getJBossServer(server).getJNDIPort();
Thread.currentThread().setContextClassLoader(twiddleLoader);
- Properties props = new Properties();
- props.put("java.naming.factory.initial",
- "org.jnp.interfaces.NamingContextFactory");
- props.put("java.naming.factory.url.pkgs",
- "org.jboss.naming:org.jnp.interfaces");
- props.put("java.naming.provider.url", "jnp://"
- + server.getHost() + ":" + port);
-
+ Properties props = JMXUtil.getDefaultProperties(server);
setCredentials();
if( pollingException != null ) {done = true; return;}
@@ -128,12 +119,8 @@
started = STATE_STOPPED;
} catch (NamingException nnfe) {
started = STATE_STOPPED;
- } catch (AttributeNotFoundException e) {
+ } catch( OperationsException e ) {
failingException = e;
- } catch (InstanceNotFoundException e) {
- failingException = e;
- } catch (MalformedObjectNameException e) {
- failingException = e;
} catch (MBeanException e) {
failingException = e;
} catch (ReflectionException e) {
@@ -143,6 +130,7 @@
} catch (IOException e) {
failingException = e;
}
+
if( failingException != null ) {
pollingException = new PollingException(failingException.getMessage());
done = true;
@@ -156,82 +144,16 @@
}
Thread.currentThread().setContextClassLoader(currentLoader);
+ JMXClassLoaderRepository.getDefault().removeConcerned(server, this);
}
protected void setCredentials() {
- Exception temp = null;
try {
- ILaunchConfiguration lc = server.getLaunchConfiguration(true,
- new NullProgressMonitor());
- // get user from the IServer, but override with launch configuration
- String user = ServerConverter.getJBossServer(server).getUsername();
-
- // get password from the IServer, but override with launch configuration
- String pass = ServerConverter.getJBossServer(server).getPassword();
-
- // get our methods
- Class simplePrincipal = Thread.currentThread()
- .getContextClassLoader().loadClass(
- "org.jboss.security.SimplePrincipal");
- Class securityAssoc = Thread.currentThread()
- .getContextClassLoader().loadClass(
- "org.jboss.security.SecurityAssociation");
- securityAssoc.getMethods(); // force-init the methods since the
- // class hasn't been initialized yet.
-
- Constructor newSimplePrincipal = simplePrincipal
- .getConstructor(new Class[] { String.class });
- Object newPrincipalInstance = newSimplePrincipal
- .newInstance(new Object[] { user });
-
- // set the principal
- Method setPrincipalMethod = securityAssoc.getMethod(
- "setPrincipal", new Class[] { Principal.class });
- setPrincipalMethod.invoke(null,
- new Object[] { newPrincipalInstance });
-
- // set the credential
- Method setCredentialMethod = securityAssoc.getMethod(
- "setCredential", new Class[] { Object.class });
- setCredentialMethod.invoke(null, new Object[] { pass });
- } catch (CoreException e) {
- temp = e;
- } catch (ClassNotFoundException e) {
- temp = e;
- } catch (SecurityException e) {
- temp = e;
- } catch (NoSuchMethodException e) {
- temp = e;
- } catch (IllegalArgumentException e) {
- temp = e;
- } catch (InstantiationException e) {
- temp = e;
- } catch (IllegalAccessException e) {
- temp = e;
- } catch (InvocationTargetException e) {
- temp = e;
+ JMXUtil.setCredentials(server);
+ } catch( CredentialException ce ) {
+ pollingException = new PollingException(ce.getWrapped().getMessage());
}
- if( temp != null ) {
- pollingException = new PollingException(temp.getMessage());
- }
}
-
- protected ClassLoader getClassLoader() {
- try {
- IRuntime rt = server.getRuntime();
- IPath loc = rt.getLocation();
- URL url = loc.append("client").append("jbossall-client.jar")
- .toFile().toURI().toURL();
- URL url2 = loc.append("bin").append("twiddle.jar").toFile()
- .toURI().toURL();
- URLClassLoader loader = new URLClassLoader(new URL[] { url,
- url2 }, Thread.currentThread().getContextClassLoader());
- return loader;
- } catch (MalformedURLException murle) {
- pollingException = new PollingException(murle.getMessage());
- }
- return null;
- }
}
private void launchJMXPoller() {
17 years, 3 months
JBoss Tools SVN: r3635 - trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2007-09-14 14:41:21 -0400 (Fri, 14 Sep 2007)
New Revision: 3635
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java
Log:
slight change to refresh viewer
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java 2007-09-14 17:39:18 UTC (rev 3634)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java 2007-09-14 18:41:21 UTC (rev 3635)
@@ -83,7 +83,7 @@
public void run() {
if( isEnabled() ) {
try {
- if( o == null ) {
+ if( o == null || o == provider ) {
JBossServerView.getDefault().getExtensionFrame().getViewer().refresh(provider);
} else {
JBossServerView.getDefault().getExtensionFrame().getViewer().refresh(new ContentWrapper(o, provider));
17 years, 3 months
JBoss Tools SVN: r3634 - in branches/jbosstools_xulrunner/vpe/plugins: org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/mozilla and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2007-09-14 13:39:18 -0400 (Fri, 14 Sep 2007)
New Revision: 3634
Modified:
branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java
branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java
branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java
branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/mozilla/MozillaEditor.java
Log:
restore selection functionality on MAC OS
Modified: branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java 2007-09-14 16:15:39 UTC (rev 3633)
+++ branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeController.java 2007-09-14 17:39:18 UTC (rev 3634)
@@ -274,7 +274,7 @@
pageContext.fireTaglibsChanged();
}
- void dispose() {
+ public void dispose() {
switcher.destroyActiveEditor();
if (templateManager != null) {
Modified: branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java 2007-09-14 16:15:39 UTC (rev 3633)
+++ branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeEditorPart.java 2007-09-14 17:39:18 UTC (rev 3634)
@@ -69,7 +69,6 @@
private StructuredTextEditor sourceEditor = null;
private MozillaEditor visualEditor;
private IEditorPart activeEditor;
- private VpeController controller;
private XModelTreeListener listener;
XModelObject optionsObject;
private SelectionBar selectionBar = new SelectionBar();
@@ -360,10 +359,10 @@
//Added by Max Areshkau
//was fixed bug(border which drawed by iflasher doesn't hide on MACOS when we swith
// to souce view)
- if(Platform.getOS().equals(Platform.OS_MACOSX)&&controller!=null) {
-
- controller.visualRefresh();
- }
+// if(Platform.getOS().equals(Platform.OS_MACOSX)&&controller!=null) {
+//
+// visualEditor.getController().visualRefresh();
+// }
}
if (visualContent != null)
visualContent.setVisible(false);
@@ -393,9 +392,11 @@
container.layout();
if (visualMode == SOURCE_MODE && type != SOURCE_MODE) {
visualMode = type;
- if (controller != null) {
- controller.visualRefresh();
- controller.sourceSelectionChanged();
+ if (visualEditor.getController() != null) {
+ visualEditor.getController().visualRefresh();
+ if(type!=PREVIEW_MODE) {
+ visualEditor.getController().sourceSelectionChanged();
+ }
}
}
visualMode = type;
@@ -503,12 +504,12 @@
.setEditorLoadWindowListener(new EditorLoadWindowListener() {
public void load() {
visualEditor.setEditorLoadWindowListener(null);
- controller = new VpeController(
- VpeEditorPart.this);
- selectionBar.setVpeController(controller);
- controller.setSelectionBarController(selectionBar);
+ visualEditor.setController(new VpeController(
+ VpeEditorPart.this));
+ selectionBar.setVpeController(visualEditor.getController());
+ visualEditor.getController().setSelectionBarController(selectionBar);
try {
- controller.init(sourceEditor, visualEditor);
+ visualEditor.getController().init(sourceEditor, visualEditor);
} catch (Exception e) {
VpePlugin.reportProblem(e);
}
@@ -614,11 +615,6 @@
shell.removeShellListener(activationListener);
activationListener = null;
}
- if (controller != null) {
- controller.dispose();
- controller = null;
- }
-
// editor will disposed as part of multipart editor
if (sourceEditor != null) {
sourceEditor.dispose();
@@ -688,8 +684,8 @@
fIsHandlingActivation = true;
try {
if (sourceEditor != null) {
- if (controller != null) {
- controller.refreshTemplates();
+ if (visualEditor.getController() != null) {
+ visualEditor.getController().refreshTemplates();
}
sourceEditor.safelySanityCheckState(getEditorInput());
}
@@ -701,7 +697,7 @@
}
public VpeController getController() {
- return controller;
+ return visualEditor.getController();
}
}
Modified: branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/mozilla/MozillaEditor.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/mozilla/MozillaEditor.java 2007-09-14 16:15:39 UTC (rev 3633)
+++ branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/mozilla/MozillaEditor.java 2007-09-14 17:39:18 UTC (rev 3634)
@@ -77,8 +77,10 @@
private nsIDOMNode headNode;
private nsIDOMEventTarget contentAreaEventTarget;
private MozillaDomEventListener contentAreaEventListener = new MozillaDomEventListener();
+ //TODO Max Areshkau may be we need delete this
private MozillaBaseEventListener baseEventListener = null;
private EditorLoadWindowListener editorLoadWindowListener;
+ //
private EditorDomEventListener editorDomEventListener;
private IVpeToolBarManager vpeToolBarManager;
private FormatControllerManager formatControllerManager = new FormatControllerManager();
@@ -299,15 +301,17 @@
public void dispose() {
removeDomEventListeners();
- // TODO Max Areshkau figure out with ClipboardDragDropHooks
-// removeClipboardDragDropHooks();
-
+ if(getController()!=null) {
+ controller.dispose();
+ controller=null;
+ }
if (xulRunnerEditor != null) {
xulRunnerEditor.getBrowser().dispose();
xulRunnerEditor = null;
}
super.dispose();
+
}
public void setEditorLoadWindowListener(EditorLoadWindowListener listener) {
@@ -582,7 +586,7 @@
/**
* @return the controller
*/
- protected VpeController getController() {
+ public VpeController getController() {
return controller;
}
Modified: branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java 2007-09-14 16:15:39 UTC (rev 3633)
+++ branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java 2007-09-14 17:39:18 UTC (rev 3634)
@@ -13,6 +13,7 @@
import java.util.regex.Pattern;
+import org.eclipse.core.runtime.Platform;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Display;
@@ -22,6 +23,7 @@
import org.jboss.tools.vpe.xulrunner.XulRunnerException;
import org.jboss.tools.vpe.xulrunner.browser.XulRunnerBrowser;
import org.mozilla.interfaces.inIFlasher;
+import org.mozilla.interfaces.nsIBaseWindow;
import org.mozilla.interfaces.nsIClipboardDragDropHookList;
import org.mozilla.interfaces.nsIComponentManager;
import org.mozilla.interfaces.nsIDOMDocument;
@@ -116,12 +118,16 @@
}
});
}};
- addListener(SWT.Activate, eventListenet);
+// addListener(SWT.Activate, eventListenet);
addListener(SWT.Paint, eventListenet);
- addListener(SWT.Resize, eventListenet);
+ //Commented by Max Areshkau (bug on Mac OS X10.4
+ //when switch from visual to preview selection rectangle doen't disappear
+// addListener(SWT.Resize, eventListenet);
addListener(SWT.Show, eventListenet);
addListener(SWT.FocusIn, eventListenet);
- addListener(SWT.FocusOut, eventListenet);
+ //Commented by Max Areshkau (bug on Mac OS X10.4
+ //when switch from visual to preview selection rectangle doen't disappear
+// addListener(SWT.FocusOut, eventListenet);
addListener(SWT.Selection, eventListenet);
addListener(SWT.Paint, eventListenet);
@@ -463,12 +469,13 @@
public void showSelectionRectangle() {
// ((nsIBaseWindow)getWebBrowser().queryInterface(nsIBaseWindow.NS_IBASEWINDOW_IID)).repaint(false);
+
if (getIFlasher() != null && getLastSelectedElement() != null) {
if (scrollRegtangleFlag) {
scrollRegtangleFlag = false;
scrollToElement(getLastSelectedElement());
- }
+ }
//checks visability of element
if(checkVisability(getLastSelectedElement())){
@@ -491,6 +498,14 @@
getIFlasher().drawElementOutline(domElement);
}
}
+ } else if(getIFlasher()!=null){
+ //Max Areshkau (bug on Mac OS X, when we swithc to preview grom other view, selection rectangle doesn't disappear
+ //TODO Max Areshkau (may be exist passability not draw selection on resize event when we swithes to other view)
+ try {
+ ((nsIBaseWindow)getWebBrowser().queryInterface(nsIBaseWindow.NS_IBASEWINDOW_IID)).repaint(true);
+ } catch(XPCOMException ex) {
+ //just ignore its
+ }
}
}
/**
17 years, 3 months
JBoss Tools SVN: r3633 - trunk/shale/plugins/org.jboss.tools.shale.text.ext.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2007-09-14 12:15:39 -0400 (Fri, 14 Sep 2007)
New Revision: 3633
Modified:
trunk/shale/plugins/org.jboss.tools.shale.text.ext/plugin.xml
Log:
http://jira.jboss.com/jira/browse/JBIDE-866 OpenOn don't work in some Struts files
Issue is fixed
Modified: trunk/shale/plugins/org.jboss.tools.shale.text.ext/plugin.xml
===================================================================
--- trunk/shale/plugins/org.jboss.tools.shale.text.ext/plugin.xml 2007-09-14 16:15:31 UTC (rev 3632)
+++ trunk/shale/plugins/org.jboss.tools.shale.text.ext/plugin.xml 2007-09-14 16:15:39 UTC (rev 3633)
@@ -22,6 +22,12 @@
<axis path="/view/component/extends/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="*/jsfid/" />
+ <axis path="/view/component/extends/" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -37,6 +43,11 @@
<axis path="/dialogs/dialog/*/className/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/dialogs/dialog/*/className/" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -67,6 +78,11 @@
<axis path="/dialogs/dialog/*/viewId/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/dialogs/dialog/*/viewId/" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -106,6 +122,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.xml.XML_ComponentJSFID" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.xml.XML_ComponentJSFID" />
+ </contenttypeidentifier>
</hyperlink>
</extension>
17 years, 3 months
JBoss Tools SVN: r3632 - trunk/struts/plugins/org.jboss.tools.struts.text.ext.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2007-09-14 12:15:31 -0400 (Fri, 14 Sep 2007)
New Revision: 3632
Modified:
trunk/struts/plugins/org.jboss.tools.struts.text.ext/plugin.xml
Log:
http://jira.jboss.com/jira/browse/JBIDE-866 OpenOn don't work in some Struts files
Issue is fixed
Modified: trunk/struts/plugins/org.jboss.tools.struts.text.ext/plugin.xml
===================================================================
--- trunk/struts/plugins/org.jboss.tools.struts.text.ext/plugin.xml 2007-09-14 14:36:12 UTC (rev 3631)
+++ trunk/struts/plugins/org.jboss.tools.struts.text.ext/plugin.xml 2007-09-14 16:15:31 UTC (rev 3632)
@@ -46,6 +46,24 @@
<axis path="*/web-app/*" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_TEXT">
+ <!-- Web.xml -->
+ <axis path="/web-app/error-page/location/" />
+ <axis path="/web-app/login-config/form-login-config/form-error-page/" />
+ <axis path="/web-app/login-config/form-login-config/form-login-page/" />
+ <axis path="/web-app/servlet/jsp-file/" />
+ <axis path="/web-app/*/icon/large-icon/" />
+ <axis path="/web-app/*/icon/small-icon/" />
+ <axis path="/web-app/taglib/taglib-location/" />
+ <axis path="/web-app/jsp-config/taglib/taglib-location/" />
+ <axis path="/web-app/welcome-file-list/welcome-file/" />
+ <!-- Web.xml -->
+ </partitionType>
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="*/web-app/*" />
+ </partitionType>
+ </contentType>
<contentType id="org.eclipse.jst.j2ee.webDD">
<partitionType id="org.jboss.tools.common.text.ext.xml.XML_TEXT">
<!-- Web.xml -->
@@ -128,6 +146,37 @@
<axis path="/form-validation/global/validator/methodParams/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/data-sources/className/" />
+ <axis path="/struts-config/data-sources/type/" />
+ <axis path="/struts-config/data-sources/data-source/className/" />
+ <axis path="/struts-config/data-sources/data-source/type/" />
+ <axis path="/struts-config/form-beans/type/" />
+ <axis path="/struts-config/form-beans/form-bean/className/" />
+ <axis path="/struts-config/form-beans/form-bean/type/" />
+ <axis path="/struts-config/form-beans/form-bean/form-property/className/" />
+ <axis path="/struts-config/form-beans/form-bean/form-property/type/" />
+ <axis path="/struts-config/form-beans/form-bean/form-property/className/" />
+ <axis path="/struts-config/global-exceptions/exception/className/" />
+ <axis path="/struts-config/global-exceptions/exception/handler/" />
+ <axis path="/struts-config/global-exceptions/exception/type/" />
+ <axis path="/struts-config/global-forwards/type/" />
+ <axis path="/struts-config/*/forward/className/" />
+ <axis path="/struts-config/action-mappings/type/" />
+ <axis path="/struts-config/action-mappings/action/className/" />
+ <axis path="/struts-config/action-mappings/action/type/" />
+ <axis path="/struts-config/controller/className/" />
+ <axis path="/struts-config/controller/multipartClass/" />
+ <axis path="/struts-config/controller/processorClass/" />
+ <axis path="/struts-config/message-resources/className/" />
+ <axis path="/struts-config/message-resources/factory/" />
+ <axis path="/struts-config/plug-in/className/" />
+
+ <axis path="/form-validation/global/validator/classname/" />
+ <axis path="/form-validation/global/validator/methodParams/" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -151,6 +200,15 @@
<axis path="/struts-config/action-mappings/action/input" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/global-exceptions/exception/path" />
+ <axis path="/struts-config/*/forward/path" />
+ <axis path="/struts-config/action-mappings/action/forward" />
+ <axis path="/struts-config/action-mappings/action/include" />
+ <axis path="/struts-config/action-mappings/action/input" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -166,6 +224,11 @@
<axis path="/struts-config/form-beans/form-bean/form-property/name" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/form-beans/form-bean/form-property/name" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -181,6 +244,11 @@
<axis path="/struts-config/global-exceptions/exception/bundle" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/global-exceptions/exception/bundle" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -196,6 +264,11 @@
<axis path="/struts-config/global-exceptions/exception/key" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/global-exceptions/exception/key" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -213,6 +286,12 @@
<axis path="/struts-config/action-mappings/action/name" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/action-mappings/action/attribute" />
+ <axis path="/struts-config/action-mappings/action/name" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -228,6 +307,11 @@
<axis path="/struts-config/plug-in/set-property/value" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/plug-in/set-property/value" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -243,6 +327,11 @@
<axis path="/struts-config/*/set-property/property" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/*/set-property/property" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -260,6 +349,12 @@
<axis path="/struts-config/*/icon/large-icon/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_TEXT">
+ <axis path="/struts-config/*/icon/small-icon/" />
+ <axis path="/struts-config/*/icon/large-icon/" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -275,6 +370,11 @@
<axis path="/web-app/servlet/init-param/param-value/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_TEXT">
+ <axis path="/web-app/servlet/init-param/param-value/" />
+ </partitionType>
+ </contentType>
<contentType id="org.eclipse.jst.j2ee.webDD">
<partitionType id="org.jboss.tools.common.text.ext.xml.XML_TEXT">
<axis path="/web-app/servlet/init-param/param-value/" />
@@ -597,6 +697,11 @@
<axis path="/struts-config/message-resources/parameter" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/struts-config/message-resources/parameter" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -886,6 +991,11 @@
<axis path="/form-validation/formset/form/name/" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/formset/form/name/" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1017,6 +1127,11 @@
<axis path="/form-validation/global/validator/msg" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/global/validator/msg" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1042,6 +1157,16 @@
<axis path="/form-validation/formset/form/field/arg3/bundle" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/formset/form/field/msg/bundle" />
+ <axis path="/form-validation/formset/form/field/arg/bundle" />
+ <axis path="/form-validation/formset/form/field/arg0/bundle" />
+ <axis path="/form-validation/formset/form/field/arg1/bundle" />
+ <axis path="/form-validation/formset/form/field/arg2/bundle" />
+ <axis path="/form-validation/formset/form/field/arg3/bundle" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1067,6 +1192,16 @@
<axis path="/form-validation/formset/form/field/arg3/key" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/formset/form/field/msg/key" />
+ <axis path="/form-validation/formset/form/field/arg/key" />
+ <axis path="/form-validation/formset/form/field/arg0/key" />
+ <axis path="/form-validation/formset/form/field/arg1/key" />
+ <axis path="/form-validation/formset/form/field/arg2/key" />
+ <axis path="/form-validation/formset/form/field/arg3/key" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1098,6 +1233,19 @@
<axis path="/form-validation/formset/form/field/arg3/name" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/global/validator/depends" />
+ <axis path="/form-validation/formset/form/field/depends" />
+ <axis path="/form-validation/formset/form/field/msg/name" />
+
+ <axis path="/form-validation/formset/form/field/arg/name" />
+ <axis path="/form-validation/formset/form/field/arg0/name" />
+ <axis path="/form-validation/formset/form/field/arg1/name" />
+ <axis path="/form-validation/formset/form/field/arg2/name" />
+ <axis path="/form-validation/formset/form/field/arg3/name" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1115,6 +1263,12 @@
<axis path="/form-validation/formset/form/field/indexedListProperty" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/formset/form/field/property" />
+ <axis path="/form-validation/formset/form/field/indexedListProperty" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1130,6 +1284,11 @@
<axis path="/form-validation/global/validator/method" />
</partitionType>
</contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE">
+ <axis path="/form-validation/global/validator/method" />
+ </partitionType>
+ </contentType>
</hyperlinkPartitioner>
<hyperlinkPartitioner
@@ -1173,6 +1332,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_CONTEXT_PARAM_LINK" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_CONTEXT_PARAM_LINK" />
+ </contenttypeidentifier>
<contenttypeidentifier id="org.eclipse.jst.j2ee.webDD">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_CONTEXT_PARAM_LINK" />
</contenttypeidentifier>
@@ -1188,6 +1350,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORWARD_PATH" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORWARD_PATH" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1199,6 +1364,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_PROPERTY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_PROPERTY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1210,6 +1378,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_BUNDLE" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_BUNDLE" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1221,6 +1392,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_BUNDLE_KEY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_BUNDLE_KEY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1232,6 +1406,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_BEAN" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_BEAN" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1243,6 +1420,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_PLUGIN_SET_PROPERTY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_PLUGIN_SET_PROPERTY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1254,6 +1434,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_SET_PROPERTY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_SET_PROPERTY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1265,6 +1448,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_PAGE" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_PAGE" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1276,6 +1462,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_VALIDATION_BUNDLE_KEY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_VALIDATION_BUNDLE_KEY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1287,6 +1476,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_LINK" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_LINK" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1298,6 +1490,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_RELATIVE_LINK" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_RELATIVE_LINK" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1317,6 +1512,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_PROPERTIES_FILE" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_PROPERTIES_FILE" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1391,6 +1589,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.jsp.STRUTS_JSP_FORM_BEAN" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.jsp.STRUTS_JSP_FORM_BEAN" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1426,6 +1627,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_BUNDLE" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_BUNDLE" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1437,6 +1641,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_BUNDLE_KEY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_BUNDLE_KEY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1448,6 +1655,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_VALIDATOR" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_VALIDATOR" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1459,6 +1669,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_PROPERTY" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_VALIDATION_PROPERTY" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
@@ -1470,6 +1683,9 @@
<contenttypeidentifier id="org.eclipse.core.runtime.xml">
<partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_VALIDATION_METHOD" />
</contenttypeidentifier>
+ <contenttypeidentifier id="org.jboss.tools.common.model.ui.xml">
+ <partitiontype id="org.jboss.tools.common.text.ext.xml.STRUTS_XML_FORM_VALIDATION_METHOD" />
+ </contenttypeidentifier>
</hyperlink>
<hyperlink
17 years, 3 months
JBoss Tools SVN: r3631 - branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2007-09-14 10:36:12 -0400 (Fri, 14 Sep 2007)
New Revision: 3631
Modified:
branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java
Log:
code adjustment
Modified: branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java 2007-09-14 14:28:14 UTC (rev 3630)
+++ branches/jbosstools_xulrunner/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java 2007-09-14 14:36:12 UTC (rev 3631)
@@ -14,7 +14,6 @@
import java.util.regex.Pattern;
import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Event;
@@ -498,11 +497,9 @@
* Scrools viiew to some elements
* @param element -element to which we should scroll
*/
- private void scrollToElement(nsIDOMElement element){
- nsIDOMWindow domWindow = getWebBrowser().getContentDOMWindow();
- // get element positions on visual page
- Rectangle rect=XulRunnerVpeUtils.getElementBounds(element);
- domWindow.scrollTo(rect.x-10, rect.y-10);
+ private void scrollToElement(nsIDOMElement element){
+
+ getIFlasher().scrollElementIntoView(element);
}
}
17 years, 3 months
JBoss Tools SVN: r3630 - trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2007-09-14 10:28:14 -0400 (Fri, 14 Sep 2007)
New Revision: 3630
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/JSFWebHelper.java
Log:
JBIDE-903
Modified: trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/JSFWebHelper.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/JSFWebHelper.java 2007-09-14 13:54:37 UTC (rev 3629)
+++ trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/JSFWebHelper.java 2007-09-14 14:28:14 UTC (rev 3630)
@@ -17,6 +17,7 @@
import org.jboss.tools.common.meta.action.XActionInvoker;
import org.jboss.tools.common.model.*;
+import org.jboss.tools.common.model.filesystems.impl.FileSystemsImpl;
import org.jboss.tools.common.model.impl.XModelImpl;
import org.jboss.tools.common.model.util.XModelObjectUtil;
import org.jboss.tools.jst.web.model.helpers.WebAppHelper;
@@ -121,6 +122,10 @@
}
public static void getConfigFiles(List<XModelObject> list, Set<XModelObject> set, XModel model, ConfigFilesData data) {
+ FileSystemsImpl fs = (FileSystemsImpl)model.getByPath("FileSystems");
+ if(fs != null) {
+ fs.updateOverlapped();
+ }
XModelObject webxml = getWebConfig(model);
String[] paths = getCompleteConfigFilesList(webxml, data);
if(paths != null) for (int i = 0; i < paths.length; i++) {
17 years, 3 months
JBoss Tools SVN: r3629 - trunk/documentation/GettingStartedGuide/docs/userguide/en/modules.
by jbosstools-commits@lists.jboss.org
Author: sabrashevich
Date: 2007-09-14 09:54:37 -0400 (Fri, 14 Sep 2007)
New Revision: 3629
Modified:
trunk/documentation/GettingStartedGuide/docs/userguide/en/modules/DevelopAsimpleJSPWebApplication.xml
Log:
little change
Modified: trunk/documentation/GettingStartedGuide/docs/userguide/en/modules/DevelopAsimpleJSPWebApplication.xml
===================================================================
--- trunk/documentation/GettingStartedGuide/docs/userguide/en/modules/DevelopAsimpleJSPWebApplication.xml 2007-09-14 13:36:40 UTC (rev 3628)
+++ trunk/documentation/GettingStartedGuide/docs/userguide/en/modules/DevelopAsimpleJSPWebApplication.xml 2007-09-14 13:54:37 UTC (rev 3629)
@@ -68,7 +68,7 @@
<section id="EditingJSPPage">
<?dbhtml filename="EditingJSPPage.html"?>
<title>Editing JSP Page</title>
- <para>Let's now make a little change so that jsp page displays that "Hello World!" message.</para>
+ <para>Let's now make a little change so that jsp page displays "Hello World!" message.</para>
<orderedlist continuation="continues">
<listitem><para>Insert this line inside the <emphasis role="bold"><property><body></property></emphasis><emphasis role="bold"><property></body></property></emphasis> tag:
</para></listitem>
@@ -131,7 +131,7 @@
<?dbhtml filename="DeployTheProject.html"?>
<title>Deploy the project</title>
<para>While creating any web project one is usually experiencing a pain writing ant scripts and managing the
-packaging even if she is writing the most trivial web applications. With Red Hat Developer Studio you are saved from such a pain. All you need is start JBoss server and launch your application in your favorite browser.</para>
+packaging even if a developer is writing the most trivial web applications. With Red Hat Developer Studio you are saved from such a pain. All you need is start JBoss server and launch your application in your favorite browser.</para>
<para>You can also create a war archive with RHDS's Archive Tools and export it to any web server.</para>
<section id="WarConfig">
<?dbhtml filename="WarConfig.html"?>
17 years, 3 months