JBoss Tools SVN: r16224 - in trunk/maven/features: org.jboss.tools.maven.runtime.feature and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2009-06-26 11:55:07 -0400 (Fri, 26 Jun 2009)
New Revision: 16224
Added:
trunk/maven/features/org.jboss.tools.maven.runtime.feature/
trunk/maven/features/org.jboss.tools.maven.runtime.feature/.project
trunk/maven/features/org.jboss.tools.maven.runtime.feature/build.properties
trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.properties
trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.xml
trunk/maven/features/org.jboss.tools.maven.runtime.feature/license.html
Log:
create runtime feature for maven + maven.seam features
Added: trunk/maven/features/org.jboss.tools.maven.runtime.feature/.project
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.runtime.feature/.project (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.runtime.feature/.project 2009-06-26 15:55:07 UTC (rev 16224)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.jboss.tools.maven.feature</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.pde.FeatureBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.FeatureNature</nature>
+ </natures>
+</projectDescription>
Added: trunk/maven/features/org.jboss.tools.maven.runtime.feature/build.properties
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.runtime.feature/build.properties (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.runtime.feature/build.properties 2009-06-26 15:55:07 UTC (rev 16224)
@@ -0,0 +1,3 @@
+bin.includes = feature.xml,\
+ license.html,\
+ feature.properties
Added: trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.properties
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.properties (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.properties 2009-06-26 15:55:07 UTC (rev 16224)
@@ -0,0 +1,43 @@
+###############################################################################
+# Copyright (c) 2008 JBoss by Red Hat and others.
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License v1.0
+# which accompanies this distribution, and is available at
+# http://www.eclipse.org/legal/epl-v10.html
+#
+# Contributors:
+# JBoss by Red Hat - Initial implementation.
+##############################################################################
+# feature.properties
+# contains externalized strings for feature.xml
+# "%foo" in feature.xml corresponds to the key "foo" in this file
+# java.io.Properties file (ISO 8859-1 with "\" escapes)
+# This file should be translated.
+
+# "featureName" property - name of the feature
+featureName=JBoss Maven Runtime Feature
+
+# "providerName" property - name of the company that provides the feature
+providerName=JBoss by Red Hat
+
+# "updateSiteName" property - label for the update site
+updateSiteName=JBossTools Update Site
+
+# "description" property - description of the feature
+description=JBoss Maven Integration
+
+# "copyright" property - text of the "Feature Update Copyright"
+copyright=Copyright (c) 2008 JBoss by Red Hat and others.\nAll rights reserved. This program and the accompanying materials\n
+are made available under the terms of the Eclipse Public License v1.0\nwhich accompanies this distribution, and is available at\nhttp\://www.eclipse.org/legal/epl-v10.html\n\nContributors\:\nJBoss by Red Hat - Initial implementation.\n
+ ############### end of copyright property ####################################
+
+# "licenseURL" property - URL of the "Feature License"
+# do not translate value - just change to point to a locale-specific HTML page
+licenseURL=license.html
+
+# START NON-TRANSLATABLE
+# "license" property - text of the "Feature Update License"
+# should be plain text version of license agreement pointed to be "licenseURL"
+license=ECLIPSE FOUNDATION SOFTWARE USER AGREEMENT\nMarch 17, 2005\n\nUsage Of Content\n\nTHE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\nOTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\nUSE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\nAGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\nNOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\nAGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\nAND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\nOR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\nTERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\nOF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\nBELOW, THEN YOU MAY NOT USE THE CONTENT.\n\nApplicable Licenses\n\nUnless otherwise indicated, all Content made available by the Eclipse Foundation\nis provided to you under the terms and conditio!
ns of the Eclipse Public\nLicense Version 1.0 ("EPL"). A copy of the EPL is provided with this\nContent and is also available at http\://www.eclipse.org/legal/epl-v10.html.\nFor purposes of the EPL, "Program" will mean the Content.\n\nContent includes, but is not limited to, source code, object code,\ndocumentation and other files maintained in the Eclipse.org CVS\nrepository ("Repository") in CVS modules ("Modules") and made available\nas downloadable archives ("Downloads").\n\n- Content may be structured and packaged into modules to facilitate delivering,\nextending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\nplug-in fragments ("Fragments"), and features ("Features").\n- Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java? ARchive)\nin a directory named "plugins".\n- A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\nEach Feature may be packaged as a sub-directory in a directory!
named "features".\nWithin a Feature, files named "feature.xml!
" may co
ntain a list of the names and version\nnumbers of the Plug-ins and/or Fragments associated with that Feature.\n- Features may also include other Features ("Included Features"). Within a Feature, files\nnamed "feature.xml" may contain a list of the names and version numbers of Included Features.\n\nFeatures may also include other Features ("Included Features"). Files named\n"feature.xml" may contain a list of the names and version numbers of\nIncluded Features.\n\nThe terms and conditions governing Plug-ins and Fragments should be\ncontained in files named "about.html" ("Abouts"). The terms and\nconditions governing Features and Included Features should be contained\nin files named "license.html" ("Feature Licenses"). Abouts and Feature\nLicenses may be located in any directory of a Download or Module\nincluding, but not limited to the following locations\:\n\n- The top-level (root) directory\n- Plug-in and Fragment directories\n- Inside Plug-ins and Fragments packaged as JAR!
s\n- Sub-directories of the directory named "src" of certain Plug-ins\n- Feature directories\n\nNote\: if a Feature made available by the Eclipse Foundation is installed using the\nEclipse Update Manager, you must agree to a license ("Feature Update\nLicense") during the installation process. If the Feature contains\nIncluded Features, the Feature Update License should either provide you\nwith the terms and conditions governing the Included Features or inform\nyou where you can locate them. Feature Update Licenses may be found in\nthe "license" property of files named "feature.properties". Such Abouts,\nFeature Licenses and Feature Update Licenses contain the terms and\nconditions (or references to such terms and conditions) that govern your\nuse of the associated Content in that directory.\n\nTHE ABOUTS, FEATURE LICENSES AND FEATURE UPDATE LICENSES MAY REFER\nTO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\nSOME OF THESE OTHER LICENSE AGREEMENTS MA!
Y INCLUDE (BUT ARE NOT LIMITED TO)\:\n\n- Common Public Licens!
e Versio
n 1.0 (available at http\://www.eclipse.org/legal/cpl-v10.html)\n- Apache Software License 1.1 (available at http\://www.apache.org/licenses/LICENSE)\n- Apache Software License 2.0 (available at http\://www.apache.org/licenses/LICENSE-2.0)\n- IBM Public License 1.0 (available at http\://oss.software.ibm.com/developerworks/opensource/license10.html)\n- Metro Link Public License 1.00 (available at http\://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n- Mozilla Public License Version 1.1 (available at http\://www.mozilla.org/MPL/MPL-1.1.html)\n\nIT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\nTO USE OF THE CONTENT. If no About, Feature License or Feature Update License\nis provided, please contact the Eclipse Foundation to determine what terms and conditions\ngovern that particular Content.\n\nCryptography\n\nContent may contain encryption software. The country in which you are\ncurrently may have restrictions on the import, posse!
ssion, and use,\nand/or re-export to another country, of encryption software. BEFORE\nusing any encryption software, please check the country's laws,\nregulations and policies concerning the import, possession, or use,\nand re-export of encryption software, to see if this is permitted.\n\nJava and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.\n
+# END NON-TRANSLATABLE
+########### end of license property ##########################################
Added: trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.xml
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.xml (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.runtime.feature/feature.xml 2009-06-26 15:55:07 UTC (rev 16224)
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<feature
+ id="org.jboss.tools.maven.runtime.feature"
+ label="%featureName"
+ version="1.0.0.qualifier"
+ provider-name="%providerName">
+
+ <description>
+ %description
+ </description>
+
+ <copyright>
+ %copyright
+ </copyright>
+
+ <license url="%licenseURL">
+ %license
+ </license>
+
+ <url>
+ <update label="%updateSiteName" url="http://download.jboss.org/jbosstools/updates/stable"/>
+ </url>
+
+ <includes
+ id="org.jboss.tools.maven.feature" version="0.0.0"/>
+
+ <includes
+ id="org.jboss.tools.maven.seam.feature" version="0.0.0"/>
+
+</feature>
Added: trunk/maven/features/org.jboss.tools.maven.runtime.feature/license.html
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.runtime.feature/license.html (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.runtime.feature/license.html 2009-06-26 15:55:07 UTC (rev 16224)
@@ -0,0 +1,79 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<html>
+<head>
+<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
+<title>Eclipse.org Software User Agreement</title>
+</head>
+
+<body lang="EN-US" link=blue vlink=purple>
+<h2>Eclipse Foundation Software User Agreement</h2>
+<p>March 17, 2005</p>
+
+<h3>Usage Of Content</h3>
+
+<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
+ (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
+ CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
+ OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
+ NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
+ CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
+
+<h3>Applicable Licenses</h3>
+
+<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
+ ("EPL"). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+ For purposes of the EPL, "Program" will mean the Content.</p>
+
+<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository ("Repository") in CVS
+ modules ("Modules") and made available as downloadable archives ("Downloads").</p>
+
+<ul>
+ <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").</li>
+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>
+ <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins
+ and/or Fragments associated with that Feature.</li>
+ <li>Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.</li>
+</ul>
+
+<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and
+Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module
+including, but not limited to the following locations:</p>
+
+<ul>
+ <li>The top-level (root) directory</li>
+ <li>Plug-in and Fragment directories</li>
+ <li>Inside Plug-ins and Fragments packaged as JARs</li>
+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>
+ <li>Feature directories</li>
+</ul>
+
+<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license ("Feature Update License") during the
+installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
+inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature.
+Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
+that directory.</p>
+
+<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
+OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
+
+<ul>
+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
+</ul>
+
+<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
+contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
+
+<h3>Cryptography</h3>
+
+<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
+ another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
+ possession, or use, and re-export of encryption software, to see if this is permitted.</p>
+
+<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
+</body>
+</html>
15 years, 6 months
JBoss Tools SVN: r16223 - in trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam: internal/core/refactoring and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: dazarov
Date: 2009-06-26 10:57:39 -0400 (Fri, 26 Jun 2009)
New Revision: 16223
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/SeamCoreMessages.java
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/messages.properties
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/RenameSeamContextVariableProcessor.java
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/SeamRenameProcessor.java
Log:
Rename Seam Context Variable https://jira.jboss.org/jira/browse/JBIDE-1077
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/SeamCoreMessages.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/SeamCoreMessages.java 2009-06-26 11:28:27 UTC (rev 16222)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/SeamCoreMessages.java 2009-06-26 14:57:39 UTC (rev 16223)
@@ -44,6 +44,7 @@
public static String RENAME_SEAM_COMPONENT_PROCESSOR_TITLE;
public static String RENAME_SEAM_COMPONENT_PROCESSOR_THIS_IS_NOT_A_SEAM_COMPONENT;
public static String RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_TITLE;
+ public static String RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_CAN_NOT_FIND_CONTEXT_VARIABLE;
public static String SEAM_RENAME_PROCESSOR_COMPONENT_HAS_DECLARATION_FROM_JAR;
public static String SEAM_RENAME_PROCESSOR_OUT_OF_SYNC_FILE;
public static String SEAM_RENAME_PROCESSOR_ERROR_PHANTOM_FILE;
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/messages.properties
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/messages.properties 2009-06-26 11:28:27 UTC (rev 16222)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/messages.properties 2009-06-26 14:57:39 UTC (rev 16223)
@@ -32,6 +32,7 @@
RENAME_SEAM_COMPONENT_PROCESSOR_TITLE=Rename Seam Component
RENAME_SEAM_COMPONENT_PROCESSOR_THIS_IS_NOT_A_SEAM_COMPONENT=This is not a Seam Component.
RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_TITLE=Rename Seam Context Variable
+RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_CAN_NOT_FIND_CONTEXT_VARIABLE=Can not find Seam Context Variable: ''{0}''.
SEAM_RENAME_PROCESSOR_COMPONENT_HAS_DECLARATION_FROM_JAR=Component ''{0}'' has a declaration which is located in jar file: ''{1}''. Press next to force rename.
SEAM_RENAME_PROCESSOR_OUT_OF_SYNC_FILE=File ''{0}'' is not in sync. Press next to force rename.
SEAM_RENAME_PROCESSOR_ERROR_PHANTOM_FILE=Cannot change phantom file: ''{0}''.
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/RenameSeamContextVariableProcessor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/RenameSeamContextVariableProcessor.java 2009-06-26 11:28:27 UTC (rev 16222)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/RenameSeamContextVariableProcessor.java 2009-06-26 14:57:39 UTC (rev 16223)
@@ -23,6 +23,9 @@
import org.eclipse.ltk.core.refactoring.participants.CheckConditionsContext;
import org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant;
import org.eclipse.ltk.core.refactoring.participants.SharableParticipants;
+import org.eclipse.ltk.internal.core.refactoring.Messages;
+import org.jboss.tools.seam.core.BijectedAttributeType;
+import org.jboss.tools.seam.core.IBijectedAttribute;
import org.jboss.tools.seam.core.ISeamComponent;
import org.jboss.tools.seam.core.ISeamContextShortVariable;
import org.jboss.tools.seam.core.ISeamContextVariable;
@@ -30,12 +33,15 @@
import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.SeamCoreMessages;
import org.jboss.tools.seam.core.SeamCorePlugin;
+import org.jboss.tools.seam.core.SeamProjectsSet;
+import org.jboss.tools.seam.internal.core.scanner.java.SeamAnnotations;
/**
* @author Daniel Azarov
*/
public class RenameSeamContextVariableProcessor extends SeamRenameProcessor {
IFile file;
+ private ISeamComponent component;
/**
* @param file where refactor was called
*/
@@ -54,17 +60,14 @@
CheckConditionsContext context) throws CoreException,
OperationCanceledException {
status = new RefactoringStatus();
- ISeamComponent component = checkComponent();
+
+ rootChange = new CompositeChange(SeamCoreMessages.RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_TITLE);
if(component != null){
checkDeclarations(component);
- rootChange = new CompositeChange(SeamCoreMessages.RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_TITLE);
-
renameComponent(pm, component);
}else{
- Set<ISeamFactory> factories = checkFactories();
- if(factories != null)
- renameFactories(pm, factories);
+ renameSeamContextVariable(pm, file);
}
return status;
}
@@ -77,6 +80,16 @@
public RefactoringStatus checkInitialConditions(IProgressMonitor pm)
throws CoreException, OperationCanceledException {
RefactoringStatus result = new RefactoringStatus();
+ boolean status = false;
+ component = checkComponent();
+
+ if(component == null){
+ status = checkContextVariable();
+ }else{
+ setOldName(component.getName());
+ }
+ if(component == null && !status)
+ result.addFatalError(Messages.format(SeamCoreMessages.RENAME_SEAM_CONTEXT_VARIABLE_PROCESSOR_CAN_NOT_FIND_CONTEXT_VARIABLE, getOldName()));
return result;
}
@@ -88,33 +101,41 @@
public Change createChange(IProgressMonitor pm) throws CoreException,
OperationCanceledException {
-
-
return rootChange;
}
- private boolean checked = false;
-
- public String getOldName(){
- if(!checked){
- ISeamComponent component = checkComponent();
- if(component != null){
- setOldName(component.getName());
+ private ISeamComponent checkComponent(){
+ ISeamComponent comp;
+ ISeamProject seamProject = SeamCorePlugin.getSeamProject(file.getProject(), true);
+ projectsSet = new SeamProjectsSet(file.getProject());
+
+ comp = checkComponent(seamProject);
+ if(comp != null)
+ return comp;
+
+ IProject[] projects = projectsSet.getAllProjects();
+ for (IProject project : projects) {
+ ISeamProject sProject = SeamCorePlugin.getSeamProject(project, true);
+ if(sProject != null){
+ comp = checkComponent(sProject);
+ if(comp != null)
+ return comp;
}
- checked = true;
}
- return super.getOldName();
+ return null;
}
- private ISeamComponent checkComponent(){
- IProject project = file.getProject();
- ISeamProject seamProject = SeamCorePlugin.getSeamProject(project, true);
+ private ISeamComponent checkComponent(ISeamProject seamProject){
if (seamProject != null) {
- ISeamComponent component = seamProject.getComponent(super.getOldName());
+ ISeamComponent component = seamProject.getComponent(getOldName());
if(component != null)
return component;
- Set<ISeamContextVariable> variables = seamProject.getVariablesByName(super.getOldName());
+ Set<ISeamContextVariable> variables = seamProject.getVariablesByName(getOldName());
+
+ if(variables == null)
+ return null;
+
for(ISeamContextVariable variable : variables){
if(variable instanceof ISeamContextShortVariable){
ISeamContextVariable original = ((ISeamContextShortVariable)variable).getOriginal();
@@ -126,15 +147,67 @@
return null;
}
- private Set<ISeamFactory> checkFactories(){
- IProject project = file.getProject();
- ISeamProject seamProject = SeamCorePlugin.getSeamProject(project, true);
+ private boolean checkContextVariable(){
+ boolean status = false;
+ ISeamProject seamProject = SeamCorePlugin.getSeamProject(file.getProject(), true);
+
+ status = checkFactories(seamProject);
+ if(status)
+ return status;
+
+ status = checkOuts(seamProject);
+ if(status)
+ return status;
+
+ status = checkDataModels(seamProject);
+ if(status)
+ return status;
+
+ IProject[] projects = projectsSet.getAllProjects();
+ for (IProject project : projects) {
+ ISeamProject sProject = SeamCorePlugin.getSeamProject(project, true);
+ if(sProject != null){
+ status = checkFactories(sProject);
+ if(status)
+ return status;
+
+ status = checkOuts(sProject);
+ if(status)
+ return status;
+
+ status = checkDataModels(sProject);
+ if(status)
+ return status;
+ }
+ }
+ return status;
+ }
+
+ private boolean checkFactories(ISeamProject seamProject){
if (seamProject != null) {
- return seamProject.getFactoriesByName(getOldName());
+ return seamProject.getFactoriesByName(getOldName()) != null;
}
- return null;
+ return false;
}
+ private boolean checkOuts(ISeamProject seamProject){
+ if (seamProject != null) {
+ Set<IBijectedAttribute> variables = seamProject.getBijectedAttributesByName(getOldName(), BijectedAttributeType.OUT);
+
+ return variables != null;
+ }
+ return false;
+ }
+
+ private boolean checkDataModels(ISeamProject seamProject){
+ if (seamProject != null) {
+ Set<IBijectedAttribute> variables = seamProject.getBijectedAttributesByName(getOldName(), BijectedAttributeType.DATA_BINDER);
+
+ return variables != null;
+ }
+ return false;
+ }
+
/*
* (non-Javadoc)
* @see org.eclipse.ltk.core.refactoring.participants.RefactoringProcessor#getElements()
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/SeamRenameProcessor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/SeamRenameProcessor.java 2009-06-26 11:28:27 UTC (rev 16222)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/refactoring/SeamRenameProcessor.java 2009-06-26 14:57:39 UTC (rev 16223)
@@ -166,24 +166,40 @@
return;
files.clear();
- findAnnotations(seamProject, true);
+ findInFactoryAnnotations(seamProject, true);
IProject[] projects = projectsSet.getAllProjects();
for (IProject project : projects) {
ISeamProject sProject = SeamCorePlugin.getSeamProject(project, true);
if(sProject != null){
- findAnnotations(sProject, false);
+ findInFactoryAnnotations(sProject, false);
}
}
}
- private void findAnnotations(ISeamProject seamProject, boolean force){
+ private void findInFactoryAnnotations(ISeamProject seamProject, boolean force){
// find @In annotations
- Set<IBijectedAttribute> inSet = seamProject.getBijectedAttributesByName(getOldName(), BijectedAttributeType.IN);
+ findAnnotations(seamProject, force, BijectedAttributeType.IN, SeamAnnotations.IN_ANNOTATION_TYPE);
+
+ findFactories(seamProject, force);
+ }
+
+ private void findFactories(ISeamProject seamProject, boolean force){
+ // find @Factory annotations
+ Set<ISeamFactory> factorySet = seamProject.getFactoriesByName(getOldName());
+
+ for(ISeamFactory factory : factorySet){
+ changeFactory(factory, force);
+ }
+ }
+
+ private void findAnnotations(ISeamProject seamProject, boolean force, BijectedAttributeType type, String locationPath){
+ Set<IBijectedAttribute> inSet = seamProject.getBijectedAttributesByName(getOldName(), type);
+
for(IBijectedAttribute inAtt : inSet){
- ITextSourceReference location = inAtt.getLocationFor(SeamAnnotations.IN_ANNOTATION_TYPE);
+ ITextSourceReference location = inAtt.getLocationFor(locationPath);
if(location != null){
if(!files.contains(inAtt.getResource().getFullPath())){
files.add(inAtt.getResource().getFullPath());
@@ -192,17 +208,11 @@
changeAnnotation(location, (IFile)inAtt.getResource());
}
}
-
- // find @Factory annotations
- Set<ISeamFactory> factorySet = seamProject.getFactoriesByName(getOldName());
-
- for(ISeamFactory factory : factorySet){
- changeFactory(factory, force);
- }
}
private void changeFactory(ISeamFactory factory, boolean force){
IFile file = (IFile)factory.getResource();
+
if(file.getFileExtension().equalsIgnoreCase(JAVA_EXT)){
ITextSourceReference location = factory.getLocationFor(SeamAnnotations.FACTORY_ANNOTATION_TYPE);
if(location != null){
@@ -692,8 +702,45 @@
pm.worked(1);
}
+ pm.done();
+ }
+
+ protected void renameSeamContextVariable(IProgressMonitor pm, IFile sourceFile)throws CoreException{
+ pm.beginTask("", 2);
+
+ declarationFile = sourceFile;
+
+ findOutDataModelFactory();
+
+ pm.worked(1);
+
findELReferences();
pm.done();
}
+
+ protected void findOutDataModelFactory(){
+ if(declarationFile == null)
+ return;
+
+ ISeamProject seamProject = SeamCorePlugin.getSeamProject(declarationFile.getProject(), true);
+
+ if(seamProject == null)
+ return;
+
+ files.clear();
+ findAnnotations(seamProject, true, BijectedAttributeType.OUT, SeamAnnotations.OUT_ANNOTATION_TYPE);
+ findAnnotations(seamProject, true, BijectedAttributeType.DATA_BINDER, "name"/*SeamAnnotations.DATA_MODEL_ANNOTATION_TYPE*/);
+ findFactories(seamProject, true);
+
+ IProject[] projects = projectsSet.getAllProjects();
+ for (IProject project : projects) {
+ ISeamProject sProject = SeamCorePlugin.getSeamProject(project, true);
+ if(sProject != null){
+ findAnnotations(sProject, false, BijectedAttributeType.OUT, SeamAnnotations.OUT_ANNOTATION_TYPE);
+ findAnnotations(sProject, false, BijectedAttributeType.DATA_BINDER, "name"/*SeamAnnotations.DATA_MODEL_ANNOTATION_TYPE*/);
+ findFactories(sProject, false);
+ }
+ }
+ }
}
15 years, 6 months
JBoss Tools SVN: r16222 - in trunk: jst/plugins/org.jboss.tools.jst.web.verification and 2 other directories.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2009-06-26 07:28:27 -0400 (Fri, 26 Jun 2009)
New Revision: 16222
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf.verification/build.properties
trunk/jst/plugins/org.jboss.tools.jst.web.verification/build.properties
trunk/seam/plugins/org.jboss.tools.seam.text.ext/build.properties
trunk/seam/plugins/org.jboss.tools.seam.xml.ui/build.properties
Log:
https://jira.jboss.org/jira/browse/JBIDE-4533 fixed
Modified: trunk/jsf/plugins/org.jboss.tools.jsf.verification/build.properties
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf.verification/build.properties 2009-06-26 10:18:51 UTC (rev 16221)
+++ trunk/jsf/plugins/org.jboss.tools.jsf.verification/build.properties 2009-06-26 11:28:27 UTC (rev 16222)
@@ -1,8 +1,9 @@
-bin.includes = *.jar,\
- META-INF/,\
+bin.includes = META-INF/,\
about.html,\
plugin.xml,\
- plugin.properties
+ plugin.properties,\
+ plugin_ja.properties,\
+ .
source.. = src/,\
resources/
jars.compile.order = .
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.verification/build.properties
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.verification/build.properties 2009-06-26 10:18:51 UTC (rev 16221)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.verification/build.properties 2009-06-26 11:28:27 UTC (rev 16222)
@@ -2,7 +2,8 @@
*.jar,\
plugin.properties,\
about.html,\
- META-INF/
+ META-INF/,\
+ .
source.. = src/,\
resources/
jars.compile.order = .
Modified: trunk/seam/plugins/org.jboss.tools.seam.text.ext/build.properties
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.text.ext/build.properties 2009-06-26 10:18:51 UTC (rev 16221)
+++ trunk/seam/plugins/org.jboss.tools.seam.text.ext/build.properties 2009-06-26 11:28:27 UTC (rev 16222)
@@ -4,7 +4,6 @@
META-INF/,\
plugin.properties,\
about.html
-source.seam-text-ext.jar = src/
src.includes = src/,\
plugin.xml,\
plugin.properties,\
Modified: trunk/seam/plugins/org.jboss.tools.seam.xml.ui/build.properties
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.xml.ui/build.properties 2009-06-26 10:18:51 UTC (rev 16221)
+++ trunk/seam/plugins/org.jboss.tools.seam.xml.ui/build.properties 2009-06-26 11:28:27 UTC (rev 16222)
@@ -3,7 +3,8 @@
plugin.properties,\
images/,\
META-INF/,\
- about.html
+ about.html,\
+ .
source.. = src/,\
resources/
jars.compile.order = .
15 years, 6 months
JBoss Tools SVN: r16221 - in trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui: commands and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: Grid.Qian
Date: 2009-06-26 06:18:51 -0400 (Fri, 26 Jun 2009)
New Revision: 16221
Modified:
trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/Messages.java
trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeleteChildCommand.java
trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeletePartnerLinkTypeCommand.java
trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/messages.properties
Log:
JBIDE-4532: when delete the partnerlink, a exception occured:java.lang.ClassCastException: org.eclipse.wst.wsdl.util.WSDLResourceImpl
Modified: trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/Messages.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/Messages.java 2009-06-26 09:44:55 UTC (rev 16220)
+++ trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/Messages.java 2009-06-26 10:18:51 UTC (rev 16221)
@@ -702,6 +702,9 @@
public static String OutlinePage_showOverviewView;
public static String OutlinePage_showOutlineView;
+
+ public static String DeletePartnerLinkTypeWarningMessage;
+ public static String DeletePartnerLinkTypeWarningDialogTitle;
static {
Modified: trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeleteChildCommand.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeleteChildCommand.java 2009-06-26 09:44:55 UTC (rev 16220)
+++ trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeleteChildCommand.java 2009-06-26 10:18:51 UTC (rev 16221)
@@ -34,12 +34,14 @@
import org.eclipse.bpel.ui.util.ModelHelper;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.resource.Resource;
+import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.osgi.util.NLS;
+import org.eclipse.ui.PlatformUI;
import org.eclipse.wst.wsdl.Definition;
/**
- * Deletes a model object from an IContainer, and removes any references to it from other
- * model objects.
+ * Deletes a model object from an IContainer, and removes any references to it
+ * from other model objects.
*
* This is more or less the opposite of InsertInContainerCommand.
*
@@ -49,28 +51,30 @@
private EObject fChild;
private EObject fParent;
-
+
IContainer fContainer;
-
+
Resource[] resourcesToModify = null;
-
+
CompoundCommand fDeleteLinksCmd;
- CompoundCommand fDeletePLTsCmd;
-
+ CompoundCommand fDeletePLTsCmd;
+
public DeleteChildCommand(EObject child) {
super(new ArrayList(2));
fParent = child.eContainer();
-
+
if (fParent instanceof FaultHandler || fParent instanceof EventHandler) {
- // If the child of the FH/EH is the *only* child, then we want to delete the
+ // If the child of the FH/EH is the *only* child, then we want to
+ // delete the
// entire FH/EH, since it has no meaningful attributes of its own.
- IContainer<EObject> container = BPELUtil.adapt(fParent, IContainer.class);
+ IContainer<EObject> container = BPELUtil.adapt(fParent,
+ IContainer.class);
List<EObject> children = container.getChildren(fParent);
if (children.size() == 1 && children.contains(child)) {
// delete the FH instead
child = fParent;
- fParent = child.eContainer();
+ fParent = child.eContainer();
}
}
this.fChild = child;
@@ -78,19 +82,21 @@
if (fParent != null) {
addModelRoot(fParent);
}
-
+
fContainer = BPELUtil.adapt(fParent, IContainer.class);
-
+
String childType = null;
- ILabeledElement labeledElement = BPELUtil.adapt(child, ILabeledElement.class);
+ ILabeledElement labeledElement = BPELUtil.adapt(child,
+ ILabeledElement.class);
if (labeledElement != null) {
childType = labeledElement.getTypeLabel(child);
}
- if (childType == null) {
- childType = Messages.DeleteChildCommand_Item_1;
+ if (childType == null) {
+ childType = Messages.DeleteChildCommand_Item_1;
}
- setLabel(NLS.bind(Messages.DeleteChildCommand_Delete_2, (new Object[] { childType })));
+ setLabel(NLS.bind(Messages.DeleteChildCommand_Delete_2,
+ (new Object[] { childType })));
}
/**
@@ -98,10 +104,10 @@
*/
@Override
public boolean canDoExecute() {
- if (fChild == null || fParent == null || fContainer==null ) {
+ if (fChild == null || fParent == null || fContainer == null) {
return false;
- }
- return fContainer.canRemoveChild ( fParent, fChild );
+ }
+ return fContainer.canRemoveChild(fParent, fChild);
}
// TODO: this is a hack.
@@ -109,78 +115,100 @@
public Resource[] getResources() {
if (resourcesToModify == null) {
Process process = ModelHelper.getProcess(fParent);
- if (process == null) return EMPTY_RESOURCE_ARRAY;
+ if (process == null)
+ return EMPTY_RESOURCE_ARRAY;
BPELEditor bpelEditor = ModelHelper.getBPELEditor(process);
-
+
Set<Resource> resultSet = new HashSet<Resource>();
resultSet.add(fParent.eResource());
-
+
// Figure out which model objects are being deleted.
HashSet<Object> deletingSet = new HashSet<Object>();
ModelHelper.addSubtreeToCollection(fChild, deletingSet);
-
- // If we are deleting any PartnerLinks which reference PLTs in the Artifacts WSDL
+
+ // If we are deleting any PartnerLinks which reference PLTs in the
+ // Artifacts WSDL
// file, also delete the referenced PLTs.
Set<PartnerLinkType> partnerLinkTypes = null;
- Definition artifactsDefinition = bpelEditor.getArtifactsDefinition();
-
- for (Iterator it = deletingSet.iterator(); it.hasNext(); ) {
+ Definition artifactsDefinition = bpelEditor
+ .getArtifactsDefinition();
+
+ for (Iterator it = deletingSet.iterator(); it.hasNext();) {
Object object = it.next();
if (object instanceof PartnerLink) {
- PartnerLinkType plt = ((PartnerLink)object).getPartnerLinkType();
- if ((plt != null) && (plt.getEnclosingDefinition() == artifactsDefinition)) {
- if (partnerLinkTypes == null) partnerLinkTypes = new HashSet<PartnerLinkType>();
+ PartnerLinkType plt = ((PartnerLink) object)
+ .getPartnerLinkType();
+ if ((plt != null)
+ && (plt.getEnclosingDefinition() == artifactsDefinition)) {
+ if (partnerLinkTypes == null)
+ partnerLinkTypes = new HashSet<PartnerLinkType>();
if (partnerLinkTypes.add(plt)) {
resultSet.add(plt.eResource());
}
}
}
}
- resourcesToModify = resultSet.toArray(new Resource[resultSet.size()]);
+ resourcesToModify = resultSet
+ .toArray(new Resource[resultSet.size()]);
}
return resourcesToModify;
}
-
+
/**
* @see org.eclipse.bpel.ui.commands.util.AutoUndoCommand#doExecute()
*/
@Override
public void doExecute() {
-
- if (!canExecute()) {
+
+ if (!canExecute()) {
throw new IllegalStateException();
}
Process process = ModelHelper.getProcess(fParent);
- if (process == null) return;
+ if (process == null)
+ return;
BPELEditor bpelEditor = ModelHelper.getBPELEditor(process);
-
+
EObject topModelObject = process;
-
- // Multi-delete safety: if the child does not have a resource, assume it has
+
+ // Multi-delete safety: if the child does not have a resource, assume it
+ // has
// already been deleted, and do nothing.
if (fChild.eResource() == null) {
return;
}
-
+
// Figure out which model objects are being deleted.
HashSet deletingSet = new HashSet();
ModelHelper.addSubtreeToCollection(fChild, deletingSet);
-
- // If we are deleting any PartnerLinks which reference PLTs in the Artifacts WSDL
- // file, also delete the referenced PLTs.
- Set<PartnerLinkType> partnerLinkTypes = null;
- Definition artifactsDefinition = bpelEditor.getArtifactsDefinition();
- for (Iterator it = deletingSet.iterator(); it.hasNext(); ) {
- Object object = it.next();
- if (object instanceof PartnerLink) {
- PartnerLinkType plt = ((PartnerLink)object).getPartnerLinkType();
- if ((plt != null) && (plt.getEnclosingDefinition() == artifactsDefinition)) {
- if (partnerLinkTypes == null) partnerLinkTypes = new HashSet<PartnerLinkType>();
- if (partnerLinkTypes.add(plt)) {
- if (fDeletePLTsCmd == null) fDeletePLTsCmd = new CompoundCommand();
- fDeletePLTsCmd.add(new DeletePartnerLinkTypeCommand(plt));
+ // We should ask the user if delete the partner link type
+ if (MessageDialog.openQuestion(PlatformUI.getWorkbench()
+ .getActiveWorkbenchWindow().getShell(),
+ Messages.DeletePartnerLinkTypeWarningDialogTitle,
+ Messages.DeletePartnerLinkTypeWarningMessage)) {
+ // If we are deleting any PartnerLinks which reference PLTs in the
+ // Artifacts WSDL
+ // file, also delete the referenced PLTs.
+ Set<PartnerLinkType> partnerLinkTypes = null;
+ Definition artifactsDefinition = bpelEditor
+ .getArtifactsDefinition();
+
+ for (Iterator it = deletingSet.iterator(); it.hasNext();) {
+ Object object = it.next();
+ if (object instanceof PartnerLink) {
+ PartnerLinkType plt = ((PartnerLink) object)
+ .getPartnerLinkType();
+ if ((plt != null)
+ && (plt.getEnclosingDefinition() == artifactsDefinition)) {
+ if (partnerLinkTypes == null)
+ partnerLinkTypes = new HashSet<PartnerLinkType>();
+ if (partnerLinkTypes.add(plt)) {
+ if (fDeletePLTsCmd == null)
+ fDeletePLTsCmd = new CompoundCommand();
+ fDeletePLTsCmd
+ .add(new DeletePartnerLinkTypeCommand(plt));
+ }
}
}
}
@@ -191,49 +219,61 @@
ModelHelper.addSubtreeToCollection(topModelObject, notDeletingSet);
notDeletingSet.removeAll(deletingSet);
- // We also need to find any flow links which involve a deleted object and remove them.
+ // We also need to find any flow links which involve a deleted object
+ // and remove them.
// This is a hack, but it could be worse..
// step 1: find all the flows which contain deleted objects
HashSet<Flow> flowSet = new HashSet<Flow>();
- for (Iterator<EObject> it = deletingSet.iterator(); it.hasNext(); ) {
- Flow [] flws = FlowLinkUtil.getParentFlows(it.next());
+ for (Iterator<EObject> it = deletingSet.iterator(); it.hasNext();) {
+ Flow[] flws = FlowLinkUtil.getParentFlows(it.next());
flowSet.addAll(Arrays.asList(flws));
}
// step 2: if any of the flows is being deleted, we can ignore it
- // this is safe because the source, dest and link itself are all children of the flow
+ // this is safe because the source, dest and link itself are all
+ // children of the flow
flowSet.removeAll(deletingSet);
-
- // step 3: check each link in each of the remaining flows to see if it involves a
- // deleted object. Even if both source and target are being deleted, we should still
- // delete the link, since it is a child of the Flow which is not being deleted.
+
+ // step 3: check each link in each of the remaining flows to see if it
+ // involves a
+ // deleted object. Even if both source and target are being deleted, we
+ // should still
+ // delete the link, since it is a child of the Flow which is not being
+ // deleted.
fDeleteLinksCmd = new CompoundCommand();
- for (Iterator<Flow> flowIt = flowSet.iterator(); flowIt.hasNext(); ) {
+ for (Iterator<Flow> flowIt = flowSet.iterator(); flowIt.hasNext();) {
Flow flow = flowIt.next();
- for (Iterator<Link> it = FlowLinkUtil.getFlowLinks(flow).iterator(); it.hasNext(); ) {
+ for (Iterator<Link> it = FlowLinkUtil.getFlowLinks(flow).iterator(); it
+ .hasNext();) {
Link link = it.next();
- if (deletingSet.contains(FlowLinkUtil.getLinkSource(link)) || deletingSet.contains(FlowLinkUtil.getLinkTarget(link))) {
- // NOTE: this is safe even if the link is scheduled for deletion by
+ if (deletingSet.contains(FlowLinkUtil.getLinkSource(link))
+ || deletingSet.contains(FlowLinkUtil
+ .getLinkTarget(link))) {
+ // NOTE: this is safe even if the link is scheduled for
+ // deletion by
// a GEF DeleteAction, see comment in DeleteLinkCommand.
DeleteLinkCommand child = new DeleteLinkCommand(link);
- if (child.canExecute()) fDeleteLinksCmd.add(child);
+ if (child.canExecute())
+ fDeleteLinksCmd.add(child);
}
}
}
-
+
fDeleteLinksCmd.doExecute();
-
+
if (fDeletePLTsCmd != null) {
fDeletePLTsCmd.doExecute();
}
-
+
// finally, we can remove the child.
fContainer.removeChild(fParent, fChild);
- // IMPORTANT: since the parent is a not-deleted object and the child will be
- // a deleted object, this step must be done *after* the IContainer removal ;)
- for (Iterator it = notDeletingSet.iterator(); it.hasNext(); ) {
- BPELUtil.deleteNonContainmentRefs((EObject)it.next(), deletingSet);
+ // IMPORTANT: since the parent is a not-deleted object and the child
+ // will be
+ // a deleted object, this step must be done *after* the IContainer
+ // removal ;)
+ for (Iterator it = notDeletingSet.iterator(); it.hasNext();) {
+ BPELUtil.deleteNonContainmentRefs((EObject) it.next(), deletingSet);
}
}
}
Modified: trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeletePartnerLinkTypeCommand.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeletePartnerLinkTypeCommand.java 2009-06-26 09:44:55 UTC (rev 16220)
+++ trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/commands/DeletePartnerLinkTypeCommand.java 2009-06-26 10:18:51 UTC (rev 16221)
@@ -10,8 +10,12 @@
*******************************************************************************/
package org.eclipse.bpel.ui.commands;
+import java.util.HashSet;
+import java.util.Set;
+
import org.eclipse.bpel.model.partnerlinktype.PartnerLinkType;
import org.eclipse.bpel.ui.IBPELUIConstants;
+import org.eclipse.bpel.ui.util.ModelHelper;
/**
@@ -26,4 +30,20 @@
public DeletePartnerLinkTypeCommand(PartnerLinkType plt) {
super(plt);
}
+
+ /**
+ * Override super's method because we should not delete other partner link
+ */
+ @Override
+ public void doExecute() {
+ fDefinition = fElement.getEnclosingDefinition();
+
+ Set<Object> modelRootSet = new HashSet<Object>();
+ modelRootSet.add(fElement.eResource());
+ modelRootSet.add(ModelHelper.getBPELEditor(fElement).getResource());
+
+ fElement.setEnclosingDefinition(null);
+ fDefinition.getEExtensibilityElements().remove(fElement);
+
+ }
}
Modified: trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/messages.properties
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/messages.properties 2009-06-26 09:44:55 UTC (rev 16220)
+++ trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/messages.properties 2009-06-26 10:18:51 UTC (rev 16221)
@@ -136,9 +136,12 @@
BPELPreferencePage_WSIL_EnterLocation = <enter location>
#
# This has \n for a reason. The wrapping in the widget works, but not as expected.
-BPELPreferencePage_WSIL_Description = \
-The document above contains links to other WSIL documents shown below.\n\
-You can add or remove WSIL links to/from the above document.\n\
+BPELPreferencePage_WSIL_Description = \
+
+The document above contains links to other WSIL documents shown below.\n\
+
+You can add or remove WSIL links to/from the above document.\n\
+
The result will be shown in the WSIL browser of the editor.
#
BPELUIRegistry_Expression_language_editors_must_provide_expressionLanguage_and_class__8=Expression language editors must provide expressionLanguage and class.
@@ -696,3 +699,5 @@
SaveImageAction_2=Overwrite {0}?
SaveImageAction_3=Error
SaveImageAction_4=Can't save image to the file {0}
+DeletePartnerLinkTypeWarningDialogTitle=Warning
+DeletePartnerLinkTypeWarningMessage=When you delete the partnerlink, you may delete the reference PartnerLinkType too, do you want to delete the PartnerLinkType?
15 years, 6 months
JBoss Tools SVN: r16220 - trunk/jbpm/features/org.jboss.tools.jbpm4.sdk.feature.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2009-06-26 05:44:55 -0400 (Fri, 26 Jun 2009)
New Revision: 16220
Modified:
trunk/jbpm/features/org.jboss.tools.jbpm4.sdk.feature/feature.xml
Log:
fix for JBPM4 compilation errors
Modified: trunk/jbpm/features/org.jboss.tools.jbpm4.sdk.feature/feature.xml
===================================================================
--- trunk/jbpm/features/org.jboss.tools.jbpm4.sdk.feature/feature.xml 2009-06-26 07:57:33 UTC (rev 16219)
+++ trunk/jbpm/features/org.jboss.tools.jbpm4.sdk.feature/feature.xml 2009-06-26 09:44:55 UTC (rev 16220)
@@ -16,28 +16,30 @@
%license
</license>
- <includes
- id="org.jboss.tools.flow.jpdl4.feature"
+ <includes
+ id="org.jboss.tools.jbpm.common.feature"
version="0.0.0"/>
<includes
- id="org.jboss.tools.flow.jpdl4.source.feature"
+ id="org.jboss.tools.jbpm.common.source.feature"
version="0.0.0"/>
<includes
- id="org.jboss.tools.jbpm.common.feature"
+ id="org.jboss.tools.flow.common.feature"
version="0.0.0"/>
<includes
- id="org.jboss.tools.jbpm.common.source.feature"
+ id="org.jboss.tools.flow.common.source.feature"
version="0.0.0"/>
-
+
<includes
- id="org.jboss.tools.flow.common.feature"
+ id="org.jboss.tools.flow.jpdl4.feature"
version="0.0.0"/>
<includes
- id="org.jboss.tools.flow.common.source.feature"
+ id="org.jboss.tools.flow.jpdl4.source.feature"
version="0.0.0"/>
+
+
</feature>
15 years, 6 months
JBoss Tools SVN: r16219 - trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util.
by jbosstools-commits@lists.jboss.org
Author: sflanigan
Date: 2009-06-26 03:57:33 -0400 (Fri, 26 Jun 2009)
New Revision: 16219
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelUtil.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3557 Externalize English strings (and add NON-NLS comments to others)
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelUtil.java 2009-06-26 07:56:07 UTC (rev 16218)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelUtil.java 2009-06-26 07:57:33 UTC (rev 16219)
@@ -18,10 +18,10 @@
import org.jboss.tools.common.model.impl.*;
public class XModelUtil {
- private static final String DEFAULT_MODEL_VERSION = "5.0";
+ private static final String DEFAULT_MODEL_VERSION = "5.0"; //$NON-NLS-1$
- private static final String PROPERTIES_ACTION = "Properties/Properties";
- private static final String EDIT_ACTION = "Edit";
+ private static final String PROPERTIES_ACTION = "Properties/Properties"; //$NON-NLS-1$
+ private static final String EDIT_ACTION = "Edit"; //$NON-NLS-1$
public static void addModifyListener(XModel model, Object listener) {
RootImpl impl = (RootImpl)model.getRoot();
@@ -36,7 +36,7 @@
XModelObject fss = FileSystemsHelper.getFileSystems(model);
if(fss == null) return DEFAULT_MODEL_VERSION;
String modelVersionStr = fss.getAttributeValue(XModelConstants.MODEL_VERSION);
- return (modelVersionStr == null || "".equals(modelVersionStr)) ? DEFAULT_MODEL_VERSION : modelVersionStr;
+ return (modelVersionStr == null || "".equals(modelVersionStr)) ? DEFAULT_MODEL_VERSION : modelVersionStr; //$NON-NLS-1$
}
public static void openProperyDialog(XModelObject object){
15 years, 6 months
JBoss Tools SVN: r16218 - in trunk/common/plugins: org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt and 99 other directories.
by jbosstools-commits@lists.jboss.org
Author: sflanigan
Date: 2009-06-26 03:56:07 -0400 (Fri, 26 Jun 2009)
New Revision: 16218
Added:
trunk/common/plugins/org.jboss.tools.common.projecttemplates/.settings/
trunk/common/plugins/org.jboss.tools.common.projecttemplates/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.resref.core/.settings/
trunk/common/plugins/org.jboss.tools.common.resref.core/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/Messages.java
trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/messages.properties
trunk/common/plugins/org.jboss.tools.common.text.ext/.settings/
trunk/common/plugins/org.jboss.tools.common.text.ext/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.text.xml/.settings/
trunk/common/plugins/org.jboss.tools.common.text.xml/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.verification.ui/.settings/
trunk/common/plugins/org.jboss.tools.common.verification.ui/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/Messages.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/messages.properties
trunk/common/plugins/org.jboss.tools.common.verification/.settings/
trunk/common/plugins/org.jboss.tools.common.verification/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/Messages.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/messages.properties
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/FavoritesClassController.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/Messages.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInput.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInputFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/AbstractSectionEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/DeleteFileUnderEditingSpecialWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/EditorActionBarContributorWrapper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ErrorMode.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/TreeFormPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/XMLEditorLauncher.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/DefaultChildrenForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleChildForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleErrorForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SamplePropertyForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleTreeForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Insets.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIPlugin.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/AddNatureActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/SaveModelActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvoker.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvokerWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectAction.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionInvoker.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionList.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/HelpActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/RemoveModelNatureActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyActionFilter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyAllActionFilter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/AbstractShowUrlActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/ReportProblemActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitCompanyActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitForumActionDelegate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/sample/XActionWrapper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/AttributeContentProposalProviderFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/WizardDataPropertySource.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributePropertyDescription.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributeSupport.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XModelObjectPropertySource.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ActiveValueAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/AdapterFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckListAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckTreeAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultComboBoxValueAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProcessor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultValueAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXAttributeTreeContentProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXModelObjectLabelProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/FileChooserAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/JavaClassContentAssistProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ModelObjectChildEditorAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/Note2Adapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/StructuredListAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/XChildrenTableStructuredAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/ColoredFontData.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/EclipseClassChooserAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FileSystemListContentProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FontChooserAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/TomcatJVMListAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActionButtonControl.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActiveFieldEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxCellEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckListFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckTreeFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DefaultButtonControl.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DialogCellEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DirectoryFieldEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ExtendedFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/FileFieldEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/HyperlinkStringButtonFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/IPropertyEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaChoicerFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaEclipseChoicerEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaFavoritesFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCellEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCueLabelProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListSelectionFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListStructuredFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MultipleChoiceFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableComboBoxFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/NoteFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/PropertyEditorFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/RadioArrayFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/SliderFieldEditor2.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditorEx.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringTwoButtonFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/ErrorDialog.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/MessageAndCheckboxDialog.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/SelectEclipseFileWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialogs/PageDialog.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ControlDragDrop.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ModelTransfer.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/DefaultEditorPart.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorActionBarContributorWrapper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapperExtension.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectJarEntryEditorInput.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectStorageEditorInput.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/XMLContentDescriber.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/AbsoluteFilePathAttributeValueLoader.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/CssLinkAttributeValueLoader.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommand.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommandRunner.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardModel.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultElementGenerator.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropURI.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropUtils.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardDialog.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardMessages.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileDropCommand.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileTagProposalLoader.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/IDropWizardModel.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/JSPTagProposalFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/LoadBundleBaseNameAttributeValueLoader.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/PaletteDropCommand.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagAttributesWizardPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagProposal.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagAttributesComposite.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagProposalsComposite.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/context/DropContext.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/multipage/DefaultMultipageEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AbstractForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AnyElementForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultFormPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultXModelObjectForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ExpandableForm.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Form.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormContainer.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormLayoutDataUtil.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/IFormColor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/LayouredFormFactory.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Memento.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/MementoDOM.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ModelFormLayoutData.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/SplitFormContainer.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/image/XModelObjectImageDescriptor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/FilteredTreeContentProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/LabelDecoratorImpl.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorLabelProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorStatusLineProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeDragDropProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeViewerModelListenerImpl.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/AttributeDecoratorPart.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorConstants.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorManager.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorPart.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/NameDecoratorPart.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/Variable.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/XModelObjectDecorator.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/PropertiesWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/SaveUnopenSpecialWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XCellModifier.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XModelObjectEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XTable.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/OutlineMenuInvoker.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/XModelObjectContentOutlineProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesListener.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/TabbedPreferencesPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/XMOBasedPreferencesPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/Problem.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ProblemDialog.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ResourceProblemManager.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ProblemReporter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportPreference.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportProblemWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/SelectObjectWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/XModelObjectSelectionProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/assistent/TemplateContentAssistentProcessor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaClassTemplateHelper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaConfigurationLoader.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaClassTemplate.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaTemplateConstants.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/AddInterfaceSupport.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/GlobalTemplatePreferencePage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/TemplateComponent.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/AbstractMultiPageContributor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/PropertiesTextEditorComponent.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextActionHelper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorComponent.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorSupport.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorComponent.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorStandAlone.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/dnd/TextEditorDrop.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/EditorsPreferencesPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/ReplaceTabsAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/TabWidthAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/ExtensionPointUtils.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/StringUtilities.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/FilteredTreesCache.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCopyAction.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCutAction.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NDeleteAction.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NPasteAction.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorContentProvider.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorMenuInvoker.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorViewPart.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteContents.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteDescriptionManager.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertHelper.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertManager.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteTaglibInserter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteViewPart.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/EditorTypesAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/NatureTypesAdapter.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialog.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialogState.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/model/PaletteModel.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/DefaultSettings.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/NoTextBorderSettings.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/TextAndReferenceComponent.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/WhiteSettings.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/xpl/FormLabel.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewClassCreationWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewFileContext.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewHTMLFileWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewJSPFileWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewPropertiesFileWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewXHTMLFileWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/WizardInvoker.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/MessageWizardPage.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/NewClassWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/OneStepWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/one/ServiceDialogOption.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizard.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractListWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractTreeWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/special/DefaultSpecialWizard.java
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/util/DeadLock.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLocaleEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesCompoundEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/BundleModel.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/PropertyModel.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/text/PropertyTextEditorSupport.java
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/event/XModelTreeEvent.java
trunk/common/plugins/org.jboss.tools.common.projecttemplates/src/org/jboss/tools/common/projecttemplates/ProjectTemplatesPlugin.java
trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/ResourceReference.java
trunk/common/plugins/org.jboss.tools.common.resref.ui/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Activator.java
trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/BaseAddReferenceSupport.java
trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Messages.java
trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/ResourceReferencesTableProvider.java
trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/messages.properties
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/ExtensionsPlugin.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/CSSClassHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassMethodHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/FilterNameHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkDetector.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerBuilder.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerDefinition.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkRegion.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JSPStylesheetRelLinkHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JumpToHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/RoleNameHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ServletNameHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/TLDAttributeNameHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/XModelBasedHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanSetPropertyHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPCSSClassHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPClassHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementAttributeValueHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPLinkHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRelativeLinkHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRootHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPStylesheetRelLinkHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeValueHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTextHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/TLDAttributeNameHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLClassHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeValueHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementNameHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLFilterNameHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLJumpToHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRoleNameHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRootHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLServletNameHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlinkPartitioner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/AbstractBaseHyperlink.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/HyperlinkDefinition.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/CSSTextScanner.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/TaglibManagerWrapper.java
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/Utils.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XMLTextViewerConfiguration.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XmlEditorPlugin.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/contentassist/ContentAssistProcessorDefinition.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/BasePreferenceConstants.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/XmlPreferenceConstants.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/xpl/ToggleOccurencesMarkUpAction.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/LabelFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/PreferenceConstants.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencePreferenceConstants.java
trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencesPreferencePage.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VRulesConfigurationAction.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VerifyAllAction.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/SignificanceView.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/VRuleTipFactory.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/ConfigRulesProvider.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/VRulesConfigurationWizardView.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/RuntimeRulesProvider.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VTaskListenerImpl.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VerifyWizardView.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VTaskListenerImpl.java
trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VerifyWizardView.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VHelper.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResult.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResultTemplate.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VTaskListenerImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VerifyBuilder.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyConfigurationHandler.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyHandler.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRuleSetHandler.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesAllHandler.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesHandler.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VManagerImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleSetImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VTaskImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VEntityImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VModelImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VObjectImpl.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/RuleSetResourceLoader.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VManagerModel.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultModel.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultTemplateModel.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleModel.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetModel.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetsLoader.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRulesTree.java
trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/plugin/VerificationPlugin.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3557 Externalize English strings (and add NON-NLS comments to others)
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/event/XModelTreeEvent.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/event/XModelTreeEvent.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/event/XModelTreeEvent.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -20,8 +20,8 @@
public static final int CHILD_REMOVED = 2;
public static final int STRUCTURE_CHANGED = 3;
- public static final String BEFORE_MERGE = "beforeMerge";
- public static final String AFTER_MERGE = "afterMerge";
+ public static final String BEFORE_MERGE = "beforeMerge"; //$NON-NLS-1$
+ public static final String AFTER_MERGE = "afterMerge"; //$NON-NLS-1$
private XModelObject object;
private Object info;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/FavoritesClassController.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/FavoritesClassController.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/FavoritesClassController.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
public class FavoritesClassController {
- private static final String FAVORITES_CLASSES_LIST = "JavaFavoritesFieldEditor.classes";
+ private static final String FAVORITES_CLASSES_LIST = "JavaFavoritesFieldEditor.classes"; //$NON-NLS-1$
private static final Image CLASS_ICON = JavaPluginImages.get(JavaPluginImages.IMG_OBJS_CLASS);
@@ -37,7 +37,7 @@
if ((classesList==null)||(classesList.length()==0)) {
classesList = Messages.FavoritesClassController_defaultClasses;
}
- StringTokenizer st = new StringTokenizer(classesList,",");
+ StringTokenizer st = new StringTokenizer(classesList,","); //$NON-NLS-1$
while (st.hasMoreTokens()) {
list.add(st.nextToken());
}
@@ -48,7 +48,7 @@
StringBuffer buffer = new StringBuffer();
Iterator i = list.iterator();
while (i.hasNext()) {
- buffer.append((String)i.next()).append(",");
+ buffer.append((String)i.next()).append(","); //$NON-NLS-1$
}
return buffer.toString();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/Messages.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/jdt/Messages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -14,7 +14,7 @@
public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.jboss.tools.common.core.jdt.messages";
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.core.jdt.messages"; //$NON-NLS-1$
public static String FavoritesClassController_defaultClasses;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInput.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInput.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInput.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -152,7 +152,7 @@
private void hackSetFile(IFile f) {
try {
- Field field = FileEditorInput.class.getDeclaredField("file");
+ Field field = FileEditorInput.class.getDeclaredField("file"); //$NON-NLS-1$
field.setAccessible(true);
field.set(this, f);
} catch (NoSuchFieldException e) {
@@ -231,9 +231,9 @@
public static String[] parseJarEntryFile(IStorage storage) {
if(storage == null) return null;
String s = storage.toString();
- if(!s.startsWith("JarEntryFile[")) return null;
- s = s.substring("JarEntryFile[".length());
- int i = s.indexOf("::");
+ if(!s.startsWith("JarEntryFile[")) return null; //$NON-NLS-1$
+ s = s.substring("JarEntryFile[".length()); //$NON-NLS-1$
+ int i = s.indexOf("::"); //$NON-NLS-1$
if(i < 0) return null;
String jarFile = s.substring(0, i);
String entry = storage.getFullPath().toString();
@@ -245,7 +245,7 @@
if(f == null) return null;
IProject p = f.getProject();
IModelNature n = EclipseResourceUtil.getModelNature(p);
- return (n == null) ? null : n.getModel().getByPath("/" + entry);
+ return (n == null) ? null : n.getModel().getByPath("/" + entry); //$NON-NLS-1$
}
public static IEditorInput createJarEntryEditorInput(String jarFile, final String entry) {
@@ -266,7 +266,7 @@
IFile f = getFile();
if(f == null || f.equals(super.getFile())) return;
try {
- Field field = FileEditorInput.class.getDeclaredField("file");
+ Field field = FileEditorInput.class.getDeclaredField("file"); //$NON-NLS-1$
field.setAccessible(true);
field.set(this, f);
} catch (NoSuchFieldException e) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInputFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInputFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/core/resources/XModelObjectEditorInputFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -28,11 +28,11 @@
public class XModelObjectEditorInputFactory implements IElementFactory {
private static final String ID_FACTORY =
- "org.jboss.tools.common.core.resources.XModelObjectEditorInputFactory";
- private static final String TAG_PATH = "path";
- private static final String TAG_PROJECT = "project";
- private static final String TAG_FILE_LOCATION = "filepath";
- private static final String TAG_ENTRY = "entry";
+ "org.jboss.tools.common.core.resources.XModelObjectEditorInputFactory"; //$NON-NLS-1$
+ private static final String TAG_PATH = "path"; //$NON-NLS-1$
+ private static final String TAG_PROJECT = "project"; //$NON-NLS-1$
+ private static final String TAG_FILE_LOCATION = "filepath"; //$NON-NLS-1$
+ private static final String TAG_ENTRY = "entry"; //$NON-NLS-1$
public IAdaptable createElement(IMemento memento) {
String projectPath = memento.getString(TAG_PROJECT);
@@ -55,7 +55,7 @@
private IAdaptable createStorageElement(IMemento memento) {
String projectPath = memento.getString(TAG_PROJECT);
XModelObject object = null;
- String missingName = "";
+ String missingName = ""; //$NON-NLS-1$
if(projectPath == null) {
String fileLocation = memento.getString(TAG_FILE_LOCATION);
if(fileLocation != null) {
@@ -76,7 +76,7 @@
String objectPath = memento.getString(TAG_PATH);
IModelNature nature = EclipseResourceUtil.getModelNature(project);
if(nature == null) {
- missingName = "" + objectPath;
+ missingName = "" + objectPath; //$NON-NLS-1$
} else {
XModel model = nature.getModel();
object = model.getByPath(objectPath);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/AbstractSectionEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/AbstractSectionEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/AbstractSectionEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -114,10 +114,10 @@
private void setErroneousObject(XModelObject object) {
if(object == null) return;
- String err = object.get("errors");
+ String err = object.get("errors"); //$NON-NLS-1$
if(err == null || err.length() == 0 && isWrongEntity(object.getModelEntity().getName()))
- err = "Warning: @ @0:0@" + "This editor is not intended for editing " + object.getAttributeValue("element type") + ". You can use source page, but its coloring may be inadequate.";
- if(err == null) err = "";
+ err = "Warning: @ @0:0@" + "This editor is not intended for editing " + object.getAttributeValue("element type") + ". You can use source page, but its coloring may be inadequate."; //$NON-NLS-3$
+ if(err == null) err = ""; //$NON-NLS-1$
errorMode.update(err);
}
@@ -140,7 +140,7 @@
public String getTitle() {
String s = super.getTitle();
- return s == null ? "" : s;
+ return s == null ? "" : s; //$NON-NLS-1$
}
public Image getTitleImage() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/DeleteFileUnderEditingSpecialWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/DeleteFileUnderEditingSpecialWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/DeleteFileUnderEditingSpecialWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -33,7 +33,7 @@
XModelObject eo = (XModelObject)editor.getEditorInput().getAdapter(XModelObject.class);
if(eo == null) continue;
String eop = eo.getPath();
- if(eop != null && (eop + "/").startsWith(path + "/")) {
+ if(eop != null && (eop + "/").startsWith(path + "/")) { //$NON-NLS-1$ //$NON-NLS-2$
if(!editor.isDirty()) {
workbenchPage.closeEditor(editor, false);
} else {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/EditorActionBarContributorWrapper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/EditorActionBarContributorWrapper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/EditorActionBarContributorWrapper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -59,7 +59,7 @@
}
IEditorActionBarContributor getContributor(String entity) {
- if(entity == null) entity = "";
+ if(entity == null) entity = ""; //$NON-NLS-1$
IEditorActionBarContributor c = (IEditorActionBarContributor)contributors.get(entity);
if(c == null) {
if(entity != null) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ErrorMode.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ErrorMode.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ErrorMode.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -24,7 +24,7 @@
private ScrolledComposite errors = null;
Composite c = null;
private ArrayList<Lbl> labels = new ArrayList<Lbl>();
- String es = "";
+ String es = ""; //$NON-NLS-1$
ErrorSelectionListener listener;
boolean visible = true;
@@ -59,7 +59,7 @@
if(!errors.isDisposed()) errors.dispose();
errors = null;
labels.clear();
- es = "";
+ es = ""; //$NON-NLS-1$
}
listener = null;
c = null;
@@ -87,11 +87,11 @@
}
public void update(XModelObject o) {
- update(o.get("errors"));
+ update(o.get("errors")); //$NON-NLS-1$
}
public void update(String err) {
String s = err;
- if(s == null) s = "";
+ if(s == null) s = ""; //$NON-NLS-1$
if(es.equals(s)) return;
createC();
labels.clear();
@@ -120,8 +120,8 @@
}
String[] getErrors(String s) {
- if(s == null) s = "";
- StringTokenizer st = new StringTokenizer(s, "\n");
+ if(s == null) s = ""; //$NON-NLS-1$
+ StringTokenizer st = new StringTokenizer(s, "\n"); //$NON-NLS-1$
String[] rs = new String[st.countTokens()];
for (int i = 0; i < rs.length; i++) rs[i] = st.nextToken();
return rs;
@@ -137,8 +137,8 @@
class Lbl {
private L label = null;
- private String error = "";
- private String[] messages = new String[]{"", "", ""};
+ private String error = ""; //$NON-NLS-1$
+ private String[] messages = new String[]{"", "", ""}; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
private int line = 1;
private int position = 1;
ErrorSelectionListener listener;
@@ -157,7 +157,7 @@
label.addMouseListener(new SL());
label.setData(messages);
}
- if(s == null) s = "";
+ if(s == null) s = ""; //$NON-NLS-1$
if(!error.equals(s)) parse(s);
}
@@ -179,11 +179,11 @@
}
} else {
messages[0] = "ERROR";
- messages[1] = "0:0";
+ messages[1] = "0:0"; //$NON-NLS-1$
messages[2] = s;
}
- if(messages[1] == null || "0:0".equals(messages[1])) {
- messages[1] = "";
+ if(messages[1] == null || "0:0".equals(messages[1])) { //$NON-NLS-1$
+ messages[1] = ""; //$NON-NLS-1$
}
}
@@ -216,7 +216,7 @@
class L extends Canvas implements PaintListener, MouseMoveListener {
Cursor DEF_CURSOR = new Cursor(null, SWT.CURSOR_ARROW);
Cursor HAND_CURSOR = new Cursor(null, SWT.CURSOR_HAND);
- private String[] messages = new String[]{"", "", ""};
+ private String[] messages = new String[]{"", "", ""}; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
public L(Composite parent, int style) {
super (parent, style);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -11,6 +11,7 @@
package org.jboss.tools.common.editor;
import java.io.*;
+import java.text.MessageFormat;
import java.util.*;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
@@ -82,7 +83,7 @@
protected XModelObjectSelectionProvider selectionProvider = new XModelObjectSelectionProvider();
protected NatureChecker natureChecker = new NatureChecker();
- private QualifiedName persistentTabQualifiedName = new QualifiedName("", "Selected_tab");
+ private QualifiedName persistentTabQualifiedName = new QualifiedName("", "Selected_tab"); //$NON-NLS-1$ //$NON-NLS-2$
int selectedPageIndex = 0;
public void init(IEditorSite site, IEditorInput input) throws PartInitException {
@@ -125,7 +126,7 @@
* have a supported nature.
*/
protected String getNatureWarningMessageKey() {
- return "SharableEditors.natureWarning.message";
+ return "SharableEditors.natureWarning.message"; //$NON-NLS-1$
}
private void updateFile() {
@@ -145,7 +146,7 @@
private void loadSelectedTab() {
IFile file = getFile();
try {
- if("yes".equals(PreferenceModelUtilities.getPreferenceModel().getByPath("%Options%/Struts Studio/Editors").getAttributeValue("selectSourceTab"))) {
+ if("yes".equals(PreferenceModelUtilities.getPreferenceModel().getByPath("%Options%/Struts Studio/Editors").getAttributeValue("selectSourceTab"))) { //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
selectedPageIndex = getSourcePageIndex();
} else if(file == null) {
loadSelectedTabForStorage();
@@ -163,7 +164,7 @@
private void loadSelectedTabForStorage() {
if(object == null) return;
String path = object.getPath();
- QualifiedName qn = new QualifiedName("", "Selected_tab_" + path);
+ QualifiedName qn = new QualifiedName("", "Selected_tab_" + path); //$NON-NLS-1$ //$NON-NLS-2$
IProject p = EclipseResourceUtil.getProject(object);
if(p == null || !p.isOpen()) return;
try {
@@ -184,7 +185,7 @@
saveSelectedTabForStorage();
} else {
try {
- if(file.isAccessible()) file.setPersistentProperty(persistentTabQualifiedName, "" + selectedPageIndex);
+ if(file.isAccessible()) file.setPersistentProperty(persistentTabQualifiedName, "" + selectedPageIndex); //$NON-NLS-1$
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
@@ -196,9 +197,9 @@
IProject p = EclipseResourceUtil.getProject(object);
if(p == null || !p.isOpen()) return;
String path = object.getPath();
- QualifiedName qn = new QualifiedName("", "Selected_tab_" + path);
+ QualifiedName qn = new QualifiedName("", "Selected_tab_" + path); //$NON-NLS-1$ //$NON-NLS-2$
try {
- p.setPersistentProperty(qn, "" + selectedPageIndex);
+ p.setPersistentProperty(qn, "" + selectedPageIndex); //$NON-NLS-1$
} catch (CoreException e) {
//ignore
}
@@ -315,7 +316,7 @@
treeEditor.addErrorSelectionListener(createErrorSelectionListener());
int index = addPage(control);
setPageText(index, "Tree");
- selectionProvider.addHost("treeEditor", treeEditor.getSelectionProvider());
+ selectionProvider.addHost("treeEditor", treeEditor.getSelectionProvider()); //$NON-NLS-1$
}
protected ObjectTextEditor createTextEditor() {
@@ -377,7 +378,7 @@
void saveX(IProgressMonitor monitor) {
if(!(textEditor instanceof AbstractTextEditor)) return;
try {
- Method m = AbstractTextEditor.class.getDeclaredMethod("performSave", new Class[]{boolean.class, IProgressMonitor.class});
+ Method m = AbstractTextEditor.class.getDeclaredMethod("performSave", new Class[]{boolean.class, IProgressMonitor.class}); //$NON-NLS-1$
m.setAccessible(true);
m.invoke(textEditor, new Object[]{Boolean.TRUE, monitor});
} catch (SecurityException e) {
@@ -399,7 +400,7 @@
public void gotoMarker(IMarker marker) {
if(marker == null || getModelObject() == null || !marker.exists()) return;
- String path = marker.getAttribute("path", null);
+ String path = marker.getAttribute("path", null); //$NON-NLS-1$
if(path != null) {
XModelObject o = getModelObject().getModel().getByPath(path);
if(o == null) return;
@@ -410,7 +411,7 @@
postponedTextSelection.clean();
if(textEditor != null) textEditor.gotoMarker(marker);
} else {
- String attr = marker.getAttribute("attribute", "");
+ String attr = marker.getAttribute("attribute", ""); //$NON-NLS-1$ //$NON-NLS-2$
if(attr == null || attr.length() == 0) {
postponedTextSelection.select(o, null);
} else {
@@ -463,7 +464,7 @@
XModelObject o = getModelObject();
if(o != null && o.isModified() && o.isActive()) {
try {
- XAction action = XActionInvoker.getAction("DiscardActions.Discard", object);
+ XAction action = XActionInvoker.getAction("DiscardActions.Discard", object); //$NON-NLS-1$
if(action != null) {
// to avoid confirmation
action.executeHandler(object, null);
@@ -552,7 +553,7 @@
protected void checkErrorMode() {
if(object == null) return;
- boolean i = isWrongEntity() || "yes".equals(object.get("isIncorrect"));
+ boolean i = isWrongEntity() || "yes".equals(object.get("isIncorrect")); //$NON-NLS-1$ //$NON-NLS-2$
if(isErrorMode == i) return;
isErrorMode = i;
}
@@ -871,7 +872,7 @@
if(f == null || !f.exists() || !f.isReadOnly()) return true;
String title= "Save problems";
String msg= " Cannot could not be completed.";
- IStatus status = new Status(Status.ERROR, ModelUIPlugin.PLUGIN_ID, Status.OK, "File " + f.getLocation().toString() + " is read-only.", new Exception());
+ IStatus status = new Status(Status.ERROR, ModelUIPlugin.PLUGIN_ID, Status.OK, MessageFormat.format("File {0} is read-only.", f.getLocation().toString()), new Exception());
ErrorDialog.openError(getSite().getShell(), title, msg, status);
return false;
}
@@ -881,7 +882,7 @@
protected TreeFormPage createTreeFormPage() {
treeFormPage = new TreeFormPage();
treeFormPage.setLabel("Tree");
- treeFormPage.setTitle("%TreeFormPage%");
+ treeFormPage.setTitle("%TreeFormPage%"); //$NON-NLS-1$
treeFormPage.addErrorSelectionListener(createErrorSelectionListener());
return treeFormPage;
}
@@ -890,7 +891,7 @@
try {
int index = addPage(formPage, getEditorInput());
setPageText(index, formPage.getLabel());
- selectionProvider.addHost("treeEditor", formPage.getSelectionProvider());
+ selectionProvider.addHost("treeEditor", formPage.getSelectionProvider()); //$NON-NLS-1$
//Activate key binding service here
formPage.getEditorSite().getKeyBindingService();
} catch (PartInitException ex) {
@@ -971,7 +972,7 @@
}
if(o == null) o = EclipseResourceUtil.createObjectForResource(file);
if(o != null) {
- XActionInvoker.invoke("Open", o, null);
+ XActionInvoker.invoke("Open", o, null); //$NON-NLS-1$
}
}
}
@@ -1225,7 +1226,7 @@
input = XModelObjectEditorInput.checkInput(input);
if(!(input instanceof IModelObjectEditorInput)) return false;
XModelObject o = ((IModelObjectEditorInput)input).getXModelObject();
- IProject project = (IProject)o.getModel().getProperties().get("project");
+ IProject project = (IProject)o.getModel().getProperties().get("project"); //$NON-NLS-1$
if(project == null) return false;
if(natures != null && natures.length == 0) return true;
IModelNature n = EclipseResourceUtil.getModelNature(project);
@@ -1238,7 +1239,7 @@
}
private void showWarning() throws XModelException {
- boolean isShowingWarning = "yes".equals(Preference.SHOW_NATURE_WARNING.getValue());
+ boolean isShowingWarning = "yes".equals(Preference.SHOW_NATURE_WARNING.getValue()); //$NON-NLS-1$
if(!isShowingWarning) return;
ServiceDialog d = PreferenceModelUtilities.getPreferenceModel().getService();
Properties p = new Properties();
@@ -1254,7 +1255,7 @@
}
String message = WizardKeys.getString(warningKey);
p.setProperty(ServiceDialog.DIALOG_MESSAGE, message);
- String box = WizardKeys.getString("SharableEditors.natureWarning.box.message");
+ String box = WizardKeys.getString("SharableEditors.natureWarning.box.message"); //$NON-NLS-1$
Option showOption = new Option(box);
int k = 0;
for (int i = 0; i < options.length; i++) {
@@ -1262,11 +1263,11 @@
}
if(showOption.register(p, k)) {
- p.setProperty(ServiceDialog.SEPARATOR + "_" + k, "true");
+ p.setProperty(ServiceDialog.SEPARATOR + "_" + k, "true"); //$NON-NLS-1$ //$NON-NLS-2$
++k;
}
- p.setProperty("title", "Warning");
+ p.setProperty("title", "Warning"); //$NON-NLS-1$
p.put(ServiceDialog.BUTTONS, new String[]{"OK"});
d.openConfirm(p);
for (int i = 0; i < options.length; i++) {
@@ -1291,21 +1292,21 @@
}
public void run() throws XModelException {
- Preference.SHOW_NATURE_WARNING.setValue("no");
+ Preference.SHOW_NATURE_WARNING.setValue("no"); //$NON-NLS-1$
}
}
class NatureOptionList {
//use extension point to avoid hardcode
static String[][] natureOptionDescriptions = new String[][]{
- {"org.jboss.tools.jsf.jsfnature",
+ {"org.jboss.tools.jsf.jsfnature", //$NON-NLS-1$
"JSF",
- "org.jboss.tools.jsf.ui",
- "org.jboss.tools.jsf.ui.action.AddJSFNatureActionDelegate"},
- {"org.jboss.tools.struts.strutsnature",
+ "org.jboss.tools.jsf.ui", //$NON-NLS-1$
+ "org.jboss.tools.jsf.ui.action.AddJSFNatureActionDelegate"}, //$NON-NLS-1$
+ {"org.jboss.tools.struts.strutsnature", //$NON-NLS-1$
"Struts",
- "org.jboss.tools.struts.ui",
- "org.jboss.tools.struts.ui.internal.action.AddStrutsNatureActionDelegate"
+ "org.jboss.tools.struts.ui", //$NON-NLS-1$
+ "org.jboss.tools.struts.ui.internal.action.AddStrutsNatureActionDelegate" //$NON-NLS-1$
},
};
static Map<String,String[]> natureOptionDescriptionsMap = new HashMap<String,String[]>();
@@ -1333,7 +1334,7 @@
IResource resource = null;
public NatureOption(String name, String plugin) {
- super("Add " + name + " Capabilities now");
+ super(MessageFormat.format("Add {0} Capabilities now", name));
this.plugin = plugin;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.editor;
+import java.text.MessageFormat;
import java.util.Properties;
import org.eclipse.ui.*;
import org.eclipse.ui.ide.IDE;
@@ -34,18 +35,18 @@
public int execute() {
try {
IEditorPart editor = null;
- XModelObject object = (XModelObject)p.get("object");
+ XModelObject object = (XModelObject)p.get("object"); //$NON-NLS-1$
IWorkbenchPage workbenchPage = getWorkbenchPage();
if(workbenchPage == null) return 0;
String id = object.getModelEntity().getEditorClassName();
- if(id != null && (id.length() == 0 || id.equals("DefaultEditor"))) {
+ if(id != null && (id.length() == 0 || id.equals("DefaultEditor"))) { //$NON-NLS-1$
id = null;
} else {
- boolean b = "yes".equals(PreferenceModelUtilities.getPreferenceModel().getByPath("%Options%/Struts Studio/Editors").getAttributeValue("useRedHatEditors"));
+ boolean b = "yes".equals(PreferenceModelUtilities.getPreferenceModel().getByPath("%Options%/Struts Studio/Editors").getAttributeValue("useRedHatEditors")); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
if(!b) id = null;
}
IModelObjectEditorInput input = XModelObjectEditorInput.createInstance(object);
- if(input == null) throw new IllegalStateException("Cannot find resource for object " + object.getPresentationString());
+ if(input == null) throw new IllegalStateException("Cannot find resource for object " + object.getPresentationString()); //$NON-NLS-1$
if(input instanceof IFileEditorInput) {
IFileEditorInput fei = (IFileEditorInput)input;
IFile f = fei.getFile();
@@ -59,13 +60,14 @@
if(f == null || !f.exists()) {
ServiceDialog d = object.getModel().getService();
Object pathData = f == null ? object.getPath() : f.getFullPath();
- String message = "The file " + pathData + " was removed externally.";
+ String message = MessageFormat.format(
+ "The file {0} was removed externally.", pathData);
d.showDialog("Warning", message, new String[]{"Close"}, null, ServiceDialog.WARNING);
object.getModel().update();
return 1;
}
}
- if("true".equals(p.getProperty("onlySelectIfOpen"))) {
+ if("true".equals(p.getProperty("onlySelectIfOpen"))) { //$NON-NLS-1$ //$NON-NLS-2$
editor = workbenchPage.findEditor(input);
if(editor != null) workbenchPage.bringToTop(editor);
} else if(id == null) {
@@ -77,16 +79,16 @@
} else {
editor = workbenchPage.openEditor(input, id);
}
- if(p != null && editor != null) p.put("editor", editor);
- if(p != null && "true".equals(p.get("toErrorTab")) && (editor instanceof ObjectMultiPageEditor)) {
+ if(p != null && editor != null) p.put("editor", editor); //$NON-NLS-1$
+ if(p != null && "true".equals(p.get("toErrorTab")) && (editor instanceof ObjectMultiPageEditor)) { //$NON-NLS-1$ //$NON-NLS-2$
ObjectMultiPageEditor m = (ObjectMultiPageEditor)editor;
m.activateErrorTab();
}
} catch (XModelException e) {
- p.put("exception", e);
+ p.put("exception", e); //$NON-NLS-1$
return 1;
} catch (PartInitException e) {
- p.put("exception", e);
+ p.put("exception", e); //$NON-NLS-1$
return 1;
}
return 0;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/TreeFormPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/TreeFormPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/TreeFormPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -177,7 +177,7 @@
XActionItem[] items = actionList.getActionItems();
for (int i=0;i<items.length;++i) {
if (items[i] instanceof XActionList) {
- printActionList(level+" ", (XActionList)items[i]);
+ printActionList(level+" ", (XActionList)items[i]); //$NON-NLS-1$
} else {
String actionItemName = items[i].getName();
String actionItemDisplayName = items[i].getDisplayName();
@@ -198,7 +198,7 @@
if(selection == xmo) return;
selection = xmo;
- if (xmo!=null && xmo.getModelEntity()!=null) printActionList("", xmo.getModelEntity().getActionList());
+ if (xmo!=null && xmo.getModelEntity()!=null) printActionList("", xmo.getModelEntity().getActionList()); //$NON-NLS-1$
IForm form = (xmo == null) ? null : getFormFactory(xmo).getForm();
// store form into memento
@@ -230,10 +230,10 @@
private IFormFactory getFormFactory(XModelObject selected) {
if(selected == null) return null;
XModelObjectFormFactory formFactory = null;
- String formFactoryClassName = selected.getModelEntity().getProperty("formFactory");
+ String formFactoryClassName = selected.getModelEntity().getProperty("formFactory"); //$NON-NLS-1$
if(formFactoryClassName != null) {
- if("%Default%".equals(formFactoryClassName)) {
+ if("%Default%".equals(formFactoryClassName)) { //$NON-NLS-1$
return new LayouredFormFactory(selected);
}
Class cls = ModelFeatureFactory.getInstance().getFeatureClass(formFactoryClassName);
@@ -272,8 +272,8 @@
class XMTL implements XModelTreeListener {
public void nodeChanged(XModelTreeEvent event) {
XModelObject o = event.getModelObject();
- String p1 = "" + installedObject.getPath() + "/";
- String p2 = "" + o.getPath() + "/";
+ String p1 = "" + installedObject.getPath() + "/"; //$NON-NLS-1$ //$NON-NLS-2$
+ String p2 = "" + o.getPath() + "/"; //$NON-NLS-1$ //$NON-NLS-2$
if(p2.startsWith(p1)) {
update();
}
@@ -281,8 +281,8 @@
public void structureChanged(XModelTreeEvent event) {
XModelObject o = event.getModelObject();
- String p1 = "" + installedObject.getPath() + "/";
- String p2 = "" + o.getPath() + "/";
+ String p1 = "" + installedObject.getPath() + "/"; //$NON-NLS-1$ //$NON-NLS-2$
+ String p2 = "" + o.getPath() + "/"; //$NON-NLS-1$ //$NON-NLS-2$
if(p2.startsWith(p1)) {
update();
}
@@ -317,7 +317,7 @@
f = f.getParent();
}
if(f == null) f = installedObject;
- return f.get("errors");
+ return f.get("errors"); //$NON-NLS-1$
}
public IDocumentProvider getDocumentProvider() {
@@ -382,7 +382,7 @@
this.site = site;
this.input = input;
if (input instanceof IFileEditorInput) {
- memento = new MementoDOM(ResourceLayoutManager.getDefault().getLayoutElement(getFile(), "TreeFormPage"));
+ memento = new MementoDOM(ResourceLayoutManager.getDefault().getLayoutElement(getFile(), "TreeFormPage")); //$NON-NLS-1$
}
}
@@ -460,7 +460,7 @@
public void doOperation(int operation) {
if (operation>actionMapping.size()) {
- ModelUIPlugin.getPluginLog().logError(new IllegalArgumentException("Can not find global action with index: "+operation));
+ ModelUIPlugin.getPluginLog().logError(new IllegalArgumentException("Can not find global action with index: "+operation)); //$NON-NLS-1$
} else {
String globalAction = (String)actionMapping.get(operation);
this.doGlobalAction(globalAction);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/XMLEditorLauncher.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/XMLEditorLauncher.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/XMLEditorLauncher.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,11 +32,11 @@
EditorPartWrapperExtension extension = EditorPartWrapperExtension.getInstance();
EditorPartFactory factory = extension.getFactory(entity);
String id = factory.getEditorId();
- if(id == null) id = "org.jboss.tools.common.text.xml.internal.ui.xmleditor.XmlEditor";
+ if(id == null) id = "org.jboss.tools.common.text.xml.internal.ui.xmleditor.XmlEditor"; //$NON-NLS-1$
new Thread(new LaunchThread(id, input)).start();
}
- static String DEFAULT_ENTITY = "xml";
+ static String DEFAULT_ENTITY = "xml"; //$NON-NLS-1$
private String computeEntity(IEditorInput input) {
if(!(input instanceof IModelObjectEditorInput)) return DEFAULT_ENTITY;
@@ -112,7 +112,7 @@
String l = resource.getLocation().toFile().getAbsolutePath();
if (!location.startsWith(l)) return null;
String relative = location.substring(l.length()).replace('\\', '/');
- StringTokenizer st = new StringTokenizer(relative, "/");
+ StringTokenizer st = new StringTokenizer(relative, "/"); //$NON-NLS-1$
while(st.hasMoreTokens()) {
String token = st.nextToken();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/DefaultChildrenForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/DefaultChildrenForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/DefaultChildrenForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -83,12 +83,12 @@
XModelObject o = helper.getModelObject(xtable.getSelectionIndex());
if(o == null) return;
XActionList l = (XActionList)o.getModelEntity().getActionList();
- if(l.getAction("Edit") != null) {
- callAction(o, "Edit");
- } else if(l.getAction("EditActions.Edit") != null) {
- callAction(o, "EditActions.Edit");
+ if(l.getAction("Edit") != null) { //$NON-NLS-1$
+ callAction(o, "Edit"); //$NON-NLS-1$
+ } else if(l.getAction("EditActions.Edit") != null) { //$NON-NLS-1$
+ callAction(o, "EditActions.Edit"); //$NON-NLS-1$
} else {
- callAction(o, "Properties.Properties");
+ callAction(o, "Properties.Properties"); //$NON-NLS-1$
}
}
@@ -99,10 +99,10 @@
protected String getAddActionPath() {
XModelObject o = helper.getModelObject();
- XActionList l = (XActionList)o.getModelEntity().getActionList().getItem("CreateActions");
+ XActionList l = (XActionList)o.getModelEntity().getActionList().getItem("CreateActions"); //$NON-NLS-1$
XActionItem[] is = l.getActionItems();
if(is.length != 1 || !(is[0] instanceof XAction)) return null;
- return "CreateActions" + "." + is[0].getName();
+ return "CreateActions" + "." + is[0].getName(); //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -117,7 +117,7 @@
ArrayList<String> l = new ArrayList<String>();
for (int i = 0; i < as.length; i++) {
if(!as[i].isVisible()) continue;
- if("element type".equals(as[i].getName())) continue;
+ if("element type".equals(as[i].getName())) continue; //$NON-NLS-1$
l.add(as[i].getName());
if(l.size() >= 4) break;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleChildForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleChildForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleChildForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -37,8 +37,8 @@
- private static final String FORM_DESCRIPTION = "SampleChildForm.description";
- private static final String FORM_HEADER = "SampleChildForm.header";
+ private static final String FORM_DESCRIPTION = "SampleChildForm.description"; //$NON-NLS-1$
+ private static final String FORM_HEADER = "SampleChildForm.header"; //$NON-NLS-1$
public SampleChildForm() {}
@@ -97,18 +97,18 @@
this.tableAdapter = new XChildrenTableStructuredAdapter();
//this.tableAdapter.setShownEntities(new String[] {"XXXXX"});
this.tableAdapter.getActionMapping().clear();
- this.tableAdapter.getActionMapping().put(TableStructuredEditor.ADD_ACTION,"CreateActions.CreateFilter");
- this.tableAdapter.getActionMapping().put(TableStructuredEditor.REMOVE_ACTION,"DeleteActions.Delete");
- this.tableAdapter.getActionMapping().put(TableStructuredEditor.EDIT_ACTION,"Properties.Properties");
- this.tableAdapter.getActionMapping().put(TableStructuredEditor.UP_ACTION,"%internal%");
- this.tableAdapter.getActionMapping().put(TableStructuredEditor.DOWN_ACTION,"%internal%");
- this.tableAdapter.setShownProperties(new String[] {"name"});
+ this.tableAdapter.getActionMapping().put(TableStructuredEditor.ADD_ACTION,"CreateActions.CreateFilter"); //$NON-NLS-1$
+ this.tableAdapter.getActionMapping().put(TableStructuredEditor.REMOVE_ACTION,"DeleteActions.Delete"); //$NON-NLS-1$
+ this.tableAdapter.getActionMapping().put(TableStructuredEditor.EDIT_ACTION,"Properties.Properties"); //$NON-NLS-1$
+ this.tableAdapter.getActionMapping().put(TableStructuredEditor.UP_ACTION,"%internal%"); //$NON-NLS-1$
+ this.tableAdapter.getActionMapping().put(TableStructuredEditor.DOWN_ACTION,"%internal%"); //$NON-NLS-1$
+ this.tableAdapter.setShownProperties(new String[] {"name"}); //$NON-NLS-1$
this.tableAdapter.setColumnLabels(new String[] {"Name"});
this.tableAdapter.setWidths(new int[] {100});
this.tableAdapter.setModelObject(xmo);
this.tableEditor = new TableStructuredEditor(settings);
- this.tableEditor.setLabelText("");
+ this.tableEditor.setLabelText(""); //$NON-NLS-1$
this.tableEditor.setInput(this.tableAdapter);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleErrorForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleErrorForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleErrorForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -87,7 +87,7 @@
public void initialize(Object model) {
String newErrors = (String)model;
- if (newErrors==null) newErrors = "";
+ if (newErrors==null) newErrors = ""; //$NON-NLS-1$
if (newErrors.equals(errorsString)) return;
this.errorsString = newErrors;
disposeLabels();
@@ -210,7 +210,7 @@
if(i < errors.length - 1) {
a = sb.length();
- sb.append("\n");
+ sb.append("\n"); //$NON-NLS-1$
region = new StyleRange(a, sb.length() - a, WHITE, null);
regionList.add(region);
}
@@ -230,7 +230,7 @@
int position = 0;
public StyleRange2(int start, int length, Color fg, Color bg, String location) {
super(start, length, fg, bg);
- int i = location.indexOf(":");
+ int i = location.indexOf(":"); //$NON-NLS-1$
line = i < 0 ? 0 : getInt(location.substring(0, i), 0);
position = i < 0 ? 0 : getInt(location.substring(i + 1), 0);
}
@@ -295,7 +295,7 @@
regions = new StyleRange[0];
if(styledText != null && !styledText.isDisposed()) {
styledText.setStyleRanges(regions);
- styledText.setText("");
+ styledText.setText(""); //$NON-NLS-1$
}
}
}
@@ -313,8 +313,8 @@
// error reader from slava
private String[] getErrorMessages(String s) {
- if(s == null) s = "";
- StringTokenizer st = new StringTokenizer(s, "\n");
+ if(s == null) s = ""; //$NON-NLS-1$
+ StringTokenizer st = new StringTokenizer(s, "\n"); //$NON-NLS-1$
String[] rs = new String[st.countTokens()];
for (int i = 0; i < rs.length; i++) rs[i] = st.nextToken();
return rs;
@@ -335,11 +335,11 @@
result[ERROR_MESSAGE] = s.substring(k + 1);
} else {
result[ERROR_TYPE] = "ERROR";
- result[ERROR_LOCATION] = "0:0";
+ result[ERROR_LOCATION] = "0:0"; //$NON-NLS-1$
result[ERROR_MESSAGE] = s;
}
- if(result[ERROR_LOCATION] == null || "0:0".equals(result[ERROR_LOCATION])) {
- result[ERROR_LOCATION] = "";
+ if(result[ERROR_LOCATION] == null || "0:0".equals(result[ERROR_LOCATION])) { //$NON-NLS-1$
+ result[ERROR_LOCATION] = ""; //$NON-NLS-1$
}
return result;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SamplePropertyForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SamplePropertyForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SamplePropertyForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -74,7 +74,7 @@
composite.setLayoutData(new GridData(GridData.FILL_BOTH));
}
- String elementType = xmo.getAttributeValue("element type");
+ String elementType = xmo.getAttributeValue("element type"); //$NON-NLS-1$
if(elementType != null) {
Label label = new Label(composite, SWT.NONE);
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
@@ -105,7 +105,7 @@
isGreedy = false;
XAttribute[] as = xmo.getModelEntity().getAttributes();
for (int i = 0; i < as.length && !isGreedy; i++) {
- if("always".equals(as[i].getProperty("greedy"))) isGreedy = true;
+ if("always".equals(as[i].getProperty("greedy"))) isGreedy = true; //$NON-NLS-1$ //$NON-NLS-2$
}
updateEnablement();
this.support.setAutoStore(Boolean.TRUE.booleanValue());
@@ -118,7 +118,7 @@
list.add(new String[]{xmo.getModelEntity().getName()});
XAttribute[] as = xmo.getModelEntity().getAttributes();
for (int i = 0; i < as.length; i++) {
- if("element type".equals(as[i].getName()) || !as[i].isVisible()) continue;
+ if("element type".equals(as[i].getName()) || !as[i].isVisible()) continue; //$NON-NLS-1$
list.add(new String[]{as[i].getName(), "no"});
}
String[][] ss = list.toArray(new String[0][]);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleTreeForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleTreeForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/form/SampleTreeForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -65,7 +65,7 @@
}
protected Control createClientArea(Composite parent, IWidgetSettings settings) {
- BorderedControl borderedControl = new BorderedControl(parent, SWT.NONE, settings.getBorder("Table.Border"));
+ BorderedControl borderedControl = new BorderedControl(parent, SWT.NONE, settings.getBorder("Table.Border")); //$NON-NLS-1$
borderedControl.setLayoutData(new GridData(GridData.FILL_BOTH));
Control treeControl = tree.createControl(borderedControl, SWT.H_SCROLL | SWT.V_SCROLL);
@@ -84,7 +84,7 @@
public void initialize(Object model) {
this.xmo = (XModelObject)model;
this.model = xmo.getModel();
- setHeadingText(this.xmo.getAttributeValue("name"));
+ setHeadingText(this.xmo.getAttributeValue("name")); //$NON-NLS-1$
for (int i = 0; i < filters.length; i++) tree.addFilter(filters[i]);
tree.setCache(new XModelObjectCache(xmo));
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Insets.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Insets.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Insets.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -41,13 +41,13 @@
public String toString() {
StringBuffer buffer = new StringBuffer();
- buffer.append("Insets: ");
+ buffer.append("Insets: "); //$NON-NLS-1$
buffer.append(top);
- buffer.append(", ");
+ buffer.append(", "); //$NON-NLS-1$
buffer.append(left);
- buffer.append(", ");
+ buffer.append(", "); //$NON-NLS-1$
buffer.append(bottom);
- buffer.append(", ");
+ buffer.append(", "); //$NON-NLS-1$
buffer.append(right);
return buffer.toString();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,28 +23,28 @@
// private static String PREFIX_ICON_DISABLED = "d";
// private static String PREFIX_ICON_HOVER = "h";
- private static String ACTIONS_PATH = "wizards/";
+ private static String ACTIONS_PATH = "wizards/"; //$NON-NLS-1$
- public static String ACT_CREATE_PROJECT = ACTIONS_PATH + "new_project.gif";
- public static String ACT_ADOPT_PROJECT = ACTIONS_PATH + "adopt_project.gif";
- public static String ACT_IMPORT_PROJECT = ACTIONS_PATH + "import_project.gif";
+ public static String ACT_CREATE_PROJECT = ACTIONS_PATH + "new_project.gif"; //$NON-NLS-1$
+ public static String ACT_ADOPT_PROJECT = ACTIONS_PATH + "adopt_project.gif"; //$NON-NLS-1$
+ public static String ACT_IMPORT_PROJECT = ACTIONS_PATH + "import_project.gif"; //$NON-NLS-1$
- public static String WIZARD_NEW_PROJECT = ACTIONS_PATH + "EclipseCreateNewProject.png";
- public static String WIZARD_DEFAULT = ACTIONS_PATH + "EclipseDefault.png";
- public static String WIZARD_IMPORT_PROJECT = ACTIONS_PATH + "EclipseImport.png";
- public static String WIZARD_MODULES_CONFIG = ACTIONS_PATH + "EclipseModulesConfiguration.gif";
+ public static String WIZARD_NEW_PROJECT = ACTIONS_PATH + "EclipseCreateNewProject.png"; //$NON-NLS-1$
+ public static String WIZARD_DEFAULT = ACTIONS_PATH + "EclipseDefault.png"; //$NON-NLS-1$
+ public static String WIZARD_IMPORT_PROJECT = ACTIONS_PATH + "EclipseImport.png"; //$NON-NLS-1$
+ public static String WIZARD_MODULES_CONFIG = ACTIONS_PATH + "EclipseModulesConfiguration.gif"; //$NON-NLS-1$
// JAVA
- public static String JAVA_CLASS = "java/class.gif";
- public static String JAVA_INTERFACE = "java/interface.gif";
- public static String JAVA_PACKAGE = "java/package.gif";
+ public static String JAVA_CLASS = "java/class.gif"; //$NON-NLS-1$
+ public static String JAVA_INTERFACE = "java/interface.gif"; //$NON-NLS-1$
+ public static String JAVA_PACKAGE = "java/package.gif"; //$NON-NLS-1$
// this blok staye witout changes for compatibility
private static ModelUIImages INSTANCE;
static {
try {
- INSTANCE = new ModelUIImages(new URL(ModelUIPlugin.getDefault().getBundle().getEntry("/"), "images/xstudio/"));
+ INSTANCE = new ModelUIImages(new URL(ModelUIPlugin.getDefault().getBundle().getEntry("/"), "images/xstudio/")); //$NON-NLS-1$ //$NON-NLS-2$
} catch (MalformedURLException e) {
// do nothing
ModelUIPlugin.getPluginLog().logError(e);
@@ -53,14 +53,14 @@
public static Image getImage(String key) {
if(ModelUIPlugin.isDebugEnabled()) {
- ModelUIPlugin.getPluginLog().logInfo("Create image for key '"+key+"'.");
+ ModelUIPlugin.getPluginLog().logInfo("Create image for key '"+key+"'."); //$NON-NLS-1$ //$NON-NLS-2$
}
return INSTANCE.createImageDescriptor(key).createImage();
}
public static ImageDescriptor getImageDescriptor(String key) {
if(ModelUIPlugin.isDebugEnabled()) {
- ModelUIPlugin.getPluginLog().logInfo("Create image descriptor for key '"+key+"'.");
+ ModelUIPlugin.getPluginLog().logInfo("Create image descriptor for key '"+key+"'."); //$NON-NLS-1$ //$NON-NLS-2$
}
return INSTANCE.createImageDescriptor(key);
}
@@ -80,12 +80,12 @@
protected ModelUIImages(URL registryUrl, ModelUIImages parent){
if(ModelUIPlugin.isDebugEnabled()) {
- ModelUIPlugin.getPluginLog().logInfo("Create ModelUIImages class.");
- ModelUIPlugin.getPluginLog().logInfo("RegistryUrl = " + registryUrl);
- ModelUIPlugin.getPluginLog().logInfo("parent = " + (parent==null?"null":parent.getClass().getName()));
+ ModelUIPlugin.getPluginLog().logInfo("Create ModelUIImages class."); //$NON-NLS-1$
+ ModelUIPlugin.getPluginLog().logInfo("RegistryUrl = " + registryUrl); //$NON-NLS-1$
+ ModelUIPlugin.getPluginLog().logInfo("parent = " + (parent==null?"null":parent.getClass().getName())); //$NON-NLS-1$ //$NON-NLS-2$
}
- if(registryUrl == null) throw new IllegalArgumentException("Base url for image registry cannot be null.");
+ if(registryUrl == null) throw new IllegalArgumentException("Base url for image registry cannot be null."); //$NON-NLS-1$
baseUrl = registryUrl;
parentRegistry = parent;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIPlugin.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIPlugin.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,14 +21,14 @@
import org.osgi.framework.BundleContext;
public class ModelUIPlugin extends BaseUIPlugin implements IModelPlugin {
- public static final String PLUGIN_ID = "org.jboss.tools.common.model.ui";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.model.ui"; //$NON-NLS-1$
private static ModelUIPlugin INSTANCE;
private ResourceBundle resourceBundle;
public ModelUIPlugin() {
INSTANCE = this;
try {
- resourceBundle= ResourceBundle.getBundle(PLUGIN_ID + ".PluginResources");
+ resourceBundle= ResourceBundle.getBundle(PLUGIN_ID + ".PluginResources"); //$NON-NLS-1$
}
catch (MissingResourceException x) {
resourceBundle = null;
@@ -65,10 +65,10 @@
}
- public static final String PROJECT_OVERRIDE = "org.jboss.tools.common.model.ui.templates.projectOverriveTemplates";
+ public static final String PROJECT_OVERRIDE = "org.jboss.tools.common.model.ui.templates.projectOverriveTemplates"; //$NON-NLS-1$
// public static final String PROJECT_CAN_OVERRIDE = "org.jboss.tools.common.model.ui.templates.projectCanOverriveTemplates";
- public static final String ID_PLUGIN= "org.jboss.tools.common.model.ui.templates";
- public static final String META_TEMPLATES_DTD = "-//Red Hat Inc.//DTD Meta Templates 1.0//EN";
+ public static final String ID_PLUGIN= "org.jboss.tools.common.model.ui.templates"; //$NON-NLS-1$
+ public static final String META_TEMPLATES_DTD = "-//Red Hat Inc.//DTD Meta Templates 1.0//EN"; //$NON-NLS-1$
public static String getPluginId() {
return ModelUIPlugin.ID_PLUGIN;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/AddNatureActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/AddNatureActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/AddNatureActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -89,19 +89,19 @@
}
protected String findWebXML(String root) {
- if(root == null) return "";
+ if(root == null) return ""; //$NON-NLS-1$
File rf = new File(root);
- if(!rf.isDirectory()) return "";
+ if(!rf.isDirectory()) return ""; //$NON-NLS-1$
List<File> folders = new ArrayList<File>();
folders.add(rf);
return findWebXML(folders);
}
protected String findWebXML(List<File> folders) {
- if(folders == null || folders.size() == 0) return "";
+ if(folders == null || folders.size() == 0) return ""; //$NON-NLS-1$
for (File f: folders) {
if(!f.isDirectory()) continue;
- String s = f.getAbsolutePath().replace('\\', '/') + "/WEB-INF/web.xml";
+ String s = f.getAbsolutePath().replace('\\', '/') + "/WEB-INF/web.xml"; //$NON-NLS-1$
if(new File(s).isFile()) return s;
}
List<File> nextLevelFolders = new ArrayList<File>();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,8 +21,8 @@
import org.jboss.tools.common.model.ui.widgets.IWidgetSettings;
public class CommandBar {
- public static final String SEPARATOR = "_SEPARATOR_";
- public static String FILL = " ";
+ public static final String SEPARATOR = "_SEPARATOR_"; //$NON-NLS-1$
+ public static String FILL = " "; //$NON-NLS-1$
CommandBarListener listener = null;
Composite control = null;
CommandBarLayout layout = new CommandBarLayout();
@@ -162,14 +162,14 @@
button = new ToolItem((ToolBar)parent, SWT.PUSH);
((ToolItem)button).addSelectionListener(this);
} else {
- int style = (settings == null) ? SWT.PUSH : settings.getStyle("Button.Style");
+ int style = (settings == null) ? SWT.PUSH : settings.getStyle("Button.Style"); //$NON-NLS-1$
if (style == SWT.DEFAULT) style = SWT.NONE;
if (style == 0) style = SWT.PUSH;
button = new Button(parent, style);
if(settings != null) {
- Color bg = settings.getColor("Button.Background");
- Color fg = settings.getColor("Button.Foreground");
- Font font = settings.getFont("Button.Font");
+ Color bg = settings.getColor("Button.Background"); //$NON-NLS-1$
+ Color fg = settings.getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = settings.getFont("Button.Font"); //$NON-NLS-1$
((Control)button).setBackground(bg);
((Control)button).setForeground(fg);
((Control)button).setFont(font);
@@ -221,10 +221,10 @@
if(layout.iconsOnly) {
if (layout.asToolBar) {
((ToolItem)button).setToolTipText(getText(false));
- ((ToolItem)button).setText("");
+ ((ToolItem)button).setText(""); //$NON-NLS-1$
} else {
((Button)button).setToolTipText(getText(false));
- ((Button)button).setText("");
+ ((Button)button).setText(""); //$NON-NLS-1$
}
if(image != null) {
if (layout.asToolBar) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/SaveModelActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/SaveModelActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/SaveModelActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -90,8 +90,8 @@
if(this.model != null) {
RootImpl r = (RootImpl)this.model.getRoot();
r.addModifyListener(monitor);
- XModelObject fs = model.getByPath("FileSystems");
- String fsn = (fs == null) ? "" : " " + fs.getPresentationString();
+ XModelObject fs = model.getByPath("FileSystems"); //$NON-NLS-1$
+ String fsn = (fs == null) ? "" : " " + fs.getPresentationString(); //$NON-NLS-1$ //$NON-NLS-2$
action.setToolTipText("Save Struts Project" + fsn);
} else {
action.setToolTipText("Save Struts Project");
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvoker.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvoker.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvoker.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -64,8 +64,8 @@
if(e.button == 1) {
XModelObject o = getSelectedModelObject();
if(o == null) return;
- if("true".equals(o.get("overlapped"))) {
- XActionInvoker.invoke("Open", o, new Properties());
+ if("true".equals(o.get("overlapped"))) { //$NON-NLS-1$ //$NON-NLS-2$
+ XActionInvoker.invoke("Open", o, new Properties()); //$NON-NLS-1$
}
}
}
@@ -100,13 +100,13 @@
protected void processKey(KeyEvent e) {
if(((e.stateMask & SWT.CTRL) != 0) && e.keyCode == (int)'c') {
- invoke("CopyActions.Copy");
+ invoke("CopyActions.Copy"); //$NON-NLS-1$
} else if(((e.stateMask & SWT.CTRL) != 0) && e.keyCode == (int)'x') {
- invoke("CopyActions.Cut");
+ invoke("CopyActions.Cut"); //$NON-NLS-1$
} else if(((e.stateMask & SWT.CTRL) != 0) && e.keyCode == (int)'v') {
- invoke("CopyActions.Paste");
+ invoke("CopyActions.Paste"); //$NON-NLS-1$
} else if((e.stateMask == 0) && e.character == SWT.DEL) {
- invoke("DeleteActions.Delete");
+ invoke("DeleteActions.Delete"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvokerWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvokerWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XMenuInvokerWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,9 +23,9 @@
public void setObject(Object object) {
Properties p = (Properties)object;
- this.object = (XModelObject)p.get("object");
- list = (XActionList)p.get("actionList");
- control = (Control)p.get("control");
+ this.object = (XModelObject)p.get("object"); //$NON-NLS-1$
+ list = (XActionList)p.get("actionList"); //$NON-NLS-1$
+ control = (Control)p.get("control"); //$NON-NLS-1$
if(control == null) {
control = ModelPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -75,6 +75,7 @@
runObject = redirectObject;
}
if (action.getSignificantFlag(object)) {
+ // i18n: can't construct sentences by concatenation
String message = SignificanceMessageFactory.getInstance()
.getMessage(action, object, targets)
+ "?";
@@ -86,12 +87,12 @@
return;
}
String wizardName = runAction.getWizardClassName();
- if (wizardName == null || wizardName.equals("")) {
+ if (wizardName == null || wizardName.equals("")) { //$NON-NLS-1$
action.getEntityData(object);
try {
Properties p = prepareProperties();
if (p == null) p = new Properties();
- if (getShell() != null) p.put("shell", getShell());
+ if (getShell() != null) p.put("shell", getShell()); //$NON-NLS-1$
if (targets == null) action.executeHandler(object, p);
else action.executeHandler(object, targets, p);
} catch (ActionDeclinedException e) {
@@ -105,10 +106,10 @@
Properties p = prepareProperties();
if (p == null)
p = new Properties();
- p.put("action", runAction);
- p.put("object", runObject);
+ p.put("action", runAction); //$NON-NLS-1$
+ p.put("object", runObject); //$NON-NLS-1$
if (getShell() != null)
- p.put("shell", getShell());
+ p.put("shell", getShell()); //$NON-NLS-1$
w.setObject(p);
w.execute();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionInvoker.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionInvoker.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionInvoker.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,7 +32,7 @@
Properties p = (Properties)os[2];
XModelObject[] targets = (os.length < 4) ? null : (XModelObject[])os[3];
XModelObjectAction mo = new XModelObjectAction(action, o, targets, new Object[]{p});
- if(p != null && p.get("shell") != null) mo.setShell((Shell)p.get("shell"));
+ if(p != null && p.get("shell") != null) mo.setShell((Shell)p.get("shell")); //$NON-NLS-1$ //$NON-NLS-2$
mo.actionPerformed();
return 0;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionList.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionList.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/XModelObjectActionList.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -77,7 +77,7 @@
a.createMenuItem(menu);
} else {
XActionList l = (XActionList)is[i];
- if ("OpenWith".equals(l.getName())) {
+ if ("OpenWith".equals(l.getName())) { //$NON-NLS-1$
if (object.getFileType() == XFileObject.FILE && (targets == null || targets.length < 2)) {
IResource resource = EclipseResourceUtil.getResource(object);
if (resource != null && resource.getType() == IResource.FILE) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/HelpActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/HelpActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/HelpActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -14,6 +14,6 @@
public class HelpActionDelegate extends ModelResourceActionDelegate {
protected String getActionPath() {
- return "Help";
+ return "Help"; //$NON-NLS-1$
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/RemoveModelNatureActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/RemoveModelNatureActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/file/RemoveModelNatureActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,12 +17,12 @@
public class RemoveModelNatureActionDelegate extends ProjectRootActionDelegate {
protected String getActionPath() {
- return "EclipseActions.RemoveModelNature";
+ return "EclipseActions.RemoveModelNature"; //$NON-NLS-1$
}
protected void initProperties(Properties p) {
String nature = getModelNatureName();
- if(nature != null) p.setProperty("nature", nature);
+ if(nature != null) p.setProperty("nature", nature); //$NON-NLS-1$
}
protected boolean hasModelNature(IProject project) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyActionFilter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyActionFilter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyActionFilter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -15,8 +15,8 @@
import org.jboss.tools.common.model.XModelObject;
public class VerifyActionFilter implements IModelObjectActionFilter {
- static String path1 = "VerifyActions.StaticActions.VerifyAll";
- static String path2 = "ProcessVerifyActions.StaticActions.VerifyAll";
+ static String path1 = "VerifyActions.StaticActions.VerifyAll"; //$NON-NLS-1$
+ static String path2 = "ProcessVerifyActions.StaticActions.VerifyAll"; //$NON-NLS-1$
public boolean isEnabled(XModelObject object, String info) {
return (object != null) && (DnDUtil.getEnabledAction(object, null, getActionPath(object)) != null);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyAllActionFilter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyAllActionFilter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/filter/VerifyAllActionFilter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -14,7 +14,7 @@
public class VerifyAllActionFilter extends VerifyActionFilter {
public boolean isEnabled(XModelObject object, String info) {
- if(object != null) object = object.getModel().getByPath("FileSystems");
+ if(object != null) object = object.getModel().getByPath("FileSystems"); //$NON-NLS-1$
return super.isEnabled(object, info);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/AbstractShowUrlActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/AbstractShowUrlActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/AbstractShowUrlActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -12,6 +12,7 @@
import java.net.MalformedURLException;
import java.net.URL;
+import java.text.MessageFormat;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.ui.IWorkbenchWindow;
@@ -43,14 +44,14 @@
public static void runURL(String url) {
if(url == null || url.length() == 0) return;
- if(!url.startsWith("http://")) url = "http://" + url;
+ if(!url.startsWith("http://")) url = "http://" + url; //$NON-NLS-1$ //$NON-NLS-2$
try {
IWorkbenchBrowserSupport browserSupport = ModelUIPlugin.getDefault().getWorkbench().getBrowserSupport();
IWebBrowser browser = browserSupport.createBrowser(IWorkbenchBrowserSupport.LOCATION_BAR | IWorkbenchBrowserSupport.NAVIGATION_BAR | IWorkbenchBrowserSupport.AS_EXTERNAL, null, null, null);
browser.openURL(new URL(url));
} catch (MalformedURLException mue) {
ServiceDialog d = PreferenceModelUtilities.getPreferenceModel().getService();
- d.showDialog("Error", "Incorrect URL: " + mue.getMessage() + ".", new String[]{"OK"}, null, ServiceDialog.ERROR);
+ d.showDialog("Error", MessageFormat.format("Incorrect URL: {0}.", mue.getMessage()), new String[]{"OK"}, null, ServiceDialog.ERROR);
} catch (PartInitException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/ReportProblemActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/ReportProblemActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/ReportProblemActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
ReportProblemWizard wizard = new ReportProblemWizard();
Properties p = new Properties();
- p.setProperty(ReportProblemWizard.Property.HELP, "ReportProblemWizard");
+ p.setProperty(ReportProblemWizard.Property.HELP, "ReportProblemWizard"); //$NON-NLS-1$
wizard.setObject(p);
wizard.execute();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitCompanyActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitCompanyActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitCompanyActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -13,7 +13,7 @@
public class VisitCompanyActionDelegate extends AbstractShowUrlActionDelegate {
protected String getUrl() {
- return "www.redhat.com";
+ return "www.redhat.com"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitForumActionDelegate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitForumActionDelegate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/global/VisitForumActionDelegate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -13,7 +13,7 @@
public class VisitForumActionDelegate extends AbstractShowUrlActionDelegate {
protected String getUrl() {
- return "http://www.jboss.com/index.html?module=bb&op=viewforum&f=258";
+ return "http://www.jboss.com/index.html?module=bb&op=viewforum&f=258"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/sample/XActionWrapper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/sample/XActionWrapper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/sample/XActionWrapper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -49,7 +49,7 @@
public void run() {
if (xmo == null || path == null) return;
Properties p = new Properties();
- p.setProperty("actionSourceGUIComponentID", "editor");
+ p.setProperty("actionSourceGUIComponentID", "editor"); //$NON-NLS-1$ //$NON-NLS-2$
initRunningProperties(p);
XActionInvoker.invoke(path, xmo, null, p);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/AttributeContentProposalProviderFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/AttributeContentProposalProviderFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/AttributeContentProposalProviderFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -53,7 +53,7 @@
KeyStroke ks = null;
try {
- ks = KeyStroke.getInstance("Ctrl+Space");
+ ks = KeyStroke.getInstance("Ctrl+Space"); //$NON-NLS-1$
} catch (ParseException e) {
//Cannot happen, this code is safe.
ModelUIPlugin.getPluginLog().logError(e);
@@ -147,7 +147,7 @@
}
}
- static String POINT_ID = ModelUIPlugin.PLUGIN_ID + ".attributeContentProposalProviders";
+ static String POINT_ID = ModelUIPlugin.PLUGIN_ID + ".attributeContentProposalProviders"; //$NON-NLS-1$
public List<IAttributeContentProposalProvider> getContentProposalProviders(XModelObject object, XAttribute attribute) {
List<IAttributeContentProposalProvider> result = EMPTY;
@@ -160,7 +160,7 @@
for (int j = 0; j < cs.length; j++) {
IAttributeContentProposalProvider provider = null;
try {
- Object o = cs[j].createExecutableExtension("class");
+ Object o = cs[j].createExecutableExtension("class"); //$NON-NLS-1$
provider = (IAttributeContentProposalProvider)o;
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/WizardDataPropertySource.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/WizardDataPropertySource.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/WizardDataPropertySource.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -45,8 +45,8 @@
// String value = properties.get(key).toString();
// }
- action = (XAction)properties.get("action");
- object = (XModelObject)properties.get("object");
+ action = (XAction)properties.get("action"); //$NON-NLS-1$
+ object = (XModelObject)properties.get("object"); //$NON-NLS-1$
data = action.getEntityData(this.object)[0];
attributeData = data.getAttributeData();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributePropertyDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributePropertyDescription.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributePropertyDescription.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -66,7 +66,7 @@
editor.setValidator(new ICellEditorValidator() {
public String isValid(Object value) {
if(modelObject == null) return null;
- String error = ((XModelImpl)modelObject.getModel()).getError(modelObject, attribute.getName(), value == null ? "" : value.toString());
+ String error = ((XModelImpl)modelObject.getModel()).getError(modelObject, attribute.getName(), value == null ? "" : value.toString()); //$NON-NLS-1$
return error;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributeSupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributeSupport.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XAttributeSupport.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -76,7 +76,7 @@
}
public XAttributeSupport(XModelObject xmo) {
- if(xmo==null) throw new IllegalArgumentException("XModelObject cannot be null.");
+ if(xmo==null) throw new IllegalArgumentException("XModelObject cannot be null."); //$NON-NLS-1$
init(xmo);
}
@@ -85,7 +85,7 @@
}
public XAttributeSupport(XModelObject xmo, XEntityData data, boolean useObject) {
- if(data==null) throw new IllegalArgumentException("XEntityData cannot be null.");
+ if(data==null) throw new IllegalArgumentException("XEntityData cannot be null."); //$NON-NLS-1$
init(xmo, data, useObject);
}
@@ -110,7 +110,7 @@
PropertyEditor editor = createEditor(adapter, xmo, attribute[i]);
adapters.add(adapter);
editors.add(editor);
- if("always".equals(attribute[i].getProperty("greedy"))) {
+ if("always".equals(attribute[i].getProperty("greedy"))) { //$NON-NLS-1$ //$NON-NLS-2$
alwaysGreedy.add(attribute[i].getName());
}
}
@@ -131,14 +131,14 @@
PropertyEditor editor = (useObject) ? createEditor(adapter, xmo, attr) : createEditor(adapter, xmo, ads[i]);
String labelText = WizardKeys.getAttributeDisplayName(ads[i]);
if (labelText!=null) {
- labelText = labelText + ((ads[i].getMandatoryFlag()) ? "*" : "");
+ labelText = labelText + ((ads[i].getMandatoryFlag()) ? "*" : ""); //$NON-NLS-1$ //$NON-NLS-2$
editor.setLabelText(labelText);
}
adapters.add(adapter);
editors.add(editor);
- if("always".equals(attr.getProperty("greedy"))) {
+ if("always".equals(attr.getProperty("greedy"))) { //$NON-NLS-1$ //$NON-NLS-2$
alwaysGreedy.add(attr.getName());
}
}
@@ -225,7 +225,7 @@
}
Control[] controls = fillComposite(composite, fieldEditor, greedy);
if(fieldEditor instanceof StringButtonFieldEditorEx) {
- ((StringButtonFieldEditorEx)fieldEditor).setStringValue("" + editor.getValue());
+ ((StringButtonFieldEditorEx)fieldEditor).setStringValue("" + editor.getValue()); //$NON-NLS-1$
}
return controls;
}
@@ -309,7 +309,7 @@
}
fillComposite(composite, fieldEditor, greedy);
if(fieldEditor instanceof StringButtonFieldEditorEx) {
- ((StringButtonFieldEditorEx)fieldEditor).setStringValue("" + editor.getValue());
+ ((StringButtonFieldEditorEx)fieldEditor).setStringValue("" + editor.getValue()); //$NON-NLS-1$
}
}
}
@@ -354,7 +354,7 @@
}
fillComposite(composite, fieldEditor, greedy);
if(fieldEditor instanceof StringButtonFieldEditorEx) {
- ((StringButtonFieldEditorEx)fieldEditor).setStringValue("" + editor.getValue());
+ ((StringButtonFieldEditorEx)fieldEditor).setStringValue("" + editor.getValue()); //$NON-NLS-1$
}
}
return composite;
@@ -371,16 +371,16 @@
}
public void load() {
- if(xmo == null) throw new IllegalArgumentException("" +
- "Init support with XModelObject before saving");
+ if(xmo == null) throw new IllegalArgumentException("" + //$NON-NLS-1$
+ "Init support with XModelObject before saving"); //$NON-NLS-1$
for (int i = 0; i < editors.size(); i++)
((IModelPropertyEditorAdapter)adapters.get(i)).load();
}
public void save() {
- if(xmo == null) throw new IllegalArgumentException("" +
- "Init support with XModelObject before saving");
- if(xmo.getModel()==null) throw new IllegalArgumentException("Cannot store deleted or removed XModel object");
+ if(xmo == null) throw new IllegalArgumentException("" + //$NON-NLS-1$
+ "Init support with XModelObject before saving"); //$NON-NLS-1$
+ if(xmo.getModel()==null) throw new IllegalArgumentException("Cannot store deleted or removed XModel object"); //$NON-NLS-1$
xmo.getModel().saveOptions();
}
@@ -406,7 +406,7 @@
public IPropertyEditor getPropertyEditorByName(String attributeName) {
IPropertyEditor result = null;
- if (attributeName != null && !"".equals(attributeName)) {
+ if (attributeName != null && !"".equals(attributeName)) { //$NON-NLS-1$
Iterator iterator = editors.iterator();
while (iterator.hasNext() && result == null) {
IPropertyEditor editor = (IPropertyEditor)iterator.next();
@@ -427,7 +427,7 @@
public IModelPropertyEditorAdapter getPropertyEditorAdapterByName(String attributeName) {
IModelPropertyEditorAdapter result = null;
- if (attributeName != null && !"".equals(attributeName)) {
+ if (attributeName != null && !"".equals(attributeName)) { //$NON-NLS-1$
Iterator iterator = adapters.iterator();
while (iterator.hasNext() && result == null) {
IModelPropertyEditorAdapter adapter = (IModelPropertyEditorAdapter)iterator.next();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XModelObjectPropertySource.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XModelObjectPropertySource.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/XModelObjectPropertySource.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -55,7 +55,7 @@
if(a != null && v != null && a.getConstraint() instanceof XAttributeConstraintAList) {
v = WizardKeys.getVisualListValue(a, v);
}
- cachedValues.setProperty(n, "" + v);
+ cachedValues.setProperty(n, "" + v); //$NON-NLS-1$
return v;
}
@@ -89,7 +89,7 @@
String n = getAttributeNameById(id);
String v = cachedValues.getProperty(n);
if(value.equals(v)) return;
- cachedValues.setProperty(n, "" + value);
+ cachedValues.setProperty(n, "" + value); //$NON-NLS-1$
value = fromVisualToModel(n, value.toString());
if(modelObject.isActive()) {
try {
@@ -121,15 +121,15 @@
XAttribute[] attrs = modelObject.getModelEntity().getAttributes();
propertyDescriptors = new ArrayList<IPropertyDescriptor>();
for (int i=0;i<attrs.length;++i) {
- if (attrs[i].isVisible() && !"element type".equals(attrs[i].getName())) {
+ if (attrs[i].isVisible() && !"element type".equals(attrs[i].getName())) { //$NON-NLS-1$
//propertyDescriptors.add(new TextPropertyDescriptor(attrs[i].getName(),attrs[i].getName()));
propertyDescriptors.add(new XAttributePropertyDescription(this, attrs[i], modelObject));
}
}
XModel model = modelObject.getModel();
- if(model.getManager("propertySheetUpdate") == null) {
+ if(model.getManager("propertySheetUpdate") == null) { //$NON-NLS-1$
model.addModelTreeListener(listener);
- model.addManager("propertySheetUpdate", listener);
+ model.addManager("propertySheetUpdate", listener); //$NON-NLS-1$
}
}
@@ -142,7 +142,7 @@
if(modelObject == null || modelObject != event.getModelObject()) return;
PropertySheet sh = null;
try {
- sh = (PropertySheet)PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().findView("org.eclipse.ui.views.PropertySheet");
+ sh = (PropertySheet)PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().findView("org.eclipse.ui.views.PropertySheet"); //$NON-NLS-1$
} catch (NullPointerException exc) {
//ignore
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ActiveValueAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ActiveValueAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ActiveValueAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -29,10 +29,10 @@
public void setAttribute(XAttribute attribute) {
super.setAttribute(attribute);
support = (SpecialWizardSupport)attribute.getEditor().getContext();
- qActionName = "...:" + attribute.getName();
+ qActionName = "...:" + attribute.getName(); //$NON-NLS-1$
Properties p = support.getProperties();
String comd = (p == null) ? null : p.getProperty(qActionName);
- if(comd == null) comd = "...";
+ if(comd == null) comd = "..."; //$NON-NLS-1$
if(!comd.equals(command)) command = comd;
}
@@ -43,7 +43,7 @@
public String invoke(Control control) {
support.fireCommand(qActionName);
load();
- return "" + getValue();
+ return "" + getValue(); //$NON-NLS-1$
}
public Object getAdapter(Class adapter) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/AdapterFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/AdapterFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/AdapterFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -24,7 +24,7 @@
import org.jboss.tools.common.model.ui.ModelUIPlugin;
public class AdapterFactory {
- public static final String ATTRIBUTE_ADAPTER_EXT_POINT = "org.jboss.tools.common.model.ui.attributeAdapter";
+ public static final String ATTRIBUTE_ADAPTER_EXT_POINT = "org.jboss.tools.common.model.ui.attributeAdapter"; //$NON-NLS-1$
private static Map<String,Class> classes = new HashMap<String,Class>();
public AdapterFactory() {}
@@ -34,7 +34,7 @@
}
public static IModelPropertyEditorAdapter getAdapter(XAttribute attribute, XAttributeData attributeData, XModel model) {
- Assert.isTrue(model != null, "AdapterFactory.getAdapter(XAttribute, XAttributeData, XModel) model cannot be null!");
+ Assert.isTrue(model != null, "AdapterFactory.getAdapter(XAttribute, XAttributeData, XModel) model cannot be null!"); //$NON-NLS-1$
return getAdapter(attribute, null, attributeData, model);
}
@@ -68,7 +68,7 @@
c = ExtensionPointUtil.findClassByElementId(ATTRIBUTE_ADAPTER_EXT_POINT, id).getClass();
} catch (CoreException e) {
if(ModelUIPlugin.getDefault().isDebugging()) {
- ModelUIPlugin.getPluginLog().logInfo("Default adapter for " + id);
+ ModelUIPlugin.getPluginLog().logInfo("Default adapter for " + id); //$NON-NLS-1$
}
c = DefaultValueAdapter.class;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckListAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckListAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckListAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,8 +22,8 @@
import org.jboss.tools.common.model.util.EclipseResourceUtil;
public class CheckListAdapter extends DefaultValueAdapter {
- public Image IMAGE_ENABLED = EclipseResourceUtil.getImage("images/common/check.gif");
- public Image IMAGE_DISABLED = EclipseResourceUtil.getImage("images/common/uncheck.gif");
+ public Image IMAGE_ENABLED = EclipseResourceUtil.getImage("images/common/check.gif"); //$NON-NLS-1$
+ public Image IMAGE_DISABLED = EclipseResourceUtil.getImage("images/common/uncheck.gif"); //$NON-NLS-1$
protected ILabelProvider labelProvider;
protected ITreeContentProvider treeContentProvider;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckTreeAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckTreeAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/CheckTreeAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,9 +36,9 @@
protected ISelectionChangedListener selectionChangedListener;
- private Image IMAGE_CHECK = EclipseResourceUtil.getImage("images/common/check.gif");
- private Image IMAGE_UNCHECK = EclipseResourceUtil.getImage("images/common/uncheck.gif");
- private Image IMAGE_HALFCHECK = EclipseResourceUtil.getImage("images/common/halfcheck.gif");
+ private Image IMAGE_CHECK = EclipseResourceUtil.getImage("images/common/check.gif"); //$NON-NLS-1$
+ private Image IMAGE_UNCHECK = EclipseResourceUtil.getImage("images/common/uncheck.gif"); //$NON-NLS-1$
+ private Image IMAGE_HALFCHECK = EclipseResourceUtil.getImage("images/common/halfcheck.gif"); //$NON-NLS-1$
public class CheckTree implements ICheckable {
private ArrayList<ICheckStateListener> listeners = new ArrayList<ICheckStateListener>();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultComboBoxValueAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultComboBoxValueAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultComboBoxValueAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -63,7 +63,7 @@
}
return this.listContentProvider;
}
- Assert.isTrue(true, "DefaultValueAdapter instance itself cannot provide adapter for "+adapter.getName());
+ Assert.isTrue(true, "DefaultValueAdapter instance itself cannot provide adapter for "+adapter.getName()); //$NON-NLS-1$
return null;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -42,8 +42,8 @@
public class DefaultTreeSelectionAdapter extends DefaultValueAdapter implements IAdaptable, ISelectionProvider, ISelectionChangedListener {
- private static final String STRING_BUTTON_ACTION = "Label.Selected";
- private static final String STRING_BUTTON_XACTION = "linkAction";
+ private static final String STRING_BUTTON_ACTION = "Label.Selected"; //$NON-NLS-1$
+ private static final String STRING_BUTTON_XACTION = "linkAction"; //$NON-NLS-1$
protected ILabelProvider labelProvider;
protected ITreeContentProvider treeContentProvider;
@@ -100,7 +100,7 @@
}
}
- Assert.isTrue(true, "DefaultTreeSelectionAdapter instance itself cannot provide adapter for "+adapter.getName());
+ Assert.isTrue(true, "DefaultTreeSelectionAdapter instance itself cannot provide adapter for "+adapter.getName()); //$NON-NLS-1$
return null;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProcessor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProcessor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProcessor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -64,7 +64,7 @@
int replacementLength = text.length();
int cursorPosition = replacementString.length();
if(text.startsWith(replacementString)) {
- replacementString = "";
+ replacementString = ""; //$NON-NLS-1$
replacementLength = 0;
}
CustomCompletionProposal proposal = new CustomCompletionProposal(
@@ -86,7 +86,7 @@
String value = tree.getValue(object);
if(value != null && value.startsWith(startText)) {
if(value.length() > 0) {
- if(value.equals(startText) && value.endsWith("/")) {
+ if(value.equals(startText) && value.endsWith("/")) { //$NON-NLS-1$
//skip this value
} else {
map.put(value, EclipseResourceUtil.getImage(object));
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultTreeSelectionContentAssistProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
return false;
}
String editor = attribute.getEditor().getName();
- return editor != null && editor.startsWith("Tree");
+ return editor != null && editor.startsWith("Tree"); //$NON-NLS-1$
}
void addAttributeValueProposals(List<IContentProposal> proposalsList, String text, int offset) {
@@ -75,7 +75,7 @@
String value = tree.getValue(object);
if(value != null && value.startsWith(startText)) {
if(value.length() > 0) {
- if(value.equals(startText) && value.endsWith("/")) {
+ if(value.equals(startText) && value.endsWith("/")) { //$NON-NLS-1$
//skip this value
} else {
map.put(value, EclipseResourceUtil.getImage(object));
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultValueAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultValueAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultValueAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,7 +30,7 @@
public class DefaultValueAdapter implements IModelPropertyEditorAdapter, IAdaptable {
- protected Object value = "";
+ protected Object value = ""; //$NON-NLS-1$
protected PropertyChangeSupport pcs = new PropertyChangeSupport(this);
protected PropertyChangeSupport pcs2 = new PropertyChangeSupport(this);
@@ -213,7 +213,7 @@
public String getStringValue(boolean returnNullAsEmptyString) {
Object o = getValue();
- return (o != null) ? o.toString() : (returnNullAsEmptyString) ? "" : null;
+ return (o != null) ? o.toString() : (returnNullAsEmptyString) ? "" : null; //$NON-NLS-1$
}
public void dispose() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXAttributeTreeContentProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXAttributeTreeContentProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXAttributeTreeContentProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -86,7 +86,7 @@
//single = false;
String filteredTreeName = attributeConstraint.getFilteredTreeName();
filteredTree = this.createFilteredTree(filteredTreeName);
- boolean hideRoot = properties != null && "true".equals(properties.get("hideRoot"));
+ boolean hideRoot = properties != null && "true".equals(properties.get("hideRoot")); //$NON-NLS-1$ //$NON-NLS-2$
if(hideRoot) {
return getChildren(filteredTree.getRoot());
} else {
@@ -112,7 +112,7 @@
}
protected XFilteredTree createFilteredTree(String filteredTreeName) {
- String classname = model.getMetaData().getMapping("FilteredTrees").getValue(filteredTreeName);
+ String classname = model.getMetaData().getMapping("FilteredTrees").getValue(filteredTreeName); //$NON-NLS-1$
XFilteredTree tree = (XFilteredTree)ModelFeatureFactory.getInstance().createFeatureInstance(classname);
if(tree == null) return null;
tree.setModel(model);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXModelObjectLabelProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXModelObjectLabelProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/DefaultXModelObjectLabelProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,7 +26,7 @@
}
public String getText(Object element) {
- String result = "";
+ String result = ""; //$NON-NLS-1$
if (element != null) {
if (element instanceof XModelObject) {
XModelObject modelObject = (XModelObject)element;
@@ -36,7 +36,7 @@
} else {
result = modelObject.getPresentationString();
}
- if(modelObject.getFileType() == XFileObject.FILE && modelObject.isModified()) result += "*";
+ if(modelObject.getFileType() == XFileObject.FILE && modelObject.isModified()) result += "*"; //$NON-NLS-1$
} else {
result = element.toString();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/FileChooserAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/FileChooserAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/FileChooserAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,16 +32,16 @@
properties = c.getProperties();
if(properties != null) {
// description = properties.getProperty("description");
- String s = properties.getProperty("extensions");
- StringTokenizer st = new StringTokenizer((s == null) ? "" : s, ";,");
+ String s = properties.getProperty("extensions"); //$NON-NLS-1$
+ StringTokenizer st = new StringTokenizer((s == null) ? "" : s, ";,"); //$NON-NLS-1$ //$NON-NLS-2$
extensions = new String[st.countTokens()];
for (int i = 0; i < extensions.length; i++) {
- extensions[i] = "*." + st.nextToken();
+ extensions[i] = "*." + st.nextToken(); //$NON-NLS-1$
// if("*".equals(extensions[i])) all = true;
}
- s = properties.getProperty("filenames");
+ s = properties.getProperty("filenames"); //$NON-NLS-1$
if (s != null) {
- st = new StringTokenizer(s, ";,");
+ st = new StringTokenizer(s, ";,"); //$NON-NLS-1$
filenames = new String[st.countTokens()];
for (int i = 0; i < filenames.length; i++)
filenames[i] = st.nextToken();
@@ -62,7 +62,7 @@
public String getFilterPath() {
XAttributeConstraintFileFilter c = (XAttributeConstraintFileFilter)attribute.getConstraint();
properties = c.getProperties();
- return properties == null ? null : properties.getProperty("filterFolder");
+ return properties == null ? null : properties.getProperty("filterFolder"); //$NON-NLS-1$
}
public Object getAdapter(Class adapter) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/JavaClassContentAssistProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/JavaClassContentAssistProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/JavaClassContentAssistProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
XAttribute attribute;
public IContentProposalProvider getContentProposalProvider() {
- IProject project = (IProject)object.getModel().getProperties().get("project");
+ IProject project = (IProject)object.getModel().getProperties().get("project"); //$NON-NLS-1$
return (project == null) ? null : new TypeContentProposalProvider(project, IJavaSearchConstants.TYPE);
}
@@ -43,7 +43,7 @@
public boolean isRelevant(XModelObject object, XAttribute attribute) {
if(object == null || attribute == null) return false;
String editorName = attribute.getEditor().getName();
- return editorName != null && editorName.indexOf("AccessibleJava") >= 0;
+ return editorName != null && editorName.indexOf("AccessibleJava") >= 0; //$NON-NLS-1$
}
public LabelProvider getCustomLabelProbider() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ModelObjectChildEditorAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ModelObjectChildEditorAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/ModelObjectChildEditorAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -31,7 +31,7 @@
public String getValue();
}
- protected static final String DEFAULT_DELIMITER = ";";
+ protected static final String DEFAULT_DELIMITER = ";"; //$NON-NLS-1$
ILabelProvider labelProvider = new LabelProvider();
INewValueProvider newValueProvider = null;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/Note2Adapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/Note2Adapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/Note2Adapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
}
public void setValue(Object value) {
- String s = (value == null) ? "" : value.toString();
+ String s = (value == null) ? "" : value.toString(); //$NON-NLS-1$
super.setValue(decode(s));
}
@@ -64,17 +64,17 @@
}
public String getCommand() {
- return "...";
+ return "..."; //$NON-NLS-1$
}
public String invoke(Control control) {
String n = getAttribute().getName();
- String v = "" + getValue();
+ String v = "" + getValue(); //$NON-NLS-1$
Properties p = new Properties();
- p.put("shell", control.getShell());
+ p.put("shell", control.getShell()); //$NON-NLS-1$
XModelObject o = modelObject.copy();
o.setAttributeValue(n, v);
- XActionInvoker.invoke("EditActions.Edit_" + n, o, p);
+ XActionInvoker.invoke("EditActions.Edit_" + n, o, p); //$NON-NLS-1$
return o.getAttributeValue(n);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/StructuredListAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/StructuredListAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/StructuredListAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -37,7 +37,7 @@
public Object getValue();
}
- protected static final String DEFAULT_DELIMITER = ";";
+ protected static final String DEFAULT_DELIMITER = ";"; //$NON-NLS-1$
ILabelProvider labelProvider = new LabelProvider();
INewValueProvider newValueProvider = null;
@@ -55,13 +55,13 @@
}
private void setDelimiter(XAttribute attribute) {
- String s = attribute.getProperty("delimiter");
+ String s = attribute.getProperty("delimiter"); //$NON-NLS-1$
if(s != null) {
- if(s.equals("comma")) s = ",";
+ if(s.equals("comma")) s = ","; //$NON-NLS-1$ //$NON-NLS-2$
}
delimiter = (s == null || s.length() != 1) ? DEFAULT_DELIMITER : s;
- trim = "true".equals(attribute.getProperty("trim"));
- String newValueClassName = attribute.getProperty("newValueClassName");
+ trim = "true".equals(attribute.getProperty("trim")); //$NON-NLS-1$ //$NON-NLS-2$
+ String newValueClassName = attribute.getProperty("newValueClassName"); //$NON-NLS-1$
if(newValueClassName != null) {
try {
newValueProvider = (INewValueProvider)ModelFeatureFactory.getInstance().createFeatureInstance(newValueClassName);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/XChildrenTableStructuredAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/XChildrenTableStructuredAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/XChildrenTableStructuredAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -12,6 +12,7 @@
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
+import java.text.MessageFormat;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
@@ -67,8 +68,8 @@
public static final String UP_LABEL = "&Up";
public static final String DOWN_LABEL = "&Down";
- private static final String COPY_XACTION_PATH = "CopyActions.Copy";
- private static final String MOVE_XACTION_PATH = "MoveActions.Move";
+ private static final String COPY_XACTION_PATH = "CopyActions.Copy"; //$NON-NLS-1$
+ private static final String MOVE_XACTION_PATH = "MoveActions.Move"; //$NON-NLS-1$
private XModelTreeListener modelTreeListener;
private XModelTreeListenerSWTASync asyncListener;
@@ -80,7 +81,7 @@
this.table = table;
if (tableColumn == null) {
if ((shownProperties == null) || (shownProperties.length == 0)) {
- shownProperties = new String[] {"name"}; // name attribute as default
+ shownProperties = new String[] {"name"}; // name attribute as default //$NON-NLS-1$
widths = new int[] {100};
}
tableColumn = new TableColumn[shownProperties.length];
@@ -209,7 +210,7 @@
if (model!=null) {
model.addModelTreeListener(asyncListener);
}
- printActionList("",xmo.getModelEntity().getActionList());//.getAction(actionPath);
+ printActionList("",xmo.getModelEntity().getActionList());//.getAction(actionPath); //$NON-NLS-1$
}
public void setAttributeData(XAttributeData attributeData) {
@@ -335,16 +336,16 @@
String actionListName = actionList.getName();
String actionListDisplayName = actionList.getDisplayName();
String actionListPath = actionList.getPath();
- System.out.println(level+"ActionList ["+actionListName+"] ["+actionListDisplayName+"] ["+actionListPath+"]");
+ System.out.println(level+"ActionList ["+actionListName+"] ["+actionListDisplayName+"] ["+actionListPath+"]"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
XActionItem[] items = actionList.getActionItems();
for (int i=0;i<items.length;++i) {
if (items[i] instanceof XActionList) {
- printActionList(level+" ", (XActionList)items[i]);
+ printActionList(level+" ", (XActionList)items[i]); //$NON-NLS-1$
} else {
String actionItemName = items[i].getName();
String actionItemDisplayName = items[i].getDisplayName();
String actionItemPath = items[i].getPath();
- System.out.println(level+" "+"ActionItem ["+actionItemName+"] ["+actionItemDisplayName+"] ["+actionItemPath+"]");
+ System.out.println(level+" "+"ActionItem ["+actionItemName+"] ["+actionItemDisplayName+"] ["+actionItemPath+"]"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
}
}
}
@@ -443,7 +444,7 @@
}
public void setActionPath(String path) {
this.path = path;
- if ("%SelectIt%".equals(path)) {
+ if ("%SelectIt%".equals(path)) { //$NON-NLS-1$
if (xmo != null) {
setEnabled(true);
} else {
@@ -459,7 +460,7 @@
}
public void setXModelObject(XModelObject xmo) {
this.xmo = xmo;
- if ("%SelectIt%".equals(path)) {
+ if ("%SelectIt%".equals(path)) { //$NON-NLS-1$
if (xmo != null) {
setEnabled(true);
} else {
@@ -475,7 +476,7 @@
}
public void run() {
- if ("%SelectIt%".equals(this.path)) {
+ if ("%SelectIt%".equals(this.path)) { //$NON-NLS-1$
if (selectionChangedListener!=null) {
if(this.xmo == null) return;
ISelection selection = new StructuredSelection(this.xmo);
@@ -775,7 +776,8 @@
public String getColumnText(Object element, int columnIndex) {
XModelObject xmo = ((XModelObject)element);
String result = xmo.getAttributeValue(shownProperties[columnIndex]);
- return (result!=null)?result:"no attribute called "+shownProperties[columnIndex]+" on entity "+xmo.getModelEntity().getName();
+ return (result!=null)?result:MessageFormat.format("no attribute called {0} on entity {1}",
+ shownProperties[columnIndex], xmo.getModelEntity().getName());
}
/* (non-Javadoc)
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/ColoredFontData.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/ColoredFontData.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/ColoredFontData.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -43,19 +43,19 @@
public static ColoredFontData toFontData(String text) {
if(text == null || text.length() == 0) return DEFAULT;
- StringTokenizer st = new StringTokenizer(text, ",");
+ StringTokenizer st = new StringTokenizer(text, ","); //$NON-NLS-1$
int q = 0;
FontData data = new FontData(DEFAULT.getFontData().getName(), DEFAULT.getFontData().getHeight(), DEFAULT.getFontData().getStyle());
RGB color = DEFAULT.getColor();
while(st.hasMoreTokens()) {
String t = st.nextToken();
if(q == 0) {
- if(!"default".equals(t)) data.setName(t);
- } else if(t.startsWith("size=")) {
+ if(!"default".equals(t)) data.setName(t); //$NON-NLS-1$
+ } else if(t.startsWith("size=")) { //$NON-NLS-1$
data.setHeight(getInt(t.substring(5), data.getHeight()));
- } else if(t.startsWith("style=")) {
+ } else if(t.startsWith("style=")) { //$NON-NLS-1$
data.setStyle(getInt(t.substring(6), data.getStyle()));
- } else if(t.startsWith("color=")) {
+ } else if(t.startsWith("color=")) { //$NON-NLS-1$
String sc = t.substring(6);
int red = color.red, green = color.green, blue = color.blue;
int i = sc.indexOf('-');
@@ -90,13 +90,13 @@
public static String toString(FontData data, RGB rgb) {
StringBuffer sb = new StringBuffer();
if(data.getName().equals(DEFAULT.getFontData().getName()))
- sb.append("default");
+ sb.append("default"); //$NON-NLS-1$
else
sb.append(data.getName());
- sb.append(",size=" + data.getHeight());
- sb.append(",style=" + data.getStyle());
+ sb.append(",size=" + data.getHeight()); //$NON-NLS-1$
+ sb.append(",style=" + data.getStyle()); //$NON-NLS-1$
if(!DEFAULT.color.equals(rgb)) {
- sb.append(",color=" + rgb.red + "-" + rgb.green + "-" + rgb.blue);
+ sb.append(",color=" + rgb.red + "-" + rgb.green + "-" + rgb.blue); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
return sb.toString();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/EclipseClassChooserAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/EclipseClassChooserAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/EclipseClassChooserAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -11,6 +11,7 @@
package org.jboss.tools.common.model.ui.attribute.adapter.custom;
import java.lang.reflect.InvocationTargetException;
+import java.text.MessageFormat;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.jboss.tools.common.model.ui.*;
import org.jboss.tools.common.model.ui.attribute.adapter.DefaultValueAdapter;
@@ -40,7 +41,7 @@
SelectionDialog dialog = JavaUI.createTypeDialog(control.getShell(), context, scope, flags, false, getStringValue(true));
dialog.create();
if(getAttribute() != null) {
- String title = "Edit " + WizardKeys.getAttributeDisplayName(getAttribute(), true);
+ String title = MessageFormat.format("Edit {0}", WizardKeys.getAttributeDisplayName(getAttribute(), true));
dialog.getShell().setText(title);
} else {
dialog.getShell().setText("Edit");
@@ -60,7 +61,7 @@
}
public String getCommand() {
- return "...";
+ return "..."; //$NON-NLS-1$
}
public Object getAdapter(Class adapter) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FileSystemListContentProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FileSystemListContentProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FileSystemListContentProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,16 +25,16 @@
}
protected void loadTags() {
- XModelObject fss = model.getByPath("FileSystems");
+ XModelObject fss = model.getByPath("FileSystems"); //$NON-NLS-1$
if(fss == null) return;
XModelObject[] os = fss.getChildren();
XAttributeConstraintAList c = (XAttributeConstraintAList)attribute.getConstraint();
loadProperties(c.getValues());
List<String> list = new ArrayList<String>(os.length+1);
- if (emptyChoice) list.add("");
+ if (emptyChoice) list.add(""); //$NON-NLS-1$
for (int i = 0; i < os.length; i++) {
if (!writeOnly || os[i].isObjectEditable()) {
- list.add(os[i].get("NAME"));
+ list.add(os[i].get("NAME")); //$NON-NLS-1$
}
}
tags = list.toArray(new String[list.size()]);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FontChooserAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FontChooserAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/FontChooserAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,12 +22,12 @@
}
public String getCommand() {
- return "...";
+ return "..."; //$NON-NLS-1$
}
public String invoke0(Control control) {
FontDialog dialog = new FontDialog(control.getShell());
- String v = "" + getValue();
+ String v = "" + getValue(); //$NON-NLS-1$
ColoredFontData data = ColoredFontData.toFontData(v);
dialog.setFontList(new FontData[]{data.getFontData()});
dialog.setRGB(data.getColor());
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/TomcatJVMListAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/TomcatJVMListAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/adapter/custom/TomcatJVMListAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -76,10 +76,10 @@
for (int i = 0; i < jvmType.length; i++) {
IVMInstall[] jvmInstall = jvmType[i].getVMInstalls();
for (int j = 0; j < jvmInstall.length; j++) {
- if(jvmInstall[j].getName().equals(text)) return jvmInstall[j].getName() + " - \"" + (jvmInstall[j].getInstallLocation().getPath().length()>50?jvmInstall[j].getInstallLocation().getPath().substring(50)+" ...":jvmInstall[j].getInstallLocation().getPath()) +"\"";
+ if(jvmInstall[j].getName().equals(text)) return jvmInstall[j].getName() + " - \"" + (jvmInstall[j].getInstallLocation().getPath().length()>50?jvmInstall[j].getInstallLocation().getPath().substring(50)+" ...":jvmInstall[j].getInstallLocation().getPath()) +"\""; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
- return "";
+ return ""; //$NON-NLS-1$
}
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActionButtonControl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActionButtonControl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActionButtonControl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -73,13 +73,13 @@
}
private Control createButton(Composite parent, ButtonWrapper buttonWrapper) {
- int style = getSettings().getStyle("Button.Style");
+ int style = getSettings().getStyle("Button.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
if (style == 0) style = SWT.PUSH;
Control buttonControl = buttonWrapper.createControl(parent, style);
// widget settings
- Color fg = getSettings().getColor("Button.Foreground");
- Font font = getSettings().getFont("Button.Font");
+ Color fg = getSettings().getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Button.Font"); //$NON-NLS-1$
buttonControl.setForeground(fg);
buttonControl.setFont(font);
@@ -121,7 +121,7 @@
public Control createControl(Composite parent, int style) {
if (buttonControl==null) {
buttonControl = new Button(parent, style);
- buttonControl.setText(buttonAction.getText()!=null?buttonAction.getText():"%text%");
+ buttonControl.setText(buttonAction.getText()!=null?buttonAction.getText():"%text%"); //$NON-NLS-1$
buttonControl.setEnabled(enabled);
buttonControl.addSelectionListener(new SelectionListener(){
public void widgetSelected(SelectionEvent e) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActiveFieldEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActiveFieldEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ActiveFieldEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,7 +30,7 @@
if (action!=null) {
command = action.getCommand();
}
- if(command != null && !command.equals("...")) {
+ if(command != null && !command.equals("...")) { //$NON-NLS-1$
setChangeButtonText(command);
}
if(action instanceof IActionHelperExtension) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxCellEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxCellEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxCellEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,7 +10,6 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.attribute.editor;
-import org.eclipse.swt.custom.CCombo;
import org.eclipse.swt.widgets.Combo;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
@@ -20,8 +19,8 @@
protected Combo comboBox;
protected Composite parent;
- protected String trueValue = "true";
- protected String falseValue = "false";
+ protected String trueValue = "true"; //$NON-NLS-1$
+ protected String falseValue = "false"; //$NON-NLS-1$
public CheckBoxCellEditorEx(Composite parent, String[] items, int style) {
super(parent, items, style);
@@ -36,7 +35,7 @@
if(comboBox != null) {
comboBox.setItems(getTags());
- comboBox.setText("" + value);
+ comboBox.setText("" + value); //$NON-NLS-1$
}
}
protected Object doGetValue() {
@@ -49,9 +48,9 @@
private void initValue(Object value) {
if (value instanceof String) {
- if ("yes".equalsIgnoreCase(value.toString()) || ("no".equalsIgnoreCase(value.toString()))) {
- trueValue = "yes";
- falseValue = "no";
+ if ("yes".equalsIgnoreCase(value.toString()) || ("no".equalsIgnoreCase(value.toString()))) { //$NON-NLS-1$ //$NON-NLS-2$
+ trueValue = "yes"; //$NON-NLS-1$
+ falseValue = "no"; //$NON-NLS-1$
}
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckBoxFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -38,8 +38,8 @@
private int style = SKIP_LABEL;
private Button checkBox = null;
- protected String trueValue = "true";
- protected String falseValue = "false";
+ protected String trueValue = "true"; //$NON-NLS-1$
+ protected String falseValue = "false"; //$NON-NLS-1$
protected boolean booleanValue = false;
@@ -63,7 +63,7 @@
String text = getLabelText();
if (style == SKIP_LABEL) {
Label label = new Label(parent,SWT.NONE);
- label.setText("");
+ label.setText(""); //$NON-NLS-1$
numColumns--;
}
if (style == SEPARATE_LABEL) {
@@ -103,7 +103,7 @@
}
int style = 0;
if (getSettings() != null) {
- style = getSettings().getStyle("CheckBox.Style");
+ style = getSettings().getStyle("CheckBox.Style"); //$NON-NLS-1$
}
if (style == SWT.DEFAULT) {
style = SWT.CHECK | SWT.LEFT;
@@ -199,9 +199,9 @@
private void initValue(Object value) {
if (value instanceof String) {
- if ("yes".equalsIgnoreCase(value.toString()) || "no".equalsIgnoreCase(value.toString())) {
- trueValue = "yes";
- falseValue = "no";
+ if ("yes".equalsIgnoreCase(value.toString()) || "no".equalsIgnoreCase(value.toString())) { //$NON-NLS-1$ //$NON-NLS-2$
+ trueValue = "yes"; //$NON-NLS-1$
+ falseValue = "no"; //$NON-NLS-1$
}
}
}
@@ -209,7 +209,7 @@
private boolean isTrue(Object value) {
if (value instanceof Boolean) return ((Boolean)value).booleanValue();
if (value instanceof String) {
- if ("yes".equalsIgnoreCase(value.toString()) || "true".equalsIgnoreCase(value.toString())) return true;
+ if ("yes".equalsIgnoreCase(value.toString()) || "true".equalsIgnoreCase(value.toString())) return true; //$NON-NLS-1$ //$NON-NLS-2$
}
return false;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckListFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckListFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckListFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -137,7 +137,7 @@
valueProvider.removeValueChangeListener(this);
if (IPropertyEditor.VALUE.equals(event.getPropertyName())) {
Object v = event.getNewValue();
- String s = (v == null) ? "" : v.toString();
+ String s = (v == null) ? "" : v.toString(); //$NON-NLS-1$
if(!s.equals(stringValue)) {
stringValue = s;
@@ -150,7 +150,7 @@
TreeItem[] is = tree.getItems();
for (int i = 0; i < is.length; i++) {
Object d = is[i].getData();
- StringTokenizer values = new StringTokenizer(stringValue, ";,");
+ StringTokenizer values = new StringTokenizer(stringValue, ";,"); //$NON-NLS-1$
while(values.hasMoreTokens()) {
String n = values.nextToken();
if(n.equals(d)) {
@@ -174,20 +174,20 @@
if(item == null) return;
String currentItem = item.getData().toString();
- StringTokenizer values = new StringTokenizer(valueProvider.getStringValue(true), ";,");
- String newValue = "";
+ StringTokenizer values = new StringTokenizer(valueProvider.getStringValue(true), ";,"); //$NON-NLS-1$
+ String newValue = ""; //$NON-NLS-1$
boolean currentItemExists = false;
while (values.hasMoreTokens()) {
String value = values.nextToken();
if (value.equals(currentItem))
currentItemExists = true;
else {
- if(newValue.length() > 0 && !newValue.endsWith(";") && !newValue.endsWith(",")) newValue += ";";
+ if(newValue.length() > 0 && !newValue.endsWith(";") && !newValue.endsWith(",")) newValue += ";"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
newValue += value;
}
}
if (!currentItemExists) {
- if(newValue.length() > 0 && !newValue.endsWith(";") && !newValue.endsWith(",")) newValue += ";";
+ if(newValue.length() > 0 && !newValue.endsWith(";") && !newValue.endsWith(",")) newValue += ";"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
newValue += currentItem;
}
valueChanged(newValue);
@@ -203,7 +203,7 @@
}
public boolean isSelected(Object data) {
- StringTokenizer values = new StringTokenizer(valueProvider.getStringValue(true), ";,");
+ StringTokenizer values = new StringTokenizer(valueProvider.getStringValue(true), ";,"); //$NON-NLS-1$
while (values.hasMoreTokens()) {
String n = values.nextToken();
if(data != null && data.equals(n)) return true;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckTreeFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckTreeFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/CheckTreeFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -28,7 +28,6 @@
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.TreeItem;
-import org.jboss.tools.common.model.ui.attribute.adapter.CheckTreeAdapter;
import org.jboss.tools.common.model.ui.viewers.xpl.ICheckable;
import org.jboss.tools.common.model.ui.widgets.IWidgetSettings;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DefaultButtonControl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DefaultButtonControl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DefaultButtonControl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -106,7 +106,7 @@
createButton(composite, buttonWrapper);
} else {
if(ModelUIPlugin.getDefault().isDebugging()) {
- ModelUIPlugin.getPluginLog().logInfo("No button for action: "+object);
+ ModelUIPlugin.getPluginLog().logInfo("No button for action: "+object); //$NON-NLS-1$
}
}
}
@@ -134,13 +134,13 @@
}
protected Control createButton(Composite parent, ButtonWrapper buttonWrapper) {
- int style = getSettings().getStyle("Button.Style");
+ int style = getSettings().getStyle("Button.Style"); //$NON-NLS-1$
if (style == SWT.DEFAULT) style = SWT.PUSH;
Control buttonControl = buttonWrapper.createControl(parent, style);
// widget settings
- Color bg = getSettings().getColor("Button.Background");
- Color fg = getSettings().getColor("Button.Foreground");
- Font font = getSettings().getFont("Button.Font");
+ Color bg = getSettings().getColor("Button.Background"); //$NON-NLS-1$
+ Color fg = getSettings().getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Button.Font"); //$NON-NLS-1$
buttonControl.setBackground(bg);
buttonControl.setForeground(fg);
buttonControl.setFont(font);
@@ -207,7 +207,7 @@
protected void doButtonPressed(Button control, String action) {
if(ModelUIPlugin.getDefault().isDebugging()) {
- ModelUIPlugin.getPluginLog().logInfo("Button pressed: "+action);
+ ModelUIPlugin.getPluginLog().logInfo("Button pressed: "+action); //$NON-NLS-1$
}
firePropertyChange(new PropertyChangeEvent(control, action, null, Boolean.TRUE));
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DialogCellEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DialogCellEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DialogCellEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.attribute.editor;
+import java.text.MessageFormat;
import org.jboss.tools.common.model.ui.IValueChangeListener;
import org.jboss.tools.common.model.ui.IValueProvider;
import org.jboss.tools.common.model.ui.attribute.AttributeContentProposalProviderFactory;
@@ -90,7 +91,7 @@
DialogCellEditorEx.this.focusLost();
}
});
- result.setText("...");
+ result.setText("..."); //$NON-NLS-1$
return button = result;
}
@@ -125,7 +126,7 @@
}
dialog = new PropertyEditorDialog(ModelUIPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell(),propertyEditor);
dialog.create();
- String title = "Edit " + WizardKeys.getAttributeDisplayName(a.getAttribute(), true);
+ String title = MessageFormat.format("Edit {0}", WizardKeys.getAttributeDisplayName(a.getAttribute(), true));
dialog.getShell().setText(title);
externalEditing = true;
ExtendedFieldEditor fieldEditor = propertyEditor.getFieldEditor(null);
@@ -223,7 +224,7 @@
protected void updateContents(Object value) {
if(modifyLock > 0) return;
if (text == null) return;
- String txt = "";
+ String txt = ""; //$NON-NLS-1$
if (value != null) txt = value.toString();
setTextEditable(!(txt.indexOf('\n') >= 0 || txt.indexOf('\r') >= 0));
if(!editable) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DirectoryFieldEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DirectoryFieldEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/DirectoryFieldEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -107,7 +107,7 @@
if (dirChooserLabelText != null)
dialog.setMessage(dirChooserLabelText);
if(propertyEditor != null && propertyEditor.getValue() != null && propertyEditor.getValue().toString().trim().length() > 0) {
- String v = "" + propertyEditor.getValue();
+ String v = "" + propertyEditor.getValue(); //$NON-NLS-1$
if(new File(v).isFile()) v = new File(v).getParent();
dialog.setFilterPath(v);
} else if (lastPath != null) {
@@ -162,7 +162,7 @@
valueProvider.removeValueChangeListener(this);
if (IPropertyEditor.VALUE.equals(evt.getPropertyName())) {
Object v = evt.getNewValue();
- this.setStringValue((v == null) ? "" : v.toString());
+ this.setStringValue((v == null) ? "" : v.toString()); //$NON-NLS-1$
}
valueProvider.addValueChangeListener(this);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ExtendedFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ExtendedFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ExtendedFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -121,7 +121,7 @@
layout.horizontalSpacing = 2;
labelComposite.setLayout(layout);
- Color fg = getSettings().getColor("Label.Foreground");
+ Color fg = getSettings().getColor("Label.Foreground"); //$NON-NLS-1$
/// Color bg = parent.getBackground();
///getSettings().getColor("Label.Background");
/// labelComposite.setBackground(bg);
@@ -142,11 +142,11 @@
protected Label createLabelControl(Composite parent) {
if (getLabelControl() == null) { // cannot comment this! for details see label.addDisposeListener
- int style = getSettings().getStyle("Label.Style");
+ int style = getSettings().getStyle("Label.Style"); //$NON-NLS-1$
/// Color bg = parent.getBackground();
///getSettings().getColor("Label.Background");
- Color fg = getSettings().getColor("Label.Foreground");
- Font font = getSettings().getFont("Label.Font");
+ Color fg = getSettings().getColor("Label.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Label.Font"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
style |= SWT.RIGHT;
label = new Label(parent, style);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/FileFieldEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/FileFieldEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/FileFieldEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -63,7 +63,7 @@
dialog.setFilterPath(lastPath);
} else {
FileChooserAdapter adapter = (FileChooserAdapter)propertyEditor.getAdapter(FileChooserAdapter.class);
- if(adapter != null) {int oo;
+ if(adapter != null) {
String filterPath = adapter.getFilterPath();
if(filterPath != null && new File(filterPath).exists()) {
dialog.setFilterPath(filterPath);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/HyperlinkStringButtonFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/HyperlinkStringButtonFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/HyperlinkStringButtonFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -67,12 +67,12 @@
if (this.labelAction!=null) {
// hyperlink style
- style = getSettings().getStyle("Hyperlink.Style");
+ style = getSettings().getStyle("Hyperlink.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
bg = parent.getBackground();
///getSettings().getColor("Hyperlink.Background");
- fg = getSettings().getColor("Hyperlink.Foreground");
- font = getSettings().getFont("Hyperlink.Font");
+ fg = getSettings().getColor("Hyperlink.Foreground"); //$NON-NLS-1$
+ font = getSettings().getFont("Hyperlink.Font"); //$NON-NLS-1$
label = new SelectableFormLabel(parent, style);
((SelectableFormLabel)label).addSelectionListener(new SelectionListener() {
public void widgetSelected(SelectionEvent e) {
@@ -83,11 +83,11 @@
});
} else {
// label
- style = getSettings().getStyle("Label.Style");
+ style = getSettings().getStyle("Label.Style"); //$NON-NLS-1$
bg = parent.getBackground();
///getSettings().getColor("Label.Background");
- fg = getSettings().getColor("Label.Foreground");
- font = getSettings().getFont("Label.Font");
+ fg = getSettings().getColor("Label.Foreground"); //$NON-NLS-1$
+ font = getSettings().getFont("Label.Font"); //$NON-NLS-1$
label = new Label(parent, style);
}
@@ -119,7 +119,7 @@
valueProvider.addValueChangeListener(this);
actionProvider = (IActionProvider)propertyEditor.getAdapter(IActionProvider.class);
if (actionProvider!=null) {
- labelAction = actionProvider.getAction("LABEL_ACTION");
+ labelAction = actionProvider.getAction("LABEL_ACTION"); //$NON-NLS-1$
}
setErrorProvider((IAttributeErrorProvider)propertyEditor.getAdapter(IAttributeErrorProvider.class));
}
@@ -193,7 +193,7 @@
if (IPropertyEditor.VALUE.equals(evt.getPropertyName())) {
Object v = evt.getNewValue();
valueProvider.removeValueChangeListener(this);
- this.setStringValue((v == null) ? "" : v.toString());
+ this.setStringValue((v == null) ? "" : v.toString()); //$NON-NLS-1$
valueProvider.addValueChangeListener(this);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/IPropertyEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/IPropertyEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/IPropertyEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -15,9 +15,9 @@
import org.eclipse.swt.widgets.Composite;
public interface IPropertyEditor extends IAdaptable {
- public static final String ERROR = "IPropertyEditor.error";
- public static final String VALUE = "IPropertyEditor.value";
- public static final String LIST_CONTENT = "IPropertyEditor.listContent";
+ public static final String ERROR = "IPropertyEditor.error"; //$NON-NLS-1$
+ public static final String VALUE = "IPropertyEditor.value"; //$NON-NLS-1$
+ public static final String LIST_CONTENT = "IPropertyEditor.listContent"; //$NON-NLS-1$
// get components
public CellEditor getCellEditor(Composite parent);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -60,7 +60,7 @@
try {
javaProject = (IJavaProject)project.getNature(JavaCore.NATURE_ID);
} catch (CoreException e) {
- ModelUIPlugin.getPluginLog().logError("Cannot find Java Project Nature.", e);
+ ModelUIPlugin.getPluginLog().logError("Cannot find Java Project Nature.", e); //$NON-NLS-1$
return null;
}
IResource r = EclipseResourceUtil.getJavaSourceRoot(project);
@@ -78,19 +78,19 @@
}
packageName = null;
String fullClassName = null;
- if (name == null) name = "";
- fullClassName = name.replace('.', '/') + ".java";
+ if (name == null) name = ""; //$NON-NLS-1$
+ fullClassName = name.replace('.', '/') + ".java"; //$NON-NLS-1$
if (name.lastIndexOf('.') > 0) {
className = name.substring(name.lastIndexOf('.') + 1);
packageName = name.substring(0,name.lastIndexOf('.'));
} else {
className = name;
- packageName = "";
+ packageName = ""; //$NON-NLS-1$
}
try {
javaProject = (IJavaProject)project.getNature(JavaCore.NATURE_ID);
} catch (CoreException e) {
- ModelUIPlugin.getPluginLog().logError("Cannot find Java Project Nature.", new Exception());
+ ModelUIPlugin.getPluginLog().logError("Cannot find Java Project Nature.", new Exception()); //$NON-NLS-1$
return;
}
@@ -116,7 +116,7 @@
}
public String getSuperClass() {
- if (superClass==null || superClass.length()==0) superClass = "java.lang.Object";
+ if (superClass==null || superClass.length()==0) superClass = "java.lang.Object"; //$NON-NLS-1$
return superClass;
}
public void setSuperClass(String superClass) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaChoicerFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaChoicerFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaChoicerFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -65,12 +65,12 @@
private Composite treeAndText;
private XModel model;
- private JavaElement rootElement = new JavaRootElement("Java");
+ private JavaElement rootElement = new JavaRootElement("Java"); //$NON-NLS-1$
AccessibleJava.IContextPackageProvider cpp = null;
- private static final String ROOT_PATH = "%root%";
- private static final String EMPTY_PATH = "";
- private static final Image ROOT_IMAGE = ModelImages.getImage("images/navigationtree/java.gif");
+ private static final String ROOT_PATH = "%root%"; //$NON-NLS-1$
+ private static final String EMPTY_PATH = ""; //$NON-NLS-1$
+ private static final Image ROOT_IMAGE = ModelImages.getImage("images/navigationtree/java.gif"); //$NON-NLS-1$
private static final Image PACKAGE_IMAGE = JavaPluginImages.get(JavaPluginImages.IMG_OBJS_PACKAGE);
private static final Image CLASS_IMAGE = JavaPluginImages.get(JavaPluginImages.IMG_OBJS_CLASS);
@@ -148,7 +148,7 @@
Label label;
label = new Label(composite, SWT.NONE);
- label.setText(EditorMessages.getString("JavaChoicerFieldEditor.Tab1.Tree.Label"));
+ label.setText(EditorMessages.getString("JavaChoicerFieldEditor.Tab1.Tree.Label")); //$NON-NLS-1$
tree = new TreeViewer(composite,SWT.BORDER | SWT.SINGLE | SWT.H_SCROLL | SWT.V_SCROLL);
gd = new GridData(GridData.FILL_BOTH);
@@ -156,7 +156,7 @@
tree.getControl().setLayoutData(gd);
tree.setContentProvider(new ContentProviderEx());
tree.setLabelProvider(new LabelProviderEx());
- tree.setInput("Java");
+ tree.setInput("Java"); //$NON-NLS-1$
if ((this.stringValue!=null)&&(this.stringValue.length()>0)) {
ISelection selection = getSelection(this.stringValue);
tree.setSelection(selection);
@@ -173,7 +173,7 @@
});
label = new Label(composite, SWT.NONE);
- label.setText(EditorMessages.getString("JavaChoicerFieldEditor.Tab1.Text.Label"));
+ label.setText(EditorMessages.getString("JavaChoicerFieldEditor.Tab1.Text.Label")); //$NON-NLS-1$
text = new Text(composite,SWT.SINGLE | SWT.BORDER | SWT.READ_ONLY);
gd = new GridData(GridData.FILL_HORIZONTAL);
@@ -186,12 +186,12 @@
}
private Object getObject(String path) {
- StringTokenizer st = new StringTokenizer(path, ".");
+ StringTokenizer st = new StringTokenizer(path, "."); //$NON-NLS-1$
JavaElement element = rootElement;
- String find = "";
+ String find = ""; //$NON-NLS-1$
while (st.hasMoreTokens()) {
find = st.nextToken();
- find = (element.getPath().equals(rootElement.getPath()))?find:element.getPath()+"."+find;
+ find = (element.getPath().equals(rootElement.getPath()))?find:element.getPath()+"."+find; //$NON-NLS-1$
if (element.getChildByPath(find) == null) {
// try find like element startWith()
int childCount = element.getChildCount();
@@ -211,7 +211,7 @@
if(o == null && cpp != null && path != null && path.length() > 0 && path.indexOf('.') < 0) {
String pkg = cpp.getContextPackage();
if(pkg != null && pkg.length() > 0) {
- o = getObject(pkg + "." + path);
+ o = getObject(pkg + "." + path); //$NON-NLS-1$
}
}
return new StructuredSelection(new Object[] {o});
@@ -304,8 +304,8 @@
class JavaElement {
protected JavaElement parent = null;
private boolean isLoaded = false;
- protected String path = "";
- protected String name = "";
+ protected String path = ""; //$NON-NLS-1$
+ protected String name = ""; //$NON-NLS-1$
protected boolean isPackage = false;
private List<JavaElement> children = new ArrayList<JavaElement>();
@@ -313,7 +313,7 @@
}
public JavaElement(String parentpath, String name) {
- this.path = (parentpath == null) ? name : parentpath + "." + name;
+ this.path = (parentpath == null) ? name : parentpath + "." + name; //$NON-NLS-1$
this.name = name;
}
@@ -358,7 +358,7 @@
if(ns == null) return;
for (int i = 0; i < ns.length; i++) {
String s = ns[i];
- boolean p = s.endsWith(".");
+ boolean p = s.endsWith("."); //$NON-NLS-1$
if(p) s = s.substring(0, s.length() - 1);
if(!isJavaName(s)) continue;
JavaElement c = createChild(s);
@@ -427,7 +427,7 @@
public void modifyText(ModifyEvent e) {
String newValue = ((Text)e.getSource()).getText();
tree.removeSelectionChangedListener(this);
- if (newValue.endsWith(" ")) {
+ if (newValue.endsWith(" ")) { //$NON-NLS-1$
StructuredSelection selection = (StructuredSelection)tree.getSelection();
JavaElement element = (JavaElement)selection.getFirstElement();
if (element != null) {
@@ -437,7 +437,7 @@
valueChanged(EMPTY_PATH);
}
newValue = stringValue;
- if(newValue == null) newValue = "";
+ if(newValue == null) newValue = ""; //$NON-NLS-1$
text.setText(newValue);
text.setSelection(newValue.length());
}
@@ -519,7 +519,7 @@
IModelPropertyEditorAdapter adapter = (IModelPropertyEditorAdapter)propertyEditor.getInput();
XAttribute a = adapter.getAttribute();
if(a == null) return null;
- String cls = a.getProperty("contextPackageProvider");
+ String cls = a.getProperty("contextPackageProvider"); //$NON-NLS-1$
if(cls == null || cls.length() == 0) return null;
try {
AccessibleJava.IContextPackageProvider o = (AccessibleJava.IContextPackageProvider)ModelFeatureFactory.getInstance().createFeatureInstance(cls);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaEclipseChoicerEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaEclipseChoicerEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaEclipseChoicerEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.attribute.editor;
+import java.text.MessageFormat;
import org.eclipse.core.resources.IProject;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IJavaProject;
@@ -69,7 +70,7 @@
}
public String getChangeButtonName() {
- return JFaceResources.getString("openBrowse");
+ return JFaceResources.getString("openBrowse"); //$NON-NLS-1$
}
public boolean callsExternal() {
@@ -86,14 +87,15 @@
jp = EclipseResourceUtil.getJavaProject(p);
}
}
- String title = "Select " + getAttributeName();
+ String title = MessageFormat.format("Select {0}", getAttributeName());
if(adapter != null && adapter.getAttribute() != null) {
- String key = "" + adapter.getAttribute().getModelEntity().getName() + "." + adapter.getAttribute().getName().replace(' ', '_') + ".edit";
+ String key = "" + adapter.getAttribute().getModelEntity().getName() + "." + adapter.getAttribute().getName().replace(' ', '_') + ".edit"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
String t = WizardKeys.getLabelText(key);
if(t != null) {
title = t;
} else {
- title = "Select " + WizardKeys.getAttributeDisplayName(adapter.getAttribute(), true);
+ title = MessageFormat.format("Select {0}",
+ WizardKeys.getAttributeDisplayName(adapter.getAttribute(), true));
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaFavoritesFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaFavoritesFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaFavoritesFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -97,7 +97,7 @@
// label
classListLabel = new Label(composite, SWT.NONE);
- classListLabel.setText(EditorMessages.getString("JavaFavoritesChoicerFieldEditor.ClassesList.Label"));
+ classListLabel.setText(EditorMessages.getString("JavaFavoritesChoicerFieldEditor.ClassesList.Label")); //$NON-NLS-1$
// list
classList = createList(composite);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCellEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCellEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCellEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -48,7 +48,7 @@
if (((DefaultValueAdapter)valueProvider).getModel()!=null) {
XModelObject xmo = FileSystemsHelper.getFileSystems(((DefaultValueAdapter)valueProvider).getModel());
if (xmo!=null) {
- IProject project = (IProject)xmo.getModel().getProperties().get("project");
+ IProject project = (IProject)xmo.getModel().getProperties().get("project"); //$NON-NLS-1$
if (project!=null) {
this.project = project;
}
@@ -76,10 +76,10 @@
IPackageFragmentRoot root = (project == null) ? null : JavaAdapter.getInstance().getPackageFragmentRoot(project);
if (root != null) {
JavaTypeCompletionProcessor contentAssistentProcessor = new JavaTypeCompletionProcessor(false, false);
- IPackageFragment currentPackage = root.getPackageFragment("");
+ IPackageFragment currentPackage = root.getPackageFragment(""); //$NON-NLS-1$
contentAssistentProcessor.setPackageFragment(currentPackage);
Text text = getTextField();
- text.setData("JavaHyperlinkLineFieldEditor", this);
+ text.setData("JavaHyperlinkLineFieldEditor", this); //$NON-NLS-1$
ControlContentAssistHelper.createTextContentAssistant(getTextField(), contentAssistentProcessor, JavaHyperlinkCueLabelProvider.INSTANCE);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCueLabelProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCueLabelProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkCueLabelProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -24,7 +24,7 @@
}
static Image createClassImage() {
- return ModelUIImages.getImage("java/wizard.gif");
+ return ModelUIImages.getImage("java/wizard.gif"); //$NON-NLS-1$
}
public static JavaHyperlinkCueLabelProvider INSTANCE = new JavaHyperlinkCueLabelProvider();
@@ -38,7 +38,7 @@
if(!(element instanceof Text)) return null;
Text text = (Text)element;
if(text.isDisposed()) return null;
- JavaClassHolder editor = (JavaClassHolder)text.getData("JavaHyperlinkLineFieldEditor");
+ JavaClassHolder editor = (JavaClassHolder)text.getData("JavaHyperlinkLineFieldEditor"); //$NON-NLS-1$
return (editor == null || editor.classExists() || !editor.canCreateClass()) ? null : CLASS_IMAGE;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -90,7 +90,7 @@
if (((DefaultValueAdapter)valueProvider).getModel()!=null) {
XModelObject xmo = FileSystemsHelper.getFileSystems(((DefaultValueAdapter)valueProvider).getModel());
if (xmo!=null) {
- IProject project = (IProject)xmo.getModel().getProperties().get("project");
+ IProject project = (IProject)xmo.getModel().getProperties().get("project"); //$NON-NLS-1$
if (project!=null) {
this.project = project;
}
@@ -118,7 +118,7 @@
if(project != null) {
setLabelAction(new OpenJavaEditorAction());
setSelectableLabel(Boolean.TRUE.booleanValue());
- setChangeButtonText(JFaceResources.getString("openBrowse"));
+ setChangeButtonText(JFaceResources.getString("openBrowse")); //$NON-NLS-1$
}
}
}
@@ -213,7 +213,7 @@
public Control createTextControl(Composite parent) {
Control control = super.createTextControl(parent);
Text text = getTextField();
- text.setData("JavaHyperlinkLineFieldEditor", this);
+ text.setData("JavaHyperlinkLineFieldEditor", this); //$NON-NLS-1$
return control;
}
@@ -258,7 +258,7 @@
IModelPropertyEditorAdapter adapter = (IModelPropertyEditorAdapter)propertyEditor.getInput();
XAttribute a = adapter.getAttribute();
if(a == null) return null;
- String cls = a.getProperty("contextPackageProvider");
+ String cls = a.getProperty("contextPackageProvider"); //$NON-NLS-1$
if(cls == null || cls.length() == 0) return null;
try {
AccessibleJava.IContextPackageProvider o = (AccessibleJava.IContextPackageProvider)ModelFeatureFactory.getInstance().createFeatureInstance(cls);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListSelectionFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListSelectionFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListSelectionFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -107,7 +107,7 @@
}
listViewer.setInput(this);
if(valueProvider != null) {
- String v = ("" + valueProvider.getValue()).toString();
+ String v = ("" + valueProvider.getValue()).toString(); //$NON-NLS-1$
listViewer.setSelection(new StructuredSelection(v));
}
listViewer.addSelectionChangedListener(new ISelectionChangedListener() {
@@ -233,7 +233,7 @@
protected void valueChanged() {
setPresentsDefaultValue(false);
- String oldValue = "";
+ String oldValue = ""; //$NON-NLS-1$
String newValue = getSelection();
this.valueProvider.removeValueChangeListener(this);
java.beans.PropertyChangeEvent event = new java.beans.PropertyChangeEvent(this, IPropertyEditor.VALUE, oldValue, newValue);
@@ -243,8 +243,8 @@
String getSelection() {
ISelection s = listViewer.getSelection();
- if(s == null || s.isEmpty()) return "";
- if(!(s instanceof StructuredSelection)) return "";
+ if(s == null || s.isEmpty()) return ""; //$NON-NLS-1$
+ if(!(s instanceof StructuredSelection)) return ""; //$NON-NLS-1$
return ((StructuredSelection)s).getFirstElement().toString();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListStructuredFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListStructuredFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/ListStructuredFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -120,10 +120,10 @@
}
private void createButtons(Composite parent) {
- buttons[ADD] = createButton(parent, "ListEditor.add");
- buttons[REMOVE] = createButton(parent, "ListEditor.remove");
- buttons[UP] = createButton(parent, "ListEditor.up");
- buttons[DOWN] = createButton(parent, "ListEditor.down");
+ buttons[ADD] = createButton(parent, "ListEditor.add"); //$NON-NLS-1$
+ buttons[REMOVE] = createButton(parent, "ListEditor.remove"); //$NON-NLS-1$
+ buttons[UP] = createButton(parent, "ListEditor.up"); //$NON-NLS-1$
+ buttons[DOWN] = createButton(parent, "ListEditor.down"); //$NON-NLS-1$
}
private Button createButton(Composite parent, String key) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MultipleChoiceFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MultipleChoiceFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MultipleChoiceFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -172,7 +172,7 @@
DefaultValueAdapter a = (DefaultValueAdapter)propertyEditor.getInput();
a.load();
String newValue = (String)valueProvider.getValue();
- valueProvider.setValue("");
+ valueProvider.setValue(""); //$NON-NLS-1$
resetChoices();
valueProvider.setValue(newValue);
}
@@ -211,8 +211,8 @@
ess.add(es[i]);
}
String value = (String)valueProvider.getValue();
- if(value == null) value = "";
- StringTokenizer st = new StringTokenizer(value, ",;");
+ if(value == null) value = ""; //$NON-NLS-1$
+ StringTokenizer st = new StringTokenizer(value, ",;"); //$NON-NLS-1$
String[] vs = new String[st.countTokens()];
Set<String> vss = new HashSet<String>();
for (int i = 0; i < vs.length; i++) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableComboBoxFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableComboBoxFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableComboBoxFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -110,12 +110,12 @@
protected Button getChangeControl(Composite parent) {
if (changeButton == null) {
- int style = getSettings().getStyle("Button.Style");
+ int style = getSettings().getStyle("Button.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
if (style==0) style = SWT.PUSH;
- Color bg = getSettings().getColor("Button.Background");
- Color fg = getSettings().getColor("Button.Foreground");
- Font font = getSettings().getFont("Button.Font");
+ Color bg = getSettings().getColor("Button.Background"); //$NON-NLS-1$
+ Color fg = getSettings().getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Button.Font"); //$NON-NLS-1$
changeButton = new Button(parent, style);
changeButton.setFont(font);
changeButton.setBackground(bg);
@@ -189,10 +189,10 @@
protected String changePressed() {
if(change == null) return null;
Properties p = new Properties();
- p.put("shell", changeButton.getShell());
+ p.put("shell", changeButton.getShell()); //$NON-NLS-1$
change.setObject(p);
int i = change.execute();
if(i != 0) return null;
- return p.getProperty("value");
+ return p.getProperty("value"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/NoteFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/NoteFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/NoteFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -179,13 +179,13 @@
}
public Text createTextControl(Composite parent) {
if (textField == null) {
- int style = getSettings().getStyle("Note.Style");
+ int style = getSettings().getStyle("Note.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
- Color bg = getSettings().getColor("Note.Background");
- Color fg = getSettings().getColor("Note.Foreground");
- Font font = getSettings().getFont("Note.Font");
- Border border = getSettings().getBorder("Note.Border");
- this.validateStrategy = getSettings().getInt("Note.ValidateStrategy");
+ Color bg = getSettings().getColor("Note.Background"); //$NON-NLS-1$
+ Color fg = getSettings().getColor("Note.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Note.Font"); //$NON-NLS-1$
+ Border border = getSettings().getBorder("Note.Border"); //$NON-NLS-1$
+ this.validateStrategy = getSettings().getInt("Note.ValidateStrategy"); //$NON-NLS-1$
if (validateStrategy==SWT.DEFAULT) validateStrategy = VALIDATE_ON_KEY_STROKE;
boolean b = isAlwaysReadOnly();
if (border != null) {
@@ -200,7 +200,7 @@
textField.getAccessible();
if(propertyEditor.getInput() instanceof DefaultValueAdapter) {
DefaultValueAdapter a = (DefaultValueAdapter)propertyEditor.getInput();
- String s = (a.getAttribute() == null) ? null : a.getAttribute().getProperty("font");
+ String s = (a.getAttribute() == null) ? null : a.getAttribute().getProperty("font"); //$NON-NLS-1$
if(s != null) {
Font oldFont = textField.getFont();
FontData data = oldFont.getFontData()[0];
@@ -356,7 +356,7 @@
String newValue = getTextFieldValue();
if (!newValue.equals(oldValue)) {
fireValueChanged(VALUE, oldValue, newValue);
- PropertyChangeEvent event = new PropertyChangeEvent(this, "value", oldValue, newValue);
+ PropertyChangeEvent event = new PropertyChangeEvent(this, "value", oldValue, newValue); //$NON-NLS-1$
valueChangeListener.valueChange(event);
oldValue = newValue;
}
@@ -471,7 +471,7 @@
}
if(o == null) return false;
String entity = o.getModelEntity().getName();
- if(entity.indexOf("Jar") >= 0) return true;
+ if(entity.indexOf("Jar") >= 0) return true; //$NON-NLS-1$
}
return false;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/PropertyEditorFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/PropertyEditorFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/PropertyEditorFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,7 +26,7 @@
import org.jboss.tools.common.model.ui.widgets.IWidgetSettings;
public class PropertyEditorFactory {
- public static final String ATTRIBUTE_EDITOR_EXT_POINT = "org.jboss.tools.common.model.ui.attributeEditor";
+ public static final String ATTRIBUTE_EDITOR_EXT_POINT = "org.jboss.tools.common.model.ui.attributeEditor"; //$NON-NLS-1$
private static Map<String,Class<?>> classes = new HashMap<String,Class<?>>();
private static IWidgetSettings settings = new DefaultSettings();
@@ -68,12 +68,12 @@
}
String labelText = WizardKeys.getAttributeDisplayName(attribute, true);
String editorName = attribute.getEditor().getName();
- if(!"CheckBox".equals(editorName) && !"ListRadio".equals(editorName)) {
+ if(!"CheckBox".equals(editorName) && !"ListRadio".equals(editorName)) { //$NON-NLS-1$ //$NON-NLS-2$
//Note: If later there appear more cases of editors that do not need ':'
//it will be better to add a property to extension point for field editors.
- labelText += ":";
+ labelText += ":"; //$NON-NLS-1$
}
- if(required) labelText += "*";
+ if(required) labelText += "*"; //$NON-NLS-1$
propertyEditor.setLabelText(labelText);
propertyEditor.setInput(adapter);
@@ -95,7 +95,7 @@
} catch (CoreException e) {
if(!defaultEditorIds.contains(id)) {
defaultEditorIds.add(id);
- ModelUIPlugin.getPluginLog().logInfo("PropertyEditorFactory: Default editor used for " + id);
+ ModelUIPlugin.getPluginLog().logInfo("PropertyEditorFactory: Default editor used for " + id); //$NON-NLS-1$
}
}
classes.put(id, c);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/RadioArrayFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/RadioArrayFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/RadioArrayFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
ILabelProvider labelProvider;
IListContentProvider listContentProvider;
- private String stringValue = "";
+ private String stringValue = ""; //$NON-NLS-1$
private boolean isValid;
private Composite panel;
private Button[] radioButtons;
@@ -100,7 +100,7 @@
Color fg = getSettings().getColor("Combo.Foreground");
Font font = getSettings().getFont("Combo.Font");
*/
- Border border = getSettings().getBorder("Combo.Border");
+ Border border = getSettings().getBorder("Combo.Border"); //$NON-NLS-1$
boolean makeGroup = makeGroup();
if (border!=null) {
BorderedControl borderedControl = new BorderedControl(parent, SWT.NONE, border);
@@ -151,7 +151,7 @@
Object input = propertyEditor.getInput();
if(input instanceof DefaultValueAdapter) {
DefaultValueAdapter adapter = (DefaultValueAdapter)input;
- return "true".equals(adapter.getAttribute().getProperty("border"));
+ return "true".equals(adapter.getAttribute().getProperty("border")); //$NON-NLS-1$ //$NON-NLS-2$
}
return false;
}
@@ -232,7 +232,7 @@
if (IPropertyEditor.VALUE.equals(evt.getPropertyName())) {
Object v = evt.getNewValue();
valueProvider.removeValueChangeListener(this);
- this.setStringValue((v == null) ? "" : v.toString());
+ this.setStringValue((v == null) ? "" : v.toString()); //$NON-NLS-1$
valueProvider.addValueChangeListener(this);
}
if (IPropertyEditor.LIST_CONTENT.equals(evt.getPropertyName())) {
@@ -286,11 +286,11 @@
}
private String getSelectedValue() {
- if(radioButtons == null) return "";
+ if(radioButtons == null) return ""; //$NON-NLS-1$
for (int i = 0; i < radioButtons.length; i++) {
if(radioButtons[i].getSelection()) return tags[i];
}
- return "";
+ return ""; //$NON-NLS-1$
}
private void setSelectedValue(String v) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/SliderFieldEditor2.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/SliderFieldEditor2.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/SliderFieldEditor2.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -219,7 +219,7 @@
* Initialize slider presentation
*/
slider.setSelection(intValue);
- String weightsString = "" + (intValue /10) + "%"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ String weightsString = "" + (intValue /10) + "%"; //$NON-NLS-1$ //$NON-NLS-2$
slider.setToolTipText(weightsString);
sliderLabel.setText(weightsString);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -60,12 +60,12 @@
checkParent(button, parent);
return button;
}
- int style = getSettings().getStyle("Button.Style");
+ int style = getSettings().getStyle("Button.Style"); //$NON-NLS-1$
if (style == SWT.DEFAULT) style = SWT.NONE;
if (style == 0) style = SWT.PUSH;
/// Color bg = getSettings().getColor("Button.Background");
- Color fg = getSettings().getColor("Button.Foreground");
- Font font = getSettings().getFont("Button.Font");
+ Color fg = getSettings().getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Button.Font"); //$NON-NLS-1$
button = new Button(parent, style);
button.setFont(font);
/// button.setBackground(bg);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringButtonFieldEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -12,17 +12,16 @@
import java.beans.PropertyChangeListener;
import java.beans.PropertyChangeSupport;
+import java.text.MessageFormat;
import org.jboss.tools.common.model.ui.IAttributeErrorProvider;
import org.jboss.tools.common.model.ui.IValueChangeListener;
import org.jboss.tools.common.model.ui.IValueProvider;
import org.jboss.tools.common.model.ui.attribute.AttributeContentProposalProviderFactory;
import org.jboss.tools.common.model.ui.attribute.adapter.DefaultValueAdapter;
-import org.eclipse.jdt.internal.ui.refactoring.contentassist.ControlContentAssistHelper;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.jface.util.PropertyChangeEvent;
import org.eclipse.swt.SWT;
@@ -91,14 +90,14 @@
Font font;
Cursor cursor;
if (getLabelAction()!=null) {
- style = getSettings().getStyle("Hyperlink.Style");
+ style = getSettings().getStyle("Hyperlink.Style"); //$NON-NLS-1$
/// bg = parent.getBackground();
///getSettings().getColor("Hyperlink.Background");
- fg = getSettings().getColor("Hyperlink.Foreground");
- disabled = getSettings().getColor("Hyperlink.Disabled");
- activeColor = getSettings().getColor("Hyperlink.ActiveColor");
- font = getSettings().getFont("Hyperlink.Font");
- cursor = getSettings().getCursor("Hyperlink.ActiveCursor");
+ fg = getSettings().getColor("Hyperlink.Foreground"); //$NON-NLS-1$
+ disabled = getSettings().getColor("Hyperlink.Disabled"); //$NON-NLS-1$
+ activeColor = getSettings().getColor("Hyperlink.ActiveColor"); //$NON-NLS-1$
+ font = getSettings().getFont("Hyperlink.Font"); //$NON-NLS-1$
+ cursor = getSettings().getCursor("Hyperlink.ActiveCursor"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
SelectableFormLabel selectableLabel = new SelectableFormLabel(parent, style);
@@ -136,12 +135,12 @@
// by default
getLabelAction().setEnabled(Boolean.FALSE.booleanValue());
} else {
- style = getSettings().getStyle("Label.Style");
+ style = getSettings().getStyle("Label.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
/// bg = parent.getBackground();
///getSettings().getColor("Label.Background");
- fg = getSettings().getColor("Label.Foreground");
- font = getSettings().getFont("Label.Font");
+ fg = getSettings().getColor("Label.Foreground"); //$NON-NLS-1$
+ font = getSettings().getFont("Label.Font"); //$NON-NLS-1$
label = new Label(parent, style);
label.setFont(font);
@@ -210,14 +209,14 @@
//editorDialog.create();
//ExtendedFieldEditor fieldEditor = propertyEditor.getFieldEditor(null);
DefaultValueAdapter adapter = (DefaultValueAdapter)propertyEditor.getInput();
- String title = "Edit " + propertyEditor.getAttributeName();
+ String title = MessageFormat.format("Edit {0}", propertyEditor.getAttributeName());
if(adapter != null && adapter.getAttribute() != null) {
- String key = "" + adapter.getAttribute().getModelEntity().getName() + "." + adapter.getAttribute().getName().replace(' ', '_') + ".edit";
+ String key = "" + adapter.getAttribute().getModelEntity().getName() + "." + adapter.getAttribute().getName().replace(' ', '_') + ".edit"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
String t = WizardKeys.getLabelText(key);
if(t != null) {
title = t;
} else {
- title = "Edit " + WizardKeys.getAttributeDisplayName(adapter.getAttribute(), true);
+ title = MessageFormat.format("Edit {0}", WizardKeys.getAttributeDisplayName(adapter.getAttribute(), true));
}
}
editorDialog.create();
@@ -234,7 +233,7 @@
} else {
java.beans.PropertyChangeEvent event = new java.beans.PropertyChangeEvent(this, BUTTON_SELECTED, Boolean.TRUE, Boolean.FALSE);
firePropertyChange(event);
- return "";
+ return ""; //$NON-NLS-1$
}
}
@@ -326,7 +325,7 @@
if (IPropertyEditor.VALUE.equals(evt.getPropertyName())) {
Object v = evt.getNewValue();
valueProvider.removeValueChangeListener(this);
- this.setStringValue((v == null) ? "" : v.toString());
+ this.setStringValue((v == null) ? "" : v.toString()); //$NON-NLS-1$
valueProvider.addValueChangeListener(this);
}
}
@@ -379,7 +378,7 @@
}
if(o == null) return false;
String entity = o.getModelEntity().getName();
- if(entity.indexOf("Jar") >= 0) return true;
+ if(entity.indexOf("Jar") >= 0) return true; //$NON-NLS-1$
}
return false;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,12 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.attribute.editor;
-import java.util.ArrayList;
-import org.eclipse.jface.fieldassist.ContentProposalAdapter;
-import org.eclipse.jface.fieldassist.IContentProposal;
-import org.eclipse.jface.fieldassist.IContentProposalProvider;
-import org.eclipse.jface.fieldassist.TextContentAdapter;
import org.eclipse.jface.util.Assert;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.DisposeEvent;
@@ -154,12 +149,12 @@
///do not restore this assignment! glory
///textControl = textField;
if (textField == null) {
- int style = getSettings().getStyle("Text.Style");
+ int style = getSettings().getStyle("Text.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
/// Color bg = getSettings().getColor("Text.Background");
- Color fg = getSettings().getColor("Text.Foreground");
- Font font = getSettings().getFont("Text.Font");
- Border border = getSettings().getBorder("Text.Border");
+ Color fg = getSettings().getColor("Text.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Text.Font"); //$NON-NLS-1$
+ Border border = getSettings().getBorder("Text.Border"); //$NON-NLS-1$
boolean readOnly = isAlwaysReadOnly();
if (border != null) {
if(readOnly) style |= SWT.READ_ONLY;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditorEx.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditorEx.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringFieldEditorEx.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -85,7 +85,7 @@
valueProvider.removeValueChangeListener(this);
if (IPropertyEditor.VALUE.equals(evt.getPropertyName())) {
Object v = evt.getNewValue();
- this.setStringValue((v == null) ? "" : v.toString());
+ this.setStringValue((v == null) ? "" : v.toString()); //$NON-NLS-1$
}
valueProvider.addValueChangeListener(this);
}
@@ -119,7 +119,7 @@
}
if(o == null) return false;
String entity = o.getModelEntity().getName();
- if(entity.indexOf("Jar") >= 0) return true;
+ if(entity.indexOf("Jar") >= 0) return true; //$NON-NLS-1$
}
return false;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringTwoButtonFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringTwoButtonFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/StringTwoButtonFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -90,7 +90,7 @@
if ((this.buttonLabels!=null)&&(buttonLabels.length>1)) {
buttonLabel = buttonLabels[0];
} else {
- buttonLabel = JFaceResources.getString("openBrowse");
+ buttonLabel = JFaceResources.getString("openBrowse"); //$NON-NLS-1$
}
button1.setText(buttonLabel);
return button1;
@@ -98,12 +98,12 @@
protected Control getChange2Control(Composite parent) {
if (button2 == null) {
- int style = getSettings().getStyle("Button.Style");
+ int style = getSettings().getStyle("Button.Style"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
if (style==0) style = SWT.PUSH;
- Color bg = getSettings().getColor("Button.Background");
- Color fg = getSettings().getColor("Button.Foreground");
- Font font = getSettings().getFont("Button.Font");
+ Color bg = getSettings().getColor("Button.Background"); //$NON-NLS-1$
+ Color fg = getSettings().getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Button.Font"); //$NON-NLS-1$
button2 = new Button(parent, style);
button2.setFont(font);
button2.setBackground(bg);
@@ -116,7 +116,7 @@
if ((this.buttonLabels!=null)&&(buttonLabels.length>1)) {
buttonLabel = buttonLabels[1];
} else {
- buttonLabel = JFaceResources.getString("open");
+ buttonLabel = JFaceResources.getString("open"); //$NON-NLS-1$
}
button2.setText(buttonLabel);
button2.setFont(parent.getFont());
@@ -188,7 +188,7 @@
// initialize
if (this.valueProvider!=null) {
- getTextField().setText(""+valueProvider.getValue());
+ getTextField().setText(""+valueProvider.getValue()); //$NON-NLS-1$
}
return composite;
@@ -212,7 +212,7 @@
if (IPropertyEditor.VALUE.equals(evt.getPropertyName())) {
Object v = evt.getNewValue();
valueProvider.removeValueChangeListener(this);
- this.setStringValue((v == null) ? "" : v.toString());
+ this.setStringValue((v == null) ? "" : v.toString()); //$NON-NLS-1$
valueProvider.addValueChangeListener(this);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,12 +18,12 @@
public class TableStructuredEditor extends StructuredEditor {
- public static final String ADD_ACTION = "ADD_ACTION";
- public static final String REMOVE_ACTION = "REMOVE_ACTION";
- public static final String EDIT_ACTION = "EDIT_ACTION";
- public static final String UP_ACTION = "UP_ACTION";
- public static final String DOWN_ACTION = "DOWN_ACTION";
- public static final String DOUBLE_CLICK__ACTION = "DOUBLE_CLICK__ACTION";
+ public static final String ADD_ACTION = "ADD_ACTION"; //$NON-NLS-1$
+ public static final String REMOVE_ACTION = "REMOVE_ACTION"; //$NON-NLS-1$
+ public static final String EDIT_ACTION = "EDIT_ACTION"; //$NON-NLS-1$
+ public static final String UP_ACTION = "UP_ACTION"; //$NON-NLS-1$
+ public static final String DOWN_ACTION = "DOWN_ACTION"; //$NON-NLS-1$
+ public static final String DOUBLE_CLICK__ACTION = "DOUBLE_CLICK__ACTION"; //$NON-NLS-1$
protected DialogCellEditorEx cellEditor;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TableStructuredFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,7 +17,6 @@
import org.jboss.tools.common.model.ui.IListEditor;
import org.jboss.tools.common.model.ui.IStructuredChangeListener;
import org.jboss.tools.common.model.ui.IStructuredEditor;
-import org.jboss.tools.common.model.ui.ModelUIPlugin;
import org.jboss.tools.common.model.ui.StructuredChangedEvent;
import org.jboss.tools.common.model.ui.attribute.IListContentProvider;
import org.jboss.tools.common.model.ui.attribute.adapter.ITableAdapter;
@@ -133,9 +132,9 @@
protected void applyButtonSkin(Control button) {
if (button!=null) {
- Color bg = getSettings().getColor("Button.Background");
- Color fg = getSettings().getColor("Button.Foreground");
- Font font = getSettings().getFont("Button.Font");
+ Color bg = getSettings().getColor("Button.Background"); //$NON-NLS-1$
+ Color fg = getSettings().getColor("Button.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Button.Font"); //$NON-NLS-1$
button.setBackground(bg);
button.setForeground(fg);
@@ -163,11 +162,11 @@
public Control createTableControl(Composite parent) {
if (tableField == null) {
- int style = getSettings().getStyle("Table.Style");
- Color bg = getSettings().getColor("Table.Background");
- Color fg = getSettings().getColor("Table.Foreground");
- Font font = getSettings().getFont("Table.Font");
- Border border = getSettings().getBorder("Table.Border");
+ int style = getSettings().getStyle("Table.Style"); //$NON-NLS-1$
+ Color bg = getSettings().getColor("Table.Background"); //$NON-NLS-1$
+ Color fg = getSettings().getColor("Table.Foreground"); //$NON-NLS-1$
+ Font font = getSettings().getFont("Table.Font"); //$NON-NLS-1$
+ Border border = getSettings().getBorder("Table.Border"); //$NON-NLS-1$
if (style==SWT.DEFAULT) style = SWT.NONE;
if (border!=null) {
@@ -283,7 +282,7 @@
// table
control = createTableControl(tableButtonsControl);
if(tableField.getColumnCount() == 1) {
- l.setText("" + tableField.getColumn(0).getText());
+ l.setText("" + tableField.getColumn(0).getText()); //$NON-NLS-1$
} else {
l.dispose();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -52,7 +52,7 @@
}
public String getChangeButtonName() {
- return JFaceResources.getString("openBrowse");
+ return JFaceResources.getString("openBrowse"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/TreeSelectionFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -113,7 +113,7 @@
// getter and setter for style
public int getStyle() {
if (this.style!=SWT.DEFAULT) return style;
- return getSettings().getStyle("Table.Style");
+ return getSettings().getStyle("Table.Style"); //$NON-NLS-1$
}
public void setStyle(int i) {
style = i;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/ErrorDialog.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/ErrorDialog.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/ErrorDialog.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -130,7 +130,7 @@
}
private String createProblemText() {
- String problem = exception == null ? "" : ProblemReporter.throwableToString(message, exception);
+ String problem = exception == null ? "" : ProblemReporter.throwableToString(message, exception); //$NON-NLS-1$
return wrapProblem(problem);
}
@@ -139,7 +139,7 @@
// sb.append(getEnvironment()).append("\n");
sb.append("------Type your additional comment here--------\n\n");
- sb.append("-----------------------------------------------\n");
+ sb.append("-----------------------------------------------\n"); //$NON-NLS-1$
sb.append(problem);
return sb.toString();
}
@@ -170,8 +170,8 @@
protected void okPressed() {
if(getAwayButton.getSelection()) {
try {
- ReportPreference.SHOW_ERROR_DIALOG_OPTION.setValue("no");
- ReportPreference.SUBMIT_AUTOMATICALLY_OPTION.setValue("yes");
+ ReportPreference.SHOW_ERROR_DIALOG_OPTION.setValue("no"); //$NON-NLS-1$
+ ReportPreference.SUBMIT_AUTOMATICALLY_OPTION.setValue("yes"); //$NON-NLS-1$
} catch (XModelException e) {
ModelPlugin.getPluginLog().logError(e);
}
@@ -183,7 +183,7 @@
protected void cancelPressed() {
if(getAwayButton.getSelection()) {
try {
- ReportPreference.SHOW_ERROR_DIALOG_OPTION.setValue("no");
+ ReportPreference.SHOW_ERROR_DIALOG_OPTION.setValue("no"); //$NON-NLS-1$
} catch (XModelException e) {
ModelPlugin.getPluginLog().logError(e);
}
@@ -194,7 +194,7 @@
private void submit() {
String email = ReportPreference.E_MAIL_OPTION.getValue();
String other = ReportPreference.OTHER_OPTION.getValue();
- String text = "" + getEnvironment() + "\n" + problemText;
+ String text = "" + getEnvironment() + "\n" + problemText; //$NON-NLS-1$//$NON-NLS-2$
ProblemReportingHelper.buffer.report(text, email, other, false);
}
@@ -219,7 +219,7 @@
}
public static int openError(Shell shell, Throwable exception) {
- ErrorDialog dialog = new ErrorDialog(shell, WizardKeys.getString("ErrorDialog.DefaultWindowTitle"), exception);
+ ErrorDialog dialog = new ErrorDialog(shell, WizardKeys.getString("ErrorDialog.DefaultWindowTitle"), exception); //$NON-NLS-1$
return dialog.open();
}
@@ -233,7 +233,7 @@
}
public static int openError(Shell shell, String message) {
- ErrorDialog dialog = new ErrorDialog(shell, WizardKeys.getString("ErrorDialog.DefaultWindowTitle"), message, null);
+ ErrorDialog dialog = new ErrorDialog(shell, WizardKeys.getString("ErrorDialog.DefaultWindowTitle"), message, null); //$NON-NLS-1$
return dialog.open();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/MessageAndCheckboxDialog.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/MessageAndCheckboxDialog.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/MessageAndCheckboxDialog.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
public static String CHECKED = ServiceDialog.CHECKED;
public static String BUTTONS = ServiceDialog.BUTTONS;
public static String SEPARATOR = ServiceDialog.SEPARATOR;
- public static String TITLE = "title";
+ public static String TITLE = "title"; //$NON-NLS-1$
public static String RETURN_CODE = ServiceDialog.RETURN_CODE;
Button button;
Button[] buttons = new Button[0];
@@ -52,10 +52,10 @@
public static boolean openConfirm(Shell parent, Properties p) {
Assert.isNotNull(p);
- Assert.isNotNull(p.getProperty(MESSAGE), "Property " + MESSAGE + " is null");
- Assert.isNotNull(p.getProperty(CHECKBOX_MESSAGE), "Property " + CHECKBOX_MESSAGE + " is null");
- Assert.isTrue(p.get(CHECKED) instanceof Boolean, "Property " + CHECKED + " must have type Boolean");
- String title = p.getProperty("title", "Confirmation");
+ Assert.isNotNull(p.getProperty(MESSAGE), "Property " + MESSAGE + " is null"); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.isNotNull(p.getProperty(CHECKBOX_MESSAGE), "Property " + CHECKBOX_MESSAGE + " is null"); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.isTrue(p.get(CHECKED) instanceof Boolean, "Property " + CHECKED + " must have type Boolean"); //$NON-NLS-1$ //$NON-NLS-2$
+ String title = p.getProperty("title", "Confirmation"); //$NON-NLS-1$
MessageAndCheckboxDialog dialog = new MessageAndCheckboxDialog(parent, title, QUESTION, p);
int result = dialog.open();
p.put(RETURN_CODE, Integer.valueOf(result));
@@ -63,8 +63,8 @@
}
protected Control createCustomArea(Composite parent) {
- String b1 = properties.getProperty(CHECKBOX_MESSAGE + "_1");
- if(b1 == null) return button = createCheckBox(parent, "");
+ String b1 = properties.getProperty(CHECKBOX_MESSAGE + "_1"); //$NON-NLS-1$
+ if(b1 == null) return button = createCheckBox(parent, ""); //$NON-NLS-1$
return createMultiCheckBox(parent);
}
@@ -86,11 +86,11 @@
l.marginWidth = 0;
l.marginHeight = 11;
c.setLayout(l);
- button = createCheckBox(c, "");
+ button = createCheckBox(c, ""); //$NON-NLS-1$
ArrayList<Button> list = new ArrayList<Button>();
int i = 1;
while(true) {
- String suffix = "_" + i;
+ String suffix = "_" + i; //$NON-NLS-1$
if(properties.getProperty(CHECKBOX_MESSAGE + suffix) == null) break;
if(properties.getProperty(SEPARATOR + suffix) != null) {
// actually here we should only call
@@ -128,7 +128,7 @@
protected void buttonPressed(int buttonId) {
properties.put(CHECKED, Boolean.valueOf(button.getSelection()));
for (int i = 0; i < buttons.length; i++) {
- properties.put(CHECKED + "_" + (i + 1), Boolean.valueOf(buttons[i].getSelection()));
+ properties.put(CHECKED + "_" + (i + 1), Boolean.valueOf(buttons[i].getSelection())); //$NON-NLS-1$
}
super.buttonPressed(buttonId);
}
@@ -155,7 +155,7 @@
composite.setLayout(l);
GridData data = new GridData(GridData.VERTICAL_ALIGN_CENTER | GridData.FILL_HORIZONTAL);
composite.setLayoutData(data);
- Button b = createCheckBox(composite, "_" + lastButton);
+ Button b = createCheckBox(composite, "_" + lastButton); //$NON-NLS-1$
b.setLayoutData(new GridData());
Button[] bs = new Button[buttons.length + 1];
System.arraycopy(buttons, 0, bs, 0, buttons.length);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/SelectEclipseFileWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/SelectEclipseFileWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialog/SelectEclipseFileWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.dialog;
+import java.text.MessageFormat;
import java.util.*;
import java.util.List;
import org.eclipse.core.resources.*;
@@ -39,27 +40,27 @@
}
public int execute() {
- String[] extensions = getExtensions(p.getProperty("extension"));
+ String[] extensions = getExtensions(p.getProperty("extension")); //$NON-NLS-1$
FSDialog d = new FSDialog(
ServiceDialogImpl.getShell(),
- (IResource)p.get("root"),
+ (IResource)p.get("root"), //$NON-NLS-1$
new ArrayList(),
"Select File",
- p.getProperty("message"),
+ p.getProperty("message"), //$NON-NLS-1$
extensions,
getFilterName(extensions),
- p.getProperty("selection"));
+ p.getProperty("selection")); //$NON-NLS-1$
if(d.open() != FSDialog.OK) return 1;
Object result = d.getFirstResult();
- if(result != null) p.put("result", result);
+ if(result != null) p.put("result", result); //$NON-NLS-1$
return 0;
}
String[] getExtensions(String extension) {
- if(extension == null || extension.length() == 0 || extension.equals("*")) return null;
- StringTokenizer st = new StringTokenizer(extension, ",;");
+ if(extension == null || extension.length() == 0 || extension.equals("*")) return null; //$NON-NLS-1$
+ StringTokenizer st = new StringTokenizer(extension, ",;"); //$NON-NLS-1$
String[] r = new String[st.countTokens()];
for (int i = 0; i < r.length; i++) {
r[i] = st.nextToken().trim();
@@ -70,10 +71,10 @@
if(extensions == null) return null;
StringBuffer sb = new StringBuffer();
for (int i = 0; i < extensions.length; i++) {
- if(sb.length() > 0) sb.append(", ");
- sb.append("*.").append(extensions[i]);
+ if(sb.length() > 0) sb.append(", "); //$NON-NLS-1$
+ sb.append("*.").append(extensions[i]); //$NON-NLS-1$
}
- return "Show only " + sb.toString() + " files";
+ return MessageFormat.format("Show only {0} files", sb.toString());
}
}
@@ -100,13 +101,13 @@
return new ISelectionStatusValidator() {
public IStatus validate(Object[] os) {
if (os.length == 0) {
- return new Status(IStatus.ERROR, "org.jboss.tools.common.model.ui", 0, "", null); //$NON-NLS-1$
+ return new Status(IStatus.ERROR, "org.jboss.tools.common.model.ui", 0, "", null); //$NON-NLS-1$ //$NON-NLS-2$
}
for (int i = 0; i < os.length; i++) {
if (os[i] instanceof IFile) continue;
- return new Status(IStatus.ERROR, "org.jboss.tools.common.model.ui", 0, "", null); //$NON-NLS-1$
+ return new Status(IStatus.ERROR, "org.jboss.tools.common.model.ui", 0, "", null); //$NON-NLS-1$ //$NON-NLS-2$
}
- return new Status(IStatus.OK, "org.jboss.tools.common.model.ui", 0, "", null); //$NON-NLS-1$
+ return new Status(IStatus.OK, "org.jboss.tools.common.model.ui", 0, "", null); //$NON-NLS-1$ //$NON-NLS-2$
}
};
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialogs/PageDialog.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialogs/PageDialog.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dialogs/PageDialog.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -93,7 +93,7 @@
private void updateWindowTitle() {
if (getShell() == null) return;
- if (windowTitle == null) windowTitle = "";
+ if (windowTitle == null) windowTitle = ""; //$NON-NLS-1$
getShell().setText(windowTitle);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ControlDragDrop.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ControlDragDrop.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ControlDragDrop.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,8 +32,8 @@
static {
try {
- if(Platform.getBundle("org.jboss.tools.jst.web") != null) {
- paletteAdopt = (XAdoptManager)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.web.tld.model.handlers.JSPAdopt");
+ if(Platform.getBundle("org.jboss.tools.jst.web") != null) { //$NON-NLS-1$
+ paletteAdopt = (XAdoptManager)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.web.tld.model.handlers.JSPAdopt"); //$NON-NLS-1$
}
} catch (ClassCastException e) {
ModelUIPlugin.getPluginLog().logError(e);
@@ -81,7 +81,7 @@
}
public void enableDrop() {
- DropTarget old = (DropTarget)getControl().getData("DropTarget");
+ DropTarget old = (DropTarget)getControl().getData("DropTarget"); //$NON-NLS-1$
if(old != null) {
old.setTransfer(new Transfer[]{ModelTransfer.getInstance(), TextTransfer.getInstance()});
old.addDropListener(new DTL());
@@ -111,10 +111,10 @@
if (ModelTransfer.getInstance().isSupportedType(event.dataType)) {
XModelObject o = getLeadSelection();
/// event.data = (o == null) ? new String[0] : new String[]{o.getPresentationString()};
- event.data = (o == null) ? "" : o.getPresentationString();
+ event.data = (o == null) ? "" : o.getPresentationString(); //$NON-NLS-1$
} else if(TextTransfer.getInstance().isSupportedType(event.dataType)) {
XModelObject o = getLeadSelection();
- event.data = (o == null) ? "" : o.getPresentationString();
+ event.data = (o == null) ? "" : o.getPresentationString(); //$NON-NLS-1$
}
}
public void dragFinished(DragSourceEvent event) {
@@ -276,10 +276,10 @@
isTextDrop = false;
isPaletteDrop = false;
Properties p = provider.getDropProperties(event.x, event.y);
- if(p != null && ("none".equals(p.getProperty("text-context")))) {
+ if(p != null && ("none".equals(p.getProperty("text-context")))) { //$NON-NLS-1$ //$NON-NLS-2$
enabled = false;
} else if(!enabled && o.isObjectEditable()) {
- if(p != null && "true".equals(p.getProperty("accepsAsString"))) {
+ if(p != null && "true".equals(p.getProperty("accepsAsString"))) { //$NON-NLS-1$ //$NON-NLS-2$
if(isAdoptableMacro(o)) {
isPaletteDrop = true;
} else {
@@ -318,20 +318,20 @@
try {
Properties p = provider.getDropProperties(event.x, event.y);
if(p == null) p = new Properties();
- p.setProperty("isDrop", "true");
+ p.setProperty("isDrop", "true"); //$NON-NLS-1$ //$NON-NLS-2$
if(isTextDrop) {
XModelObject s = o.getModel().getModelBuffer().source();
if(s == null) return;
- p.put("start text", "" + s.getPresentationString());
+ p.put("start text", "" + s.getPresentationString()); //$NON-NLS-1$ //$NON-NLS-2$
} else if(isPaletteDrop) {
paletteAdopt.adopt(o, o.getModel().getModelBuffer().source(), p);
} else if(DnDUtil.isPasteEnabled(o)) {
DnDUtil.paste(o, p);
}
if(provider instanceof IControlDropListener) {
- p.put("drop.x", Integer.valueOf(event.x));
- p.put("drop.y", Integer.valueOf(event.y));
- if(draggedObject != null) p.put("draggedObject", draggedObject);
+ p.put("drop.x", Integer.valueOf(event.x)); //$NON-NLS-1$
+ p.put("drop.y", Integer.valueOf(event.y)); //$NON-NLS-1$
+ if(draggedObject != null) p.put("draggedObject", draggedObject); //$NON-NLS-1$
((IControlDropListener)provider).drop(p);
}
} catch (ActionDeclinedException ade) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ModelTransfer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ModelTransfer.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/dnd/ModelTransfer.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -15,7 +15,7 @@
import org.jboss.tools.common.model.ui.ModelUIPlugin;
public class ModelTransfer extends ByteArrayTransfer {
- public static final String MODEL = "vpe/model";
+ public static final String MODEL = "vpe/model"; //$NON-NLS-1$
public static final int MODEL_ID = registerType(MODEL);
private static ModelTransfer instance = new ModelTransfer();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/DefaultEditorPart.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/DefaultEditorPart.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/DefaultEditorPart.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -168,7 +168,7 @@
public void doOperation(int operation) {
if (operation>actionMapping.size()) {
- ModelUIPlugin.getPluginLog().logError(new IllegalArgumentException("Can not find global action with index: "+operation));
+ ModelUIPlugin.getPluginLog().logError(new IllegalArgumentException("Can not find global action with index: "+operation)); //$NON-NLS-1$
} else {
String globalAction = (String)actionMapping.get(operation);
this.doGlobalAction(globalAction);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorActionBarContributorWrapper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorActionBarContributorWrapper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorActionBarContributorWrapper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -53,7 +53,7 @@
}
IEditorActionBarContributor getContributor(String entity) {
- if(entity == null) entity = "";
+ if(entity == null) entity = ""; //$NON-NLS-1$
IEditorActionBarContributor c = (IEditorActionBarContributor)contributors.get(entity);
if(c == null) {
if(entity != null) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,9 +26,9 @@
this.editorClass = editorClass;
this.contributorClass = contributorClass;
if(!IEditorPart.class.isAssignableFrom(editorClass))
- throw new ClassCastException("Class " + editorClass + " must be instance of org.eclipse.ui.IEditorPart");
+ throw new ClassCastException("Class " + editorClass + " must be instance of org.eclipse.ui.IEditorPart"); //$NON-NLS-1$ //$NON-NLS-2$
if(!IEditorActionBarContributor.class.isAssignableFrom(contributorClass))
- throw new ClassCastException("Class " + contributorClass.getName() + " must be instance of org.eclipse.ui.IEditorActionBarContributor");
+ throw new ClassCastException("Class " + contributorClass.getName() + " must be instance of org.eclipse.ui.IEditorActionBarContributor"); //$NON-NLS-1$ //$NON-NLS-2$
editorClass.newInstance();
contributorClass.newInstance();
id = editorClass.getName();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -49,7 +49,7 @@
public class EditorPartWrapper extends EditorPart implements IReusableEditor, IEditorWrapper {
- public static final String EDITOR_ID = "org.jboss.tools.common.model.ui.editor.EditorPartWrapper";
+ public static final String EDITOR_ID = "org.jboss.tools.common.model.ui.editor.EditorPartWrapper"; //$NON-NLS-1$
IEditorPart editor;
String entity = null;
@@ -66,7 +66,7 @@
if(editor != null) {
try {
Class editorClass = editor.getClass();
- Method method = editorClass.getMethod("gotoMarker",new Class[]{IMarker.class});
+ Method method = editorClass.getMethod("gotoMarker",new Class[]{IMarker.class}); //$NON-NLS-1$
method.setAccessible(true);
method.invoke(editor,new Object[]{marker});
} catch(NoSuchMethodException e1) {
@@ -86,7 +86,7 @@
public void init(IEditorSite site, IEditorInput input) throws PartInitException {
input = XModelObjectEditorInput.checkInput(input);
if(input instanceof NullEditorInput) {
- entity = "";
+ entity = ""; //$NON-NLS-1$
editor = new NullEditorPart();
editor.init(site, input);
setSite(site);
@@ -98,7 +98,7 @@
EditorPartFactory f = extension.getFactory(entity);
editor = f.createEditorPart();
if(editor != null) {
- ((WorkbenchPart)editor).setInitializationData(f.getConfigurationElement(), "", null);
+ ((WorkbenchPart)editor).setInitializationData(f.getConfigurationElement(), "", null); //$NON-NLS-1$
}
editor.init(site, input);
setSite(site);
@@ -151,7 +151,7 @@
}
}
- static String DEFAULT_ENTITY = "xml";
+ static String DEFAULT_ENTITY = "xml"; //$NON-NLS-1$
private String computeEntity(IEditorInput input) {
if(!(input instanceof IModelObjectEditorInput)) return DEFAULT_ENTITY;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapperExtension.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapperExtension.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/EditorPartWrapperExtension.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,7 +23,7 @@
import org.osgi.framework.Bundle;
public class EditorPartWrapperExtension {
- static String POINT_ID = "org.jboss.tools.common.model.ui.xmlEditor";
+ static String POINT_ID = "org.jboss.tools.common.model.ui.xmlEditor"; //$NON-NLS-1$
static EditorPartWrapperExtension instance;
Map<String,EditorPartFactory> factories = new HashMap<String,EditorPartFactory>();
Map<String,Integer> priorities = new HashMap<String,Integer>();
@@ -47,33 +47,33 @@
IConfigurationElement[] cs = es[i].getConfigurationElements();
for (int j = 0; j < cs.length; j++) {
Bundle bundle = Platform.getBundle(es[i].getNamespaceIdentifier());
- String entities = cs[j].getAttribute("entities");
- String editor = cs[j].getAttribute("class");
- String priorityString = cs[j].getAttribute("priority");
+ String entities = cs[j].getAttribute("entities"); //$NON-NLS-1$
+ String editor = cs[j].getAttribute("class"); //$NON-NLS-1$
+ String priorityString = cs[j].getAttribute("priority"); //$NON-NLS-1$
int priority = 0;
try {
if(priorityString != null && priorityString.length() > 0) {
priority = Integer.parseInt(priorityString);
}
} catch (NumberFormatException e) {
- ModelUIPlugin.getPluginLog().logError("Incorrect priority value " + priorityString + ".");
+ ModelUIPlugin.getPluginLog().logError("Incorrect priority value " + priorityString + "."); //$NON-NLS-1$ //$NON-NLS-2$
}
Class editorClass = null;
try {
editorClass = bundle.loadClass(editor);
} catch (ClassNotFoundException e) {
if(ModelUIPlugin.getDefault().isDebugging()) {
- ModelUIPlugin.getPluginLog().logError("Cannot load editor class " + editor + " from " + es[i].getNamespaceIdentifier(), e);
+ ModelUIPlugin.getPluginLog().logError("Cannot load editor class " + editor + " from " + es[i].getNamespaceIdentifier(), e); //$NON-NLS-1$ //$NON-NLS-2$
}
continue;
}
- String contributor = cs[j].getAttribute("contributorClass");
+ String contributor = cs[j].getAttribute("contributorClass"); //$NON-NLS-1$
Class contributorClass = null;
try {
contributorClass = bundle.loadClass(contributor);
} catch (ClassNotFoundException e) {
if(ModelUIPlugin.getDefault().isDebugging()) {
- String message = "Cannot load contributor class " + contributor;
+ String message = "Cannot load contributor class " + contributor; //$NON-NLS-1$
ModelUIPlugin.getPluginLog().logError( message, e);
}
contributorClass = EditorActionBarContributor.class;
@@ -87,7 +87,7 @@
} catch (IllegalAccessException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
- StringTokenizer st = new StringTokenizer(entities, ",;");
+ StringTokenizer st = new StringTokenizer(entities, ",;"); //$NON-NLS-1$
while(st.hasMoreTokens()) {
String t = st.nextToken();
Integer p = (Integer)priorities.get(t);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectJarEntryEditorInput.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectJarEntryEditorInput.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectJarEntryEditorInput.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -43,7 +43,7 @@
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
- String s = (storage == null) ? "" : storage.toString();
+ String s = (storage == null) ? "" : storage.toString(); //$NON-NLS-1$
if(jarEntryFileToString().equals(s)) return true;
}
return super.equals(o);
@@ -51,7 +51,7 @@
//see
public String jarEntryFileToString() {
- return "JarEntryFile[" + jarFile+"::" + jarEntry+"]";
+ return "JarEntryFile[" + jarFile+"::" + jarEntry+"]"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectStorageEditorInput.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectStorageEditorInput.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/ModelObjectStorageEditorInput.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -75,8 +75,8 @@
if(jar != null) return jar.getFullPath();
}
}
- String n = p == null ? "" : p.getName();
- return new Path(n + "/" + object.getPath());
+ String n = p == null ? "" : p.getName(); //$NON-NLS-1$
+ return new Path(n + "/" + object.getPath()); //$NON-NLS-1$
}
public String getName() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/XMLContentDescriber.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/XMLContentDescriber.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editor/XMLContentDescriber.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -40,10 +40,10 @@
}
private int describe(String text, IContentDescription description) {
- String entity = PreferenceModelUtilities.getPreferenceModel().getEntityRecognizer().getEntityName("xml", text);
- if(entity == null || entity.length() == 0 || entity.equals("FileXML")
- || entity.equals("FileHibConfig3") || entity.equals("FileHibernate3")
- || entity.equals("FileANT")
+ String entity = PreferenceModelUtilities.getPreferenceModel().getEntityRecognizer().getEntityName("xml", text); //$NON-NLS-1$
+ if(entity == null || entity.length() == 0 || entity.equals("FileXML") //$NON-NLS-1$
+ || entity.equals("FileHibConfig3") || entity.equals("FileHibernate3") //$NON-NLS-1$ //$NON-NLS-2$
+ || entity.equals("FileANT") //$NON-NLS-1$
) {
return INDETERMINATE;
}
@@ -51,7 +51,7 @@
}
static String read(Reader is) {
- StringBuffer sb = new StringBuffer("");
+ StringBuffer sb = new StringBuffer(""); //$NON-NLS-1$
try {
char[] b = new char[4096];
while(true) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/AbsoluteFilePathAttributeValueLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/AbsoluteFilePathAttributeValueLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/AbsoluteFilePathAttributeValueLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -61,7 +61,7 @@
// Now it is absolute.
// TODO Eskimo - think what we have to do id dropped file is not from WEB-ROOT folder
String v = (input == null) ? null : dropFileToFile(file, input.getFile(), model);
- if(v == null) v = "/"+filePath.toString();
+ if(v == null) v = "/"+filePath.toString(); //$NON-NLS-1$
model.setAttributeValue(fPathAttributeName, v);
}
}
@@ -81,11 +81,11 @@
if(!DnDUtil.isPasteEnabled(t)) return null;
Properties p = new Properties();
String tagName = model.getTagProposal().getName();
- p.setProperty("isDrop", "true");
- if(tagName != null) p.setProperty("context:tagName", tagName);
+ p.setProperty("isDrop", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+ if(tagName != null) p.setProperty("context:tagName", tagName); //$NON-NLS-1$
DnDUtil.paste(t, p);
- return p.getProperty("start text");
+ return p.getProperty("start text"); //$NON-NLS-1$
} catch (XModelException e) {
return null;
} finally {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/CssLinkAttributeValueLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/CssLinkAttributeValueLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/CssLinkAttributeValueLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,8 +18,8 @@
public void fillTagAttributes(IDropWizardModel model) {
super.fillTagAttributes(model);
- model.setAttributeValue("rel", "stylesheet");
- model.setAttributeValue("type", "text/css");
+ model.setAttributeValue("rel", "stylesheet"); //$NON-NLS-1$ //$NON-NLS-2$
+ model.setAttributeValue("type", "text/css"); //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommand.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommand.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommand.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -62,7 +62,7 @@
*/
public void initialize() {
if(getDefaultModel().getDropData()==null) {
- throw new IllegalStateException("Wizard model isn't intialized, call setDropDataFirst");
+ throw new IllegalStateException("Wizard model isn't intialized, call setDropDataFirst"); //$NON-NLS-1$
}
TagProposal[] proposals
= TagProposalsComposite.getTagProposals(
@@ -105,7 +105,7 @@
*/
public void execute() {
if(getDefaultModel().getDropData()==null) {
- throw new IllegalStateException("Call setDndData() first");
+ throw new IllegalStateException("Call setDndData() first"); //$NON-NLS-1$
} else if(getDefaultModel().getTagProposal()!=IDropWizardModel.UNDEFINED_TAG_PROPOSAL) {
IWorkspace workspace = ResourcesPlugin.getWorkspace();
try {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommandRunner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommandRunner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropCommandRunner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -56,7 +56,7 @@
if(!(editor instanceof AbstractTextEditor)) return null;
AbstractTextEditor ae = (AbstractTextEditor)editor;
try {
- Method m = AbstractTextEditor.class.getDeclaredMethod("getSourceViewer", new Class[0]);
+ Method m = AbstractTextEditor.class.getDeclaredMethod("getSourceViewer", new Class[0]); //$NON-NLS-1$
m.setAccessible(true);
return (ISourceViewer)m.invoke(ae, new Object[0]);
} catch (NoSuchMethodException e1) {
@@ -75,9 +75,9 @@
public void setObject(Object object) {
Properties p = (Properties)object;
- flavor = p.getProperty("flavor");
- data = p.getProperty("data");
- textEditor = (ITextEditor)p.get("textEditor");
+ flavor = p.getProperty("flavor"); //$NON-NLS-1$
+ data = p.getProperty("data"); //$NON-NLS-1$
+ textEditor = (ITextEditor)p.get("textEditor"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -59,7 +59,7 @@
*
*/
public void setAttributeValue(String name, Object value) {
- if(name==null) throw new IllegalArgumentException("Attribute name cannot be null");
+ if(name==null) throw new IllegalArgumentException("Attribute name cannot be null"); //$NON-NLS-1$
AttributeDescriptorValue descrValue = null;
for (int i = 0; i < fAttributeValues.size(); i++) {
AttributeDescriptorValue arrayElement = (AttributeDescriptorValue)fAttributeValues.get(i);
@@ -67,7 +67,7 @@
descrValue = arrayElement;
}
}
- if(descrValue==null) throw new IllegalArgumentException("Attribute '" + name + "' not found");
+ if(descrValue==null) throw new IllegalArgumentException("Attribute '" + name + "' not found"); //$NON-NLS-1$ //$NON-NLS-2$
descrValue.setValue(value);
fireModelChaged(ATTRIBUTE_VALUE,null,descrValue);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultDropWizardPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -63,7 +63,7 @@
try {
validate();
setPageComplete(true);
- setMessage("",NONE);
+ setMessage("",NONE); //$NON-NLS-1$
} catch (ValidationException e) {
validationErrorOccurs(e);
setPageComplete(false);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultElementGenerator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultElementGenerator.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DefaultElementGenerator.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,7 +22,7 @@
fDataModel = (IDropWizardModel)object;
return;
}
- throw new IllegalArgumentException("Object parametr must be instance of " + this.getClass().getName());
+ throw new IllegalArgumentException("Object parametr must be instance of " + this.getClass().getName()); //$NON-NLS-1$
}
public IDropWizardModel getWizardDataModel() {
@@ -50,55 +50,55 @@
// for HTML
fullName = fullName.toLowerCase();
}
- tagText.append("<" + applayTagPreferences(fullName));
+ tagText.append("<" + applayTagPreferences(fullName)); //$NON-NLS-1$
AttributeDescriptorValue[] values = getWizardDataModel().getAttributeValueDescriptors();
for(int i=0;i<values.length;i++) {
Object value = values[i].getValue();
- if(value != null && !"".equals(value.toString().trim())) {
+ if(value != null && !"".equals(value.toString().trim())) { //$NON-NLS-1$
tagText
- .append(" ")
+ .append(" ") //$NON-NLS-1$
.append(applayAttributePreferences(values[i].getName()))
- .append("=")
- .append("\"")
+ .append("=") //$NON-NLS-1$
+ .append("\"") //$NON-NLS-1$
.append(value.toString())
- .append("\"");
+ .append("\""); //$NON-NLS-1$
}
}
if(descr.hasClosingTag()) {
if(descr.hasBody()) {
tagText
- .append(">")
- .append("</")
+ .append(">") //$NON-NLS-1$
+ .append("</") //$NON-NLS-1$
.append(fullName);
} else {
tagText
- .append("/");
+ .append("/"); //$NON-NLS-1$
}
}
tagText
- .append(">");
+ .append(">"); //$NON-NLS-1$
} else {
tagText
- .append("<");
+ .append("<"); //$NON-NLS-1$
if(getWizardDataModel().getTagProposal().getPrefix()!=null
- && !"".equals(getWizardDataModel().getTagProposal().getPrefix().trim())) {
+ && !"".equals(getWizardDataModel().getTagProposal().getPrefix().trim())) { //$NON-NLS-1$
tagText.append(getWizardDataModel().getTagProposal().getPrefix())
- .append(":");
+ .append(":"); //$NON-NLS-1$
}
tagText
.append(getWizardDataModel().getTagProposal().getName())
- .append("/>");
+ .append("/>"); //$NON-NLS-1$
}
return tagText.toString();
}
public String generateEndTag() {
- return "";
+ return ""; //$NON-NLS-1$
}
protected String applayAttributePreferences(String attribute) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropURI.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropURI.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropURI.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -12,12 +12,12 @@
public class DropURI {
- public static final String JSF_HTML_URI = "http://java.sun.com/jsf/html";
- public static final String JSF_CORE_URI = "http://java.sun.com/jsf/core";
- public static final String HTML_4_0_URI = "-//w3c//dtd html 4.0 transitional//en";
- public static final String STRUTS_HTML_URI = "http://struts.apache.org/tags-html";
- public static final String JSP_URI = "http://java.sun.com/JSP/Page";
- public static final String SEAM_URI = "http://jboss.com/products/seam/taglib";
+ public static final String JSF_HTML_URI = "http://java.sun.com/jsf/html"; //$NON-NLS-1$
+ public static final String JSF_CORE_URI = "http://java.sun.com/jsf/core"; //$NON-NLS-1$
+ public static final String HTML_4_0_URI = "-//w3c//dtd html 4.0 transitional//en"; //$NON-NLS-1$
+ public static final String STRUTS_HTML_URI = "http://struts.apache.org/tags-html"; //$NON-NLS-1$
+ public static final String JSP_URI = "http://java.sun.com/JSP/Page"; //$NON-NLS-1$
+ public static final String SEAM_URI = "http://jboss.com/products/seam/taglib"; //$NON-NLS-1$
// yradtsevich: fix of JBIDE-3984: Exclude t:graphicImage option from Insert tag dialog
// public static final String TOMOHAWK_URI = "http://myfaces.apache.org/tomahawk";
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropUtils.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropUtils.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropUtils.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -54,7 +54,7 @@
*/
public class DropUtils {
- public static final String HTML40_URI = "";
+ public static final String HTML40_URI = ""; //$NON-NLS-1$
/**
* Get TLD's content.
@@ -103,7 +103,7 @@
JspWtpKbConnector wtpKbConnector;
List attributes = null;
String tldContent = getTldContent(input, uri);
- String tldLocation = "";
+ String tldLocation = ""; //$NON-NLS-1$
try {
wtpKbConnector = (JspWtpKbConnector)KbConnectorFactory.getIntstance().createConnector(KbConnectorType.JSP_WTP_KB_CONNECTOR, document);
String version = libraryVersion;
@@ -114,7 +114,7 @@
resource.setTldContent(tldContent);
wtpKbConnector.registerResource(resource, true);
- TagDescriptor tagInfo = wtpKbConnector.getTagInformation("/"+(tagPrefix==TagProposal.EMPTY_PREFIX?"":tagPrefix+":")+tagName);
+ TagDescriptor tagInfo = wtpKbConnector.getTagInformation("/"+(tagPrefix==TagProposal.EMPTY_PREFIX?"":tagPrefix+":")+tagName); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
if(tagInfo != null) {
attributes = tagInfo.getAttributesDescriptors();
}
@@ -145,8 +145,8 @@
if(libraryVersion==null || libraryVersion.trim().length()<1) {
version = TLDVersionHelper.getTldVersion(uri, tagPrefix, document);
}
- wtpKbConnector.registerResource(new KbTldResource(uri, "", tagPrefix, version), true);
- tagInfo = wtpKbConnector.getTagInformation("/"+(tagPrefix==TagProposal.EMPTY_PREFIX?"":tagPrefix+":")+tagName);
+ wtpKbConnector.registerResource(new KbTldResource(uri, "", tagPrefix, version), true); //$NON-NLS-1$
+ tagInfo = wtpKbConnector.getTagInformation("/"+(tagPrefix==TagProposal.EMPTY_PREFIX?"":tagPrefix+":")+tagName); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
} catch (KbException ex) {
ModelUIPlugin.getPluginLog().logError(ex);
}
@@ -195,7 +195,7 @@
// TODO Eskimo - look how it can be done through WTP EMF model for flexible project
IModelNature modelNature = EclipseResourceUtil.getModelNature(project);
if(modelNature == null) return project;
- XModelObject o = modelNature.getModel().getByPath("FileSystems/WEB-ROOT");
+ XModelObject o = modelNature.getModel().getByPath("FileSystems/WEB-ROOT"); //$NON-NLS-1$
if(o != null) {
container = (IContainer)EclipseResourceUtil.getResource(o);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardDialog.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardDialog.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardDialog.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -35,8 +35,8 @@
}
protected int getPreferredWidth() {
- String os_name = System.getProperty("os.name");
- if(os_name != null && os_name.indexOf("Windows") >= 0) return DO_WIDTH_VALUE;
+ String os_name = System.getProperty("os.name"); //$NON-NLS-1$
+ if(os_name != null && os_name.indexOf("Windows") >= 0) return DO_WIDTH_VALUE; //$NON-NLS-1$
return DO_WIDTH_VALUE_LINUX;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardMessages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardMessages.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/DropWizardMessages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,6 +17,6 @@
public static String Advanced_Tab_Title;
public static String Wizard_Window_Title;
static {
- NLS.initializeMessages("org.jboss.tools.common.model.ui.editors.dnd.DropWizardMessages", DropWizardMessages.class);
+ NLS.initializeMessages("org.jboss.tools.common.model.ui.editors.dnd.DropWizardMessages", DropWizardMessages.class); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileDropCommand.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileDropCommand.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileDropCommand.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -50,7 +50,7 @@
properties.put(PaletteInsertHelper.PROPOPERTY_TAGLIBRARY_VERSION,getDefaultModel().getTagProposal().getLibraryVersion());
properties.put(PaletteInsertHelper.PROPOPERTY_DEFAULT_PREFIX,getDefaultModel().getTagProposal().getPrefix());
properties.put(PaletteInsertHelper.PROPOPERTY_SELECTION_PROVIDER, getDefaultModel().getDropData().getSelectionProvider());
- properties.put(PaletteInsertHelper.PROPOPERTY_ADD_TAGLIB, "true");
+ properties.put(PaletteInsertHelper.PROPOPERTY_ADD_TAGLIB, "true"); //$NON-NLS-1$
addCustomProperties(properties);
PaletteInsertHelper.insertIntoEditor(
getDefaultModel().getDropData().getSourceViewer(),
@@ -63,16 +63,16 @@
String type = data.getMimeType();
String mime = data.getMimeData();
/*nsITransferable.kFileMime*/
- if("application/x-moz-file".equals(type) && mime != null) {
- if(mime.startsWith("file:")) mime = mime.substring(5);
+ if("application/x-moz-file".equals(type) && mime != null) { //$NON-NLS-1$
+ if(mime.startsWith("file:")) mime = mime.substring(5); //$NON-NLS-1$
File f = new File(mime);
IFile file = EclipseResourceUtil.getFile(f.getAbsolutePath());
if(file == null) return;
XModelObject o = EclipseResourceUtil.getObjectByResource(file);
if(o == null) return;
- XActionInvoker.invoke("CopyActions.Copy", o, null);
+ XActionInvoker.invoke("CopyActions.Copy", o, null); //$NON-NLS-1$
data.setMimeType(ModelTransfer.MODEL);
- data.setMimeData("");
+ data.setMimeData(""); //$NON-NLS-1$
DropCommandFactory.getInstance().getDropCommand(ModelTransfer.MODEL, tagProposalFactory).execute(data);
}
}
@@ -80,7 +80,7 @@
protected void addCustomProperties(Properties properties) {}
protected String getReformatBodyProperty() {
- return "yes";
+ return "yes"; //$NON-NLS-1$
}
protected IDropWizardModel createSpecificModel() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileTagProposalLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileTagProposalLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/FileTagProposalLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,27 +22,27 @@
static TagProposal[] IMG_TAG_PROPOSALS = new TagProposal[]{
new TagProposal(
DropURI.JSF_HTML_URI,
- "h",
- "graphicImage",
- new AbsoluteFilePathAttributeValueLoader("value","","")
+ "h", //$NON-NLS-1$
+ "graphicImage", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("value","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
),
new TagProposal(
DropURI.HTML_4_0_URI,
TagProposal.EMPTY_PREFIX,
- "img",
- new AbsoluteFilePathAttributeValueLoader("src","","")
+ "img", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("src","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
),
new TagProposal(
DropURI.STRUTS_HTML_URI,
- "html",
- "img",
- new AbsoluteFilePathAttributeValueLoader("page","","")
+ "html", //$NON-NLS-1$
+ "img", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("page","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
),
new TagProposal(
DropURI.SEAM_URI,
- "s",
- "graphicImage",
- new AbsoluteFilePathAttributeValueLoader("url","","")
+ "s", //$NON-NLS-1$
+ "graphicImage", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("url","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
)
// yradtsevich: fix of JBIDE-3984: Exclude t:graphicImage option from Insert tag dialog
// ,
@@ -58,37 +58,37 @@
new TagProposal(
DropURI.HTML_4_0_URI,
TagProposal.EMPTY_PREFIX,
- "link",
- new CssLinkAttributeValueLoader("href")
+ "link", //$NON-NLS-1$
+ new CssLinkAttributeValueLoader("href") //$NON-NLS-1$
),
};
static TagProposal JSP_INCLUDE = new TagProposal(
DropURI.JSP_URI,
- "jsp",
- "include",
- new AbsoluteFilePathAttributeValueLoader("page","","")
+ "jsp", //$NON-NLS-1$
+ "include", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("page","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
);
static TagProposal JSP_FORWARD = new TagProposal(
DropURI.JSP_URI,
- "jsp",
- "forward",
- new AbsoluteFilePathAttributeValueLoader("page","","")
+ "jsp", //$NON-NLS-1$
+ "forward", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("page","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
);
static TagProposal UI_INCLUDE = new TagProposal(
PaletteTaglibInserter.faceletUri,
- "ui",
- "include",
- new AbsoluteFilePathAttributeValueLoader("src","","")
+ "ui", //$NON-NLS-1$
+ "include", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("src","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
);
static TagProposal S_DECORATE = new TagProposal(
DropURI.SEAM_URI,
- "s",
- "decorate",
- new AbsoluteFilePathAttributeValueLoader("template","","")
+ "s", //$NON-NLS-1$
+ "decorate", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("template","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
);
static TagProposal[] PAGE_TAG_PROPOSALS = new TagProposal[]{
@@ -105,38 +105,38 @@
static {
// There is the question here what store HTML or TLD will been asked about TagDescription
- extensionMap.put("jpg", IMG_TAG_PROPOSALS);
+ extensionMap.put("jpg", IMG_TAG_PROPOSALS); //$NON-NLS-1$
- extensionMap.put("jpeg", IMG_TAG_PROPOSALS);
+ extensionMap.put("jpeg", IMG_TAG_PROPOSALS); //$NON-NLS-1$
- extensionMap.put("gif",IMG_TAG_PROPOSALS);
+ extensionMap.put("gif",IMG_TAG_PROPOSALS); //$NON-NLS-1$
- extensionMap.put("bmp",IMG_TAG_PROPOSALS);
+ extensionMap.put("bmp",IMG_TAG_PROPOSALS); //$NON-NLS-1$
- extensionMap.put("png",IMG_TAG_PROPOSALS);
+ extensionMap.put("png",IMG_TAG_PROPOSALS); //$NON-NLS-1$
- extensionMap.put("jsp",PAGE_TAG_PROPOSALS);
- extensionMap.put("html",PAGE_TAG_PROPOSALS);
- extensionMap.put("xhtml",XHTML_PAGE_TAG_PROPOSALS);
+ extensionMap.put("jsp",PAGE_TAG_PROPOSALS); //$NON-NLS-1$
+ extensionMap.put("html",PAGE_TAG_PROPOSALS); //$NON-NLS-1$
+ extensionMap.put("xhtml",XHTML_PAGE_TAG_PROPOSALS); //$NON-NLS-1$
extensionMap.put(
- "properties",new TagProposal[]{
+ "properties",new TagProposal[]{ //$NON-NLS-1$
new TagProposal(
DropURI.JSF_CORE_URI,
- "f",
- "loadBundle",
+ "f", //$NON-NLS-1$
+ "loadBundle", //$NON-NLS-1$
new LoadBundleBaseNameAttributeValueLoader()
)
}
);
- extensionMap.put("css",CSS_TAG_PROPOSALS);
+ extensionMap.put("css",CSS_TAG_PROPOSALS); //$NON-NLS-1$
extensionMap.put(
- "inc", new TagProposal[]{
+ "inc", new TagProposal[]{ //$NON-NLS-1$
new TagProposal(
DropURI.JSP_URI,
- "jsp",
- "include",
- new AbsoluteFilePathAttributeValueLoader("page","","")
+ "jsp", //$NON-NLS-1$
+ "include", //$NON-NLS-1$
+ new AbsoluteFilePathAttributeValueLoader("page","","") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
)
}
);
@@ -149,7 +149,7 @@
public TagProposal[] getTagProposals(Object data) {
String fileName = data.toString();
- String extension = fileName.substring(fileName.lastIndexOf(".")+1);
+ String extension = fileName.substring(fileName.lastIndexOf(".")+1); //$NON-NLS-1$
TagProposal[] tagProposals = (TagProposal[])extensionMap.get(extension.toLowerCase());
if(tagProposals==null) {
tagProposals = new TagProposal[0];
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/IDropWizardModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/IDropWizardModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/IDropWizardModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,11 +22,11 @@
* Constants
*/
- public static final String TAG_PROPOSAL = "tagProposal";
+ public static final String TAG_PROPOSAL = "tagProposal"; //$NON-NLS-1$
- public static final String ATTRIBUTE_VALUE = "attributeValue";
+ public static final String ATTRIBUTE_VALUE = "attributeValue"; //$NON-NLS-1$
- public static final TagProposal UNDEFINED_TAG_PROPOSAL = new TagProposal("http://www.redhat.com/undefined","","");
+ public static final TagProposal UNDEFINED_TAG_PROPOSAL = new TagProposal("http://www.redhat.com/undefined","",""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
/*
* Methods
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/JSPTagProposalFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/JSPTagProposalFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/JSPTagProposalFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -20,8 +20,8 @@
public static Map<String,String> loaderMap = new HashMap<String,String>();
static {
- loaderMap.put(DropCommandFactory.kFileMime, DropCommandFactory.PACKAGE + "FileTagProposalLoader");
- loaderMap.put(DropCommandFactory.kURLMime, DropCommandFactory.PACKAGE + "FileTagProposalLoader");
+ loaderMap.put(DropCommandFactory.kFileMime, DropCommandFactory.PACKAGE + "FileTagProposalLoader"); //$NON-NLS-1$
+ loaderMap.put(DropCommandFactory.kURLMime, DropCommandFactory.PACKAGE + "FileTagProposalLoader"); //$NON-NLS-1$
}
public static JSPTagProposalFactory getInstance() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/LoadBundleBaseNameAttributeValueLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/LoadBundleBaseNameAttributeValueLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/LoadBundleBaseNameAttributeValueLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,8 +26,8 @@
IAttributeValueLoader {
public void fillTagAttributes(IDropWizardModel model) {
- String baseName = "";
- String fileName = "";
+ String baseName = ""; //$NON-NLS-1$
+ String fileName = ""; //$NON-NLS-1$
IFile file = DropUtils.getResourceForMimeData(model.getDropData());
IJavaElement javaElement = null;
@@ -37,9 +37,9 @@
s = s.replace('\\','/');
int l = s.lastIndexOf('.');
if(l >= 0) s = s.substring(0, l);
- int k = s.indexOf("/JavaSource/");
+ int k = s.indexOf("/JavaSource/"); //$NON-NLS-1$
if(k >= 0) {
- baseName = s.substring(k + "/JavaSource/".length());
+ baseName = s.substring(k + "/JavaSource/".length()); //$NON-NLS-1$
} else {
baseName = s.substring(s.lastIndexOf('/') + 1);
}
@@ -49,7 +49,7 @@
XModelObject o = EclipseResourceUtil.getObjectByResource(file);
if(o != null) {
String path = XModelObjectLoaderUtil.getResourcePath(o);
- if(path.startsWith("/")) path = path.substring(1);
+ if(path.startsWith("/")) path = path.substring(1); //$NON-NLS-1$
int i = path.lastIndexOf('.');
if(i >= 0) path = path.substring(0,i);
baseName = path.replace('/', '.');
@@ -61,7 +61,7 @@
int i = fileName.lastIndexOf('.');
if(i >= 0) fileName = fileName.substring(0,i);
if(javaElement != null) {
- baseName = javaElement.getElementName()+ "." + fileName;
+ baseName = javaElement.getElementName()+ "." + fileName; //$NON-NLS-1$
} else {
baseName = fileName;
}
@@ -69,8 +69,8 @@
}
// TODO Eskimo - Think about how reject drop id properties file is not under java source
- model.setAttributeValue("basename", baseName);
- model.setAttributeValue("var", fileName.toLowerCase());
+ model.setAttributeValue("basename", baseName); //$NON-NLS-1$
+ model.setAttributeValue("var", fileName.toLowerCase()); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/PaletteDropCommand.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/PaletteDropCommand.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/PaletteDropCommand.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -47,7 +47,7 @@
String startText;
String endText;
String newLine;
- String reformat = "no";
+ String reformat = "no"; //$NON-NLS-1$
Properties properties = new Properties();
boolean callPaletteWizard = false;
@@ -61,10 +61,10 @@
protected void addCustomProperties(Properties runningProperties) {
newLine = properties.getProperty(PaletteInsertHelper.PROPOPERTY_NEW_LINE);
- if (newLine == null) newLine="true";
+ if (newLine == null) newLine="true"; //$NON-NLS-1$
runningProperties.setProperty(PaletteInsertHelper.PROPOPERTY_NEW_LINE, newLine);
String addTaglib = properties.getProperty(PaletteInsertHelper.PROPOPERTY_ADD_TAGLIB);
- if(addTaglib == null) addTaglib = "true";
+ if(addTaglib == null) addTaglib = "true"; //$NON-NLS-1$
runningProperties.setProperty(PaletteInsertHelper.PROPOPERTY_ADD_TAGLIB, addTaglib);
}
@@ -93,12 +93,12 @@
int containerOffset = container.getStartOffset();
int containerLenght = container.getStartEndOffset()-containerOffset;
String containerString = document.get(containerOffset, containerLenght);
- int slashPosition = containerString.lastIndexOf("/");
+ int slashPosition = containerString.lastIndexOf("/"); //$NON-NLS-1$
if(slashPosition >= 0){
int deltaOffset = (containerString.length()-1)-slashPosition;
- String text = "";
- for(int i=0; i < deltaOffset;i++) text += " ";
- text += "></"+container.getNodeName()+">";
+ String text = ""; //$NON-NLS-1$
+ for(int i=0; i < deltaOffset;i++) text += " "; //$NON-NLS-1$
+ text += "></"+container.getNodeName()+">"; //$NON-NLS-1$ //$NON-NLS-2$
document.replace(containerOffset+slashPosition, containerString.length()-slashPosition, text);
}
}catch(BadLocationException ex){
@@ -132,14 +132,14 @@
ISourceViewer viewer = data.getSourceViewer();
properties = new Properties();
- properties.put("viewer", viewer);
- properties.setProperty("text", viewer.getDocument().get());
- properties.setProperty("isDrop", "true");
- properties.setProperty("actionSourceGUIComponentID", "editor");
- properties.setProperty("accepsAsString", "true");
+ properties.put("viewer", viewer); //$NON-NLS-1$
+ properties.setProperty("text", viewer.getDocument().get()); //$NON-NLS-1$
+ properties.setProperty("isDrop", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+ properties.setProperty("actionSourceGUIComponentID", "editor"); //$NON-NLS-1$ //$NON-NLS-2$
+ properties.setProperty("accepsAsString", "true"); //$NON-NLS-1$ //$NON-NLS-2$
if(f != null) {
- properties.put("file", f);
+ properties.put("file", f); //$NON-NLS-1$
}
ISelection selection = data.getSelectionProvider().getSelection();
@@ -151,15 +151,15 @@
} else {
offset = viewer.getTextWidget().getCaretOffset();
}
- properties.setProperty("pos", "" + offset);
+ properties.setProperty("pos", "" + offset); //$NON-NLS-1$ //$NON-NLS-2$
if(selection instanceof IStructuredSelection && !selection.isEmpty()) {
Object so = ((IStructuredSelection)selection).getFirstElement();
if(so instanceof IDOMElement) {
String en = ((IDOMElement)so).getNodeName();
- properties.setProperty("context:tagName", en);
+ properties.setProperty("context:tagName", en); //$NON-NLS-1$
String attrName = data.getAttributeName();
if(attrName != null) {
- properties.setProperty("context:attrName", attrName);
+ properties.setProperty("context:attrName", attrName); //$NON-NLS-1$
}
}
}
@@ -169,9 +169,9 @@
} else {
XModelObject s = PreferenceModelUtilities.getPreferenceModel().getModelBuffer().source();
if(s != null) {
- properties.setProperty("start text", "" + getDefaultText(s));
- properties.setProperty("end text", "");
- properties.setProperty("new line", "newLine");
+ properties.setProperty("start text", "" + getDefaultText(s)); //$NON-NLS-1$ //$NON-NLS-2$
+ properties.setProperty("end text", ""); //$NON-NLS-1$ //$NON-NLS-2$
+ properties.setProperty("new line", "newLine"); //$NON-NLS-1$ //$NON-NLS-2$
}
}
} catch (CoreException e) {
@@ -183,11 +183,11 @@
String uri = properties.getProperty(URIConstants.LIBRARY_URI);
String libraryVersion = properties.getProperty(URIConstants.LIBRARY_VERSION);
String defaultPrefix = properties.getProperty(URIConstants.DEFAULT_PREFIX);
- String tagname = properties.getProperty("tag name");
+ String tagname = properties.getProperty("tag name"); //$NON-NLS-1$
callPaletteWizard = PaletteInsertManager.getInstance().getWizardName(properties) != null;
- boolean isWizardEnabled = (!"FileJAVA".equals(target.getModelEntity().getName()));
+ boolean isWizardEnabled = (!"FileJAVA".equals(target.getModelEntity().getName())); //$NON-NLS-1$
if(getDefaultModel() instanceof PaletteDropWizardModel) {
((PaletteDropWizardModel)getDefaultModel()).setWizardEnabled(isWizardEnabled);
}
@@ -203,14 +203,14 @@
private void initialize2() {
XModelObject object = PreferenceModelUtilities.getPreferenceModel().getModelBuffer().source();
- String tagname = object.getAttributeValue("name");
+ String tagname = object.getAttributeValue("name"); //$NON-NLS-1$
XModelObject parent = object.getParent();
- String uri = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_URI);
- String libraryVersion = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_VERSION);
- String defaultPrefix = (parent == null) ? "" : parent.getAttributeValue(URIConstants.DEFAULT_PREFIX);
+ String uri = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_URI); //$NON-NLS-1$
+ String libraryVersion = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_VERSION); //$NON-NLS-1$
+ String defaultPrefix = (parent == null) ? "" : parent.getAttributeValue(URIConstants.DEFAULT_PREFIX); //$NON-NLS-1$
this.getDefaultModel().setTagProposal(new TagProposal(uri, libraryVersion,defaultPrefix,tagname));
- startText = object.getAttributeValue("start text");
- endText = object.getAttributeValue("end text");
+ startText = object.getAttributeValue("start text"); //$NON-NLS-1$
+ endText = object.getAttributeValue("end text"); //$NON-NLS-1$
}
private void insertInitialValues() {
@@ -240,7 +240,7 @@
char c = header.charAt(i);
if(state == NOTHING) {
if(Character.isJavaIdentifierStart(c)) {
- name = "" + c;
+ name = "" + c; //$NON-NLS-1$
state = ATT_NAME;
}
} else if(state == ATT_NAME) {
@@ -259,7 +259,7 @@
quote = '\0';
} else if(c == '"' || c == '\'') {
quote = c;
- value = "";
+ value = ""; //$NON-NLS-1$
} else if(quote != '\0') {
value += c;
}
@@ -268,7 +268,7 @@
}
protected String generateStartText() {
- startText = properties.getProperty("start text");
+ startText = properties.getProperty("start text"); //$NON-NLS-1$
if(getDefaultModel().getTagProposal()==IDropWizardModel.UNDEFINED_TAG_PROPOSAL
|| getDefaultModel().getTagProposal().getUri().length() == 0) {
return startText;
@@ -296,8 +296,8 @@
}
protected String generateEndText() {
- endText = properties.getProperty("end text");
- return (endText != null) ? endText : "";
+ endText = properties.getProperty("end text"); //$NON-NLS-1$
+ return (endText != null) ? endText : ""; //$NON-NLS-1$
}
protected String getReformatBodyProperty() {
@@ -321,7 +321,7 @@
}
private String getDefaultText(XModelObject o) {
- if(o == null) return "";
+ if(o == null) return ""; //$NON-NLS-1$
if(o.getFileType() != XModelObject.FILE) return o.getPresentationString();
IWebProject p = WebProjectFactory.instance.getWebProject(o.getModel());
String path = p.getPathInWebRoot(o);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagAttributesWizardPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagAttributesWizardPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagAttributesWizardPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -38,7 +38,7 @@
*
*/
public TagAttributesWizardPage() {
- super("Edit required and preferred attributes","");
+ super("Edit required and preferred attributes",""); //$NON-NLS-2$
}
/**
@@ -46,7 +46,7 @@
* @param pageName
*/
protected TagAttributesWizardPage(String pageName) {
- super(pageName,"");
+ super(pageName,""); //$NON-NLS-1$
}
private TabItem general = null;
@@ -121,15 +121,15 @@
protected void updateTitle() {
TagProposal tagProposal = (TagProposal)getDropWizardModel().getTagProposal();
StringBuffer titleText = new StringBuffer();
- titleText.append("<");
+ titleText.append("<"); //$NON-NLS-1$
if(!TagProposal.EMPTY_PREFIX.equals(tagProposal.getPrefix())) {
titleText
.append(tagProposal.getPrefix())
- .append(":");
+ .append(":"); //$NON-NLS-1$
}
titleText
.append(tagProposal.getName())
- .append("> attributes");
+ .append("> attributes"); //$NON-NLS-1$
setTitle(titleText.toString());
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagProposal.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagProposal.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/TagProposal.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -12,8 +12,8 @@
public class TagProposal {
- public static final String EMPTY_PREFIX = "";
- public static final String EMPTY_URI = "";
+ public static final String EMPTY_PREFIX = ""; //$NON-NLS-1$
+ public static final String EMPTY_URI = ""; //$NON-NLS-1$
public static final IAttributeValueLoader EMPTY_ATTRIBUTE_VALUE_LOADER = new IAttributeValueLoader() {
public void fillTagAttributes(IDropWizardModel model) {
@@ -22,7 +22,7 @@
};
String uri;
- String libraryVersion = "";
+ String libraryVersion = ""; //$NON-NLS-1$
String prefix;
String name;
IAttributeValueLoader attributeValueLoader = EMPTY_ATTRIBUTE_VALUE_LOADER;
@@ -36,7 +36,7 @@
String prefix,
String name
) {
- this(uri, "", prefix, name);
+ this(uri, "", prefix, name); //$NON-NLS-1$
}
public TagProposal(
@@ -46,7 +46,7 @@
String name
) {
this.uri = uri;
- this.libraryVersion = (libraryVersion == null) ? "" : libraryVersion;
+ this.libraryVersion = (libraryVersion == null) ? "" : libraryVersion; //$NON-NLS-1$
this.prefix = prefix;
this.name = name;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagAttributesComposite.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagAttributesComposite.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagAttributesComposite.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -233,7 +233,7 @@
col = new TableColumn(swtTable, SWT.NONE);
col.setText("Value");
- tableViewer.setColumnProperties(new String[] {"Name","Value"});
+ tableViewer.setColumnProperties(new String[] {"Name","Value"}); //$NON-NLS-1$ //$NON-NLS-2$
tableViewer.setUseHashlookup(true);
tableViewer.setComparer(new IElementComparer() {
@@ -256,14 +256,14 @@
public Object getValue(Object element, String property) {
AttributeDescriptorValue attrDescr = (AttributeDescriptorValue)element;
- context.setProperty("attributeName", attrDescr.getName());
- String tagName = "" + fWizardModel.getTagProposal().getName();
+ context.setProperty("attributeName", attrDescr.getName()); //$NON-NLS-1$
+ String tagName = "" + fWizardModel.getTagProposal().getName(); //$NON-NLS-1$
String prefix = fWizardModel.getTagProposal().getPrefix();
- if(prefix != null && prefix.length() > 0 && !tagName.startsWith("prefix" + ":")) {
- tagName = prefix + ":" + tagName;
+ if(prefix != null && prefix.length() > 0 && !tagName.startsWith("prefix" + ":")) { //$NON-NLS-1$ //$NON-NLS-2$
+ tagName = prefix + ":" + tagName; //$NON-NLS-1$
}
- context.setProperty("nodeName", tagName);
- return attrDescr.getValue()==null?"":attrDescr.getValue();
+ context.setProperty("nodeName", tagName); //$NON-NLS-1$
+ return attrDescr.getValue()==null?"":attrDescr.getValue(); //$NON-NLS-1$
}
public void modify(Object element, String property, Object value) {
@@ -362,9 +362,9 @@
}
case ATTRIBUTE_VALUE_INDEX:
- return attrDescr.getValue()==null?"":attrDescr.getValue().toString();
+ return attrDescr.getValue()==null?"":attrDescr.getValue().toString(); //$NON-NLS-1$
}
- throw new IllegalArgumentException("Wrong column index for LabelProvider");
+ throw new IllegalArgumentException("Wrong column index for LabelProvider"); //$NON-NLS-1$
}
public void addListener(ILabelProviderListener listener) {
@@ -387,7 +387,7 @@
private Properties context = new Properties();
private ExtendedCellEditorProvider createCellEditorProvider() {
- return (ExtendedCellEditorProvider)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.jsp.outline.JSPCellEditorProviderImpl");
+ return (ExtendedCellEditorProvider)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.jsp.outline.JSPCellEditorProviderImpl"); //$NON-NLS-1$
}
/**
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagProposalsComposite.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagProposalsComposite.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/composite/TagProposalsComposite.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -133,12 +133,12 @@
TagProposal prop = (TagProposal)element;
switch (columnIndex) {
case TAG_NAME_INDEX:
- return prop.getPrefix()==TagProposal.EMPTY_PREFIX?prop.getName():prop.getPrefix()+":"+prop.getName();
+ return prop.getPrefix()==TagProposal.EMPTY_PREFIX?prop.getName():prop.getPrefix()+":"+prop.getName(); //$NON-NLS-1$
case TAG_URI_INDEX:
return prop.getUri();
}
- throw new IllegalArgumentException("Wrong column index for LabelProvider");
+ throw new IllegalArgumentException("Wrong column index for LabelProvider"); //$NON-NLS-1$
}
public void addListener(ILabelProviderListener listener) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/context/DropContext.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/context/DropContext.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/dnd/context/DropContext.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -153,7 +153,7 @@
if(event == null) return;
if(getFlavor() == null) {
return;
- } else if (getFlavor().equals("text/html")) {
+ } else if (getFlavor().equals("text/html")) { //$NON-NLS-1$
new VpeTextDropAction().run(event, editor);
} else {
editor.runDropCommand(getFlavor(), getMimeData());
@@ -165,7 +165,7 @@
if(o == null) return false;
if(o.getFileType() != XModelObject.FILE || isOverAttributeValue) return false;
if(TLDUtil.isTaglib(o)) return false;
- String extension = o.getAttributeValue("extension");
+ String extension = o.getAttributeValue("extension"); //$NON-NLS-1$
return extension != null && FileTagProposalLoader.isExtensionMapped(extension);
}
@@ -197,7 +197,7 @@
if(!XModelTransferBuffer.getInstance().isEnabled()) return;
XModelObject o = PreferenceModelUtilities.getPreferenceModel().getModelBuffer().source();
if(dropAsFileObject(o)) {
- flavor = "application/x-moz-file";
+ flavor = "application/x-moz-file"; //$NON-NLS-1$
mimeData = getURL(o);
if(mimeData == null) flavor = ModelTransfer.MODEL;
} else {
@@ -208,7 +208,7 @@
class HTMLTransferProcessor extends TransferProcessor {
public void process(TransferData data) {
- flavor = "text/html";
+ flavor = "text/html"; //$NON-NLS-1$
TransferData currentDataType = null;
if(event instanceof DropTargetEvent){
currentDataType = (( DropTargetEvent)event).currentDataType;
@@ -226,7 +226,7 @@
class LocalTransferProcessor extends TransferProcessor {
public void process(TransferData data) {
- flavor = "application/x-moz-file";
+ flavor = "application/x-moz-file"; //$NON-NLS-1$
Object ooo = LocalSelectionTransfer.getTransfer().getSelection();
if(ooo instanceof StructuredSelection) {
ooo = ((StructuredSelection)ooo).getFirstElement();
@@ -250,7 +250,7 @@
if(!ok) return;
}
mimeData = getURL(event);
- flavor = "application/x-moz-file";
+ flavor = "application/x-moz-file"; //$NON-NLS-1$
if(mimeData != null && isOverAttributeValue) {
String path = getFile(event).getAbsolutePath();
IFile f = EclipseResourceUtil.getFile(path);
@@ -266,7 +266,7 @@
class TextTransferProcessor extends TransferProcessor {
public void process(TransferData data) {
- flavor = "text/html";
+ flavor = "text/html"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/multipage/DefaultMultipageEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/multipage/DefaultMultipageEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/editors/multipage/DefaultMultipageEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -67,7 +67,7 @@
protected void checkErrorMode() {
if(object == null) return;
- boolean i = "yes".equals(object.get("isIncorrect"));
+ boolean i = "yes".equals(object.get("isIncorrect")); //$NON-NLS-1$ //$NON-NLS-2$
if(isErrorMode == i) return;
isErrorMode = i;
/*
@@ -84,8 +84,8 @@
}
protected void updateSelectionProvider() {
- if(textEditor != null) selectionProvider.addHost("textEditor", getTextSelectionProvider());
- if(treeFormPage != null) selectionProvider.addHost("treeEditor", treeFormPage.getSelectionProvider());
+ if(textEditor != null) selectionProvider.addHost("textEditor", getTextSelectionProvider()); //$NON-NLS-1$
+ if(treeFormPage != null) selectionProvider.addHost("treeEditor", treeFormPage.getSelectionProvider()); //$NON-NLS-1$
int index = getActivePage();
if(index == getSourcePageIndex()) {
if(textEditor != null) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AbstractForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AbstractForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AbstractForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
protected Color headingBackground;
protected Color headingForeground;
protected Image headingImage;
- protected String headingText = "%No text%";
+ protected String headingText = "%No text%"; //$NON-NLS-1$
private Object layoutData;
private Layout layout;
private boolean enabled = Boolean.TRUE.booleanValue();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AnyElementForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AnyElementForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/AnyElementForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.forms;
+import java.text.MessageFormat;
import java.util.Properties;
import java.util.StringTokenizer;
@@ -82,7 +83,7 @@
composite.setLayout(layout);
if(xmo == null) return composite;
- String description = "";
+ String description = ""; //$NON-NLS-1$
if(description != null && description.length() > 0) {
Label label = new Label(composite, SWT.WRAP);
settings.setupControl(label);
@@ -133,7 +134,7 @@
String heading = "Attributes";
this.setHeadingText(heading);
if(!(model instanceof XModelObject)) {
- ModelUIPlugin.getPluginLog().logInfo( "Error to create form " + heading + ". Model object cannot be null.", new Exception());
+ ModelUIPlugin.getPluginLog().logInfo( "Error to create form " + heading + ". Model object cannot be null.", new Exception()); //$NON-NLS-1$ //$NON-NLS-2$
return;
}
this.xmo = (XModelObject)model;
@@ -159,14 +160,14 @@
if(xmo == null) {
tableProvider.attributes = null;
} else {
- String attrs = xmo.getAttributeValue("attributes");
- StringTokenizer st = new StringTokenizer(attrs, ";");
+ String attrs = xmo.getAttributeValue("attributes"); //$NON-NLS-1$
+ StringTokenizer st = new StringTokenizer(attrs, ";"); //$NON-NLS-1$
int length = st.countTokens();
String[][] as = new String[length][2];
for (int i = 0; i < length; i++) {
String t = st.nextToken();
int k = t.indexOf('=');
- String n = k < 0 ? "" : t.substring(0, k);
+ String n = k < 0 ? "" : t.substring(0, k); //$NON-NLS-1$
String v = t.substring(k + 1);
as[i][0] = n;
as[i][1] = v;
@@ -207,14 +208,14 @@
class CellModifier implements ICellModifier {
public boolean canModify(Object element, String property) {
- if(!"value".equals(property)) return false;
+ if(!"value".equals(property)) return false; //$NON-NLS-1$
return xmo != null && xmo.isObjectEditable() && getColumn(property) >= 0;
}
public Object getValue(Object element, String property) {
int r = ((Integer)element).intValue();
int c = getColumn(property);
- return (c < 0) ? "" : tableProvider.getValueAt(r, c);
+ return (c < 0) ? "" : tableProvider.getValueAt(r, c); //$NON-NLS-1$
}
int getColumn(String property) {
@@ -230,7 +231,7 @@
if(c < 0) return;
String oldValue = tableProvider.getValueAt(r, c);
if(oldValue != null && oldValue.equals(value)) return;
- tableProvider.attributes[r][c] = "" + value;
+ tableProvider.attributes[r][c] = "" + value; //$NON-NLS-1$
try {
commitAttributes();
} catch (XModelException e) {
@@ -251,7 +252,7 @@
sb.append(n).append('=').append(v);
}
String v = sb.toString();
- xmo.getModel().editObjectAttribute(xmo, "attributes", v);
+ xmo.getModel().editObjectAttribute(xmo, "attributes", v); //$NON-NLS-1$
}
class CommandBarListenerImpl implements CommandBarListener {
@@ -282,7 +283,7 @@
}
void add() {
- XActionInvoker.invoke("CreateActions.CreateAttribute", xmo, new Properties());
+ XActionInvoker.invoke("CreateActions.CreateAttribute", xmo, new Properties()); //$NON-NLS-1$
}
void edit() {
@@ -291,8 +292,8 @@
if(i < 0) return;
String name = tableProvider.getValueAt(i, 0);
Properties p = new Properties();
- p.setProperty("name", name);
- XActionInvoker.invoke("AnyElementNew", "EditActions.EditAttribute", xmo, p);
+ p.setProperty("name", name); //$NON-NLS-1$
+ XActionInvoker.invoke("AnyElementNew", "EditActions.EditAttribute", xmo, p); //$NON-NLS-1$ //$NON-NLS-2$
}
void delete() throws XModelException {
@@ -303,9 +304,9 @@
ServiceDialog d = xmo.getModel().getService();
String message = null;
if(is.length == 1) {
- message = "Delete attribute " + name + "?";
+ message = MessageFormat.format("Delete attribute {0}?", name);
} else {
- message = "Delete " + is.length + " attributes?";
+ message = MessageFormat.format("Delete {0} attributes?", is.length);
}
int q = d.showDialog("Delete", message, new String[]{"OK", "Cancel"}, null, ServiceDialog.QUESTION);
if(q != 0) return;
@@ -321,7 +322,7 @@
sb.append(n).append('=').append(v);
}
String v = sb.toString();
- xmo.getModel().editObjectAttribute(xmo, "attributes", v);
+ xmo.getModel().editObjectAttribute(xmo, "attributes", v); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
public DefaultForm() {}
public Control createControl(Composite parent, IWidgetSettings settings) {
- composite = new Composite(parent, settings.getStyle("Composite.Style"));
+ composite = new Composite(parent, settings.getStyle("Composite.Style")); //$NON-NLS-1$
composite.setLayout(getLayout());
composite.setLayoutData(getLayoutData());
// create client area
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultFormPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultFormPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultFormPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -35,7 +35,7 @@
public class DefaultFormPage implements IFormPage, PaintListener {
- public static final String IMG_FORM_BANNER = "form_banner.gif";
+ public static final String IMG_FORM_BANNER = "form_banner.gif"; //$NON-NLS-1$
private ISelectionProvider selectionProvider;
@@ -98,7 +98,7 @@
public Control createControl(Composite parent) {
settings = new WhiteSettings();
- titleFont = settings.getFont("Label.Font.Title");
+ titleFont = settings.getFont("Label.Font.Title"); //$NON-NLS-1$
Composite composite = new Composite(parent, SWT.NONE);
settings.setupControl(composite);
composite.addPaintListener(this);
@@ -136,7 +136,7 @@
private int getTitleHeight() {
int imageHeight = 0;
if (image != null
- && SWT.getPlatform().equals("motif") == false) {
+ && SWT.getPlatform().equals("motif") == false) { //$NON-NLS-1$
imageHeight = image.getBounds().height;
}
int height = getFontHeight() + 2 * HEADER_V_GAP;
@@ -156,8 +156,8 @@
if (image != null) {
paintWithImage(form, gc);
} else {
- gc.setBackground(settings.getColor("Composite.Background"));
- gc.setForeground(settings.getColor("Composite.Foreground"));
+ gc.setBackground(settings.getColor("Composite.Background")); //$NON-NLS-1$
+ gc.setForeground(settings.getColor("Composite.Foreground")); //$NON-NLS-1$
}
gc.setFont(titleFont);
gc.drawText(getTitle(), HEADER_H_GAP, HEADER_V_GAP, true);
@@ -169,10 +169,10 @@
gc.setBackground(headingBackground);
gc.fillRectangle(0, 0, bounds.width, getTitleHeight());
}
- if (!SWT.getPlatform().equals("motif")) {
+ if (!SWT.getPlatform().equals("motif")) { //$NON-NLS-1$
// gc.drawImage(image, 0, 0);
}
- Color fg = (headingForeground != null) ? headingForeground : settings.getColor("Composite.Foreground");
+ Color fg = (headingForeground != null) ? headingForeground : settings.getColor("Composite.Foreground"); //$NON-NLS-1$
FormToolkit t = settings.getToolkit(form.getDisplay());
if(t != null && t.getColors().getColor(FormColors.TITLE) != null) {
fg = t.getColors().getColor(FormColors.TITLE);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultXModelObjectForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultXModelObjectForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/DefaultXModelObjectForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -35,6 +35,6 @@
//this.addForm(childEditorForm);
//childEditorForm.setParent(this);
- this.setHeadingText("");
+ this.setHeadingText(""); //$NON-NLS-1$
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ExpandableForm.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ExpandableForm.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ExpandableForm.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -42,7 +42,7 @@
private boolean collapsable = true;
private boolean collapsed = false;
private Composite control;
- private static final String COLLAPSED_ID = "collapsed";
+ private static final String COLLAPSED_ID = "collapsed"; //$NON-NLS-1$
protected Section section;
@@ -79,7 +79,7 @@
//section = toolkit.createSection(parent, ExpandableComposite.TWISTIE|ExpandableComposite.EXPANDED|ExpandableComposite.TITLE_BAR);
// ExpandableComposite.TITLE_BAR option results for the tree flicking in "Hibernate Configuration 3.0 XML Editor"
section = toolkit.createSection(parent, ExpandableComposite.TWISTIE|ExpandableComposite.EXPANDED|ExpandableComposite.SHORT_TITLE_BAR);
- section.setText("" + getHeadingText());
+ section.setText("" + getHeadingText()); //$NON-NLS-1$
section.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | /*GridData.FILL_VERTICAL |*/ GridData.VERTICAL_ALIGN_BEGINNING));
toolkit.adapt(section);
section.setBackground(parent.getBackground());
@@ -182,7 +182,7 @@
}
public void store(IMemento memento) {
- memento.putString(COLLAPSED_ID, ""+isCollapsed());
+ memento.putString(COLLAPSED_ID, ""+isCollapsed()); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Form.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Form.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Form.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -211,7 +211,7 @@
this.tableAdapter.setModelObject(xmo);
this.tableEditor = new TableStructuredEditor(formData.getWidgetSettings());
- this.tableEditor.setLabelText("");
+ this.tableEditor.setLabelText(""); //$NON-NLS-1$
this.tableEditor.setInput(this.tableAdapter);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormContainer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormContainer.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormContainer.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -63,7 +63,7 @@
// Here it is not entity but rather a unique child name
child = xmo.getChildByPath(entity);
if(child == null) {
- String message = "Cannot build child form '" + forms[i].getEntityName() + "' for form '" + formData.getEntityName() + "'.";
+ String message = "Cannot build child form '" + forms[i].getEntityName() + "' for form '" + formData.getEntityName() + "'."; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
Exception exc = new FormRuntimeException(message);
ModelUIPlugin.getPluginLog().logError(exc);
} else {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,7 +30,7 @@
private void initialize() {
// String entityName = getXModelObject().getModelEntity().getName();
String formClassName = null;
- formClassName = getXModelObject().getModelEntity().getProperty("formClassName");
+ formClassName = getXModelObject().getModelEntity().getProperty("formClassName"); //$NON-NLS-1$
formClass = ModelFeatureFactory.getInstance().getFeatureClass(formClassName);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormLayoutDataUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormLayoutDataUtil.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/FormLayoutDataUtil.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -28,20 +28,20 @@
* @author glory
*/
public class FormLayoutDataUtil {
- private final static String STBFE_CLASS_NAME = "org.jboss.tools.common.model.ui.attribute.editor.JavaHyperlinkLineFieldEditor";
- private final static String SBFEE_CLASS_NAME = "org.jboss.tools.common.model.ui.attribute.editor.StringButtonFieldEditorEx";
+ private final static String STBFE_CLASS_NAME = "org.jboss.tools.common.model.ui.attribute.editor.JavaHyperlinkLineFieldEditor"; //$NON-NLS-1$
+ private final static String SBFEE_CLASS_NAME = "org.jboss.tools.common.model.ui.attribute.editor.StringButtonFieldEditorEx"; //$NON-NLS-1$
- private final static String SELECT_IT_ACTION = "%SelectIt%";
- private final static String INTERNAL_ACTION = "%internal%";
- private final static String DEFAULT_DELETE_ACTION = "DeleteActions.Delete";
- private final static String DEFAULT_EDIT_ACTION = "Properties.Properties";
+ private final static String SELECT_IT_ACTION = "%SelectIt%"; //$NON-NLS-1$
+ private final static String INTERNAL_ACTION = "%internal%"; //$NON-NLS-1$
+ private final static String DEFAULT_DELETE_ACTION = "DeleteActions.Delete"; //$NON-NLS-1$
+ private final static String DEFAULT_EDIT_ACTION = "Properties.Properties"; //$NON-NLS-1$
public static IFormAttributeData[] createGeneralFormAttributeData(String entityName) {
- return createFormAttributeData(entityName, "general");
+ return createFormAttributeData(entityName, "general"); //$NON-NLS-1$
}
public static IFormAttributeData[] createAdvancedFormAttributeData(String entityName) {
- return createFormAttributeData(entityName, "advanced");
+ return createFormAttributeData(entityName, "advanced"); //$NON-NLS-1$
}
public static IFormAttributeData[] createFormAttributeData(String entityName, String categoryName) {
@@ -51,14 +51,14 @@
XAttribute[] as = entity.getAttributes();
for (int i = 0; i < as.length; i++) {
if(!as[i].isVisible()) continue;
- String category = as[i].getProperty("category");
+ String category = as[i].getProperty("category"); //$NON-NLS-1$
if(category != null && category.equals(categoryName)) {
String editorName = as[i].getEditor().getName();
- if("AccessibleJava".equals(editorName)) {
+ if("AccessibleJava".equals(editorName)) { //$NON-NLS-1$
list.add(new FormAttributeData(as[i].getName(), null, STBFE_CLASS_NAME));
- } else if("Note".equals(editorName)) {
+ } else if("Note".equals(editorName)) { //$NON-NLS-1$
list.add(new FormAttributeData(as[i].getName(), InfoLayoutDataFactory.getInstance()));
- } else if("TreeChooser".equals(editorName)) {
+ } else if("TreeChooser".equals(editorName)) { //$NON-NLS-1$
list.add(new FormAttributeData(as[i].getName(), null, SBFEE_CLASS_NAME));
} else {
list.add(new FormAttributeData(as[i].getName()));
@@ -88,7 +88,7 @@
public static FormData createChildrenFormData(String name, String entityName, String childName, String attributeName, String[] entityNames, String createAction) {
return new FormData(
name,
- "", //"Description
+ "", //"Description //$NON-NLS-1$
childName != null ? childName : entityName,
new FormAttributeData[]{new FormAttributeData(attributeName, 100, attributeName)},
entityNames,
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/IFormColor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/IFormColor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/IFormColor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -11,17 +11,17 @@
package org.jboss.tools.common.model.ui.forms;
public interface IFormColor {
- public static final String DEFAULT_BACKGROUND = "_default_background";
- public static final String DEFAULT_FOREGROUND = "_default_foreground";
- public static final String DEFAULT_HEADER_BACKGROUND = "_default_header_background";
- public static final String DEFAULT_HEADER_FOREGROUND = "_default_header_foreground";
- public static final String BORDER_BACKGOUND = "_border_background";
- public static final String BORDER_FOREGOUND = "_border_foreground";
- public static final String SEPARATOR_COMPOSITE_BACKGOUND = "_separator_composite_background";
- public static final String HYPERLINK_DEFAULT_BACKGOUND = "_hyperlink_default_background";
- public static final String HYPERLINK_DEFAULT_FOREGOUND = "_hyperlink_default_foreground";
- public static final String HYPERLINK_ROLLOVER_BACKGOUND = "_hyperlink_rollover_background";
- public static final String HYPERLINK_ROLLOVER_FOREGOUND = "_hyperlink_rollover_foreground";
- public static final String HYPERLINK_VISITED_BACKGOUND = "_hyperlink_visited_background";
- public static final String HYPERLINK_VISITED_FOREGOUND = "_hyperlink_visited_foreground";
+ public static final String DEFAULT_BACKGROUND = "_default_background"; //$NON-NLS-1$
+ public static final String DEFAULT_FOREGROUND = "_default_foreground"; //$NON-NLS-1$
+ public static final String DEFAULT_HEADER_BACKGROUND = "_default_header_background"; //$NON-NLS-1$
+ public static final String DEFAULT_HEADER_FOREGROUND = "_default_header_foreground"; //$NON-NLS-1$
+ public static final String BORDER_BACKGOUND = "_border_background"; //$NON-NLS-1$
+ public static final String BORDER_FOREGOUND = "_border_foreground"; //$NON-NLS-1$
+ public static final String SEPARATOR_COMPOSITE_BACKGOUND = "_separator_composite_background"; //$NON-NLS-1$
+ public static final String HYPERLINK_DEFAULT_BACKGOUND = "_hyperlink_default_background"; //$NON-NLS-1$
+ public static final String HYPERLINK_DEFAULT_FOREGOUND = "_hyperlink_default_foreground"; //$NON-NLS-1$
+ public static final String HYPERLINK_ROLLOVER_BACKGOUND = "_hyperlink_rollover_background"; //$NON-NLS-1$
+ public static final String HYPERLINK_ROLLOVER_FOREGOUND = "_hyperlink_rollover_foreground"; //$NON-NLS-1$
+ public static final String HYPERLINK_VISITED_BACKGOUND = "_hyperlink_visited_background"; //$NON-NLS-1$
+ public static final String HYPERLINK_VISITED_FOREGOUND = "_hyperlink_visited_foreground"; //$NON-NLS-1$
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/LayouredFormFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/LayouredFormFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/LayouredFormFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,10 +32,10 @@
private void initialize() {
// String entityName = getXModelObject().getModelEntity().getName();
String formLayoutDataClassName = null;
- formLayoutDataClassName = getXModelObject().getModelEntity().getProperty("formLayout");
+ formLayoutDataClassName = getXModelObject().getModelEntity().getProperty("formLayout"); //$NON-NLS-1$
Class formLayoutDataClass = ModelFeatureFactory.getInstance().getFeatureClass(formLayoutDataClassName);
try {
- formLayoutData = (IFormLayoutData)formLayoutDataClass.getMethod("getInstance", (Class[])null).invoke(null, (Object[])null);
+ formLayoutData = (IFormLayoutData)formLayoutDataClass.getMethod("getInstance", (Class[])null).invoke(null, (Object[])null); //$NON-NLS-1$
} catch (IllegalAccessException e) {
ModelUIPlugin.getPluginLog().logError(e);
} catch (InvocationTargetException e) {
@@ -52,7 +52,7 @@
String entity = getXModelObject().getModelEntity().getName();
IFormData formData = formLayoutData.getFormData(entity);
if(formData == null) {
- String message = "Cannot find form for entity " + entity + ".";
+ String message = "Cannot find form for entity " + entity + "."; //$NON-NLS-1$ //$NON-NLS-2$
ModelUIPlugin.getPluginLog().logError(message);
} else if(formData.getForms() != null) {
form = new FormContainer(formData);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Memento.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Memento.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/Memento.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,19 +25,19 @@
*/
public class Memento implements IMemento {
- private static final String MEMENTO = "M";
- private static final String DIVIDER = ":";
- private static final String LINE = "|";
+ private static final String MEMENTO = "M"; //$NON-NLS-1$
+ private static final String DIVIDER = ":"; //$NON-NLS-1$
+ private static final String LINE = "|"; //$NON-NLS-1$
- private static final String ARRAY = "A";
- private static final String FLOAT = "F";
- private static final String INTEGER = "I";
- private static final String STRING = "S";
+ private static final String ARRAY = "A"; //$NON-NLS-1$
+ private static final String FLOAT = "F"; //$NON-NLS-1$
+ private static final String INTEGER = "I"; //$NON-NLS-1$
+ private static final String STRING = "S"; //$NON-NLS-1$
private String id;
private HashMap map = new HashMap();
final private String type;
- private static final String TEXT_DATA = "org.jboss.tools.common.model.ui.forms.Memento.textData.id";
+ private static final String TEXT_DATA = "org.jboss.tools.common.model.ui.forms.Memento.textData.id"; //$NON-NLS-1$
private Memento() {
@@ -45,7 +45,7 @@
}
public Memento(String type, String id) {
- ModelUIPlugin.getPluginLog().logInfo("new Memento("+id+")");
+ ModelUIPlugin.getPluginLog().logInfo("new Memento("+id+")"); //$NON-NLS-1$ //$NON-NLS-2$
this.id = id;
this.type = type;
}
@@ -165,7 +165,7 @@
* @see java.lang.Object#toString()
*/
public String toString() {
- return super.toString()+" id="+id;
+ return super.toString()+" id="+id; //$NON-NLS-1$
}
public String stringify() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/MementoDOM.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/MementoDOM.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/MementoDOM.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,9 +26,9 @@
public class MementoDOM implements IMemento {
private Element element;
- private static final String ID = "id";
- private static final String MEMENTO = "Memento";
- private static final String TYPE = "type";
+ private static final String ID = "id"; //$NON-NLS-1$
+ private static final String MEMENTO = "Memento"; //$NON-NLS-1$
+ private static final String TYPE = "type"; //$NON-NLS-1$
private Hashtable hash = new Hashtable();
private MementoDOM() {}
@@ -138,14 +138,14 @@
* @see org.eclipse.ui.IMemento#putFloat(java.lang.String, float)
*/
public void putFloat(String key, float value) {
- element.setAttribute(key, ""+value);
+ element.setAttribute(key, ""+value); //$NON-NLS-1$
}
/* (non-Javadoc)
* @see org.eclipse.ui.IMemento#putInteger(java.lang.String, int)
*/
public void putInteger(String key, int value) {
- element.setAttribute(key, ""+value);
+ element.setAttribute(key, ""+value); //$NON-NLS-1$
}
/* (non-Javadoc)
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ModelFormLayoutData.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ModelFormLayoutData.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/ModelFormLayoutData.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,27 +18,27 @@
import org.jboss.tools.common.meta.key.WizardKeys;
public class ModelFormLayoutData implements IFormLayoutData {
- public static String EMPTY_DESCRIPTION = "";
+ public static String EMPTY_DESCRIPTION = ""; //$NON-NLS-1$
public static IFormData TAG_LIST = new FormData(
"Tags",
- "", //"Description
- new FormAttributeData[]{new FormAttributeData("tag", 100)},
- new String[]{"AnyElement"},
- FormLayoutDataUtil.createDefaultFormActionData("CreateActions.CreateTag")
+ "", //"Description //$NON-NLS-1$
+ new FormAttributeData[]{new FormAttributeData("tag", 100)}, //$NON-NLS-1$
+ new String[]{"AnyElement"}, //$NON-NLS-1$
+ FormLayoutDataUtil.createDefaultFormActionData("CreateActions.CreateTag") //$NON-NLS-1$
);
private final static IFormData[] FORM_LAYOUT_DEFINITIONS =
new IFormData[] {
new FormData(
- "AnyElement",
+ "AnyElement", //$NON-NLS-1$
new String[]{null},
new IFormData[] {
- new FormData("org.jboss.tools.common.model.ui.forms.AnyElementForm"),
+ new FormData("org.jboss.tools.common.model.ui.forms.AnyElementForm"), //$NON-NLS-1$
new FormData(
"Body Content",
- "", //"Description, description, description",
- new FormAttributeData[]{new FormAttributeData("text", InfoLayoutDataFactory.getInstance())}
+ "", //"Description, description, description", //$NON-NLS-1$
+ new FormAttributeData[]{new FormAttributeData("text", InfoLayoutDataFactory.getInstance())} //$NON-NLS-1$
),
TAG_LIST
}
@@ -80,7 +80,7 @@
*/
public static IFormData createGeneralFormData(XModelEntity entity) {
String entityName = entity.getName();
- XAttribute attr = entity.getAttribute("element type");
+ XAttribute attr = entity.getAttribute("element type"); //$NON-NLS-1$
String kind = attr == null ? entity.getXMLSubPath() : attr.getDefaultValue();
String label = WizardKeys.toDisplayName(kind);
IFormAttributeData[] attrData = FormLayoutDataUtil.createGeneralFormAttributeData(entityName);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/SplitFormContainer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/SplitFormContainer.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/forms/SplitFormContainer.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -84,7 +84,7 @@
}
public Control createControl(Composite parent, IWidgetSettings settings) {
- Composite main = new Composite(parent, settings.getStyle("Composite.Style"));
+ Composite main = new Composite(parent, settings.getStyle("Composite.Style")); //$NON-NLS-1$
settings.setupControl(main);
main.setLayout(getLayout());
main.setLayoutData(getLayoutData());
@@ -94,7 +94,7 @@
GridData gd;
// 1
- Composite fistFormComposite = new Composite(composite, settings.getStyle("Composite.Style"));
+ Composite fistFormComposite = new Composite(composite, settings.getStyle("Composite.Style")); //$NON-NLS-1$
settings.setupControl(fistFormComposite);
fistFormComposite.setLayout(getLayout());
gd = new GridData(GridData.FILL_BOTH);
@@ -106,7 +106,7 @@
// 2
- Composite secondFormComposite = new Composite(composite, settings.getStyle("Composite.Style"));
+ Composite secondFormComposite = new Composite(composite, settings.getStyle("Composite.Style")); //$NON-NLS-1$
settings.setupControl(secondFormComposite);
secondFormComposite.setLayout(getLayout());
gd = new GridData(GridData.FILL_BOTH);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/image/XModelObjectImageDescriptor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/image/XModelObjectImageDescriptor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/image/XModelObjectImageDescriptor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -33,7 +33,7 @@
public Image createImage(boolean returnMissingImageOnError, Device device) {
int code = xicon.getIconHash();
if (code == 0) return null;
- String key = "" + code;
+ String key = "" + code; //$NON-NLS-1$
Image img = (Image)imageCache.get(key);
if (img != null) return img;
img = xicon.getEclipseImage();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/FilteredTreeContentProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/FilteredTreeContentProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/FilteredTreeContentProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -43,7 +43,7 @@
}
if (result == null) {
try {
- String classname = model.getMetaData().getMapping("FilteredTrees").getValue(filteredTreeName);
+ String classname = model.getMetaData().getMapping("FilteredTrees").getValue(filteredTreeName); //$NON-NLS-1$
result = (XFilteredTree)getClass().getClassLoader().loadClass(classname).newInstance();
result.setModel(model);
} catch (InstantiationException e) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/LabelDecoratorImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/LabelDecoratorImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/LabelDecoratorImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,9 +21,9 @@
import org.jboss.tools.common.model.ui.ModelUIImages;
public class LabelDecoratorImpl implements ILabelDecorator {
- public static Image emptyImage = ModelUIImages.getImage("empty_co.gif");
- public static Image errorImage = ModelUIImages.getImage("error_co.gif");
- public static Image warningImage = ModelUIImages.getImage("warning_co.gif");
+ public static Image emptyImage = ModelUIImages.getImage("empty_co.gif"); //$NON-NLS-1$
+ public static Image errorImage = ModelUIImages.getImage("error_co.gif"); //$NON-NLS-1$
+ public static Image warningImage = ModelUIImages.getImage("warning_co.gif"); //$NON-NLS-1$
List<ILabelProviderListener> listeners = new ArrayList<ILabelProviderListener>();
static Map<Image,Image> errorImages = new HashMap<Image,Image>();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorLabelProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorLabelProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorLabelProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,7 +23,7 @@
public class NavigatorLabelProvider extends LabelProvider implements IColorProvider {
public String getText(Object element) {
- String result = "";
+ String result = ""; //$NON-NLS-1$
if (element != null) {
if (element instanceof XModelObject) {
XModelObject o = (XModelObject)element;
@@ -32,11 +32,11 @@
} else
result = element.toString();
}
- return (result == null) ? "" : result;
+ return (result == null) ? "" : result; //$NON-NLS-1$
}
protected String applyModification(XModelObject o, String text) {
- if(o.getFileType() == XFileObject.FILE && o.isModified()) text += "*";
+ if(o.getFileType() == XFileObject.FILE && o.isModified()) text += "*"; //$NON-NLS-1$
return text;
}
@@ -62,11 +62,11 @@
}
private boolean isLink(XModelObject obj) {
- return "true".equals(obj.get("overlapped"));
+ return "true".equals(obj.get("overlapped")); //$NON-NLS-1$ //$NON-NLS-2$
}
private boolean hasErrors(XModelObject o) {
- return o != null && "yes".equals(o.get("_hasErrors_"));
+ return o != null && "yes".equals(o.get("_hasErrors_")); //$NON-NLS-1$ //$NON-NLS-2$
}
private boolean hasParentFileErrors(XModelObject o) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorStatusLineProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorStatusLineProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/NavigatorStatusLineProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.navigator;
+import java.text.MessageFormat;
import org.eclipse.core.resources.IResource;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.jboss.tools.common.model.XModelObject;
@@ -23,13 +24,13 @@
if (o instanceof XModelObject) {
return getStatusLineMessage((XModelObject)o);
} else {
- return "";
+ return ""; //$NON-NLS-1$
}
}
if (selection.size() > 1) {
- return "" + selection.size() + " items selected";
+ return MessageFormat.format("{0} items selected", selection.size());
}
- return "";
+ return ""; //$NON-NLS-1$
}
protected String getStatusLineMessage(XModelObject object) {
@@ -42,15 +43,15 @@
private String getStatusLineMessageForResource(XModelObject object) {
IResource resource = EclipseResourceUtil.getResource(object);
- String msg = (resource == null) ? "" : resource.getFullPath().makeRelative().toString();
+ String msg = (resource == null) ? "" : resource.getFullPath().makeRelative().toString(); //$NON-NLS-1$
if(msg.length() == 0 && object.getFileType() == XModelObject.SYSTEM) {
- msg = XModelObjectUtil.expand("" + object.get("location"), object.getModel(), null);
+ msg = XModelObjectUtil.expand("" + object.get("location"), object.getModel(), null); //$NON-NLS-1$ //$NON-NLS-2$
}
return (msg.length() == 0) ? object.getPathPart() : msg;
}
private String getStatusLineMessageForFileFragment(XModelObject object) {
- if(object == null) return "";
+ if(object == null) return ""; //$NON-NLS-1$
if(!object.isActive()) return object.getPresentationString();
XModelObject f = object.getParent();
while(f != null && f.getFileType() == XModelObject.NONE) f = f.getParent();
@@ -64,7 +65,7 @@
}
String relative = sb.toString();
String parent = getStatusLineMessageForResource(f);
- return relative + " - " + parent;
+ return relative + " - " + parent; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeDragDropProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeDragDropProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeDragDropProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -41,7 +41,7 @@
public Properties getDropProperties(int x, int y) {
Properties p = new Properties();
- p.setProperty("actionSourceGUIComponentID", "navigator");
+ p.setProperty("actionSourceGUIComponentID", "navigator"); //$NON-NLS-1$ //$NON-NLS-2$
return p;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeViewerModelListenerImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeViewerModelListenerImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/TreeViewerModelListenerImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -87,7 +87,7 @@
// }
} else if(event.kind() == XModelTreeEvent.CHILD_REMOVED) {
if(selected != null && !selected.isActive() &&
- event.getInfo().toString().endsWith("/" + selected.getPathPart())) {
+ event.getInfo().toString().endsWith("/" + selected.getPathPart())) { //$NON-NLS-1$
setSelection(event.getModelObject());
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/AttributeDecoratorPart.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/AttributeDecoratorPart.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/AttributeDecoratorPart.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,7 +17,7 @@
*/
public class AttributeDecoratorPart implements IDecoratorPart {
Variable variable;
- String parameters = "";
+ String parameters = ""; //$NON-NLS-1$
public AttributeDecoratorPart(Variable variable) {
this.variable = variable;
@@ -32,7 +32,7 @@
return variable.custom.getLabelPart(object, parameters);
}
String v = object.getAttributeValue(variable.getName());
- return v == null ? "{" + variable.getName() + "}" : v;
+ return v == null ? "{" + variable.getName() + "}" : v; //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorConstants.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorConstants.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorConstants.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -15,30 +15,30 @@
*/
public interface DecoratorConstants {
- public String ATTR_NAME = "name";
+ public String ATTR_NAME = "name"; //$NON-NLS-1$
- public String ATTR_PARTITION = "partition";
+ public String ATTR_PARTITION = "partition"; //$NON-NLS-1$
- public String ATTR_ENTITIES = "entities";
+ public String ATTR_ENTITIES = "entities"; //$NON-NLS-1$
- public String ATTR_ENTITY = "entity";
+ public String ATTR_ENTITY = "entity"; //$NON-NLS-1$
- public String ATTR_DEFAULT = "defaultValue";
+ public String ATTR_DEFAULT = "defaultValue"; //$NON-NLS-1$
- public String ATTR_DESCRIPTION = "description";
+ public String ATTR_DESCRIPTION = "description"; //$NON-NLS-1$
- public String ATTR_VALUE = "value";
+ public String ATTR_VALUE = "value"; //$NON-NLS-1$
- public String ATTR_CLASS = "class";
+ public String ATTR_CLASS = "class"; //$NON-NLS-1$
- public String NODE_VARIABLE = "variable";
+ public String NODE_VARIABLE = "variable"; //$NON-NLS-1$
- public String NODE_EXAMPLE = "example";
+ public String NODE_EXAMPLE = "example"; //$NON-NLS-1$
- public String NODE_PUT = "put";
+ public String NODE_PUT = "put"; //$NON-NLS-1$
- public String RULE_OPENING = "{";
+ public String RULE_OPENING = "{"; //$NON-NLS-1$
- public String RULE_CLOSING = "}";
+ public String RULE_CLOSING = "}"; //$NON-NLS-1$
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorManager.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorManager.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -29,7 +29,7 @@
* @author Viacheslav Kabanovich
*/
public class DecoratorManager {
- public static final String EXTENSION_POINT_ID = ModelUIPlugin.PLUGIN_ID + ".labelDecorator";
+ public static final String EXTENSION_POINT_ID = ModelUIPlugin.PLUGIN_ID + ".labelDecorator"; //$NON-NLS-1$
private Map<String, XModelObjectDecorator> mapByName = new HashMap<String, XModelObjectDecorator>();
private Map<String, XModelObjectDecorator> mapByEntity = new HashMap<String, XModelObjectDecorator>();
@@ -87,7 +87,7 @@
set.add(d);
for (String entity: entities) {
mapByEntity.put(entity, d);
- if(entity.startsWith("File") && entityByPartition.get(partition) == null) {
+ if(entity.startsWith("File") && entityByPartition.get(partition) == null) { //$NON-NLS-1$
entityByPartition.put(partition, entity);
}
}
@@ -100,7 +100,7 @@
IPreferenceStore p = getPreferences();
for (String name: mapByName.keySet()) {
XModelObjectDecorator d = mapByName.get(name);
- String key = ModelUIPlugin.PLUGIN_ID + ".labelDecorator." + name;
+ String key = ModelUIPlugin.PLUGIN_ID + ".labelDecorator." + name; //$NON-NLS-1$
String value = p.getString(key);
if(value != null && value.length() > 0) {
d.setValue(value);
@@ -112,12 +112,12 @@
IPreferenceStore p = getPreferences();
for (String name: mapByName.keySet()) {
XModelObjectDecorator d = mapByName.get(name);
- String key = ModelUIPlugin.PLUGIN_ID + ".labelDecorator." + name;
+ String key = ModelUIPlugin.PLUGIN_ID + ".labelDecorator." + name; //$NON-NLS-1$
String value = d.getValue();
- if(value != null && !value.equals(d.getDefaultValue()) && !value.equals("{name}")) {
+ if(value != null && !value.equals(d.getDefaultValue()) && !value.equals("{name}")) { //$NON-NLS-1$
p.setValue(key, value);
} else {
- p.setValue(key, "");
+ p.setValue(key, ""); //$NON-NLS-1$
}
}
if(p instanceof IPersistentPreferenceStore) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorPart.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorPart.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/DecoratorPart.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,7 +23,7 @@
}
public String getLabelPart(XModelObject object) {
- return value == null ? "" : value;
+ return value == null ? "" : value; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/NameDecoratorPart.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/NameDecoratorPart.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/NameDecoratorPart.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,7 +22,7 @@
}
public String getLabelPart(XModelObject object) {
- return "" + object.getPresentationString();
+ return "" + object.getPresentationString(); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/Variable.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/Variable.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/Variable.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,10 +18,10 @@
* @author Viacheslav Kabanovich
*/
public class Variable implements DecoratorConstants {
- public static Variable NAME = new Variable("name", "default label");
+ public static Variable NAME = new Variable("name", "default label"); //$NON-NLS-1$ //$NON-NLS-2$
String name;
- String parameters = "";
+ String parameters = ""; //$NON-NLS-1$
String description;
ICustomVariable custom;
@@ -48,7 +48,7 @@
if(description == null || description.length() == 0) {
return name;
}
- return name + parameters + " - " + description;
+ return name + parameters + " - " + description; //$NON-NLS-1$
}
public void load(IConfigurationElement element) {
@@ -66,7 +66,7 @@
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
} catch (ClassCastException e1) {
- ModelUIPlugin.getPluginLog().logError("Attribute " + ATTR_CLASS + " must be instanceof ICustomVariable", e1);
+ ModelUIPlugin.getPluginLog().logError("Attribute " + ATTR_CLASS + " must be instanceof ICustomVariable", e1); //$NON-NLS-1$ //$NON-NLS-2$
}
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/XModelObjectDecorator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/XModelObjectDecorator.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/navigator/decorator/XModelObjectDecorator.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -90,7 +90,7 @@
value = defaultValue;
String s = element.getAttribute(ATTR_ENTITIES);
if(s != null) {
- String[] es = s.split(",");
+ String[] es = s.split(","); //$NON-NLS-1$
for (int i = 0; i < es.length; i++) entities.add(es[i]);
}
IConfigurationElement[] cs = element.getChildren(NODE_VARIABLE);
@@ -119,9 +119,9 @@
List<IDecoratorPart> parts = new ArrayList<IDecoratorPart>();
String v = value;
if(value == null || value.length() == 0) v = defaultValue;
- if(v == null) v = "";
+ if(v == null) v = ""; //$NON-NLS-1$
if(v.indexOf(RULE_OPENING) < 0) {
- if(v.length() > 0) v = " " + v;
+ if(v.length() > 0) v = " " + v; //$NON-NLS-1$
v = Variable.NAME.getRuleText() + v;
}
StringTokenizer s = new StringTokenizer(v, RULE_OPENING + RULE_CLOSING, true);
@@ -134,7 +134,7 @@
inVariable = false;
} else if(inVariable) {
String n = t;
- String p = "";
+ String p = ""; //$NON-NLS-1$
int i = t.indexOf('(');
int j = t.indexOf(')');
if(i >= 0 && j > i) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -24,7 +24,7 @@
public class ExtendedPropertiesEditor {
static Color DEFAULT_COLOR = new Color(null, 0, 0, 0);
static Color DISABLED_COLOR = new Color(null, 127, 127, 127);
- static Image EMPTY = EclipseResourceUtil.getImage("images/actions/empty.gif");
+ static Image EMPTY = EclipseResourceUtil.getImage("images/actions/empty.gif"); //$NON-NLS-1$
protected XTable xtable = new XTable();
protected ExtendedProperties attributes;
protected ICellModifier modifier = new CellModifierImpl();
@@ -41,10 +41,10 @@
stopEditing();
this.attributes = attributes;
if(attributes != null) {
- context.setProperty("nodeName", "" + attributes.getNodeName());
+ context.setProperty("nodeName", "" + attributes.getNodeName()); //$NON-NLS-1$ //$NON-NLS-2$
cellEditorProvider = attributes.createCellEditorProvider();
if(attributes.getNode() != null) {
- context.put("node", attributes.getNode());
+ context.put("node", attributes.getNode()); //$NON-NLS-1$
}
}
if(xtable.getTable() == null || xtable.getTable().isDisposed()) return;
@@ -62,7 +62,7 @@
public Control createControl(Composite parent, int style) {
xtable.createControl(parent, style);
- xtable.getViewer().setColumnProperties(new String[]{"name", "value"});
+ xtable.getViewer().setColumnProperties(new String[]{"name", "value"}); //$NON-NLS-1$ //$NON-NLS-2$
xtable.getViewer().setCellModifier(modifier);
if(!readOnly) {
CellEditor cellEditor = (cellEditorProvider != null)
@@ -119,7 +119,7 @@
public String getValueAt(int r, int c) {
String name = attributes.getAttributes()[r];
- return (c == 0) ? name : "" + attributes.getAttributeValue(name);
+ return (c == 0) ? name : "" + attributes.getAttributeValue(name); //$NON-NLS-1$
}
public Object getDataAt(int r) {
@@ -151,7 +151,7 @@
class CellModifierImpl implements ICellModifier {
public boolean canModify(Object element, String property) {
- if(!"value".equals(property)) return false;
+ if(!"value".equals(property)) return false; //$NON-NLS-1$
AttributeWrapper v = (AttributeWrapper)element;
return v != null && v.attributes.isEditableAttribute(v.name);
}
@@ -165,7 +165,7 @@
if(v == null || v.value == null) return;
String stringValue = v.value;
String old = v.attributes.getAttributeValue(v.name);
- if("".equals(stringValue)) {
+ if("".equals(stringValue)) { //$NON-NLS-1$
if(old == null || old.length() == 0) return;
} else {
if(old != null && old.equals(stringValue)) return;
@@ -195,7 +195,7 @@
}
protected void doSetValue(Object value) {
wrapper = (AttributeWrapper)value;
- super.doSetValue(wrapper == null ? "" : wrapper.attributes.getAttributeValue(wrapper.name));
+ super.doSetValue(wrapper == null ? "" : wrapper.attributes.getAttributeValue(wrapper.name)); //$NON-NLS-1$
setValueValid(true);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/ExtendedPropertiesWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,8 +26,8 @@
public static void run(ExtendedProperties attributes) {
ExtendedPropertiesWizard wizard = new ExtendedPropertiesWizard();
Properties p = new Properties();
- p.put("extendedProperties", attributes);
- p.put("model", PreferenceModelUtilities.getPreferenceModel());
+ p.put("extendedProperties", attributes); //$NON-NLS-1$
+ p.put("model", PreferenceModelUtilities.getPreferenceModel()); //$NON-NLS-1$
wizard.setObject(p);
wizard.execute();
}
@@ -53,13 +53,13 @@
public void setObject(Object data) {
super.setObject(data);
Properties p = findProperties(data);
- ExtendedProperties attributes = (ExtendedProperties)p.get("extendedProperties");
+ ExtendedProperties attributes = (ExtendedProperties)p.get("extendedProperties"); //$NON-NLS-1$
objectEditor.setExtendedProperties(attributes);
- boolean viewMode = p != null && "true".equals(p.getProperty("viewMode"));
+ boolean viewMode = p != null && "true".equals(p.getProperty("viewMode")); //$NON-NLS-1$ //$NON-NLS-2$
objectEditor.setReadOnly(viewMode);
setWindowTitle("Attributes");
String nodeName = attributes.getNodeName();
- setTitle((nodeName != null) ? "<" + nodeName + ">" : "");
+ setTitle((nodeName != null) ? "<" + nodeName + ">" : ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
public Control createControl(Composite parent) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/PropertiesWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/PropertiesWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/PropertiesWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -53,9 +53,9 @@
objectEditor.setModelObject((XModelObject)dataObject);
Properties p = findProperties(data);
if(windowTitle == null) {
- windowTitle = WizardKeys.getHeader("Properties");
+ windowTitle = WizardKeys.getHeader("Properties"); //$NON-NLS-1$
}
- boolean viewMode = p != null && "true".equals(p.getProperty("viewMode"));
+ boolean viewMode = p != null && "true".equals(p.getProperty("viewMode")); //$NON-NLS-1$ //$NON-NLS-2$
objectEditor.setViewMode(viewMode);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/SaveUnopenSpecialWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/SaveUnopenSpecialWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/SaveUnopenSpecialWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -35,8 +35,8 @@
IEditorPart editor = workbenchPage.findEditor(input);
if(editor != null) return 0;
}
- if(object != null && XActionInvoker.getAction("SaveActions.Save", object) != null) {
- XActionInvoker.invoke("SaveActions.Save", object, null);
+ if(object != null && XActionInvoker.getAction("SaveActions.Save", object) != null) { //$NON-NLS-1$
+ XActionInvoker.invoke("SaveActions.Save", object, null); //$NON-NLS-1$
}
return 0;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XCellModifier.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XCellModifier.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XCellModifier.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,7 +17,7 @@
public class XCellModifier implements ICellModifier {
public boolean canModify(Object element, String property) {
- if(!"value".equals(property)) return false;
+ if(!"value".equals(property)) return false; //$NON-NLS-1$
XAttributeInfo v = (XAttributeInfo)element;
return v != null && v.isEditable();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XModelObjectEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XModelObjectEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XModelObjectEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
public class XModelObjectEditor {
static Color DEFAULT_COLOR = new Color(null, 0, 0, 0);
static Color DISABLED_COLOR = new Color(null, 127, 127, 127);
- static Image EMPTY = EclipseResourceUtil.getImage("images/actions/empty.gif");
+ static Image EMPTY = EclipseResourceUtil.getImage("images/actions/empty.gif"); //$NON-NLS-1$
protected XTable xtable = new XTable();
protected XModelObject object = null;
protected XAttribute[] attributes = new XAttribute[0];
@@ -62,7 +62,7 @@
public Control createControl(Composite parent, int style) {
updateTimeStamp = -1;
xtable.createControl(parent, style);
- xtable.getViewer().setColumnProperties(new String[]{"name", "value"});
+ xtable.getViewer().setColumnProperties(new String[]{"name", "value"}); //$NON-NLS-1$ //$NON-NLS-2$
xtable.getViewer().setCellModifier(modifier);
if(!viewMode) {
xtable.getViewer().setCellEditors(new CellEditor[]{null, new XCellEditor(xtable.getTable())});
@@ -127,7 +127,7 @@
return labelText;
}
- String v = "" + object.getAttributeValue(attributes[r].getName());
+ String v = "" + object.getAttributeValue(attributes[r].getName()); //$NON-NLS-1$
if(attributes[r].getConstraint() instanceof XAttributeConstraintAList) {
v = WizardKeys.getVisualListValue(attributes[r], v);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XTable.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XTable.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/objecteditor/XTable.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -208,7 +208,7 @@
}
public static String toVisualValue(String v) {
- if(v == null) return "";
+ if(v == null) return ""; //$NON-NLS-1$
if(v.indexOf('\n') >= 0) v = v.replace('\n', ' ');
if(v.indexOf('\t') >= 0) v = v.replace('\t', ' ');
if(v.indexOf('\r') >= 0) v = v.replace('\r', ' ');
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/OutlineMenuInvoker.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/OutlineMenuInvoker.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/OutlineMenuInvoker.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
public XActionList getActionList(XModelObject o) {
if(o.getFileType() != XModelObject.FILE) return super.getActionList(o);
- String ent = o.getModelEntity().getName() + "_EditorActionList";
+ String ent = o.getModelEntity().getName() + "_EditorActionList"; //$NON-NLS-1$
XModelEntity entity = o.getModel().getMetaData().getEntity(ent);
return (entity != null) ? entity.getActionList() : super.getActionList(o);
}
@@ -33,14 +33,14 @@
public void mouseDoubleClick(MouseEvent e) {
XModelObject o = getModelObjectAt(new Point(e.x, e.y));
if (o == null || o.getFileType() != XModelObject.NONE) return;
- if(XActionInvoker.getAction(o.getModelEntity(), "Open") != null) {
- XActionInvoker.invoke("Open", o, new Properties());
- } else if(XActionInvoker.getAction(o.getModelEntity(), "Properties.Properties") != null) {
- XActionInvoker.invoke("Properties.Properties", o, new Properties());
+ if(XActionInvoker.getAction(o.getModelEntity(), "Open") != null) { //$NON-NLS-1$
+ XActionInvoker.invoke("Open", o, new Properties()); //$NON-NLS-1$
+ } else if(XActionInvoker.getAction(o.getModelEntity(), "Properties.Properties") != null) { //$NON-NLS-1$
+ XActionInvoker.invoke("Properties.Properties", o, new Properties()); //$NON-NLS-1$
}
}
protected void fillRunningProperties(Properties p) {
- p.setProperty("actionSourceGUIComponentID", "editor");
+ p.setProperty("actionSourceGUIComponentID", "editor"); //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/XModelObjectContentOutlineProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/XModelObjectContentOutlineProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/outline/XModelObjectContentOutlineProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -63,7 +63,7 @@
public void createControl(Composite parent) {
super.createControl(parent);
- selectionProvider.addHost("tree", getTreeViewer(), true);
+ selectionProvider.addHost("tree", getTreeViewer(), true); //$NON-NLS-1$
getSite().setSelectionProvider(selectionProvider);
getTreeViewer().setContentProvider(content);
getTreeViewer().setInput(cache);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesListener.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesListener.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesListener.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -38,7 +38,7 @@
public void propertyChange(PropertyChangeEvent event) {
String s = event.getProperty();
- if(s.startsWith(DecoratorManager.EXTENSION_POINT_ID + ".")) {
+ if(s.startsWith(DecoratorManager.EXTENSION_POINT_ID + ".")) { //$NON-NLS-1$
if(viewer != null && viewer.getControl() != null && !viewer.getControl().isDisposed()) {
viewer.refresh(true);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/DecoratorPreferencesPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -24,7 +24,7 @@
*/
public class DecoratorPreferencesPage extends PreferencePage implements IWorkbenchPreferencePage {
- public static final String ID = "org.jboss.tools.common.model.ui.decorator";
+ public static final String ID = "org.jboss.tools.common.model.ui.decorator"; //$NON-NLS-1$
DecoratorGeneralPreferencesPage general = new DecoratorGeneralPreferencesPage();
DecoratorTextPreferencesPage text = new DecoratorTextPreferencesPage();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/TabbedPreferencesPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/TabbedPreferencesPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/TabbedPreferencesPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -52,9 +52,9 @@
private List convertPathArrayToPreferencePageList(String[] path) {
XModel model = getPreferenceModel();
- if(model==null) throw new IllegalArgumentException("Preference XModel not loaded.");
- if(path==null) throw new IllegalArgumentException("String array with path's cannot be null");
- if(path.length==0) throw new IllegalArgumentException("Path array should contains at least one element.");
+ if(model==null) throw new IllegalArgumentException("Preference XModel not loaded."); //$NON-NLS-1$
+ if(path==null) throw new IllegalArgumentException("String array with path's cannot be null"); //$NON-NLS-1$
+ if(path.length==0) throw new IllegalArgumentException("Path array should contains at least one element."); //$NON-NLS-1$
List<XMOBasedPreferencesPage> pages = new ArrayList<XMOBasedPreferencesPage>();
for (int i = 0; i < path.length; i++) {
XModelObject o = model.getByPath(path[i]);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/XMOBasedPreferencesPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/XMOBasedPreferencesPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/preferences/XMOBasedPreferencesPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -56,7 +56,7 @@
public String getTitle() {
String value = support.getTitle();
if(object != null) {
- String s = WizardKeys.getVisualListValue(object.getModelEntity().getAttribute("name"), value);
+ String s = WizardKeys.getVisualListValue(object.getModelEntity().getAttribute("name"), value); //$NON-NLS-1$
if(s != null) {
return s;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/Problem.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/Problem.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/Problem.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,7 +19,7 @@
*/
public class Problem {
- public static final String ERROR = "Problem.Error";
+ public static final String ERROR = "Problem.Error"; //$NON-NLS-1$
public static final int NONE = -1;
@@ -133,7 +133,7 @@
}
public String toString() {
- return "type=" + type + " location=" + location + " message=" + message + " line=" + line + " column=" + column;
+ return "type=" + type + " location=" + location + " message=" + message + " line=" + line + " column=" + column; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ProblemDialog.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ProblemDialog.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ProblemDialog.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,7 +30,7 @@
public ProblemDialog(Shell shell, Problem error) {
super(shell);
setShellStyle(SWT.DIALOG_TRIM | SWT.APPLICATION_MODAL);
- this.title = (error.getTitle()!=null)?error.getTitle():"";
+ this.title = (error.getTitle()!=null)?error.getTitle():""; //$NON-NLS-1$
this.message = error.getMessage();
if (error.getLine()!=Problem.NONE) this.message = this.message + " at line:" + error.getLine();
if (error.getColumn()!=Problem.NONE) this.message = this.message + " column:" + error.getColumn();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ResourceProblemManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ResourceProblemManager.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/problem/ResourceProblemManager.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -96,8 +96,8 @@
}
private Problem getProblem(IMarker marker) {
- String message = marker.getAttribute(IMarker.MESSAGE, "");
- String location = marker.getAttribute(IMarker.LOCATION, "");
+ String message = marker.getAttribute(IMarker.MESSAGE, ""); //$NON-NLS-1$
+ String location = marker.getAttribute(IMarker.LOCATION, ""); //$NON-NLS-1$
int line = marker.getAttribute(IMarker.LINE_NUMBER, -1);
int position = marker.getAttribute(IMarker.CHAR_START, -1);
String type = IMarker.PROBLEM;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ProblemReporter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ProblemReporter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ProblemReporter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -45,11 +45,11 @@
}
private boolean isShowProblemDialogOn() {
- return "yes".equals(ReportPreference.SHOW_ERROR_DIALOG_OPTION.getValue());
+ return "yes".equals(ReportPreference.SHOW_ERROR_DIALOG_OPTION.getValue()); //$NON-NLS-1$
}
private boolean isSubmitProblemAutomaticallyOn() {
- return "yes".equals(ReportPreference.SUBMIT_AUTOMATICALLY_OPTION.getValue());
+ return "yes".equals(ReportPreference.SUBMIT_AUTOMATICALLY_OPTION.getValue()); //$NON-NLS-1$
}
private int showProblemDialog(IStatus status) {
@@ -65,7 +65,7 @@
if(message == null) message = t.getMessage();
if(message != null) {
ps.print(message);
- ps.print("\n");
+ ps.print("\n"); //$NON-NLS-1$
}
t.printStackTrace(ps);
if((t instanceof SWTError) && (((SWTError)t).throwable != null)) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportPreference.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportPreference.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportPreference.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -13,13 +13,13 @@
import org.jboss.tools.common.model.options.Preference;
public class ReportPreference extends Preference {
- public static final String OPTIONS_REPORT_PROBLEM_PATH = "%Options%/Struts Studio/Report Problem";
- public static final String ATT_SHOW_ERROR_DIALOG = "showErrorDialog";
- public static final String ATT_SUBMIT_AUTOMATICALLY = "submitProblemAutomatically";
- public static final String ATT_E_MAIL = "eMail";
- public static final String ATT_OTHER = "other";
- public static final String ATT_ATTACH_REDHAT_LOG = "attachRedHatLog";
- public static final String ATT_ATTACH_ECLIPSE_LOG = "attachEclipseLog";
+ public static final String OPTIONS_REPORT_PROBLEM_PATH = "%Options%/Struts Studio/Report Problem"; //$NON-NLS-1$
+ public static final String ATT_SHOW_ERROR_DIALOG = "showErrorDialog"; //$NON-NLS-1$
+ public static final String ATT_SUBMIT_AUTOMATICALLY = "submitProblemAutomatically"; //$NON-NLS-1$
+ public static final String ATT_E_MAIL = "eMail"; //$NON-NLS-1$
+ public static final String ATT_OTHER = "other"; //$NON-NLS-1$
+ public static final String ATT_ATTACH_REDHAT_LOG = "attachRedHatLog"; //$NON-NLS-1$
+ public static final String ATT_ATTACH_ECLIPSE_LOG = "attachEclipseLog"; //$NON-NLS-1$
public static final ReportPreference SHOW_ERROR_DIALOG_OPTION = new ReportPreference(OPTIONS_REPORT_PROBLEM_PATH, ATT_SHOW_ERROR_DIALOG);
public static final ReportPreference SUBMIT_AUTOMATICALLY_OPTION = new ReportPreference(OPTIONS_REPORT_PROBLEM_PATH, ATT_SUBMIT_AUTOMATICALLY);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportProblemWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportProblemWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/reporting/ReportProblemWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -95,13 +95,13 @@
class ReportProblemWizardView extends AbstractQueryWizardView {
/** LOG_DATE_FORMAT */
final private static SimpleDateFormat LOG_DATE_FORMAT = new SimpleDateFormat(
- "yyyyMMddHHmmss");
+ "yyyyMMddHHmmss"); //$NON-NLS-1$
final private static SimpleDateFormat CURENT_DATE_FORMAT = new SimpleDateFormat(
- "yyyy-MM-dd");
+ "yyyy-MM-dd"); //$NON-NLS-1$
final private static SimpleDateFormat SESSION_DATE_FORMAT = new SimpleDateFormat(
- "yyyy-MM-dd HH:mm");
+ "yyyy-MM-dd HH:mm"); //$NON-NLS-1$
final private static long TWENTY_FOUR_HOURS = 86400000;
@@ -125,20 +125,20 @@
XModelObject exceptionsObject = PreferenceModelUtilities
.getPreferenceModel()
- .createModelObject("ProblemBufferEditor", null);
+ .createModelObject("ProblemBufferEditor", null); //$NON-NLS-1$
XEntityData sendData = XEntityDataImpl.create(new String[][] {
- { "SharableReportProblem" },
- { ReportPreference.ATT_ATTACH_REDHAT_LOG, "no" },
+ { "SharableReportProblem" }, //$NON-NLS-1$
+ { ReportPreference.ATT_ATTACH_REDHAT_LOG, "no" }, //$NON-NLS-1$
// {ReportPreference.ATT_ATTACH_ECLIPSE_LOG, "no"}
});
XEntityData sendData2 = XEntityDataImpl
- .create(new String[][] { { "SharableReportProblem" },
+ .create(new String[][] { { "SharableReportProblem" }, //$NON-NLS-1$
// {ReportPreference.ATT_ATTACH_ECLIPSE_LOG, "no"}
});
XEntityData infoData = XEntityDataImpl.create(new String[][] {
- { "SharableReportProblem" }, { ReportPreference.ATT_E_MAIL, "no" },
- { ReportPreference.ATT_OTHER, "no" } });
+ { "SharableReportProblem" }, { ReportPreference.ATT_E_MAIL, "no" }, //$NON-NLS-1$ //$NON-NLS-2$
+ { ReportPreference.ATT_OTHER, "no" } }); //$NON-NLS-1$
class PixelConverter {
@@ -256,21 +256,21 @@
};
private String getLogByCurentDate(String log){
- String lastOldSession="";
+ String lastOldSession=""; //$NON-NLS-1$
boolean isAccept = false;
Date today = new Date();
StringBuffer sb = new StringBuffer();
- StringTokenizer st = new StringTokenizer(log, "\n", true);
+ StringTokenizer st = new StringTokenizer(log, "\n", true); //$NON-NLS-1$
while (st.hasMoreTokens()) {
String t = st.nextToken();
- if(t.startsWith("!SESSION")){
+ if(t.startsWith("!SESSION")){ //$NON-NLS-1$
String dateString = t.substring(9, 25);
try{
Date date = SESSION_DATE_FORMAT.parse(dateString);
long delta = today.getTime()-date.getTime();
if(delta < TWENTY_FOUR_HOURS){
- if(!isAccept) sb.append(lastOldSession+"\n");
+ if(!isAccept) sb.append(lastOldSession+"\n"); //$NON-NLS-1$
sb.append(t);
isAccept = true;
}else{
@@ -297,12 +297,12 @@
private byte[] getUserCommentContent() {
StringBuffer sb = new StringBuffer();
- sb = sb.append("email : ").append(
- ReportPreference.E_MAIL_OPTION.getValue()).append("\n");
- sb = sb.append("description : ").append(problemDescription.getText())
- .append("\n");
- sb.append("other : ").append(ReportPreference.OTHER_OPTION.getValue())
- .append("\n");
+ sb = sb.append("email : ").append( //$NON-NLS-1$
+ ReportPreference.E_MAIL_OPTION.getValue()).append("\n"); //$NON-NLS-1$
+ sb = sb.append("description : ").append(problemDescription.getText()) //$NON-NLS-1$
+ .append("\n"); //$NON-NLS-1$
+ sb.append("other : ").append(ReportPreference.OTHER_OPTION.getValue()) //$NON-NLS-1$
+ .append("\n"); //$NON-NLS-1$
return sb.toString().getBytes();
}
@@ -332,11 +332,11 @@
ZipOutputStream zout = new ZipOutputStream(new FileOutputStream(zipFilename));
try {
- addFileToZip(getEclipseLogContent(), "eclipse.log", zout);
- addFileToZip(getUserCommentContent(), "usercomment.txt", zout);
- addFileToZip(getEclipsePropertiesContent(), "eclipse.properties", zout);
+ addFileToZip(getEclipseLogContent(), "eclipse.log", zout); //$NON-NLS-1$
+ addFileToZip(getUserCommentContent(), "usercomment.txt", zout); //$NON-NLS-1$
+ addFileToZip(getEclipsePropertiesContent(), "eclipse.properties", zout); //$NON-NLS-1$
- ModelUIPlugin.getDefault().logInfo("Wrote diagnostic info to " + zipFilename);
+ ModelUIPlugin.getDefault().logInfo("Wrote diagnostic info to " + zipFilename); //$NON-NLS-1$
} finally {
zout.close();
}
@@ -369,12 +369,12 @@
Date today = new Date();
currentDate = LOG_DATE_FORMAT.format(today);
- return "jbosstools-diagnostics-" + currentDate.toString() + ".zip";
+ return "jbosstools-diagnostics-" + currentDate.toString() + ".zip"; //$NON-NLS-1$ //$NON-NLS-2$
}
private void createStackTracesControl(Composite parent) {
stackTracesCount = ProblemReportingHelper.buffer.getSize();
- exceptionsObject.setAttributeValue("exceptions",
+ exceptionsObject.setAttributeValue("exceptions", //$NON-NLS-1$
formatContent(ProblemReportingHelper.buffer.getContent()));
XEntityData data = (stackTracesCount > 0) ? sendData : sendData2;
boolean isSeparatorNeeded = false;
@@ -437,7 +437,7 @@
fileDialog.setFilterPath(fileName.getParent());
fileDialog.setFileName(fileName.getName());
- String[] filterExt = { "*.zip" };
+ String[] filterExt = { "*.zip" }; //$NON-NLS-1$
fileDialog.setFilterExtensions(filterExt);
String selected = fileDialog.open();
@@ -482,7 +482,7 @@
layout.marginWidth = 10;
panel.setLayout(layout);
Label image = new Label(panel, SWT.NONE);
- image.setImage(ModelUIImages.getImage("warning.gif"));
+ image.setImage(ModelUIImages.getImage("warning.gif")); //$NON-NLS-1$
GridData d = new GridData();
d.widthHint = 16;
image.setLayoutData(d);
@@ -497,7 +497,7 @@
t2.setText(text, 300);
t2.addReferenceListener(new ReferenceListener() {
public void referenceSelected(String reference) {
- XActionInvoker.invoke("EditActions.Edit", exceptionsObject,
+ XActionInvoker.invoke("EditActions.Edit", exceptionsObject, //$NON-NLS-1$
null);
}
});
@@ -508,20 +508,20 @@
sendSupport.store();
if (infoSupport != null)
infoSupport.store();
- String text = CommonPlugin.getEnvironment() + "\n"
+ String text = CommonPlugin.getEnvironment() + "\n" //$NON-NLS-1$
+ problemDescription.getText();
- boolean addRedHatLog = "yes"
+ boolean addRedHatLog = "yes" //$NON-NLS-1$
.equals(ReportPreference.ATTACH_REDHAT_LOG_OPTION.getValue());
if (addRedHatLog && stackTracesCount > 0) {
- String log = exceptionsObject.getAttributeValue("exceptions");
- text += "\n----------Red Hat Log-----------\n" + log + "\n";
+ String log = exceptionsObject.getAttributeValue("exceptions"); //$NON-NLS-1$
+ text += "\n----------Red Hat Log-----------\n" + log + "\n"; //$NON-NLS-1$ //$NON-NLS-2$
}
- boolean addEclipseLog = "yes"
+ boolean addEclipseLog = "yes" //$NON-NLS-1$
.equals(ReportPreference.ATTACH_ECLIPSE_LOG_OPTION.getValue());
if (addEclipseLog) {
String eclipseLog = ProblemReportingHelper.buffer
.getEclipseLogContent();
- text += "\n----------Eclipse Log----------\n" + eclipseLog + "\n";
+ text += "\n----------Eclipse Log----------\n" + eclipseLog + "\n"; //$NON-NLS-1$ //$NON-NLS-2$
}
/*
String email = ReportPreference.E_MAIL_OPTION.getValue();
@@ -546,10 +546,10 @@
private String formatContent(String content) {
StringBuffer sb = new StringBuffer();
- StringTokenizer st = new StringTokenizer(content, "\n", true);
+ StringTokenizer st = new StringTokenizer(content, "\n", true); //$NON-NLS-1$
while (st.hasMoreTokens()) {
String t = st.nextToken();
- if ("\n".equals(t)) {
+ if ("\n".equals(t)) { //$NON-NLS-1$
sb.append(t);
} else {
while (t.length() > LINE_LIMIT) {
@@ -558,7 +558,7 @@
if (i > 40)
t1 = t1.substring(0, i);
t = t.substring(t1.length());
- sb.append(t1).append("\n");
+ sb.append(t1).append("\n"); //$NON-NLS-1$
}
sb.append(t);
}
@@ -575,11 +575,11 @@
if (sendSupport != null) {
IModelPropertyEditorAdapter a = sendSupport
.getPropertyEditorAdapterByName(ReportPreference.ATT_ATTACH_REDHAT_LOG);
- if (a != null && "yes".equals(a.getValue()))
+ if (a != null && "yes".equals(a.getValue())) //$NON-NLS-1$
return false;
a = sendSupport
.getPropertyEditorAdapterByName(ReportPreference.ATT_ATTACH_ECLIPSE_LOG);
- if (a != null && "yes".equals(a.getValue()))
+ if (a != null && "yes".equals(a.getValue())) //$NON-NLS-1$
return false;
}
String text = problemDescription.getText();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/SelectObjectWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/SelectObjectWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/SelectObjectWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -61,7 +61,7 @@
ISelection s = p.getSite().getSelectionProvider().getSelection();
if(isXModelSelection(s)) {
- IViewPart vs = page.findView("org.eclipse.ui.views.ContentOutline");
+ IViewPart vs = page.findView("org.eclipse.ui.views.ContentOutline"); //$NON-NLS-1$
ISelectionProvider sp = vs == null ? null : vs.getSite().getSelectionProvider();
if(sp != null) {
sp.setSelection(getSelection(object));
@@ -87,7 +87,7 @@
}
String[] views = new String[]{
- "org.jboss.tools.jst.web.ui.navigator.WebProjectsView"
+ "org.jboss.tools.jst.web.ui.navigator.WebProjectsView" //$NON-NLS-1$
// "org.jboss.tools.jsf.ui.navigator.JsfProjectsView",
// "org.jboss.tools.struts.ui.navigator.StrutsProjectsView",
// "org.jboss.tools.common.model.ui.navigator.NavigatorViewPart"
@@ -123,10 +123,10 @@
// First try to find parent file.
XModelObject ofile = o;
while(ofile != null && ofile.getFileType() == XModelObject.NONE) ofile = ofile.getParent();
- if(ofile != null && DnDUtil.getEnabledAction(ofile, null, "Open") != null) return ofile;
+ if(ofile != null && DnDUtil.getEnabledAction(ofile, null, "Open") != null) return ofile; //$NON-NLS-1$
while(o != null) {
- if(DnDUtil.getEnabledAction(o, null, "Open") != null) return o;
+ if(DnDUtil.getEnabledAction(o, null, "Open") != null) return o; //$NON-NLS-1$
if(o.getFileType() != XFileObject.NONE) return null;
o = o.getParent();
}
@@ -136,12 +136,12 @@
private IEditorPart openEditor(XModelObject of) {
Properties p = new Properties();
if(where == FindObjectHelper.IN_NAVIGATOR_AND_IN_EDITOR_IF_OPEN) {
- p.setProperty("onlySelectIfOpen", "true");
+ p.setProperty("onlySelectIfOpen", "true"); //$NON-NLS-1$ //$NON-NLS-2$
}
- if(of != null && XActionInvoker.getAction("Open", of) != null) {
- XActionInvoker.invoke("Open", of, p);
+ if(of != null && XActionInvoker.getAction("Open", of) != null) { //$NON-NLS-1$
+ XActionInvoker.invoke("Open", of, p); //$NON-NLS-1$
}
- return (IEditorPart)p.get("editor");
+ return (IEditorPart)p.get("editor"); //$NON-NLS-1$
}
private XModelObject getSelection(IViewPart part) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/XModelObjectSelectionProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/XModelObjectSelectionProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/select/XModelObjectSelectionProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -127,7 +127,7 @@
Object object = iterator.next();
if (object instanceof XModelObject) {
XModelObject xmo = (XModelObject)object;
- if ("FileJAVA".equals(xmo.getModelEntity().getName())) {
+ if ("FileJAVA".equals(xmo.getModelEntity().getName())) { //$NON-NLS-1$
Object adapter = xmo.getAdapter(ICompilationUnit.class);
if(adapter != null) adaptedObjects.add(adapter);
} else {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/assistent/TemplateContentAssistentProcessor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/assistent/TemplateContentAssistentProcessor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/assistent/TemplateContentAssistentProcessor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -52,9 +52,9 @@
public ICompletionProposal[] computeCompletionProposals(IContentAssistSubjectControl contentAssistSubjectControl, int documentOffset) {
// this method activated on ctrl+space action
ArrayList<ICompletionProposal> proposals = new ArrayList<ICompletionProposal>();
- proposals.add(new TemplateCompletionProposal("1"));
- proposals.add(new TemplateCompletionProposal("2"));
- proposals.add(new TemplateCompletionProposal("3"));
+ proposals.add(new TemplateCompletionProposal("1")); //$NON-NLS-1$
+ proposals.add(new TemplateCompletionProposal("2")); //$NON-NLS-1$
+ proposals.add(new TemplateCompletionProposal("3")); //$NON-NLS-1$
return proposals.toArray(new TemplateCompletionProposal[proposals.size()]);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaClassTemplateHelper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaClassTemplateHelper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaClassTemplateHelper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -65,7 +65,7 @@
public void setProjectOverrideTemplates(boolean b) {
QualifiedName qn = new QualifiedName(ModelUIPlugin.ID_PLUGIN, ModelUIPlugin.PROJECT_OVERRIDE);
try {
- ResourcesPlugin.getWorkspace().getRoot().setPersistentProperty(qn, "" + b);
+ ResourcesPlugin.getWorkspace().getRoot().setPersistentProperty(qn, "" + b); //$NON-NLS-1$
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaConfigurationLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaConfigurationLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/configuration/MetaConfigurationLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,17 +27,17 @@
static {
try {
- String path = FileLocator.resolve(MetaConfigurationLoader.class.getResource("/dtds/meta-templates.dtd")).toString();
- XMLEntityResolver.registerPublicEntity("-//Red Hat Inc.//DTD Meta Templates 1.0//EN", path);
+ String path = FileLocator.resolve(MetaConfigurationLoader.class.getResource("/dtds/meta-templates.dtd")).toString(); //$NON-NLS-1$
+ XMLEntityResolver.registerPublicEntity("-//Red Hat Inc.//DTD Meta Templates 1.0//EN", path); //$NON-NLS-1$
} catch (IOException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
}
- private static final String GLOBAL_FILE_NAME = "/globalTemplates.xml";
- private static final String PROJECT_FILE_NAME = "/.projectTemplates";
+ private static final String GLOBAL_FILE_NAME = "/globalTemplates.xml"; //$NON-NLS-1$
+ private static final String PROJECT_FILE_NAME = "/.projectTemplates"; //$NON-NLS-1$
- public static final String PREFERENCE_KEY = "global_templates";
+ public static final String PREFERENCE_KEY = "global_templates"; //$NON-NLS-1$
public void loadExtensionConfiguration(MetaConfiguration c) {
processExtensions(c);
@@ -111,7 +111,7 @@
private void processExtensions(MetaConfiguration c) {
IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint(EXTENSION_POINT);
if(extensionPoint == null) {
- ModelUIPlugin.getPluginLog().logError("Cannot find extension point \"" + EXTENSION_POINT);
+ ModelUIPlugin.getPluginLog().logError("Cannot find extension point \"" + EXTENSION_POINT); //$NON-NLS-1$
}
IConfigurationElement[] members = extensionPoint.getConfigurationElements();
for (int m = 0; m < members.length; m++) {
@@ -123,7 +123,7 @@
} else if (META_TEMPLATE_GROUP.equals(member.getName())) {
doMetaTemplate(member, c);
} else {
- ModelUIPlugin.getPluginLog().logInfo("Error in declaring extension \"" + EXTENSION_POINT+"\" at " + name);
+ ModelUIPlugin.getPluginLog().logInfo("Error in declaring extension \"" + EXTENSION_POINT+"\" at " + name); //$NON-NLS-1$ //$NON-NLS-2$
}
}
}
@@ -138,7 +138,7 @@
String name = element.getDeclaringExtension().getNamespaceIdentifier();
Bundle bundle = Platform.getBundle(name);
try {
- url = FileLocator.resolve(bundle.getEntry("/"));
+ url = FileLocator.resolve(bundle.getEntry("/")); //$NON-NLS-1$
} catch (IOException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaClassTemplate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaClassTemplate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaClassTemplate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -69,7 +69,7 @@
}
private boolean isOverridingDefaultClass() {
- if(!"java.lang.Object".equals(superClass.getValue())) return false;
+ if(!"java.lang.Object".equals(superClass.getValue())) return false; //$NON-NLS-1$
String pv = (parent == null) ? null : parent.getSuperClass().getValue();
return pv == null || pv.length() == 0;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaTemplateConstants.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaTemplateConstants.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/model/MetaTemplateConstants.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -15,23 +15,23 @@
*/
public interface MetaTemplateConstants {
// Extention point id
- public static final String EXTENSION_POINT = "org.jboss.tools.common.model.ui.metaTemplates";
+ public static final String EXTENSION_POINT = "org.jboss.tools.common.model.ui.metaTemplates"; //$NON-NLS-1$
// Extention point tags
- public static final String PREFIX = "%";
- public static final String INCLUDE = "include";
- public static final String FILE = "file";
- public static final String TRANSLATIONS = "translations";
- public static final String META_TEMPLATE_GROUPS = "meta-template-groups";
- public static final String META_TEMPLATE_GROUP = "meta-templates";
- public static final String META_TEMPLATE = "meta-template";
- public static final String SUPER_CLASS = "super-class";
- public static final String INTERFACE = "interface";
+ public static final String PREFIX = "%"; //$NON-NLS-1$
+ public static final String INCLUDE = "include"; //$NON-NLS-1$
+ public static final String FILE = "file"; //$NON-NLS-1$
+ public static final String TRANSLATIONS = "translations"; //$NON-NLS-1$
+ public static final String META_TEMPLATE_GROUPS = "meta-template-groups"; //$NON-NLS-1$
+ public static final String META_TEMPLATE_GROUP = "meta-templates"; //$NON-NLS-1$
+ public static final String META_TEMPLATE = "meta-template"; //$NON-NLS-1$
+ public static final String SUPER_CLASS = "super-class"; //$NON-NLS-1$
+ public static final String INTERFACE = "interface"; //$NON-NLS-1$
// MetaTemplateGroup
- public static final String URI = "uri";
+ public static final String URI = "uri"; //$NON-NLS-1$
// MetaTemplate
- public static final String AXIS = "axis";
- public static final String DISPLAY_NAME = "displayName";
- public static final String ENTITY = "xEntity";
+ public static final String AXIS = "axis"; //$NON-NLS-1$
+ public static final String DISPLAY_NAME = "displayName"; //$NON-NLS-1$
+ public static final String ENTITY = "xEntity"; //$NON-NLS-1$
// TetaTemplateClass
- public static final String NAME = "name";
+ public static final String NAME = "name"; //$NON-NLS-1$
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/AddInterfaceSupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/AddInterfaceSupport.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/AddInterfaceSupport.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,15 +19,15 @@
public class AddInterfaceSupport extends SpecialWizardSupport {
public static String runAdd(XModel model) {
- return runAdd(model, "CreateActions.AddInterface", "interface");
+ return runAdd(model, "CreateActions.AddInterface", "interface"); //$NON-NLS-1$ //$NON-NLS-2$
}
public static String runAddClass(XModel model) {
- return runAdd(model, "CreateActions.AddClass", "class");
+ return runAdd(model, "CreateActions.AddClass", "class"); //$NON-NLS-1$ //$NON-NLS-2$
}
private static String runAdd(XModel model, String action, String property) {
- String entity = "TemplateClass";
+ String entity = "TemplateClass"; //$NON-NLS-1$
Properties p = new Properties();
XModelObject o = model.createModelObject(entity, p);
XActionInvoker.invoke(action, o, p);
@@ -35,12 +35,12 @@
}
public static String runEdit(XModel model, String current) {
- String entity = "TemplateClass";
+ String entity = "TemplateClass"; //$NON-NLS-1$
Properties p = new Properties();
- if(current != null) p.setProperty("interface", current);
+ if(current != null) p.setProperty("interface", current); //$NON-NLS-1$
XModelObject o = model.createModelObject(entity, p);
- XActionInvoker.invoke("EditActions.EditInterface", o, p);
- return p.getProperty("interface");
+ XActionInvoker.invoke("EditActions.EditInterface", o, p); //$NON-NLS-1$
+ return p.getProperty("interface"); //$NON-NLS-1$
}
@@ -48,7 +48,7 @@
public void reset() {
property = getEntityData()[0].getAttributeData()[0].getAttribute().getName();
- if(property == null) property = "interface";
+ if(property == null) property = "interface"; //$NON-NLS-1$
String current = getProperties().getProperty(property);
if(current != null) setAttributeValue(0, property, current);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/GlobalTemplatePreferencePage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/GlobalTemplatePreferencePage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/GlobalTemplatePreferencePage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,7 +23,7 @@
*/
public class GlobalTemplatePreferencePage extends PreferencePage implements IWorkbenchPreferencePage {
- public static final String GLOBAL_TEMPLATES_PREFERENCES_ID = "org.jboss.tools.common.model.ui.templates";
+ public static final String GLOBAL_TEMPLATES_PREFERENCES_ID = "org.jboss.tools.common.model.ui.templates"; //$NON-NLS-1$
TemplateComponent templateComponent = new TemplateComponent();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/TemplateComponent.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/TemplateComponent.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/templates/preferences/TemplateComponent.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -58,7 +58,7 @@
// checkbox
if(!isGlobal) { //.getString CHECKBOX_LABEL
allowOverrideEditor.setLabelText(Messages.CHECKBOX_LABEL);
- allowOverrideAdapter.setValue("" + MetaClassTemplateHelper.instance. isProjectOverrideTemplates());
+ allowOverrideAdapter.setValue("" + MetaClassTemplateHelper.instance. isProjectOverrideTemplates()); //$NON-NLS-1$
control = getControls(composite, allowOverrideEditor);
control[0].dispose(); // dispose empty label
gd = new GridData(GridData.FILL_HORIZONTAL);
@@ -149,7 +149,7 @@
protected void performApply() {
if(!isGlobal) {
String s = allowOverrideAdapter.getValue().toString();
- MetaClassTemplateHelper.instance.setProjectOverrideTemplates("true".equalsIgnoreCase(s));
+ MetaClassTemplateHelper.instance.setProjectOverrideTemplates("true".equalsIgnoreCase(s)); //$NON-NLS-1$
}
configuration.save();
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/AbstractMultiPageContributor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/AbstractMultiPageContributor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/AbstractMultiPageContributor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -194,8 +194,8 @@
protected void updateStatus() {
if (fActiveEditorPart instanceof ITextEditor) {
ITextEditor textEditor= (ITextEditor) fActiveEditorPart;
- fContentAssistProposal.setAction(getAction(textEditor, "ContentAssistProposal"));
- fContentAssistTip.setAction(getAction(textEditor, "ContentAssistTip"));
+ fContentAssistProposal.setAction(getAction(textEditor, "ContentAssistProposal")); //$NON-NLS-1$
+ fContentAssistTip.setAction(getAction(textEditor, "ContentAssistTip")); //$NON-NLS-1$
}
if (fActiveEditorPart instanceof ITextEditorExtension) {
ITextEditorExtension extension= (ITextEditorExtension) fActiveEditorPart;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/PropertiesTextEditorComponent.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/PropertiesTextEditorComponent.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/PropertiesTextEditorComponent.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -95,7 +95,7 @@
if(getSourceViewer() == null) return null;
if(getSourceViewer().getDocument() == null) return null;
text = getSourceViewer().getDocument().get();
- return (text == null) ? "" : text;
+ return (text == null) ? "" : text; //$NON-NLS-1$
}
public boolean isEditable() {
@@ -227,8 +227,8 @@
public void selectModelObject(XModelObject object) {
String text = getText();
- String name = object.getAttributeValue("name");
- String nvs = object.getAttributeValue("name-value-separator");
+ String name = object.getAttributeValue("name"); //$NON-NLS-1$
+ String nvs = object.getAttributeValue("name-value-separator"); //$NON-NLS-1$
int i = text.indexOf(name + nvs);
if(i < 0) return;
int j = text.indexOf('\n', i);
@@ -309,10 +309,10 @@
XModelObject[] cs = o.getChildren();
String trimmed = txt.trim();
for (int i = 0; i < cs.length; i++) {
- String n = cs[i].getAttributeValue("name");
+ String n = cs[i].getAttributeValue("name"); //$NON-NLS-1$
if(!trimmed.startsWith(n)) continue;
- String sep = cs[i].getAttributeValue("name-value-separator");
- if(sep == null || sep.length() == 0) sep = "=";
+ String sep = cs[i].getAttributeValue("name-value-separator"); //$NON-NLS-1$
+ if(sep == null || sep.length() == 0) sep = "="; //$NON-NLS-1$
int q = trimmed.indexOf('=');
if(q < 0) continue;
String s = trimmed.substring(n.length(), q).trim();
@@ -331,7 +331,7 @@
class RevertToSavedAction3 extends RevertToSavedAction {
PropertiesTextEditorComponent t;
RevertToSavedAction3(PropertiesTextEditorComponent t) {
- super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Revert.", t);
+ super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Revert.", t); //$NON-NLS-1$ //$NON-NLS-2$
this.t = t;
}
public void update() {
@@ -342,7 +342,7 @@
class SaveAction3 extends SaveAction {
PropertiesTextEditorComponent t;
SaveAction3(PropertiesTextEditorComponent t) {
- super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Save.", t);
+ super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Save.", t); //$NON-NLS-1$ //$NON-NLS-2$
this.t = t;
}
public void update() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextActionHelper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextActionHelper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextActionHelper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
public class TextActionHelper {
public static void addCutAction(ITextEditor editor) {
- String property = "Editor.Cut.";
+ String property = "Editor.Cut."; //$NON-NLS-1$
int operationTarget = ITextOperationTarget.CUT;
String contextId = IAbstractTextEditorHelpContextIds.CUT_ACTION;
String definitionId = ITextEditorActionDefinitionIds.CUT;
@@ -30,7 +30,7 @@
}
public static void addCopyAction(ITextEditor editor) {
- String property = "Editor.Copy.";
+ String property = "Editor.Copy."; //$NON-NLS-1$
int operationTarget = ITextOperationTarget.COPY;
String contextId = IAbstractTextEditorHelpContextIds.COPY_ACTION;
String definitionId = ITextEditorActionDefinitionIds.COPY;
@@ -39,7 +39,7 @@
}
public static void addPasteAction(ITextEditor editor) {
- String property = "Editor.Paste.";
+ String property = "Editor.Paste."; //$NON-NLS-1$
int operationTarget = ITextOperationTarget.PASTE;
String contextId = IAbstractTextEditorHelpContextIds.PASTE_ACTION;
String definitionId = ITextEditorActionDefinitionIds.PASTE;
@@ -48,7 +48,7 @@
}
public static void addDeleteAction(ITextEditor editor) {
- String property = "Editor.Delete.";
+ String property = "Editor.Delete."; //$NON-NLS-1$
int operationTarget = ITextOperationTarget.DELETE;
String contextId = IAbstractTextEditorHelpContextIds.DELETE_ACTION;
String definitionId = ITextEditorActionDefinitionIds.DELETE;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorComponent.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorComponent.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorComponent.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -100,8 +100,8 @@
protected String loadContent() {
XModelObject o = getModelObject();
- String content = (o == null? "": o.get("body"));
- content = (content == null ? "" : content);
+ String content = (o == null? "": o.get("body")); //$NON-NLS-1$ //$NON-NLS-2$
+ content = (content == null ? "" : content); //$NON-NLS-1$
return content;
}
@@ -189,7 +189,7 @@
public String getText() {
String text = null;
if (document != null) text = document.get();
- return (text == null) ? "" : text;
+ return (text == null) ? "" : text; //$NON-NLS-1$
}
public void textChanged(TextEvent event) {
@@ -274,16 +274,16 @@
text = isEditorInputReadOnly() ? "Read Only" : "Writable";
else if (ITextEditorActionConstants.STATUS_CATEGORY_INPUT_MODE.equals(category))
text = (!fOverwriting) ? "Insert" : "Overwrite";
- field.setText(text == null ? "" : text);
+ field.setText(text == null ? "" : text); //$NON-NLS-1$
}
}
protected String getCursorPosition() {
- if (preview == null) return "";
+ if (preview == null) return ""; //$NON-NLS-1$
StyledText styledText = preview.getTextWidget();
int caret = styledText.getCaretOffset();
IDocument document= preview.getDocument();
- if (document == null) return "";
+ if (document == null) return ""; //$NON-NLS-1$
try {
int line = document.getLineOfOffset(caret);
int lineOffset= document.getLineOffset(line);
@@ -294,10 +294,10 @@
column += tabWidth - (column % tabWidth);
else
column++;
- return "" + (++line) + " : " + (++column);
+ return "" + (++line) + " : " + (++column); //$NON-NLS-1$ //$NON-NLS-2$
} catch (BadLocationException x) {
- return "";
+ return ""; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorSupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorSupport.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/TextEditorSupport.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -110,14 +110,14 @@
public boolean canRevertToSaved() {
XModelObject o = getModelObject();
if(o == null || !o.isActive()) return false;
- XAction a = o.getModelEntity().getActionList().getAction("DiscardActions.Discard");
+ XAction a = o.getModelEntity().getActionList().getAction("DiscardActions.Discard"); //$NON-NLS-1$
return (a != null && a.isEnabled(o));
}
public void revertToSaved() {
XModelObject o = getModelObject();
if(o != null) {
- XActionInvoker.invoke("DiscardActions.Discard", o, new Properties());
+ XActionInvoker.invoke("DiscardActions.Discard", o, new Properties()); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorComponent.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorComponent.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorComponent.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -124,11 +124,11 @@
public String getText() {
String text = null;
ISourceViewer sv = getSourceViewer();
- if(sv == null) return "";
+ if(sv == null) return ""; //$NON-NLS-1$
IDocument d = sv.getDocument();
- if(d == null) return "";
+ if(d == null) return ""; //$NON-NLS-1$
text = d.get();
- return (text == null) ? "" : text;
+ return (text == null) ? "" : text; //$NON-NLS-1$
}
public boolean isEditable() {
@@ -140,7 +140,7 @@
IModelObjectEditorInput input = (IModelObjectEditorInput)getEditorInput();
if(input == null || input.getXModelObject() == null) return true;
XModelObject o = input.getXModelObject();
- return !o.isObjectEditable() && !o.isAttributeEditable("body");
+ return !o.isObjectEditable() && !o.isAttributeEditable("body"); //$NON-NLS-1$
}
public void setModified(boolean set) {
@@ -441,7 +441,7 @@
class RevertToSavedAction2 extends RevertToSavedAction {
XMLTextEditorComponent t;
RevertToSavedAction2(XMLTextEditorComponent t) {
- super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Revert.", t);
+ super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Revert.", t); //$NON-NLS-1$ //$NON-NLS-2$
this.t = t;
}
public void update() {
@@ -452,7 +452,7 @@
class SaveAction2 extends SaveAction {
XMLTextEditorComponent t;
SaveAction2(XMLTextEditorComponent t) {
- super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Save.", t);
+ super(ResourceBundle.getBundle("org.eclipse.ui.texteditor.ConstructedEditorMessages"), "Editor.Save.", t); //$NON-NLS-1$ //$NON-NLS-2$
this.t = t;
}
public void update() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorStandAlone.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorStandAlone.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/XMLTextEditorStandAlone.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -65,7 +65,7 @@
super.dispose();
if(o != null && o.isModified() && o.isActive()) {
try {
- XAction action = XActionInvoker.getAction("DiscardActions.Discard", o);
+ XAction action = XActionInvoker.getAction("DiscardActions.Discard", o); //$NON-NLS-1$
if(action != null) {
// to avoid confirmation
action.executeHandler(o, null);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/dnd/TextEditorDrop.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/dnd/TextEditorDrop.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/dnd/TextEditorDrop.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -55,18 +55,18 @@
public Properties getDropProperties(int x, int y) {
Properties p = new Properties();
- p.setProperty("isDrop", "true");
- p.setProperty("actionSourceGUIComponentID", "editor");
- p.setProperty("accepsAsString", "true");
+ p.setProperty("isDrop", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+ p.setProperty("actionSourceGUIComponentID", "editor"); //$NON-NLS-1$ //$NON-NLS-2$
+ p.setProperty("accepsAsString", "true"); //$NON-NLS-1$ //$NON-NLS-2$
String text = provider.getSourceViewer().getDocument().get();
- p.setProperty("text", text);
+ p.setProperty("text", text); //$NON-NLS-1$
int pos = getPosition(x, y);
- p.setProperty("pos", "" + pos);
- p.put("viewer", provider.getSourceViewer());
+ p.setProperty("pos", "" + pos); //$NON-NLS-1$ //$NON-NLS-2$
+ p.put("viewer", provider.getSourceViewer()); //$NON-NLS-1$
if(provider instanceof TextEditorDropProvider2) {
String context = ((TextEditorDropProvider2)provider).getContext(pos);
if(context != null) {
- p.put("text-context", context);
+ p.put("text-context", context); //$NON-NLS-1$
}
}
return p;
@@ -91,8 +91,8 @@
public void drop(Properties p) {
ISourceViewer v = provider.getSourceViewer();
- int x = ((Integer)p.get("drop.x")).intValue();
- int y = ((Integer)p.get("drop.y")).intValue();
+ int x = ((Integer)p.get("drop.x")).intValue(); //$NON-NLS-1$
+ int y = ((Integer)p.get("drop.y")).intValue(); //$NON-NLS-1$
int c = getPosition(x, y);
Point sp = v.getTextWidget().getSelectionRange();
if(sp == null || c < sp.x || c >= sp.x + sp.y) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/EditorsPreferencesPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/EditorsPreferencesPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/EditorsPreferencesPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,9 +23,9 @@
public class EditorsPreferencesPage extends XMOBasedPreferencesPage {
- public static final String EDITOR_PREFERENCES_ID = "org.jboss.tools.common.xstudio.editors";
+ public static final String EDITOR_PREFERENCES_ID = "org.jboss.tools.common.xstudio.editors"; //$NON-NLS-1$
- static String PATH = "%Options%/Struts Studio/Editors";
+ static String PATH = "%Options%/Struts Studio/Editors"; //$NON-NLS-1$
public EditorsPreferencesPage() {
super(_getPreferenceModel().getByPath(PATH));
@@ -43,9 +43,9 @@
// FIXME: Remove Reflection
private static void initialize() {
if(store != null) return;
- AbstractUIPlugin plugin = (AbstractUIPlugin)Platform.getPlugin("org.jboss.tools.common.text.xml");
+ AbstractUIPlugin plugin = (AbstractUIPlugin)Platform.getPlugin("org.jboss.tools.common.text.xml"); //$NON-NLS-1$
try {
- Method m = AbstractUIPlugin.class.getDeclaredMethod("initializeDefaultPluginPreferences", new Class[0]);
+ Method m = AbstractUIPlugin.class.getDeclaredMethod("initializeDefaultPluginPreferences", new Class[0]); //$NON-NLS-1$
m.setAccessible(true);
m.invoke(plugin, new Object[0]);
} catch(NoSuchMethodException e1) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/ReplaceTabsAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/ReplaceTabsAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/ReplaceTabsAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,15 +21,15 @@
public ReplaceTabsAdapter() {}
public String getProperty(XProperty object) {
- if(EditorsPreferencesPage.store == null) return "false";
- return "" + EditorsPreferencesPage.store.getBoolean(PROPERTY);
+ if(EditorsPreferencesPage.store == null) return "false"; //$NON-NLS-1$
+ return "" + EditorsPreferencesPage.store.getBoolean(PROPERTY); //$NON-NLS-1$
}
public void setProperty(XProperty object, String value) {
XModelObject o = (XModelObject)object;
if(!o.isActive()) return;
if(EditorsPreferencesPage.store == null) return;
- EditorsPreferencesPage.store.setValue(PROPERTY, "true".equals(value));
+ EditorsPreferencesPage.store.setValue(PROPERTY, "true".equals(value)); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/TabWidthAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/TabWidthAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/preferences/TabWidthAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,10 +21,10 @@
public TabWidthAdapter() {}
public String getProperty(XProperty object) {
- if(EditorsPreferencesPage.store == null) return "4";
+ if(EditorsPreferencesPage.store == null) return "4"; //$NON-NLS-1$
int i = EditorsPreferencesPage.store.getInt(PROPERTY);
- if(i == 0) EditorsPreferencesPage.store.setDefault(PROPERTY, "4");
- return "" + EditorsPreferencesPage.store.getInt(PROPERTY);
+ if(i == 0) EditorsPreferencesPage.store.setDefault(PROPERTY, "4"); //$NON-NLS-1$
+ return "" + EditorsPreferencesPage.store.getInt(PROPERTY); //$NON-NLS-1$
}
public void setProperty(XProperty object, String value) {
XModelObject o = (XModelObject)object;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -155,7 +155,7 @@
getDocumentListenerRegister().unregister();
getDocumentListenerRegister().register();
Object dtid =
- getSourceViewer().getTextWidget().getData("DropTarget");
+ getSourceViewer().getTextWidget().getData("DropTarget"); //$NON-NLS-1$
if (dtid != null) {
if (dtid instanceof DropTarget) {
DropTarget dropTarget = (DropTarget) dtid;
@@ -323,7 +323,7 @@
*/
public Object getAdapter( Class adapter ) {
if (adapter == EditorDescriptor.class)
- return new EditorDescriptor("xml");
+ return new EditorDescriptor("xml"); //$NON-NLS-1$
return super.getAdapter( adapter );
}
@@ -411,7 +411,7 @@
NamedNodeMap attributes = jspElement.getAttributes();
if(pos==jspElement.getStartOffset()
|| pos==jspElement.getEndStartOffset()) {
- return lastContext = "text";
+ return lastContext = "text"; //$NON-NLS-1$
}
for(int i = 0;i<attributes.getLength();i++ ) {
Node attribute = attributes.item(i);
@@ -419,25 +419,25 @@
AttrImpl jspAttr = (AttrImpl)attribute;
ITextRegion valueRegion = jspAttr.getValueRegion();
if(valueRegion == null) {
- return lastContext = "none";
+ return lastContext = "none"; //$NON-NLS-1$
}
int startPos = jspElement.getStartOffset()+ valueRegion.getStart();
int endPos = jspElement.getStartOffset() + valueRegion.getTextEnd();
if(pos > startPos && pos < endPos) {
- return lastContext = "attribute";
+ return lastContext = "attribute"; //$NON-NLS-1$
}
}
}
- return lastContext = "none";
+ return lastContext = "none"; //$NON-NLS-1$
} else if(region instanceof Text) {
- return lastContext = "text";
+ return lastContext = "text"; //$NON-NLS-1$
} else if(region instanceof DocumentType) {
- return lastContext = "none";
+ return lastContext = "none"; //$NON-NLS-1$
} else if(region == null) {
//new place
- return lastContext = "text";
+ return lastContext = "text"; //$NON-NLS-1$
}
- return lastContext = "none";
+ return lastContext = "none"; //$NON-NLS-1$
}
public void textChanged(TextEvent event) {
@@ -454,8 +454,8 @@
save();
XModelObject o = getModelObject();
Properties p = new Properties();
- XActionInvoker.invoke("FileTXT", "DiscardActions.Discard", o, p);
- if(!"true".equals(p.getProperty("done"))) return;
+ XActionInvoker.invoke("FileTXT", "DiscardActions.Discard", o, p); //$NON-NLS-1$ //$NON-NLS-2$
+ if(!"true".equals(p.getProperty("done"))) return; //$NON-NLS-1$ //$NON-NLS-2$
super.doRevertToSaved();
if(o.isModified()) o.setModified(false);
modified = false;
@@ -507,7 +507,7 @@
return;
}
// Drop from VPE to Source is forbidden
- if(dropContext.getFlavor().equals("text/html")) {
+ if(dropContext.getFlavor().equals("text/html")) { //$NON-NLS-1$
if(InnerDragBuffer.object != null) {
event.detail = DND.DROP_NONE;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/ExtensionPointUtils.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/ExtensionPointUtils.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/ExtensionPointUtils.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,7 +23,7 @@
public static INewWizard findNewWizardsItem(String pluginId, String wizardId) {
Platform.getBundle(pluginId);
try {
- return (INewWizard)ExtensionPointUtil.findClassByElementId("org.eclipse.ui.newWizards", wizardId);
+ return (INewWizard)ExtensionPointUtil.findClassByElementId("org.eclipse.ui.newWizards", wizardId); //$NON-NLS-1$
} catch (CoreException ex) {
ModelUIPlugin.getPluginLog().logError(ex);
}
@@ -33,7 +33,7 @@
public static IImportWizard findImportWizardsItem(String pluginId, String wizardId) {
Platform.getBundle(pluginId);
try {
- return (IImportWizard)ExtensionPointUtil.findClassByElementId("org.eclipse.ui.importWizards", wizardId);
+ return (IImportWizard)ExtensionPointUtil.findClassByElementId("org.eclipse.ui.importWizards", wizardId); //$NON-NLS-1$
} catch (CoreException ex) {
ModelUIPlugin.getPluginLog().logError(ex);
}
@@ -44,7 +44,7 @@
public static IObjectActionDelegate findPopupMenusObjectAction(String pluginId, String actionId) {
Platform.getBundle(pluginId);
try {
- return (IObjectActionDelegate)ExtensionPointUtil.findClassByElementId("org.eclipse.ui.popupMenus", actionId);
+ return (IObjectActionDelegate)ExtensionPointUtil.findClassByElementId("org.eclipse.ui.popupMenus", actionId); //$NON-NLS-1$
} catch (CoreException ex) {
ModelUIPlugin.getPluginLog().logError(ex);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/StringUtilities.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/StringUtilities.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/util/StringUtilities.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -34,12 +34,12 @@
gc.setFont(font);
if (source == null) {
- source = "";
+ source = ""; //$NON-NLS-1$
}
String str;
if (gc.stringExtent(source).x > width) {
if (sufix == null) {
- sufix = "";
+ sufix = ""; //$NON-NLS-1$
}
str = sufix;
for (int i = 0; i < source.length(); i++) {
@@ -61,7 +61,7 @@
}
public static String dottedString(String source, int width, Drawable drawable, Font font) {
- return makeShortString(source, width, "...", drawable, font);
+ return makeShortString(source, width, "...", drawable, font); //$NON-NLS-1$
}
public static String dottedString(String source, int width, Control control) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/FilteredTreesCache.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/FilteredTreesCache.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/FilteredTreesCache.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -82,7 +82,7 @@
XFilteredTree createTree(String name, XModel model) {
if(model == null || name == null) return null;
- String classname = model.getMetaData().getMapping("FilteredTrees").getValue(name);
+ String classname = model.getMetaData().getMapping("FilteredTrees").getValue(name); //$NON-NLS-1$
XFilteredTree result = null;
try {
result = (XFilteredTree)ModelFeatureFactory.getInstance().createFeatureInstance(classname);
@@ -96,7 +96,7 @@
IProject p = EclipseResourceUtil.getProject(model.getRoot());
IModelNature nature = EclipseResourceUtil.getModelNature(p);
if(nature != null) {
- ModelUIPlugin.getPluginLog().logInfo("Red Hat Project " + p.getName() + " is corrupted.");
+ ModelUIPlugin.getPluginLog().logInfo("Red Hat Project " + p.getName() + " is corrupted."); //$NON-NLS-1$ //$NON-NLS-2$
}
}
return result;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCopyAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCopyAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCopyAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -31,7 +31,7 @@
}
protected String getActionPath() {
- return "CopyActions.Copy";
+ return "CopyActions.Copy"; //$NON-NLS-1$
}
public void run() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCutAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCutAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NCutAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -29,7 +29,7 @@
}
protected String getActionPath() {
- return "CopyActions.Cut";
+ return "CopyActions.Cut"; //$NON-NLS-1$
}
public void run() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NDeleteAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NDeleteAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NDeleteAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
}
protected String getActionPath() {
- return "DeleteActions.Delete";
+ return "DeleteActions.Delete"; //$NON-NLS-1$
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NPasteAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NPasteAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NPasteAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,6 +25,6 @@
}
protected String getActionPath() {
- return "CopyActions.Paste";
+ return "CopyActions.Paste"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorContentProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorContentProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorContentProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -201,7 +201,7 @@
}
protected String getFilteredTreeName() {
- return "FileSystems";
+ return "FileSystems"; //$NON-NLS-1$
}
XFilteredTree getFilteredTree(Object object) {
@@ -285,7 +285,7 @@
viewer.remove(o);
projects.remove(p.getLocation().toString());
} else {
- String classname = o.getModel().getMetaData().getMapping("FilteredTrees").getValue(getFilteredTreeName(o.getModel()));
+ String classname = o.getModel().getMetaData().getMapping("FilteredTrees").getValue(getFilteredTreeName(o.getModel())); //$NON-NLS-1$
XFilteredTree tree = getFilteredTree(o.getModel().getRoot());
if(tree != null && !tree.getClass().getName().equals(classname)) {
o.getModel().removeModelTreeListener(syncListener);
@@ -299,7 +299,7 @@
class C implements Comparator<Object> {
public int compare(Object o1, Object o2) {
- return (o1 == null ? "" : o1.toString()).compareToIgnoreCase(o2 == null ? "" : o2.toString());
+ return (o1 == null ? "" : o1.toString()).compareToIgnoreCase(o2 == null ? "" : o2.toString()); //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorMenuInvoker.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorMenuInvoker.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorMenuInvoker.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
if(eclipseWorkspace == null) {
XModel model = PreferenceModelUtilities.getPreferenceModel();
if(model != null) {
- eclipseWorkspace = model.createModelObject("EclipseWorkspace", null);
+ eclipseWorkspace = model.createModelObject("EclipseWorkspace", null); //$NON-NLS-1$
}
}
return eclipseWorkspace;
@@ -45,8 +45,8 @@
public void mouseDoubleClick(MouseEvent e) {
XModelObject o = getModelObjectAt(new Point(e.x, e.y));
if (o == null) return;
- if(XActionInvoker.getAction("Open", o) != null) {
- XActionInvoker.invoke("Open", o, new Properties());
+ if(XActionInvoker.getAction("Open", o) != null) { //$NON-NLS-1$
+ XActionInvoker.invoke("Open", o, new Properties()); //$NON-NLS-1$
} else if(o.getFileType() == XModelObject.NONE) {
FindObjectHelper.findModelObject(o, FindObjectHelper.IN_EDITOR_ONLY);
}
@@ -61,11 +61,11 @@
}
private boolean isOpenOnSingleClick() {
- return Platform.getPreferencesService().getBoolean("org.eclipse.ui.workbench", "OPEN_ON_SINGLE_CLICK", true, new IScopeContext[]{new InstanceScope()});
+ return Platform.getPreferencesService().getBoolean("org.eclipse.ui.workbench", "OPEN_ON_SINGLE_CLICK", true, new IScopeContext[]{new InstanceScope()}); //$NON-NLS-1$ //$NON-NLS-2$
}
protected void fillRunningProperties(Properties p) {
- p.setProperty("actionSourceGUIComponentID", "navigator");
+ p.setProperty("actionSourceGUIComponentID", "navigator"); //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorViewPart.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorViewPart.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/navigator/NavigatorViewPart.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -91,7 +91,7 @@
public class NavigatorViewPart extends ViewPart implements ISaveablePart, ISetSelectionTarget, IResourceNavigator , IShowInTarget //, ISelectionProvider
{
- public static final String VIEW_ID = "org.jboss.tools.common.model.ui.navigator.NavigatorViewPart";
+ public static final String VIEW_ID = "org.jboss.tools.common.model.ui.navigator.NavigatorViewPart"; //$NON-NLS-1$
private TreeViewer viewer;
private XModelObjectSelectionProvider selectionProvider = new XModelObjectSelectionProvider();
private TreeViewerDragDropProvider dndProvider = new TreeViewerDragDropProvider();
@@ -121,7 +121,7 @@
public void createPartControl(Composite parent) {
createViewer(parent);
viewer.setInput(getInitialInput());
- selectionProvider.addHost("viewer", viewer, true);
+ selectionProvider.addHost("viewer", viewer, true); //$NON-NLS-1$
getSite().setSelectionProvider(selectionProvider);
if (memento != null) {
restoreLinkingEnabled();
@@ -154,11 +154,11 @@
Object o = ss.getFirstElement();
if(!(o instanceof XModelObject)) return;
XModelObject object = (XModelObject)o;
- if(XActionInvoker.getAction("Open", object) == null) return;
- XActionInvoker.invoke("Open", object, null);
+ if(XActionInvoker.getAction("Open", object) == null) return; //$NON-NLS-1$
+ XActionInvoker.invoke("Open", object, null); //$NON-NLS-1$
}
};
- h.activateHandler("org.eclipse.jdt.ui.edit.text.java.open.editor", new ActionHandler(action));
+ h.activateHandler("org.eclipse.jdt.ui.edit.text.java.open.editor", new ActionHandler(action)); //$NON-NLS-1$
}
private IAction createActionInstance(String name) {
@@ -167,8 +167,8 @@
protected String[] getActionClasses() {
String[] actions = new String[]{
- "org.jboss.tools.struts.ui.internal.action.CreateProjectAction",
- "org.jboss.tools.struts.ui.internal.action.ImportProjectAction"
+ "org.jboss.tools.struts.ui.internal.action.CreateProjectAction", //$NON-NLS-1$
+ "org.jboss.tools.struts.ui.internal.action.ImportProjectAction" //$NON-NLS-1$
};
return actions;
}
@@ -306,7 +306,7 @@
if(o == null) return;
while(o != null && o.getFileType() == XFileObject.NONE) o = o.getParent();
if(o == null || o.getFileType() != XFileObject.FILE) return;
- XActionInvoker.invoke("SaveActions.Save", o, null);
+ XActionInvoker.invoke("SaveActions.Save", o, null); //$NON-NLS-1$
firePropertyChange(IEditorPart.PROP_DIRTY);
}
@@ -365,25 +365,25 @@
public void saveState(IMemento _memento) {
XModelObject o = getSelectedModelObject();
- if(o != null) _memento.putString("selection", getNodePath(o));
+ if(o != null) _memento.putString("selection", getNodePath(o)); //$NON-NLS-1$
saveLinkingEnabled(_memento);
}
public void restoreState(IMemento _memento) {
- String selection = _memento.getString("selection");
+ String selection = _memento.getString("selection"); //$NON-NLS-1$
XModelObject o = findModelObject(selection);
if(o != null) viewer.setSelection(new StructuredSelection(o));
restoreLinkingEnabled();
}
private String getNodePath(XModelObject o) {
- IProject p = (IProject)o.getModel().getProperties().get("project");
- return p.getName() + ":" + o.getPath();
+ IProject p = (IProject)o.getModel().getProperties().get("project"); //$NON-NLS-1$
+ return p.getName() + ":" + o.getPath(); //$NON-NLS-1$
}
private XModelObject findModelObject(String nodepath) {
if(nodepath == null || nodepath.length() == 0) return null;
- int i = nodepath.indexOf(":");
+ int i = nodepath.indexOf(":"); //$NON-NLS-1$
IProject p = ModelUIPlugin.getWorkspace().getRoot().getProject(nodepath.substring(0, i));
return EclipseResourceUtil.getObjectByPath(p, nodepath.substring(i + 1));
}
@@ -530,11 +530,11 @@
};
private void saveLinkingEnabled(IMemento _memento) {
- _memento.putInteger("LinkStrutsProjectsToEditor", isLinkingEnabled ? 1 : 0);
+ _memento.putInteger("LinkStrutsProjectsToEditor", isLinkingEnabled ? 1 : 0); //$NON-NLS-1$
}
private void restoreLinkingEnabled() {
- Integer val = memento.getInteger("LinkStrutsProjectsToEditor");//IWorkbenchPreferenceConstants.LINK_NAVIGATOR_TO_EDITOR);
+ Integer val = memento.getInteger("LinkStrutsProjectsToEditor");//IWorkbenchPreferenceConstants.LINK_NAVIGATOR_TO_EDITOR); //$NON-NLS-1$
if (val != null) {
isLinkingEnabled = val.intValue() != 0;
}
@@ -588,9 +588,9 @@
if(file == null && obj instanceof XModelObject) {
XModelObject o = (XModelObject)obj;
Properties p = new Properties();
- p.setProperty("onlySelectIfOpen", "true");
- if(XActionInvoker.getAction("Open", o) != null) {
- XActionInvoker.invoke("Open", o, p);
+ p.setProperty("onlySelectIfOpen", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+ if(XActionInvoker.getAction("Open", o) != null) { //$NON-NLS-1$
+ XActionInvoker.invoke("Open", o, p); //$NON-NLS-1$
}
return;
}
@@ -634,7 +634,7 @@
class ActivationXRunnable implements XRunnable {
public String getId() {
- return "Activation";
+ return "Activation"; //$NON-NLS-1$
}
public void run() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -65,7 +65,7 @@
private PaletteDescriptionManager descriptionManager = null;
private PaletteResizeManager resizeManager = null;
private PaletteDropTargetManager dropManager = null;
- private QualifiedName persistentTabQualifiedName = new QualifiedName("", "Palette_tab");
+ private QualifiedName persistentTabQualifiedName = new QualifiedName("", "Palette_tab"); //$NON-NLS-1$ //$NON-NLS-2$
private String selectedTab = null;
private boolean fWindowsFlag;
@@ -74,8 +74,8 @@
}
public Control createControl(Composite composite) {
- String osName = System.getProperty("os.name");
- fWindowsFlag = osName != null && osName.toUpperCase().indexOf("WINDOWS") != -1;
+ String osName = System.getProperty("os.name"); //$NON-NLS-1$
+ fWindowsFlag = osName != null && osName.toUpperCase().indexOf("WINDOWS") != -1; //$NON-NLS-1$
try {
selectedTab = ModelUIPlugin.getWorkspace().getRoot().getPersistentProperty(persistentTabQualifiedName);
@@ -462,11 +462,11 @@
}
private void run(XModelTreeEvent event) {
- if("transaction_begin".equals(event.getInfo())) {
+ if("transaction_begin".equals(event.getInfo())) { //$NON-NLS-1$
isTransaction = true;
return;
}
- if("transaction_end".equals(event.getInfo())) {
+ if("transaction_end".equals(event.getInfo())) { //$NON-NLS-1$
isTransaction = false;
if(isDirty) {
isDirty = false;
@@ -478,7 +478,7 @@
XModel xmodel = model.getXModel();
XModelObject exo = event.getModelObject();
boolean q = event.kind() == XModelTreeEvent.STRUCTURE_CHANGED && xmodel.getRoot().getPath().equals(exo.getPath());
- XModelObject xroot = xmodel.getRoot("Palette");
+ XModelObject xroot = xmodel.getRoot("Palette"); //$NON-NLS-1$
if (xroot == null || isExist(xroot, event.getModelObject()) || q) {
if (event.kind() == XModelTreeEvent.CHILD_ADDED && xroot != null && xroot.getPath().equals(exo.getPath())) {
Object info = event.getInfo();
@@ -502,13 +502,13 @@
if (modelObject.getPath() == null || root.getPath() == null) {
return false;
}
- return (modelObject.getPath() + "/").startsWith(root.getPath() + "/");
+ return (modelObject.getPath() + "/").startsWith(root.getPath() + "/"); //$NON-NLS-1$ //$NON-NLS-2$
}
}
private class PaletteEditAction extends Action {
public PaletteEditAction() {
- super("Palette Editor", model.createImageDescriptor("palette_editor.gif"));
+ super("Palette Editor", model.createImageDescriptor("palette_editor.gif")); //$NON-NLS-2$
setToolTipText("Palette Editor");
}
@@ -519,7 +519,7 @@
private class ShowHideTabsAction extends Action {
public ShowHideTabsAction() {
- super("Show/Hide tabs", model.createImageDescriptor("show-hide.gif"));
+ super("Show/Hide tabs", model.createImageDescriptor("show-hide.gif")); //$NON-NLS-2$
setToolTipText("Show/Hide");
}
public void run() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteContents.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteContents.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteContents.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -53,14 +53,14 @@
IProject project = file.getProject();
List<String> natures = new ArrayList<String>();
try {
- if (project.exists() && project.isOpen() && project.hasNature("org.jboss.tools.struts.strutsnature"))
- natures.add("struts");
+ if (project.exists() && project.isOpen() && project.hasNature("org.jboss.tools.struts.strutsnature")) //$NON-NLS-1$
+ natures.add("struts"); //$NON-NLS-1$
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
try {
- if (project.exists() && project.isOpen() && project.hasNature("org.jboss.tools.jsf.jsfnature"))
- natures.add("jsf");
+ if (project.exists() && project.isOpen() && project.hasNature("org.jboss.tools.jsf.jsfnature")) //$NON-NLS-1$
+ natures.add("jsf"); //$NON-NLS-1$
} catch (CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteDescriptionManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteDescriptionManager.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteDescriptionManager.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -31,8 +31,8 @@
super(new DescriptionControlCreator());
setSizeConstraints(60, 30, false, false);
fWindowsFlag = true;
- String osName = System.getProperty("os.name");
- fWindowsFlag = osName != null && osName.toUpperCase().indexOf("WINDOWS") != -1;
+ String osName = System.getProperty("os.name"); //$NON-NLS-1$
+ fWindowsFlag = osName != null && osName.toUpperCase().indexOf("WINDOWS") != -1; //$NON-NLS-1$
}
protected void computeInformation() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertHelper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertHelper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertHelper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -45,15 +45,15 @@
*/
public class PaletteInsertHelper {
- public static final String PROPOPERTY_TAG_NAME = "tag name";
+ public static final String PROPOPERTY_TAG_NAME = "tag name"; //$NON-NLS-1$
public static final String PROPOPERTY_START_TEXT = TLDToPaletteHelper.START_TEXT;
public static final String PROPOPERTY_END_TEXT = TLDToPaletteHelper.END_TEXT;
- public static final String PROPOPERTY_NEW_LINE = "new line";
+ public static final String PROPOPERTY_NEW_LINE = "new line"; //$NON-NLS-1$
public static final String PROPOPERTY_REFORMAT_BODY = TLDToPaletteHelper.REFORMAT;
public static final String PROPOPERTY_TAGLIBRARY_URI = URIConstants.LIBRARY_URI;
public static final String PROPOPERTY_TAGLIBRARY_VERSION = URIConstants.LIBRARY_VERSION;
public static final String PROPOPERTY_DEFAULT_PREFIX = URIConstants.DEFAULT_PREFIX;
- public static final String PROPOPERTY_SELECTION_PROVIDER = "selectionProvider";
+ public static final String PROPOPERTY_SELECTION_PROVIDER = "selectionProvider"; //$NON-NLS-1$
public static final String PROPOPERTY_ADD_TAGLIB = TLDToPaletteHelper.ADD_TAGLIB;
static PaletteTaglibInserter PaletteTaglibInserter = new PaletteTaglibInserter();
@@ -107,7 +107,7 @@
IDocument d = v.getDocument();
String[] texts = new String[] {startText, endText};
- if(startText != null && startText.startsWith("<%@ taglib")) {
+ if(startText != null && startText.startsWith("<%@ taglib")) { //$NON-NLS-1$
if(PaletteTaglibInserter.inserTaglibInXml(v, p)) {
return;
}
@@ -151,7 +151,7 @@
String startText = p.getProperty(PROPOPERTY_START_TEXT);
String endText = p.getProperty(PROPOPERTY_END_TEXT);
String newline = p.getProperty(PROPOPERTY_NEW_LINE);
- boolean reformat = "yes".equals(p.getProperty(PROPOPERTY_REFORMAT_BODY));
+ boolean reformat = "yes".equals(p.getProperty(PROPOPERTY_REFORMAT_BODY)); //$NON-NLS-1$
ISelectionProvider selProvider = (ISelectionProvider)p.get(PROPOPERTY_SELECTION_PROVIDER);
if (doc == null || selProvider == null) return;
@@ -163,15 +163,15 @@
//Changed due to new WTP version 1.5 R 2006.06.28 get selected text from document.
String body = null;
try {
- body = length > 0 ? doc.get(offset, length): "";
+ body = length > 0 ? doc.get(offset, length): ""; //$NON-NLS-1$
} catch (BadLocationException e1) {
ModelUIPlugin.getPluginLog().logError(e1);
}
- if (startText == null) startText = "";
- else startText = prepare(prepare(startText, "\\n", getLineDelimiter(doc)), "\\t", "\t");
- if (endText == null) endText = "";
- else endText = prepare(prepare(endText, "\\n", getLineDelimiter(doc)), "\\t", "\t");
+ if (startText == null) startText = ""; //$NON-NLS-1$
+ else startText = prepare(prepare(startText, "\\n", getLineDelimiter(doc)), "\\t", "\t"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ if (endText == null) endText = ""; //$NON-NLS-1$
+ else endText = prepare(prepare(endText, "\\n", getLineDelimiter(doc)), "\\t", "\t"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
String text = reformat ? format (doc, offset, length, body, startText, endText, newline) : (startText + body + endText);
@@ -196,7 +196,7 @@
}
}
- int pos = text.indexOf("|");
+ int pos = text.indexOf("|"); //$NON-NLS-1$
if (pos >= 0) {
text = text.substring(0, pos) + text.substring(pos + 1);
} else {
@@ -229,7 +229,7 @@
boolean indentBody = (startText != null && startText.length() > 0 &&
endText != null && endText.length() > 0);
- String firstLineIndent = "";
+ String firstLineIndent = ""; //$NON-NLS-1$
boolean indentFirstLine = false;
if (length == 0) {
firstLineIndent = getIndentOfLineOfOffset(d, offset);
@@ -237,7 +237,7 @@
firstLineIndent = getIndentOfFirstLine(d, offset);
indentFirstLine = true;
}
- String lastLineIndent = "";
+ String lastLineIndent = ""; //$NON-NLS-1$
boolean appendFirstDelimiter = true;
try {
@@ -268,11 +268,11 @@
if (startText != null && startText.length() > 0) {
if (appendFirstDelimiter) buffer.append(lineDelimiter);
if (indentFirstLine) buffer.append(firstLineIndent);
- StringTokenizer st = new StringTokenizer(startText, "\n", true);
+ StringTokenizer st = new StringTokenizer(startText, "\n", true); //$NON-NLS-1$
boolean isFirst = true;
while(st.hasMoreTokens()) {
String t = st.nextToken();
- if("\n".equals(t)) {
+ if("\n".equals(t)) { //$NON-NLS-1$
buffer.append(t);
isFirst = false;
} else {
@@ -280,10 +280,10 @@
buffer.append(t);
}
}
- if (!"false".equals(newline))
+ if (!"false".equals(newline)) //$NON-NLS-1$
buffer.append(lineDelimiter);
- body = (body == null || body.length() == 0) ? "" : firstLineIndent + body.substring(getIndentOfLine(body, lineDelimiter).length());
+ body = (body == null || body.length() == 0) ? "" : firstLineIndent + body.substring(getIndentOfLine(body, lineDelimiter).length()); //$NON-NLS-1$
}
int deltaSize = indentBody ? getTabWidth() : 0;
boolean appendPreEndLineDelimiter = true;
@@ -338,7 +338,7 @@
}
private static int getTabWidth() {
- return Platform.getPreferencesService().getInt("org.eclipse.ui.editors", AbstractDecoratedTextEditorPreferenceConstants.EDITOR_TAB_WIDTH, 4, new IScopeContext[]{new InstanceScope()});
+ return Platform.getPreferencesService().getInt("org.eclipse.ui.editors", AbstractDecoratedTextEditorPreferenceConstants.EDITOR_TAB_WIDTH, 4, new IScopeContext[]{new InstanceScope()}); //$NON-NLS-1$
}
private static boolean useSpaces() {
@@ -406,7 +406,7 @@
}
private static String getIndentOfFirstLine(IDocument d, int offset) {
- String indent = "";
+ String indent = ""; //$NON-NLS-1$
if(d == null) return indent;
try {
int line = d.getLineOfOffset(offset);
@@ -424,7 +424,7 @@
}
private static String getIndentOfLineOfOffset(IDocument d, int offset) {
- String indent = "";
+ String indent = ""; //$NON-NLS-1$
if(d == null) return indent;
try {
int line = d.getLineOfOffset(offset);
@@ -518,42 +518,42 @@
if(text == null || text.length() == 0) return text;
if(tagname == null || tagname.length() == 0) return text;
while(true) {
- int i = text.indexOf("%prefix|");
+ int i = text.indexOf("%prefix|"); //$NON-NLS-1$
if(i < 0) break;
- int j = text.indexOf("%", i + 8);
+ int j = text.indexOf("%", i + 8); //$NON-NLS-1$
if(j < 0) break;
- int j1 = text.indexOf("|", i + 8);
- String uri = "";
- String defaultPrefix = "";
- String pr = "";
+ int j1 = text.indexOf("|", i + 8); //$NON-NLS-1$
+ String uri = ""; //$NON-NLS-1$
+ String defaultPrefix = ""; //$NON-NLS-1$
+ String pr = ""; //$NON-NLS-1$
uri = text.substring(i + 8, j1);
defaultPrefix = text.substring(j1 + 1, j);
pr = prefixes.getProperty(uri, defaultPrefix);
if(pr.length() > 0) {
- text = text.substring(0, i) + pr + ":" + text.substring(j + 1);
+ text = text.substring(0, i) + pr + ":" + text.substring(j + 1); //$NON-NLS-1$
} else {
text = text.substring(0, i) + text.substring(j + 1);
}
}
- int k = text.toLowerCase().indexOf(":" + tagname.toLowerCase());
+ int k = text.toLowerCase().indexOf(":" + tagname.toLowerCase()); //$NON-NLS-1$
if(k >= 0) {
- int g = text.indexOf("</");
+ int g = text.indexOf("</"); //$NON-NLS-1$
if(g >= 0 && g < k) {
return text.substring(0, g + 2) + prefix + text.substring(k);
}
- g = text.indexOf("<");
+ g = text.indexOf("<"); //$NON-NLS-1$
if(g >= 0 && g < k) {
return text.substring(0, g + 1) + prefix + text.substring(k);
}
}
- k = text.toLowerCase().indexOf("<" + tagname.toLowerCase());
+ k = text.toLowerCase().indexOf("<" + tagname.toLowerCase()); //$NON-NLS-1$
if(k >= 0) {
- return text.substring(0, k + 1) + prefix + ":" + text.substring(k + 1);
+ return text.substring(0, k + 1) + prefix + ":" + text.substring(k + 1); //$NON-NLS-1$
}
- k = text.toLowerCase().indexOf("</" + tagname.toLowerCase());
+ k = text.toLowerCase().indexOf("</" + tagname.toLowerCase()); //$NON-NLS-1$
if(k >= 0) {
- return text.substring(0, k + 2) + prefix + ":" + text.substring(k + 2);
+ return text.substring(0, k + 2) + prefix + ":" + text.substring(k + 2); //$NON-NLS-1$
}
return text;
}
@@ -562,9 +562,9 @@
Properties p = new Properties();
int i = 0;
while(i >= 0 && i < body.length()) {
- i = body.indexOf("<%@ taglib ", i);
+ i = body.indexOf("<%@ taglib ", i); //$NON-NLS-1$
if(i < 0) break;
- int j = body.indexOf("%>", i);
+ int j = body.indexOf("%>", i); //$NON-NLS-1$
if(j < 0) j = body.length();
String taglib = body.substring(i, j);
getPrefix(p, taglib);
@@ -574,14 +574,14 @@
}
static void getPrefix(Properties p, String taglib) {
- int i = taglib.indexOf("uri=\"");
+ int i = taglib.indexOf("uri=\""); //$NON-NLS-1$
if(i < 0) return;
- int j = taglib.indexOf("\"", i + 5);
+ int j = taglib.indexOf("\"", i + 5); //$NON-NLS-1$
if(j < 0) return;
String uri = taglib.substring(i + 5, j);
- i = taglib.indexOf("prefix=\"");
+ i = taglib.indexOf("prefix=\""); //$NON-NLS-1$
if(i < 0) return;
- j = taglib.indexOf("\"", i + 8);
+ j = taglib.indexOf("\"", i + 8); //$NON-NLS-1$
if(j < 0) return;
String prefix = taglib.substring(i + 8, j);
p.setProperty(uri, prefix);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertManager.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteInsertManager.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -31,20 +31,20 @@
HashMap<String,IConfigurationElement> tagWizards = null;
public String getWizardName(Properties properties) {
- String tagname = properties.getProperty("tag name");
+ String tagname = properties.getProperty("tag name"); //$NON-NLS-1$
String uri = properties.getProperty(URIConstants.LIBRARY_URI);
return getWizardName(tagname, uri);
}
public Object createWizardInstance(Properties properties) {
- String tagname = properties.getProperty("tag name");
+ String tagname = properties.getProperty("tag name"); //$NON-NLS-1$
if(tagWizards == null) {
loadWizards();
}
if(tagname == null) return null;
IConfigurationElement o = tagWizards.get(tagname);
try {
- return o.createExecutableExtension("class");
+ return o.createExecutableExtension("class"); //$NON-NLS-1$
} catch(CoreException e) {
ModelUIPlugin.getPluginLog().logError(e);
return null;
@@ -57,18 +57,18 @@
}
if(tagname == null) return null;
IConfigurationElement o = tagWizards.get(tagname);
- return o != null ? o.getAttribute("class") : null;
+ return o != null ? o.getAttribute("class") : null; //$NON-NLS-1$
}
private void loadWizards() {
tagWizards = new HashMap<String,IConfigurationElement>();
- IExtensionPoint point = Platform.getExtensionRegistry().getExtensionPoint("org.jboss.tools.common.model.ui.InsertTagWizard");
+ IExtensionPoint point = Platform.getExtensionRegistry().getExtensionPoint("org.jboss.tools.common.model.ui.InsertTagWizard"); //$NON-NLS-1$
IExtension[] es = point.getExtensions();
for (int i = 0; i < es.length; i++) {
IConfigurationElement[] elements = es[i].getConfigurationElements();
for (int j = 0; j < elements.length; j++) {
- String name = elements[j].getAttribute("name");
- String className = elements[j].getAttribute("class");
+ String name = elements[j].getAttribute("name"); //$NON-NLS-1$
+ String className = elements[j].getAttribute("class"); //$NON-NLS-1$
if(name != null && name.trim().length() > 0 && className != null && className.trim().length() > 0) {
tagWizards.put(name.trim(), elements[j]);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteTaglibInserter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteTaglibInserter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteTaglibInserter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -39,11 +39,11 @@
public class PaletteTaglibInserter {
- private static final String JSP_SOURCE_ROOT_ELEMENT = "jsp:root";
- public static final String JSP_URI = "http://java.sun.com/JSP/Page";
- public static final String faceletUri = "http://java.sun.com/jsf/facelets";
+ private static final String JSP_SOURCE_ROOT_ELEMENT = "jsp:root"; //$NON-NLS-1$
+ public static final String JSP_URI = "http://java.sun.com/JSP/Page"; //$NON-NLS-1$
+ public static final String faceletUri = "http://java.sun.com/jsf/facelets"; //$NON-NLS-1$
- private static final String TAGLIB_START = "<%@ taglib";
+ private static final String TAGLIB_START = "<%@ taglib"; //$NON-NLS-1$
public Properties inserTaglib(ISourceViewer v, Properties p) {
if(!inserTaglibInXml(v, p)) {
@@ -53,7 +53,7 @@
}
private boolean checkProperties(Properties p) {
- return "true".equalsIgnoreCase(p.getProperty(PaletteInsertHelper.PROPOPERTY_ADD_TAGLIB)) &&
+ return "true".equalsIgnoreCase(p.getProperty(PaletteInsertHelper.PROPOPERTY_ADD_TAGLIB)) && //$NON-NLS-1$
p.getProperty(PaletteInsertHelper.PROPOPERTY_TAGLIBRARY_URI) != null &&
p.getProperty(PaletteInsertHelper.PROPOPERTY_TAGLIBRARY_URI).length() > 0 &&
!p.getProperty(PaletteInsertHelper.PROPOPERTY_TAGLIBRARY_URI).equals(JSP_URI) &&
@@ -83,7 +83,7 @@
String uri_p = p.getProperty(PaletteInsertHelper.PROPOPERTY_TAGLIBRARY_URI);
String defaultPrefix_p = p.getProperty(PaletteInsertHelper.PROPOPERTY_DEFAULT_PREFIX);
String lineDelimiter = PaletteInsertHelper.getLineDelimiter(d);
- StringBuffer tg = new StringBuffer(TAGLIB_START).append(" uri=\"").append(uri_p).append("\"").append(" prefix=\"").append(defaultPrefix_p).append("\"%>").append(lineDelimiter);
+ StringBuffer tg = new StringBuffer(TAGLIB_START).append(" uri=\"").append(uri_p).append("\"").append(" prefix=\"").append(defaultPrefix_p).append("\"%>").append(lineDelimiter); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
if (tl != null && !tl.isEmpty()) {
//If taglib already exist check the prefix if changed
@@ -92,7 +92,7 @@
p.setProperty(PaletteInsertHelper.PROPOPERTY_DEFAULT_PREFIX, (String)tl.get(uri_p));
}
} else if(!tl.containsValue(defaultPrefix_p)) {
- if (checkplace(xmlDocument, d, "jsp:directive.taglib", tg, p, v) == false) {
+ if (checkplace(xmlDocument, d, "jsp:directive.taglib", tg, p, v) == false) { //$NON-NLS-1$
d.replace(0, 0, tg.toString());
mouveFocusOnPage(p,v, tg.toString().length(), 0);
return true;
@@ -102,7 +102,7 @@
DocumentImpl docImpl = (DocumentImpl)xmlDocument;
// Only for JSP
if(docImpl.isJSPType()) {
- if (checkplace(xmlDocument, d, "jsp:directive.page", tg, p, v) == false) {
+ if (checkplace(xmlDocument, d, "jsp:directive.page", tg, p, v) == false) { //$NON-NLS-1$
d.replace(0, 0, tg.toString());
mouveFocusOnPage(p,v, tg.toString().length(), 0);
return true;
@@ -135,7 +135,7 @@
Node text = (Node)region;
- if("#text".equals(text.getNodeName()))
+ if("#text".equals(text.getNodeName())) //$NON-NLS-1$
return text.getParentNode();
else
return text;
@@ -158,8 +158,8 @@
Node a = attrs.item(j);
String name = a.getNodeName();
- if (name.startsWith("xmlns:")) {
- map.put(a.getNodeValue(), name.substring("xmlns:".length()));
+ if (name.startsWith("xmlns:")) { //$NON-NLS-1$
+ map.put(a.getNodeValue(), name.substring("xmlns:".length())); //$NON-NLS-1$
}
}
@@ -193,7 +193,7 @@
// for xhtml and jsp:root
if (xmlDocument.getDoctype() != null /* && tagLibListConainsFacelet(tl)*/ ) {
String publicId = xmlDocument.getDoctype().getPublicId();
- if (publicId!=null && publicId.toUpperCase().startsWith("-//W3C//DTD XHTML")) { // && root.getNodeName().equalsIgnoreCase(HTML_SOURCE_ROOT_ELEMENT)) {
+ if (publicId!=null && publicId.toUpperCase().startsWith("-//W3C//DTD XHTML")) { // && root.getNodeName().equalsIgnoreCase(HTML_SOURCE_ROOT_ELEMENT)) { //$NON-NLS-1$
checkTL(root, v, p, d);
return true;
}
@@ -254,8 +254,8 @@
Node a = attrs.item(j);
String name = a.getNodeName();
- if (name.startsWith("xmlns:")) {
- map.put(a.getNodeValue(), name.substring("xmlns:".length()));
+ if (name.startsWith("xmlns:")) { //$NON-NLS-1$
+ map.put(a.getNodeValue(), name.substring("xmlns:".length())); //$NON-NLS-1$
}
}
@@ -264,14 +264,14 @@
p.setProperty(PaletteInsertHelper.PROPOPERTY_DEFAULT_PREFIX, (String) map.get(uri_p));
}
} else if(!map.containsValue(defaultPrefix_p)) {
- StringBuffer attribute = new StringBuffer("xmlns:").append(defaultPrefix_p).append("=\"").append(uri_p).append("\"");
+ StringBuffer attribute = new StringBuffer("xmlns:").append(defaultPrefix_p).append("=\"").append(uri_p).append("\""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
int so = ((IDOMElement)root).getStartOffset();
int seo = ((IDOMElement)root).getStartEndOffset();
try {
String lineDelimiter = PaletteInsertHelper.getLineDelimiter(d);
StringBuffer selectedSource = new StringBuffer().append(d.get(so, seo-so));
- int xmlns = selectedSource.indexOf("xmlns");
- attribute = new StringBuffer().append(createEmptyCharArray(xmlns)).append("xmlns:").append(defaultPrefix_p).append("=\"").append(uri_p).append("\"");
+ int xmlns = selectedSource.indexOf("xmlns"); //$NON-NLS-1$
+ attribute = new StringBuffer().append(createEmptyCharArray(xmlns)).append("xmlns:").append(defaultPrefix_p).append("=\"").append(uri_p).append("\""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
if (d.getLineOffset(d.getLineOfOffset(so)) != so) {
attribute.insert(0, analyseSubstring(d.get(d.getLineOffset(d.getLineOfOffset(so)), so-d.getLineOffset(d.getLineOfOffset(so)))));
}
@@ -283,7 +283,7 @@
selectedSource.insert(selectedSource.length()-1, attribute);
d.replace(so, seo-so, selectedSource.toString());
} catch (BadLocationException t) {
- ModelUIPlugin.getPluginLog().logError("", t);
+ ModelUIPlugin.getPluginLog().logError("", t); //$NON-NLS-1$
}
}
return p;
@@ -338,7 +338,7 @@
if (xmlDocument.getDoctype() != null) {
docType = true;
String publicId = xmlDocument.getDoctype().getPublicId();
- if (publicId!=null && publicId.toUpperCase().startsWith("-//W3C//DTD HTML")) {
+ if (publicId!=null && publicId.toUpperCase().startsWith("-//W3C//DTD HTML")) { //$NON-NLS-1$
irdt = (xmlDocument.getDoctype() instanceof IndexedRegion) ?
(IndexedRegion)xmlDocument.getDoctype(): null;
}
@@ -348,7 +348,7 @@
for (int i=0; i < nl.getLength(); i++) {
Node n = nl.item(i);
//fing the first taglib to insert before
- if (n.getNodeName().equals(st) && st.equals("jsp:directive.taglib")) {
+ if (n.getNodeName().equals(st) && st.equals("jsp:directive.taglib")) { //$NON-NLS-1$
//calculate the space between taglib and left page corner
int so = ((ElementImpl)n).getStartOffset();
//taglib is at left corner
@@ -362,7 +362,7 @@
}
return true;
}
- if ((n.getNodeName().equals(st) && st.equals("jsp:directive.page")) ) {
+ if ((n.getNodeName().equals(st) && st.equals("jsp:directive.page")) ) { //$NON-NLS-1$
tg.delete(tg.lastIndexOf(PaletteInsertHelper.getLineDelimiter(d)), tg.length());
int so = ((ElementImpl)n).getStartOffset();
int eo = ((ElementImpl)n).getEndStartOffset();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteViewPart.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteViewPart.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/PaletteViewPart.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -39,8 +39,8 @@
public class PaletteViewPart extends ViewPart implements IPartListener {
- public static final String VIEW_ID = "org.jboss.tools.common.model.ui.views.palette.PaletteView";
- public static final String PALETTE_GEF_ID = "org.jboss.tools.vpe.ui.palette";
+ public static final String VIEW_ID = "org.jboss.tools.common.model.ui.views.palette.PaletteView"; //$NON-NLS-1$
+ public static final String PALETTE_GEF_ID = "org.jboss.tools.vpe.ui.palette"; //$NON-NLS-1$
private IPaletteAdapter paletteAdapter = null;
private Composite root = null;
@@ -68,7 +68,7 @@
private IPaletteAdapter createPaletteAdapter() {
try {
Bundle b = Platform.getBundle(PALETTE_GEF_ID);
- Class cls = b == null ? null : b.loadClass("org.jboss.tools.vpe.ui.palette.PaletteAdapter");
+ Class cls = b == null ? null : b.loadClass("org.jboss.tools.vpe.ui.palette.PaletteAdapter"); //$NON-NLS-1$
if(cls != null) return (IPaletteAdapter)cls.newInstance();
} catch (ClassNotFoundException t) {
//ignore
@@ -144,16 +144,16 @@
if(dropIntoEditor(editor, macro)) return;
if(dropIntoEditor2(editor, macro)) return;
- String tagname = macro.getAttributeValue("name");
- String startText = "" + macro.getAttributeValue("start text");
- String endText = "" + macro.getAttributeValue("end text");
- String newline = "" + macro.getAttributeValue("new line");
- String reformat = "" + macro.getAttributeValue("automatically reformat tag body");
+ String tagname = macro.getAttributeValue("name"); //$NON-NLS-1$
+ String startText = "" + macro.getAttributeValue("start text"); //$NON-NLS-1$ //$NON-NLS-2$
+ String endText = "" + macro.getAttributeValue("end text"); //$NON-NLS-1$ //$NON-NLS-2$
+ String newline = "" + macro.getAttributeValue("new line"); //$NON-NLS-1$ //$NON-NLS-2$
+ String reformat = "" + macro.getAttributeValue("automatically reformat tag body"); //$NON-NLS-1$ //$NON-NLS-2$
XModelObject parent = macro.getParent();
- String uri = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_URI);
- String libraryVersion = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_VERSION);
- String defaultPrefix = (parent == null) ? "" : parent.getAttributeValue(URIConstants.DEFAULT_PREFIX);
- String addTaglib = (parent == null) ? "" : parent.getAttributeValue("add taglib");
+ String uri = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_URI); //$NON-NLS-1$
+ String libraryVersion = (parent == null) ? "" : parent.getAttributeValue(URIConstants.LIBRARY_VERSION); //$NON-NLS-1$
+ String defaultPrefix = (parent == null) ? "" : parent.getAttributeValue(URIConstants.DEFAULT_PREFIX); //$NON-NLS-1$
+ String addTaglib = (parent == null) ? "" : parent.getAttributeValue("add taglib"); //$NON-NLS-1$ //$NON-NLS-2$
if (editor != null) {
Properties properties = new Properties();
properties.setProperty(PaletteInsertHelper.PROPOPERTY_TAG_NAME, tagname);
@@ -176,12 +176,12 @@
private boolean dropIntoEditor(ITextEditor editor, XModelObject macro) {
try {
- Method m = editor.getClass().getMethod("runDropCommand", new Class[]{String.class, String.class});
+ Method m = editor.getClass().getMethod("runDropCommand", new Class[]{String.class, String.class}); //$NON-NLS-1$
if(m == null) return false;
m.setAccessible(true);
Properties p = new Properties();
- p.setProperty("isDrag", "true");
- XActionInvoker.invoke("CopyActions.Copy", macro, p);
+ p.setProperty("isDrag", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+ XActionInvoker.invoke("CopyActions.Copy", macro, p); //$NON-NLS-1$
m.invoke(editor, new Object[]{ModelTransfer.MODEL, null});
return true;
} catch (NoSuchMethodException ne) {
@@ -198,13 +198,13 @@
}
}
private boolean dropIntoEditor2(ITextEditor editor, XModelObject macro) {
- SpecialWizard w = SpecialWizardFactory.createSpecialWizard("org.jboss.tools.common.model.ui.editors.dnd.DefaultDropCommandRunner");
+ SpecialWizard w = SpecialWizardFactory.createSpecialWizard("org.jboss.tools.common.model.ui.editors.dnd.DefaultDropCommandRunner"); //$NON-NLS-1$
if(w == null) return false;
Properties p = new Properties();
- p.setProperty("isDrag", "true");
- XActionInvoker.invoke("CopyActions.Copy", macro, p);
- p.setProperty("flavor", ModelTransfer.MODEL);
- p.put("textEditor", editor);
+ p.setProperty("isDrag", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+ XActionInvoker.invoke("CopyActions.Copy", macro, p); //$NON-NLS-1$
+ p.setProperty("flavor", ModelTransfer.MODEL); //$NON-NLS-1$
+ p.put("textEditor", editor); //$NON-NLS-1$
w.setObject(p);
int r = w.execute();
return r == 0;
@@ -227,7 +227,7 @@
editor = (ITextEditor)part;
} else if (part instanceof MultiPageEditorPart) {
try {
- Method m = MultiPageEditorPart.class.getDeclaredMethod("getActiveEditor", new Class[0]);
+ Method m = MultiPageEditorPart.class.getDeclaredMethod("getActiveEditor", new Class[0]); //$NON-NLS-1$
m.setAccessible(true);
Object o = m.invoke(part, new Object[0]);
if (o instanceof ITextEditor) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/EditorTypesAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/EditorTypesAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/EditorTypesAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,13 +26,13 @@
private String[] getEditorTypes() {
List<String> editorTypes = new ArrayList<String>();
- IExtension extensions[] = Platform.getExtensionRegistry().getExtensionPoint("org.jboss.tools.common.model.ui.paletteConstraints").getExtensions();
+ IExtension extensions[] = Platform.getExtensionRegistry().getExtensionPoint("org.jboss.tools.common.model.ui.paletteConstraints").getExtensions(); //$NON-NLS-1$
for (int i = 0; i < extensions.length; i++) {
IConfigurationElement elements[] = extensions[i].getConfigurationElements();
for (int j = 0; j < elements.length; j++)
- if ("editorType".equals(elements[j].getName()))
+ if ("editorType".equals(elements[j].getName())) //$NON-NLS-1$
{
- String editorType = elements[j].getAttribute("id");
+ String editorType = elements[j].getAttribute("id"); //$NON-NLS-1$
if (editorType != null && editorType.length() > 0)
editorTypes.add(editorType);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/NatureTypesAdapter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/NatureTypesAdapter.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/attribute/NatureTypesAdapter.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,14 +27,14 @@
private String[] getNatureTypes() {
List<String> editorTypes = new ArrayList<String>();
- IExtension extensions[] = Platform.getExtensionRegistry().getExtensionPoint("org.jboss.tools.common.model.ui.paletteConstraints").getExtensions();
+ IExtension extensions[] = Platform.getExtensionRegistry().getExtensionPoint("org.jboss.tools.common.model.ui.paletteConstraints").getExtensions(); //$NON-NLS-1$
for (int i = 0; i < extensions.length; i++)
{
IConfigurationElement elements[] = extensions[i].getConfigurationElements();
for (int j = 0; j < elements.length; j++)
- if ("natureType".equals(elements[j].getName()))
+ if ("natureType".equals(elements[j].getName())) //$NON-NLS-1$
{
- String editorType = elements[j].getAttribute("id");
+ String editorType = elements[j].getAttribute("id"); //$NON-NLS-1$
if (editorType != null && editorType.length() > 0)
editorTypes.add(editorType);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -14,7 +14,7 @@
public class HiddenPaletteTabsWizardView extends AbstractTreeWizardView {
public HiddenPaletteTabsWizardView() {
- setHelpKey("SharablePalette_HiddenTabs");
+ setHelpKey("SharablePalette_HiddenTabs"); //$NON-NLS-1$
}
protected String[] getActions() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialog.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialog.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialog.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -64,7 +64,7 @@
// Filter out 'Properties' item which is redundant in this editor.
l = (XActionList)l.copy(new Acceptor() {
public boolean accepts(XActionItem item) {
- if(item.getName().startsWith("Propert")) {
+ if(item.getName().startsWith("Propert")) { //$NON-NLS-1$
return false;
}
return true;
@@ -111,7 +111,7 @@
Control c = super.createContents(parent);
createEditorComponents((Composite)getDialogArea());
control = (Composite)c;
- PlatformUI.getWorkbench().getHelpSystem().setHelp(parent, ModelUIPlugin.ID_PLUGIN + ".palette_editor");
+ PlatformUI.getWorkbench().getHelpSystem().setHelp(parent, ModelUIPlugin.ID_PLUGIN + ".palette_editor"); //$NON-NLS-1$
return c;
}
@@ -208,7 +208,7 @@
protected void buttonPressed(int buttonId) {
if(buttonId == IDialogConstants.HELP_ID) {
- HelpUtil.helpEclipse(PreferenceModelUtilities.getPreferenceModel(), "PaletteEditor");
+ HelpUtil.helpEclipse(PreferenceModelUtilities.getPreferenceModel(), "PaletteEditor"); //$NON-NLS-1$
} else {
super.buttonPressed(buttonId);
}
@@ -243,7 +243,7 @@
for (int i = 0; i < as.length; i++) {
if(!as[i].isVisible()) continue;
String n = as[i].getName();
- if("name".equals(n)) continue;
+ if("name".equals(n)) continue; //$NON-NLS-1$
String v = e.getAttributeValue(n, SharableConstants.GENERAL);
String cv = e.getAttributeValue(n);
if(cv != null && cv.equals(v)) continue;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialogState.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialogState.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteDialogState.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -61,8 +61,8 @@
if(es == null || es.length < 2) {
XModel model = PreferenceModelUtilities.getPreferenceModel();
es = new Object[2];
- es[0] = model.getByPath("XStudio");
- es[1] = model.getByPath("XStudio/Palette");
+ es[0] = model.getByPath("XStudio"); //$NON-NLS-1$
+ es[1] = model.getByPath("XStudio/Palette"); //$NON-NLS-1$
}
dialog.treeViewer.setExpandedElements(es);
}
@@ -76,7 +76,7 @@
}
void loadSelection() {
- if(selected == null) selected = PreferenceModelUtilities.getPreferenceModel().getByPath("XStudio/Palette");
+ if(selected == null) selected = PreferenceModelUtilities.getPreferenceModel().getByPath("XStudio/Palette"); //$NON-NLS-1$
dialog.treeViewer.setSelection(new StructuredSelection(selected), true);
dialog.objectEditor.setModelObject((XModelObject)selected);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/PaletteEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -35,7 +35,7 @@
if(model.getService() == null) {
model.setService(new ServiceDialogImpl());
}
- fireTransactionEvent("transaction_begin");
+ fireTransactionEvent("transaction_begin"); //$NON-NLS-1$
try {
XUndoManager undo = model.getUndoManager();
undo.beginTransaction();
@@ -50,13 +50,13 @@
} finally {
if (dialog!=null) dialog.dispose();
dialog = null;
- fireTransactionEvent("transaction_end");
+ fireTransactionEvent("transaction_end"); //$NON-NLS-1$
}
}
private void fireTransactionEvent(String kind) {
XModelImpl m = (XModelImpl)ModelUtilities.getPreferenceModel();
- m.fireStructureChanged(m.getByPath("%Palette%"), 2, kind);
+ m.fireStructureChanged(m.getByPath("%Palette%"), 2, kind); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/model/PaletteModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/model/PaletteModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/model/PaletteModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,15 +27,15 @@
import org.jboss.tools.common.model.ui.util.ModelUtilities;
public class PaletteModel {
- static String SUB_GROUP_ELEMENT_TYPE = "sub-group";
- static String GROUP_ELEMENT_TYPE = "group";
+ static String SUB_GROUP_ELEMENT_TYPE = "sub-group"; //$NON-NLS-1$
+ static String GROUP_ELEMENT_TYPE = "group"; //$NON-NLS-1$
private static PaletteModel instance = null;
private static Object monitor = new Object();
private PaletteEditor editor = new PaletteEditor();
- private static final URL BASE_URL = ModelUIPlugin.getDefault().getBundle().getEntry("/");
+ private static final URL BASE_URL = ModelUIPlugin.getDefault().getBundle().getEntry("/"); //$NON-NLS-1$
private IPaletteNode root = null;
private PaletteModel() {
@@ -80,12 +80,12 @@
}
private void createTab(XModelObject xtab) {
- if (!"yes".equals(xtab.getAttributeValue("hidden"))) {
- IPaletteNode tab = addTab(xtab, xtab.getAttributeValue("name"));
+ if (!"yes".equals(xtab.getAttributeValue("hidden"))) { //$NON-NLS-1$ //$NON-NLS-2$
+ IPaletteNode tab = addTab(xtab, xtab.getAttributeValue("name")); //$NON-NLS-1$
for (int j = 0; j < xtab.getChildren().length; j++) {
XModelObject xelem = xtab.getChildAt(j);
- if (xelem.getAttributeValue("element type").equals("macro")) {
+ if (xelem.getAttributeValue("element type").equals("macro")) { //$NON-NLS-1$ //$NON-NLS-2$
createElem(tab, xelem, true);
}
}
@@ -103,7 +103,7 @@
}
public ImageDescriptor createImageDescriptor(String fileName) {
- String imagePath = "images/xstudio/palette/";
+ String imagePath = "images/xstudio/palette/"; //$NON-NLS-1$
try {
URL url = new URL(BASE_URL, imagePath + fileName);
return ImageDescriptor.createFromURL(url);
@@ -116,7 +116,7 @@
private XModelObject[] findXObjects(XModelObject root, String elementType){
ArrayList<XModelObject> v = new ArrayList<XModelObject>();
for (int i = 0; i < root.getChildren().length; i++) {
- if (root.getChildAt(i).getAttributeValue("element type").equals(elementType)) {
+ if (root.getChildAt(i).getAttributeValue("element type").equals(elementType)) { //$NON-NLS-1$
v.add(root.getChildAt(i));
}
}
@@ -124,7 +124,7 @@
}
private XModelObject getXModelRoot() {
- return getXModel().getRoot("Palette");
+ return getXModel().getRoot("Palette"); //$NON-NLS-1$
}
public XModel getXModel() {
@@ -138,7 +138,7 @@
public void runShowHideDialog() {
XModelObject root = getXModelRoot();
- XActionInvoker.invoke("HiddenTabs", root, new java.util.Properties());
+ XActionInvoker.invoke("HiddenTabs", root, new java.util.Properties()); //$NON-NLS-1$
}
public void addModelTreeListener(XModelTreeListener listener) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/DefaultSettings.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/DefaultSettings.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/DefaultSettings.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -93,84 +93,84 @@
protected void initSettings() {
// Unknow control
- put("Control.Style", SWT.NONE);
- put("Control.Background", defaultBackground);
- put("Control.Foreground", defaultForeground);
- put("Control.Font", defaultFont);
+ put("Control.Style", SWT.NONE); //$NON-NLS-1$
+ put("Control.Background", defaultBackground); //$NON-NLS-1$
+ put("Control.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Control.Font", defaultFont); //$NON-NLS-1$
// Composite
- put("Composite.Style", SWT.NONE);
- put("Composite.Background", defaultBackground);
- put("Composite.Foreground", defaultForeground);
- put("Composite.Font", defaultFont);
+ put("Composite.Style", SWT.NONE); //$NON-NLS-1$
+ put("Composite.Background", defaultBackground); //$NON-NLS-1$
+ put("Composite.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Composite.Font", defaultFont); //$NON-NLS-1$
// Label
- put("Label.Style", SWT.NONE);
+ put("Label.Style", SWT.NONE); //$NON-NLS-1$
// Please, do not put whiteBackground here, it spoils all wizards
- put("Label.Background", defaultBackground);
- put("Label.Foreground", defaultForeground);
- put("Label.Font", defaultFont);
- put("Label.Font.Title", titleFont);
- put("Label.Font.Header", headerFont);
+ put("Label.Background", defaultBackground); //$NON-NLS-1$
+ put("Label.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Label.Font", defaultFont); //$NON-NLS-1$
+ put("Label.Font.Title", titleFont); //$NON-NLS-1$
+ put("Label.Font.Header", headerFont); //$NON-NLS-1$
// Hyperlink
- put("Hyperlink.Style", SWT.NONE);
- put("Hyperlink.Background", defaultBackground);
- put("Hyperlink.Foreground", hyperlinkColor);
- put("Hyperlink.ActiveColor", activeHyperlinkColor);
- put("Hyperlink.Font", defaultFont);
- put("Hyperlink.ActiveCursor", handCursor);
- put("Hyperlink.Disabled", defaultForeground);
+ put("Hyperlink.Style", SWT.NONE); //$NON-NLS-1$
+ put("Hyperlink.Background", defaultBackground); //$NON-NLS-1$
+ put("Hyperlink.Foreground", hyperlinkColor); //$NON-NLS-1$
+ put("Hyperlink.ActiveColor", activeHyperlinkColor); //$NON-NLS-1$
+ put("Hyperlink.Font", defaultFont); //$NON-NLS-1$
+ put("Hyperlink.ActiveCursor", handCursor); //$NON-NLS-1$
+ put("Hyperlink.Disabled", defaultForeground); //$NON-NLS-1$
// Text
- put("Text.Style", SWT.BORDER);
- put("Text.Background", whiteBackground);
- put("Text.Foreground", defaultForeground);
- put("Text.Font", defaultFont);
+ put("Text.Style", SWT.BORDER); //$NON-NLS-1$
+ put("Text.Background", whiteBackground); //$NON-NLS-1$
+ put("Text.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Text.Font", defaultFont); //$NON-NLS-1$
// Note
- put("Note.Style", SWT.BORDER | SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
- put("Note.Background", whiteBackground);
- put("Note.Foreground", defaultForeground);
- put("Note.Font", defaultFont);
- put("Note.ValidateStrategy", 0);
+ put("Note.Style", SWT.BORDER | SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL); //$NON-NLS-1$
+ put("Note.Background", whiteBackground); //$NON-NLS-1$
+ put("Note.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Note.Font", defaultFont); //$NON-NLS-1$
+ put("Note.ValidateStrategy", 0); //$NON-NLS-1$
// Combo
- put("Combo.Style", SWT.BORDER);
- put("Combo.Background", whiteBackground);
- put("Combo.Background.Disabled", defaultBackground);
- put("Combo.Foreground", defaultForeground);
- put("Combo.Font", defaultFont);
+ put("Combo.Style", SWT.BORDER); //$NON-NLS-1$
+ put("Combo.Background", whiteBackground); //$NON-NLS-1$
+ put("Combo.Background.Disabled", defaultBackground); //$NON-NLS-1$
+ put("Combo.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Combo.Font", defaultFont); //$NON-NLS-1$
// Button
- put("Button.Style", SWT.PUSH);
- put("Button.Background", defaultBackground);
- put("Button.Foreground", defaultForeground);
- put("Button.Font", defaultFont);
+ put("Button.Style", SWT.PUSH); //$NON-NLS-1$
+ put("Button.Background", defaultBackground); //$NON-NLS-1$
+ put("Button.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Button.Font", defaultFont); //$NON-NLS-1$
// CheckBox
- put("CheckBox.Style", SWT.CHECK);
- put("CheckBox.Background", defaultBackground);
- put("CheckBox.Foreground", defaultForeground);
- put("CheckBox.Font", defaultFont);
+ put("CheckBox.Style", SWT.CHECK); //$NON-NLS-1$
+ put("CheckBox.Background", defaultBackground); //$NON-NLS-1$
+ put("CheckBox.Foreground", defaultForeground); //$NON-NLS-1$
+ put("CheckBox.Font", defaultFont); //$NON-NLS-1$
// List
- put("List.Style", SWT.BORDER);
- put("List.Background", whiteBackground);
- put("List.Foreground", defaultForeground);
- put("List.Font", defaultFont);
+ put("List.Style", SWT.BORDER); //$NON-NLS-1$
+ put("List.Background", whiteBackground); //$NON-NLS-1$
+ put("List.Foreground", defaultForeground); //$NON-NLS-1$
+ put("List.Font", defaultFont); //$NON-NLS-1$
// Tree
- put("Tree.Style", SWT.BORDER);
- put("Tree.Background", whiteBackground);
- put("Tree.Foreground", defaultForeground);
- put("Tree.Font", defaultFont);
+ put("Tree.Style", SWT.BORDER); //$NON-NLS-1$
+ put("Tree.Background", whiteBackground); //$NON-NLS-1$
+ put("Tree.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Tree.Font", defaultFont); //$NON-NLS-1$
// Table
- put("Table.Style", SWT.BORDER);
- put("Table.Background", whiteBackground);
- put("Table.Foreground", defaultForeground);
- put("Table.Font", defaultFont);
+ put("Table.Style", SWT.BORDER); //$NON-NLS-1$
+ put("Table.Background", whiteBackground); //$NON-NLS-1$
+ put("Table.Foreground", defaultForeground); //$NON-NLS-1$
+ put("Table.Font", defaultFont); //$NON-NLS-1$
}
public DefaultSettings() {
@@ -245,41 +245,41 @@
toolkit.adapt((Composite)control);
}
if (control instanceof CCombo || control instanceof Combo) {
- control.setBackground(getColor("Combo.Background"));
- control.setForeground(getColor("Combo.Foreground"));
- control.setFont(getFont("Combo.Font"));
+ control.setBackground(getColor("Combo.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Combo.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Combo.Font")); //$NON-NLS-1$
} else if (control instanceof Label) {
- control.setBackground(getColor("Label.Background"));
- control.setForeground(getColor("Label.Foreground"));
- control.setFont(getFont("Label.Font"));
+ control.setBackground(getColor("Label.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Label.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Label.Font")); //$NON-NLS-1$
} else if (control instanceof Text) {
- control.setBackground(getColor("Text.Background"));
- control.setForeground(getColor("Text.Foreground"));
- control.setFont(getFont("Text.Font"));
+ control.setBackground(getColor("Text.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Text.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Text.Font")); //$NON-NLS-1$
} else if (control instanceof Button) {
- control.setBackground(getColor("Button.Background"));
- control.setForeground(getColor("Button.Foreground"));
- control.setFont(getFont("Button.Font"));
+ control.setBackground(getColor("Button.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Button.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Button.Font")); //$NON-NLS-1$
} else if (control instanceof List) {
- control.setBackground(getColor("List.Background"));
- control.setForeground(getColor("List.Foreground"));
- control.setFont(getFont("List.Font"));
+ control.setBackground(getColor("List.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("List.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("List.Font")); //$NON-NLS-1$
} else if (control instanceof Tree) {
- control.setBackground(getColor("Tree.Background"));
- control.setForeground(getColor("Tree.Foreground"));
- control.setFont(getFont("Tree.Font"));
+ control.setBackground(getColor("Tree.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Tree.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Tree.Font")); //$NON-NLS-1$
} else if (control instanceof Table) {
- control.setBackground(getColor("Table.Background"));
- control.setForeground(getColor("Table.Foreground"));
- control.setFont(getFont("Table.Font"));
+ control.setBackground(getColor("Table.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Table.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Table.Font")); //$NON-NLS-1$
} else if (control instanceof Composite) {
- control.setBackground(getColor("Composite.Background"));
- control.setForeground(getColor("Composite.Foreground"));
- control.setFont(getFont("Composite.Font"));
+ control.setBackground(getColor("Composite.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Composite.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Composite.Font")); //$NON-NLS-1$
} else { // unknow control
- control.setBackground(getColor("Control.Background"));
- control.setForeground(getColor("Control.Foreground"));
- control.setFont(getFont("Control.Font"));
+ control.setBackground(getColor("Control.Background")); //$NON-NLS-1$
+ control.setForeground(getColor("Control.Foreground")); //$NON-NLS-1$
+ control.setFont(getFont("Control.Font")); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/NoTextBorderSettings.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/NoTextBorderSettings.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/NoTextBorderSettings.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,6 +18,6 @@
public NoTextBorderSettings() {
super();
- put("Text.border", (Object)null);
+ put("Text.border", (Object)null); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/TextAndReferenceComponent.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/TextAndReferenceComponent.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/TextAndReferenceComponent.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -31,7 +31,7 @@
public class TextAndReferenceComponent extends Canvas implements PaintListener, MouseMoveListener {
int defaultWidth = 100;
int width;
- String text = "";
+ String text = ""; //$NON-NLS-1$
Line[] lines = new Line[0];
int lineHeight = 12;
ReferenceListener listener;
@@ -149,7 +149,7 @@
}
boolean isReferenceStart() {
- boolean b = (c == '<' && text.indexOf("<a>", i) == i && !isReference);
+ boolean b = (c == '<' && text.indexOf("<a>", i) == i && !isReference); //$NON-NLS-1$
if(b) {
getLastToken();
isReference = true;
@@ -159,7 +159,7 @@
}
boolean isReferenceEnd() {
- boolean b = (c == '<' && text.indexOf("</a>", i) == i && isReference);
+ boolean b = (c == '<' && text.indexOf("</a>", i) == i && isReference); //$NON-NLS-1$
if(b) {
getLastToken();
isReference = false;
@@ -169,7 +169,7 @@
}
boolean isBoldStart() {
- boolean b = (c == '<' && text.indexOf("<b>", i) == i && !isBold);
+ boolean b = (c == '<' && text.indexOf("<b>", i) == i && !isBold); //$NON-NLS-1$
if(b) {
getLastToken();
isBold = true;
@@ -179,7 +179,7 @@
}
boolean isBoldEnd() {
- boolean b = (c == '<' && text.indexOf("</b>", i) == i && isBold);
+ boolean b = (c == '<' && text.indexOf("</b>", i) == i && isBold); //$NON-NLS-1$
if(b) {
getLastToken();
isBold = false;
@@ -287,7 +287,7 @@
}
class Token {
- String text = "";
+ String text = ""; //$NON-NLS-1$
boolean isReference = false;
boolean isBreak = false;
Rectangle r = new Rectangle(0, 0, 0, 0);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/WhiteSettings.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/WhiteSettings.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/WhiteSettings.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -61,40 +61,40 @@
protected void initSettings() {
super.initSettings();
// Text
- put("Text.Style", SWT.NONE);
- put("Text.Border", textBorder);
+ put("Text.Style", SWT.NONE); //$NON-NLS-1$
+ put("Text.Border", textBorder); //$NON-NLS-1$
// Note
- put("Note.Style", SWT.NONE | SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
- put("Note.Border", textBorder);
- put("Note.ValidateStrategy", 1);
+ put("Note.Style", SWT.NONE | SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL); //$NON-NLS-1$
+ put("Note.Border", textBorder); //$NON-NLS-1$
+ put("Note.ValidateStrategy", 1); //$NON-NLS-1$
// Combo
- put("Combo.Style", SWT.FLAT);
- put("Combo.Border", comboBorder);
+ put("Combo.Style", SWT.FLAT); //$NON-NLS-1$
+ put("Combo.Border", comboBorder); //$NON-NLS-1$
// Button
- put("Button.Style", SWT.FLAT);
+ put("Button.Style", SWT.FLAT); //$NON-NLS-1$
// CheckBox
- put("CheckBox.Style", SWT.FLAT | SWT.CHECK | SWT.LEFT);
+ put("CheckBox.Style", SWT.FLAT | SWT.CHECK | SWT.LEFT); //$NON-NLS-1$
// List
- put("List.Style", SWT.NONE);
- put("List.Border", listBorder);
+ put("List.Style", SWT.NONE); //$NON-NLS-1$
+ put("List.Border", listBorder); //$NON-NLS-1$
// Tree
- put("Tree.Style", SWT.NONE);
- put("Tree.Border", listBorder);
+ put("Tree.Style", SWT.NONE); //$NON-NLS-1$
+ put("Tree.Border", listBorder); //$NON-NLS-1$
// Table
- put("Table.Style", SWT.NONE);
- put("Table.Border", listBorder);
+ put("Table.Style", SWT.NONE); //$NON-NLS-1$
+ put("Table.Border", listBorder); //$NON-NLS-1$
// Separator
- put("Separator.Background", separatorColor);
+ put("Separator.Background", separatorColor); //$NON-NLS-1$
- put("Label.Foreground", hyperlinkColor);
+ put("Label.Foreground", hyperlinkColor); //$NON-NLS-1$
}
public FormToolkit getToolkit(Display display) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/xpl/FormLabel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/xpl/FormLabel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/widgets/xpl/FormLabel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -20,7 +20,7 @@
import org.eclipse.swt.widgets.*;
public class FormLabel extends Label {
- private String text = "";
+ private String text = ""; //$NON-NLS-1$
int marginWidth = 1;
int marginHeight = 1;
private boolean underlined;
@@ -43,7 +43,7 @@
return text;
}
public void setText(String text) {
- this.text = (text != null) ? text : "";
+ this.text = (text != null) ? text : ""; //$NON-NLS-1$
}
protected void checkSubclass () {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewClassCreationWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewClassCreationWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewClassCreationWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,8 +27,8 @@
public int execute() {
INewWizard wizard = ExtensionPointUtils.findNewWizardsItem(
- "org.eclipse.jdt.ui",
- "org.eclipse.jdt.ui.wizards.NewClassCreationWizard"
+ "org.eclipse.jdt.ui", //$NON-NLS-1$
+ "org.eclipse.jdt.ui.wizards.NewClassCreationWizard" //$NON-NLS-1$
);
if (wizard != null) {
wizard.init(
@@ -38,7 +38,7 @@
WizardDialog dialog = new WizardDialog(ModelUIPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell(), wizard);
dialog.open();
} else {
- ModelUIPlugin.getPluginLog().logError("Unable to create wizard 'org.eclipse.jdt.ui.wizards.NewClassCreationWizard'.", new ClassNotFoundException());
+ ModelUIPlugin.getPluginLog().logError("Unable to create wizard 'org.eclipse.jdt.ui.wizards.NewClassCreationWizard'.", new ClassNotFoundException()); //$NON-NLS-1$
}
return 0;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewFileContext.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewFileContext.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewFileContext.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -40,11 +40,11 @@
public void init() {
XModel model = ModelUtilities.getPreferenceModel();
- fakeFolder = model.createModelObject("FileFolder", null);
- XActionList list = model.getMetaData().getEntity("FileFolder").getActionList();
+ fakeFolder = model.createModelObject("FileFolder", null); //$NON-NLS-1$
+ XActionList list = model.getMetaData().getEntity("FileFolder").getActionList(); //$NON-NLS-1$
action = list.getAction(getActionPath());
support.setActionData(action, action.getEntityData(fakeFolder), fakeFolder, null);
- helpkey = "FileFolder_" + action.getName();
+ helpkey = "FileFolder_" + action.getName(); //$NON-NLS-1$
}
protected SpecialWizardSupport createSupport() {
@@ -77,7 +77,7 @@
if(folder != null) {
if(folder.getFileType() > XModelObject.FILE) {
} else if(folder.getFileType() == XModelObject.NONE)
- folder = folder.getModel().getByPath("FileSystems/WEB-INF");
+ folder = folder.getModel().getByPath("FileSystems/WEB-INF"); //$NON-NLS-1$
else if(folder.getFileType() == XModelObject.FILE)
folder = folder.getParent();
}
@@ -102,7 +102,7 @@
public void execute() throws XModelException {
Properties p = new Properties();
- if(resource != null) p.put("resource", resource);
+ if(resource != null) p.put("resource", resource); //$NON-NLS-1$
action.executeHandler(support.getTarget(), p);
}
@@ -122,11 +122,11 @@
public String getWindowTitle() {
String title = WizardKeys.getHeader(helpkey);
- return (title == null) ? "" : title;
+ return (title == null) ? "" : title; //$NON-NLS-1$
}
public String getTitle() {
String title = WizardKeys.getTitle(helpkey);
- return (title == null) ? "" : title;
+ return (title == null) ? "" : title; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewHTMLFileWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewHTMLFileWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewHTMLFileWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,7 +18,7 @@
class NewHTMLFileContext extends NewFileContextEx {
protected String getActionPath() {
- return "CreateActions.CreateFiles.Web.CreateFileHTML";
+ return "CreateActions.CreateFiles.Web.CreateFileHTML"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewJSPFileWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewJSPFileWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewJSPFileWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
protected SpecialWizardSupport createSupport() {
CreateFileSupport support = null;
try {
- support = (CreateFileSupport)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.web.model.handlers.CreateJSPFileSupport");
+ support = (CreateFileSupport)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.web.model.handlers.CreateJSPFileSupport"); //$NON-NLS-1$
} catch (ClassCastException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
@@ -35,7 +35,7 @@
return support;
}
protected String getActionPath() {
- return "CreateActions.CreateFiles.Web.CreateFileJSP";
+ return "CreateActions.CreateFiles.Web.CreateFileJSP"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewPropertiesFileWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewPropertiesFileWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewPropertiesFileWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,7 +18,7 @@
class NewPropertiesFileContext extends NewFileContextEx {
protected String getActionPath() {
- return "CreateActions.CreateFiles.Common.CreateFileProperties";
+ return "CreateActions.CreateFiles.Common.CreateFileProperties"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewXHTMLFileWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewXHTMLFileWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/NewXHTMLFileWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
protected SpecialWizardSupport createSupport() {
CreateFileSupport support = null;
try {
- support = (CreateFileSupport)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.web.model.handlers.CreateJSPFileSupport");
+ support = (CreateFileSupport)ModelFeatureFactory.getInstance().createFeatureInstance("org.jboss.tools.jst.web.model.handlers.CreateJSPFileSupport"); //$NON-NLS-1$
} catch (ClassCastException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
@@ -35,7 +35,7 @@
return support;
}
protected String getActionPath() {
- return "CreateActions.CreateFiles.Web.CreateFileXHTML";
+ return "CreateActions.CreateFiles.Web.CreateFileXHTML"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/WizardInvoker.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/WizardInvoker.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizard/newfile/WizardInvoker.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,9 +25,9 @@
if(p == null) {
return 1;
}
- String pluginId = p.getProperty("plugin");
- String wizardId = p.getProperty("wizard");
- XModelObject s = (XModelObject)p.get("object");
+ String pluginId = p.getProperty("plugin"); //$NON-NLS-1$
+ String wizardId = p.getProperty("wizard"); //$NON-NLS-1$
+ XModelObject s = (XModelObject)p.get("object"); //$NON-NLS-1$
INewWizard wizard = ExtensionPointUtils.findNewWizardsItem(pluginId, wizardId);
if(wizard == null || s == null) {
@@ -38,7 +38,7 @@
WizardDialog dialog = new WizardDialog(ModelUIPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell(), wizard);
dialog.create();
- PlatformUI.getWorkbench().getHelpSystem().setHelp(dialog.getShell(), "org.eclipse.ui.new_wizard_shortcut_context");
+ PlatformUI.getWorkbench().getHelpSystem().setHelp(dialog.getShell(), "org.eclipse.ui.new_wizard_shortcut_context"); //$NON-NLS-1$
dialog.open();
return 0;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/MessageWizardPage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/MessageWizardPage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/MessageWizardPage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,8 +18,8 @@
* Window>Preferences>Java>Code Generation>Code and Comments
*/
public class MessageWizardPage extends WizardPage{
- String message = "";
- String title = "";
+ String message = ""; //$NON-NLS-1$
+ String title = ""; //$NON-NLS-1$
public MessageWizardPage(String title,String message) {
super(message);
this.message=message;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/NewClassWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/NewClassWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/NewClassWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -41,7 +41,7 @@
super();
this.adapter = adapter;
setDialogSettings(JavaPlugin.getDefault().getDialogSettings());
- setWindowTitle(NewWizardMessages.NewClassCreationWizard_title); //$NON-NLS-1$
+ setWindowTitle(NewWizardMessages.NewClassCreationWizard_title);
setDefaultPageImageDescriptor(JavaPluginImages.DESC_WIZBAN_NEWCLASS);
}
@@ -61,7 +61,7 @@
public String getQualifiedClassName() {
String c = mainPage.getTypeName();
String p = mainPage.getPackageText();
- if(p != null && p.length() > 0) c = p + "." + c;
+ if(p != null && p.length() > 0) c = p + "." + c; //$NON-NLS-1$
return c;
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/OneStepWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/OneStepWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/OneStepWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,8 +26,8 @@
public void setObject(Object object) {
p = (Properties)object;
- action = (XAction)p.get("action");
- modelObject = (XModelObject)p.get("object");
+ action = (XAction)p.get("action"); //$NON-NLS-1$
+ modelObject = (XModelObject)p.get("object"); //$NON-NLS-1$
}
public int execute() {
@@ -58,9 +58,9 @@
public String getHelpKey() {
if(action == null) return null;
- String key = action.getProperty("key");
+ String key = action.getProperty("key"); //$NON-NLS-1$
if(key != null && key.length() > 0) return key;
- return target.getModelEntity().getName() + "_" + action.getName().replace(' ', '_');
+ return target.getModelEntity().getName() + "_" + action.getName().replace(' ', '_'); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/one/ServiceDialogOption.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/one/ServiceDialogOption.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/one/ServiceDialogOption.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,8 +26,8 @@
String message = ServiceDialog.CHECKBOX_MESSAGE;
property = ServiceDialog.CHECKED;
if(k > 0) {
- property += "_" + k;
- message += "_" + k;
+ property += "_" + k; //$NON-NLS-1$
+ message += "_" + k; //$NON-NLS-1$
}
p.setProperty(message, text);
p.put(property, Boolean.FALSE);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,12 +21,12 @@
public class AbstractQueryWizard implements SpecialWizard {
public static class Property {
- public static final String HELP = "help";
- public static final String MODAL = "modal";
- public static final String TITLE = "title";
- public static final String SUBTITLE = "subtitle";
- public static final String MESSAGE = "message";
- public static final String BLOCKING = "blocking";
+ public static final String HELP = "help"; //$NON-NLS-1$
+ public static final String MODAL = "modal"; //$NON-NLS-1$
+ public static final String TITLE = "title"; //$NON-NLS-1$
+ public static final String SUBTITLE = "subtitle"; //$NON-NLS-1$
+ public static final String MESSAGE = "message"; //$NON-NLS-1$
+ public static final String BLOCKING = "blocking"; //$NON-NLS-1$
}
private AbstractQueryWizardView view = null;
@@ -48,13 +48,13 @@
view.setModel(findModel(object));
view.setObject(object);
Properties p = findProperties(object);
- String key = (p == null) ? null : p.getProperty("help");
+ String key = (p == null) ? null : p.getProperty("help"); //$NON-NLS-1$
if(key == null) {
//put debuggin here
} else {
String title = p.getProperty(Property.TITLE);
if(title == null) title = WizardKeys.getHeader(key);
- if(title == null) title = WizardKeys.getHeader("Properties"); // NON-NLS-1
+ if(title == null) title = WizardKeys.getHeader("Properties"); // NON-NLS-1 //$NON-NLS-1$
if(title == null) title = "Title is not found for key \"" + key + "\"";
view.setWindowTitle(title);
@@ -64,7 +64,7 @@
view.setTitle(subtitle);
String message = p.getProperty(Property.MESSAGE);
- if(message == null) message = WizardKeys.getString(key + ".Message");
+ if(message == null) message = WizardKeys.getString(key + ".Message"); //$NON-NLS-1$
if(message != null) view.setMessage(message);
}
}
@@ -91,9 +91,9 @@
}
Properties p = findProperties(o);
if(p != null) {
- Object q = p.get("model");
+ Object q = p.get("model"); //$NON-NLS-1$
if(q instanceof XModel) return (XModel)q;
- q = p.get("object");
+ q = p.get("object"); //$NON-NLS-1$
if(q instanceof XModelObject) return ((XModelObject)q).getModel();
}
return null;
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
protected XModel model;
protected String windowTitle;
- private String title = "";
+ private String title = ""; //$NON-NLS-1$
private String message;
private String errorMessage;
private Image titleImage;
@@ -64,11 +64,11 @@
public void setObject(Object object) {
Properties p = findProperties(object);
if(p != null) {
- String key = p.getProperty("help");
+ String key = p.getProperty("help"); //$NON-NLS-1$
setHelpKey(key);
windowTitle = WizardKeys.getHeader(key);
title = WizardKeys.getTitle(key);
- if(title == null) title = p.getProperty("title", "");
+ if(title == null) title = p.getProperty("title", ""); //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractListWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractListWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractListWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -49,7 +49,7 @@
public void setObject(Object data) {
super.setObject(data);
Properties p = (Properties)data;
- vs = (String[][])p.get("data");
+ vs = (String[][])p.get("data"); //$NON-NLS-1$
boxes = new Button[vs.length];
}
@@ -74,7 +74,7 @@
for (int i = 0; i < vs.length; i++) {
boxes[i] = new Button(c, SWT.CHECK);
boxes[i].setText(vs[i][0]);
- boxes[i].setSelection(!"yes".equals(vs[i][1]));
+ boxes[i].setSelection(!"yes".equals(vs[i][1])); //$NON-NLS-1$
boxes[i].addSelectionListener(new AL(i));
}
c.pack();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractTreeWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractTreeWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/AbstractTreeWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -29,7 +29,7 @@
protected CheckTreeProvider provider = new CheckTreeProvider();
protected TreeItemSelectionManager treeSelectionManager;
protected String[][] vs = new String[0][];
- CheckObject object = new CheckObject(null, new String[]{"", "yes"});
+ CheckObject object = new CheckObject(null, new String[]{"", "yes"}); //$NON-NLS-1$
int expandingLevel = 2;
public AbstractTreeWizardView() {
@@ -53,8 +53,8 @@
public void setObject(Object data) {
super.setObject(data);
Properties p = (Properties)data;
- vs = (String[][])p.get("data");
- String s = p.getProperty("expandingLevel");
+ vs = (String[][])p.get("data"); //$NON-NLS-1$
+ String s = p.getProperty("expandingLevel"); //$NON-NLS-1$
if(s != null && s.length() > 0) try {
expandingLevel = Integer.parseInt(s);
} catch (NumberFormatException e) {
@@ -64,7 +64,7 @@
}
void makeObject() {
- object = new CheckObject(null, new String[]{"", "no"});
+ object = new CheckObject(null, new String[]{"", "no"}); //$NON-NLS-1$
provider.setObject(object);
for (int i = 0; i < vs.length; i++) {
String path = vs[i][0];
@@ -248,8 +248,8 @@
}
class CheckTreeProvider extends LabelProvider implements ITreeContentProvider, ILabelProvider, IColorProvider {
- public Image IMAGE_ENABLED = EclipseResourceUtil.getImage("images/common/check.gif");
- public Image IMAGE_DISABLED = EclipseResourceUtil.getImage("images/common/uncheck.gif");
+ public Image IMAGE_ENABLED = EclipseResourceUtil.getImage("images/common/check.gif"); //$NON-NLS-1$
+ public Image IMAGE_DISABLED = EclipseResourceUtil.getImage("images/common/uncheck.gif"); //$NON-NLS-1$
protected CheckObject object = null;
public CheckObject getObject() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -14,10 +14,10 @@
public class HiddenFileSystemsWizardView extends AbstractListWizardView {
public HiddenFileSystemsWizardView() {
- setHelpKey("FileSystems_ShowHide");
- this.setMessage(WizardKeys.getString("HiddenFileSystemsWizardView.Message"));
- this.setTitle(WizardKeys.getString("HiddenFileSystemsWizardView.Title"));
- this.setWindowTitle(WizardKeys.getString("HiddenFileSystemsWizardView.WindowTitle"));
+ setHelpKey("FileSystems_ShowHide"); //$NON-NLS-1$
+ this.setMessage(WizardKeys.getString("HiddenFileSystemsWizardView.Message")); //$NON-NLS-1$
+ this.setTitle(WizardKeys.getString("HiddenFileSystemsWizardView.Title")); //$NON-NLS-1$
+ this.setWindowTitle(WizardKeys.getString("HiddenFileSystemsWizardView.WindowTitle")); //$NON-NLS-1$
}
protected String[] getActions() {
@@ -27,13 +27,13 @@
protected void internalAction(String command) {
if("Hide All Jars".equals(command)) {
for (int i = 0; i < boxes.length; i++)
- if("true".equals(vs[i][2])) {
+ if("true".equals(vs[i][2])) { //$NON-NLS-1$
boxes[i].setSelection(false);
apply(i);
}
} else if("Show All Jars".equals(command)) {
for (int i = 0; i < boxes.length; i++)
- if("true".equals(vs[i][2])) {
+ if("true".equals(vs[i][2])) { //$NON-NLS-1$
boxes[i].setSelection(true);
apply(i);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/special/DefaultSpecialWizard.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/special/DefaultSpecialWizard.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/special/DefaultSpecialWizard.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -40,7 +40,7 @@
}
public int execute() {
- Shell shell = (Shell)support.getProperties().get("shell");
+ Shell shell = (Shell)support.getProperties().get("shell"); //$NON-NLS-1$
if(shell == null) shell = ModelUIPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell();
if(support.canBeProcessedByStandardWizard()) {
@@ -50,7 +50,7 @@
dsw.setDefaultPageImageDescriptor(ModelUIImages.getImageDescriptor(ModelUIImages.WIZARD_DEFAULT));
WizardDialog wd = new WizardDialog(shell, dsw);
wd.create();
- PlatformUI.getWorkbench().getHelpSystem().setHelp(wd.getShell(), "org.eclipse.ui.new_wizard_shortcut_context");
+ PlatformUI.getWorkbench().getHelpSystem().setHelp(wd.getShell(), "org.eclipse.ui.new_wizard_shortcut_context"); //$NON-NLS-1$
int ii = wd.open();
return ii;
}
@@ -59,8 +59,8 @@
dialog.setWizard(this);
dialog.create();
progressPart = new ProgressPart(dialog.getShell(), this);
- support.getProperties().put("dialogShell", dialog.getShell());
- support.getProperties().put("IRunnableContext", progressPart);
+ support.getProperties().put("dialogShell", dialog.getShell()); //$NON-NLS-1$
+ support.getProperties().put("IRunnableContext", progressPart); //$NON-NLS-1$
open();
return 0;
}
@@ -99,7 +99,7 @@
try {
save();
support.action(name);
- dialog.setMessage("");
+ dialog.setMessage(""); //$NON-NLS-1$
} catch (XModelException e) {
ModelUIPlugin.getPluginLog().logError(e);
}
@@ -144,7 +144,7 @@
}
step.setSupport(support, i);
} catch (ClassCastException e) {
- ModelUIPlugin.getPluginLog().logError("Cannot load class '" + cls + "'.");
+ ModelUIPlugin.getPluginLog().logError("Cannot load class '" + cls + "'."); //$NON-NLS-1$ //$NON-NLS-2$
}
return step;
}
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 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/standard/DefaultStandardStep.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -37,7 +37,7 @@
boolean loading = false;
public DefaultStandardStep(SpecialWizardSupport support, int id) {
- super("");
+ super(""); //$NON-NLS-1$
this.support = support;
this.id = id;
validator = support.getValidator(id);
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/util/DeadLock.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/util/DeadLock.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/util/DeadLock.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,20 +10,20 @@
return this.name;
}
public synchronized void bow(Friend bower) {
- System.out.format("%s: %s has bowed to me!%n",
+ System.out.format("%s: %s has bowed to me!%n", //$NON-NLS-1$
this.name, bower.getName());
bower.bowBack(this);
}
public synchronized void bowBack(Friend bower) {
- System.out.format("%s: %s has bowed back to me!%n",
+ System.out.format("%s: %s has bowed back to me!%n", //$NON-NLS-1$
this.name, bower.getName());
}
}
public static void main(String[] args) {
- final Friend alphonse = new Friend("Alphonse");
- final Friend gaston = new Friend("Gaston");
+ final Friend alphonse = new Friend("Alphonse"); //$NON-NLS-1$
+ final Friend gaston = new Friend("Gaston"); //$NON-NLS-1$
new Thread(new Runnable() {
public void run() { alphonse.bow(gaston); }
}).start();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,9 +27,9 @@
public class BundleLanguagesEditor implements CommandBarListener, SelectionListener {
static String CREATE = "Add";
static String DELETE = "Delete";
- public Image IMAGE_DELETE = EclipseResourceUtil.getImage("images/actions/delete.gif");
- public Image IMAGE_EDIT = EclipseResourceUtil.getImage("images/actions/edit.gif");
- public Image IMAGE_CREATE = EclipseResourceUtil.getImage("images/actions/new.gif");
+ public Image IMAGE_DELETE = EclipseResourceUtil.getImage("images/actions/delete.gif"); //$NON-NLS-1$
+ public Image IMAGE_EDIT = EclipseResourceUtil.getImage("images/actions/edit.gif"); //$NON-NLS-1$
+ public Image IMAGE_CREATE = EclipseResourceUtil.getImage("images/actions/new.gif"); //$NON-NLS-1$
BundleModel bundleModel;
protected Composite control;
protected ComboModel combomodel = new ComboModel();
@@ -132,13 +132,13 @@
private void add() {
CountriesHelper.init(bundleModel.getModelObject().getModel());
- XModelObject o = bundleModel.getModelObject().getModel().createModelObject("BundleList", null);
- XActionInvoker.invoke("CreateActions.AddBundle", o, null);
+ XModelObject o = bundleModel.getModelObject().getModel().createModelObject("BundleList", null); //$NON-NLS-1$
+ XActionInvoker.invoke("CreateActions.AddBundle", o, null); //$NON-NLS-1$
XModelObject[] os = o.getChildren();
if(os.length == 0) return;
- String lg = os[0].getAttributeValue("language");
- String ct = os[0].getAttributeValue("country");
- String locale = ((lg + ct).length() == 0) ? "" : lg + "_" + ct;
+ String lg = os[0].getAttributeValue("language"); //$NON-NLS-1$
+ String ct = os[0].getAttributeValue("country"); //$NON-NLS-1$
+ String locale = ((lg + ct).length() == 0) ? "" : lg + "_" + ct; //$NON-NLS-1$ //$NON-NLS-2$
bundleModel.addLocale(locale);
update();
widgetSelected(null);
@@ -159,7 +159,7 @@
public void widgetSelected(SelectionEvent e) {
if(lock) return;
Object o = combomodel.getSelectedItem();
- String locale = (o == null) ? "" : o.toString();
+ String locale = (o == null) ? "" : o.toString(); //$NON-NLS-1$
bundleModel.setCurrentLocale(locale);
if(listener != null) listener.update();
}
@@ -170,7 +170,7 @@
class ComboModel extends DefaultComboModel {
public String getPresentation(Object object) {
String s = super.getPresentation(object);
- return (s.length() == 0) ? "default" : s;
+ return (s.length() == 0) ? "default" : s; //$NON-NLS-1$
}
}
@@ -205,7 +205,7 @@
public void setSelectedItem(Object o) {
if(combo == null) return;
int i = getIndexOf(o);
- if(i < 0) combo.setText(""); else combo.setText(combo.getItem(i));
+ if(i < 0) combo.setText(""); else combo.setText(combo.getItem(i)); //$NON-NLS-1$
}
public Object getElementAt(int i) {
return (i < 0 || i >= list.size()) ? null : list.get(i);
@@ -219,7 +219,7 @@
}
public String getPresentation(Object object) {
- return (object == null) ? "" : object.toString();
+ return (object == null) ? "" : object.toString(); //$NON-NLS-1$
}
public void refresh() {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLocaleEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLocaleEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLocaleEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -39,7 +39,7 @@
protected void edit() {
XModelObject o = helper.getModelObject(xtable.getSelectionIndex());
if(o != null) {
- callAction(o, "Properties.Edit");
+ callAction(o, "Properties.Edit"); //$NON-NLS-1$
updatePropertyModel();
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesCompoundEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesCompoundEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesCompoundEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -80,8 +80,8 @@
}
protected void updateSelectionProvider() {
- if(propertiesEditor != null) selectionProvider.addHost("guiEditor", propertiesEditor.getSelectionProvider());
- if(textEditor != null) selectionProvider.addHost("textEditor", getTextSelectionProvider());
+ if(propertiesEditor != null) selectionProvider.addHost("guiEditor", propertiesEditor.getSelectionProvider()); //$NON-NLS-1$
+ if(textEditor != null) selectionProvider.addHost("textEditor", getTextSelectionProvider()); //$NON-NLS-1$
int index = getActivePage();
if(index == getSourcePageIndex()) {
if(textEditor != null) {
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/PropertiesEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -93,9 +93,9 @@
IEditorSite site;
FPTableHelper pHelper;
- private QualifiedName filterOpenedId = new QualifiedName("", "filterOpened"); //$NON-NLS-1$
- private QualifiedName nameFilterId = new QualifiedName("", "nameFilter"); //$NON-NLS-1$
- private QualifiedName valueFilterId = new QualifiedName("", "valueFilter"); //$NON-NLS-1$
+ private QualifiedName filterOpenedId = new QualifiedName("", "filterOpened"); //$NON-NLS-1$ //$NON-NLS-2$
+ private QualifiedName nameFilterId = new QualifiedName("", "nameFilter"); //$NON-NLS-1$ //$NON-NLS-2$
+ private QualifiedName valueFilterId = new QualifiedName("", "valueFilter"); //$NON-NLS-1$ //$NON-NLS-2$
private boolean filterOpened = false;
@@ -194,17 +194,17 @@
protected Color getItemColor(int i) {
XModelObject o = helper.getModelObject(i);
- boolean disabled = "no".equals(o.getAttributeValue(ATTR_ENABLED));
+ boolean disabled = "no".equals(o.getAttributeValue(ATTR_ENABLED)); //$NON-NLS-1$
return ((disabled) ? GREYED_COLOR : DEFAULT_COLOR);
}
protected String getAddActionPath() {
- return "CreateActions.CreateProperty";
+ return "CreateActions.CreateProperty"; //$NON-NLS-1$
}
protected void edit() {
XModelObject o = helper.getModelObject(xtable.getSelectionIndex());
- if(o != null) callAction(o, "Properties.Edit");
+ if(o != null) callAction(o, "Properties.Edit"); //$NON-NLS-1$
}
public class TMenuInvoker extends XMenuInvoker {
@@ -279,11 +279,11 @@
void loadPreferences(IFile f) {
if(f == null || !f.exists()) return;
try {
- filterOpened = "true".equals(f.getPersistentProperty(filterOpenedId));
+ filterOpened = "true".equals(f.getPersistentProperty(filterOpenedId)); //$NON-NLS-1$
pHelper.nameFilter = f.getPersistentProperty(nameFilterId);
pHelper.valueFilter = f.getPersistentProperty(valueFilterId);
- if(pHelper.nameFilter == null) pHelper.nameFilter = "";
- if(pHelper.valueFilter == null) pHelper.valueFilter = "";
+ if(pHelper.nameFilter == null) pHelper.nameFilter = ""; //$NON-NLS-1$
+ if(pHelper.valueFilter == null) pHelper.valueFilter = ""; //$NON-NLS-1$
} catch (CoreException e) {
//ignore
}
@@ -292,9 +292,9 @@
void savePreferences(IFile f) {
if(f == null || !f.exists()) return;
try {
- f.setPersistentProperty(filterOpenedId, "" + filterOpened);
+ f.setPersistentProperty(filterOpenedId, "" + filterOpened); //$NON-NLS-1$
f.setPersistentProperty(nameFilterId, pHelper.nameFilter);
- f.setPersistentProperty(valueFilterId, "" + pHelper.valueFilter);
+ f.setPersistentProperty(valueFilterId, "" + pHelper.valueFilter); //$NON-NLS-1$
} catch (CoreException e) {
//ignore
}
@@ -363,7 +363,7 @@
public void doOperation(int operation) {
if (operation>actionMapping.size()) {
- ModelUIPlugin.getPluginLog().logError(new IllegalArgumentException("Can not find global action with index: "+operation));
+ ModelUIPlugin.getPluginLog().logError(new IllegalArgumentException("Can not find global action with index: "+operation)); //$NON-NLS-1$
} else {
String globalAction = (String)actionMapping.get(operation);
doGlobalAction(globalAction);
@@ -464,8 +464,8 @@
class FPTableHelper extends AbstractTableHelper implements PropertyChangeListener {
PropertiesEditor pe;
- String nameFilter = "";
- String valueFilter = "";
+ String nameFilter = ""; //$NON-NLS-1$
+ String valueFilter = ""; //$NON-NLS-1$
XModelObject[] filteredChildren = new XModelObject[0];
long ts = -1;
@@ -521,7 +521,7 @@
public String[] getHeader() {
- return new String[]{"name", "value"};
+ return new String[]{"name", "value"}; //$NON-NLS-1$ //$NON-NLS-2$
}
public void propertyChange(PropertyChangeEvent evt) {
@@ -529,9 +529,9 @@
DefaultValueAdapter a = (DefaultValueAdapter)evt.getSource();
String name = a.getAttribute().getName();
if(PropertiesEditor.ATTR_NAME.equals(name)) {
- nameFilter = "" + evt.getNewValue();
+ nameFilter = "" + evt.getNewValue(); //$NON-NLS-1$
} else if(PropertiesEditor.ATTR_VALUE.equals(name)) {
- valueFilter = "" + evt.getNewValue();
+ valueFilter = "" + evt.getNewValue(); //$NON-NLS-1$
}
applyFilters();
pe.refresh();
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/BundleModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/BundleModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/BundleModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -33,8 +33,8 @@
public class BundleModel {
IFile main;
- XModelObject object = PreferenceModelUtilities.getPreferenceModel().createModelObject("FilePROPERTIES", null);
- String currentLocale = "";
+ XModelObject object = PreferenceModelUtilities.getPreferenceModel().createModelObject("FilePROPERTIES", null); //$NON-NLS-1$
+ String currentLocale = ""; //$NON-NLS-1$
Set<String> locales = new TreeSet<String>();
Set<String> removedLocales = new HashSet<String>();
boolean isModified;
@@ -56,7 +56,7 @@
public String getName() {
String name = main.getName();
- if(name.endsWith(".properties")) name = name.substring(0, name.length() - ".properties".length());
+ if(name.endsWith(".properties")) name = name.substring(0, name.length() - ".properties".length()); //$NON-NLS-1$ //$NON-NLS-2$
return name;
}
@@ -70,8 +70,8 @@
public IFile getFile(String locale) {
if(locale.length() == 0) return main;
- String name = getName() + "_" + locale + ".properties";
- return main.getParent().getFile(new Path("/" + name));
+ String name = getName() + "_" + locale + ".properties"; //$NON-NLS-1$ //$NON-NLS-2$
+ return main.getParent().getFile(new Path("/" + name)); //$NON-NLS-1$
}
public String[] getLocales() {
@@ -93,9 +93,9 @@
}
public PropertyModel createPropertyModel(String name, String value, String locale) {
- XModelObject o = PreferenceModelUtilities.getPreferenceModel().createModelObject("Property", null);
- o.setAttributeValue("name", name);
- o.setAttributeValue("value", value);
+ XModelObject o = PreferenceModelUtilities.getPreferenceModel().createModelObject("Property", null); //$NON-NLS-1$
+ o.setAttributeValue("name", name); //$NON-NLS-1$
+ o.setAttributeValue("value", value); //$NON-NLS-1$
object.addChild(o);
return getPropertyModel(o, locale);
}
@@ -106,11 +106,11 @@
public PropertyModel getPropertyModel(XModelObject o, String locale) {
if(o == null) return null;
- PropertyModel pm = (PropertyModel)o.getObject("propertyModel");
+ PropertyModel pm = (PropertyModel)o.getObject("propertyModel"); //$NON-NLS-1$
if(pm == null) {
pm = new PropertyModel(this);
pm.setModelObject(o);
- if(locale != null) pm.setValue(locale, o.getAttributeValue("value"));
+ if(locale != null) pm.setValue(locale, o.getAttributeValue("value")); //$NON-NLS-1$
pm.setLocale(currentLocale);
}
return pm;
@@ -123,12 +123,12 @@
public void load() {
locales.clear();
removedLocales.clear();
- locales.add("");
+ locales.add(""); //$NON-NLS-1$
String name = getName();
String[][] p = loadFile(main);
if(p == null) return;
for (int i = 0; i < p.length; i++) {
- createPropertyModel(p[i][0], p[i][1], "");
+ createPropertyModel(p[i][0], p[i][1], ""); //$NON-NLS-1$
}
IResource[] rs = new IResource[0];
try {
@@ -140,9 +140,9 @@
if(!(rs[i] instanceof IFile)) continue;
IFile f = (IFile)rs[i];
String nm = rs[i].getLocation().lastSegment().toString();
- if(!nm.startsWith(name) || !nm.endsWith(".properties") || nm.indexOf("_") < 0) continue;
- nm = nm.substring(0, nm.length() - ".properties".length());
- String locale = nm.substring(nm.indexOf("_") + 1);
+ if(!nm.startsWith(name) || !nm.endsWith(".properties") || nm.indexOf("_") < 0) continue; //$NON-NLS-1$ //$NON-NLS-2$
+ nm = nm.substring(0, nm.length() - ".properties".length()); //$NON-NLS-1$
+ String locale = nm.substring(nm.indexOf("_") + 1); //$NON-NLS-1$
locales.add(locale);
p = loadFile(f);
if(p == null) continue;
@@ -164,7 +164,7 @@
Properties p = new Properties();
try {
InputStream s = file.getContents();
- BufferedReader in = new BufferedReader(new InputStreamReader(s, "8859_1"));
+ BufferedReader in = new BufferedReader(new InputStreamReader(s, "8859_1")); //$NON-NLS-1$
while (true) {
String line = in.readLine();
if(line == null) break;
@@ -174,8 +174,8 @@
StringBuffer sb = new StringBuffer(line);
while (continueLine(line)) {
String nextLine = in.readLine();
- if(nextLine == null) nextLine = "";
- sb.append("\n");
+ if(nextLine == null) nextLine = ""; //$NON-NLS-1$
+ sb.append("\n"); //$NON-NLS-1$
sb.append(line = nextLine);
}
ByteArrayInputStream is = new ByteArrayInputStream(sb.toString().getBytes());
@@ -262,7 +262,7 @@
continue;
}
String s = os.toString();
- if(s.startsWith("#")) s = s.substring(s.indexOf('\n') + 1);
+ if(s.startsWith("#")) s = s.substring(s.indexOf('\n') + 1); //$NON-NLS-1$
sb.append(s);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/PropertyModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/PropertyModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/bundlemodel/PropertyModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
public void setModelObject(XModelObject object) {
this.object = object;
- object.setObject("propertyModel", this);
+ object.setObject("propertyModel", this); //$NON-NLS-1$
}
public XModelObject getModelObject() {
@@ -33,7 +33,7 @@
}
public String getName() {
- return object.getAttributeValue("name");
+ return object.getAttributeValue("name"); //$NON-NLS-1$
}
public boolean hasValue(String locale) {
@@ -42,8 +42,8 @@
public String getValue(String locale) {
Object v = values.get(locale);
- if(v == null) v = values.get("");
- return (v == null) ? "" : v.toString();
+ if(v == null) v = values.get(""); //$NON-NLS-1$
+ return (v == null) ? "" : v.toString(); //$NON-NLS-1$
}
public void setValue(String locale, String value) {
@@ -56,13 +56,13 @@
}
public void setLocale(String locale) {
- object.setAttributeValue("value", getValue(locale));
+ object.setAttributeValue("value", getValue(locale)); //$NON-NLS-1$
}
public void commit() {
String locale = bundleModel.getCurrentLocale();
String v = getValue(locale);
- setValue(locale, object.getAttributeValue("value"));
+ setValue(locale, object.getAttributeValue("value")); //$NON-NLS-1$
if(!v.equals(getValue(locale))) bundleModel.setModified(true);
}
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/text/PropertyTextEditorSupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/text/PropertyTextEditorSupport.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/text/PropertyTextEditorSupport.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
protected String loadContent() {
XModelObject o = getModelObject();
- return (o == null ? "" : loader.getBody(o));
+ return (o == null ? "" : loader.getBody(o)); //$NON-NLS-1$
}
public void save() {
Added: trunk/common/plugins/org.jboss.tools.common.projecttemplates/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.projecttemplates/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.projecttemplates/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common.projecttemplates/src/org/jboss/tools/common/projecttemplates/ProjectTemplatesPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.projecttemplates/src/org/jboss/tools/common/projecttemplates/ProjectTemplatesPlugin.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.projecttemplates/src/org/jboss/tools/common/projecttemplates/ProjectTemplatesPlugin.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
import org.osgi.framework.BundleContext;
public class ProjectTemplatesPlugin extends AbstractUIPlugin{
- public static final String PLUGIN_ID = "org.jboss.tools.common.projecttemplates";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.projecttemplates"; //$NON-NLS-1$
static ProjectTemplatesPlugin instance;
public static ProjectTemplatesPlugin getDefault() {
@@ -49,9 +49,9 @@
Bundle bundle = Platform.getBundle(PLUGIN_ID);
URL url = null;
try {
- url = bundle == null ? null : FileLocator.resolve(bundle.getEntry("/"));
+ url = bundle == null ? null : FileLocator.resolve(bundle.getEntry("/")); //$NON-NLS-1$
} catch (IOException e) {
- url = bundle.getEntry("/");
+ url = bundle.getEntry("/"); //$NON-NLS-1$
}
return (url == null) ? null : url.getPath();
}
@@ -65,12 +65,12 @@
FileFilter filter = new FileFilter() {
public boolean accept(File pathname) {
return pathname != null
- && !"CVS".equals(pathname.getName())
- && !".svn".equalsIgnoreCase(pathname.getName());
+ && !"CVS".equals(pathname.getName()) //$NON-NLS-1$
+ && !".svn".equalsIgnoreCase(pathname.getName()); //$NON-NLS-1$
}
};
- copy(location, install, "templates", filter);
- copy(location, install, "lib", filter);
+ copy(location, install, "templates", filter); //$NON-NLS-1$
+ copy(location, install, "lib", filter); //$NON-NLS-1$
}
private void copy(File location, File install, String name, FileFilter filter) {
@@ -83,7 +83,7 @@
public static String getTemplateStateLocation() {
String stateLocation = getTemplateStatePath().toString().replace('\\', '/');
- if(!stateLocation.endsWith("/")) stateLocation += "/";
+ if(!stateLocation.endsWith("/")) stateLocation += "/"; //$NON-NLS-1$ //$NON-NLS-2$
return stateLocation;
}
@@ -93,7 +93,7 @@
}
static public void log(Exception ex) {
- getDefault().getLog().log(new Status(Status.ERROR, PLUGIN_ID, Status.OK, "No message", ex));
+ getDefault().getLog().log(new Status(Status.ERROR, PLUGIN_ID, Status.OK, "No message", ex)); //$NON-NLS-1$
}
}
\ No newline at end of file
Added: trunk/common/plugins/org.jboss.tools.common.resref.core/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.core/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.resref.core/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Added: trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/Messages.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/Messages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1,18 @@
+package org.jboss.tools.common.resref.core;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.resref.core.messages"; //$NON-NLS-1$
+ public static String ResourceReference_Folder;
+ public static String ResourceReference_Global;
+ public static String ResourceReference_Page;
+ public static String ResourceReference_Project;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
Modified: trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/ResourceReference.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/ResourceReference.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/ResourceReference.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,12 +18,14 @@
public final static int PROJECT_SCOPE = 2;
public final static int GLOBAL_SCOPE = 3;
- public final static String[] SCOPE_NAMES = new String[]{"Page", "Folder", "Project","Global"};
+ // This array should not be translated: names used in BaseAddReferenceSupport
+ public final static String[] SCOPE_NAMES = new String[]{"Page", "Folder", "Project","Global"}; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
+ private final static String[] LOCALIZED_SCOPE_NAMES = new String[]{Messages.ResourceReference_Page, Messages.ResourceReference_Folder, Messages.ResourceReference_Project,Messages.ResourceReference_Global};
protected String location;
protected int scope;
protected int depth = 0;
- protected String properties = "";
+ protected String properties = ""; //$NON-NLS-1$
protected boolean isGlobal = false;
@@ -73,6 +75,10 @@
return SCOPE_NAMES[scope];
}
+ public String getLocalizedScopeName() {
+ return LOCALIZED_SCOPE_NAMES[scope];
+ }
+
public void setDepth(int depth) {
this.depth = depth;
}
@@ -84,7 +90,7 @@
public String getLocationAndProperties() {
String v = location;
if(properties.length() > 0) {
- v += "%" + properties;
+ v += "%" + properties; //$NON-NLS-1$
}
return v;
}
Added: trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/messages.properties (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.resref.core/src/org/jboss/tools/common/resref/core/messages.properties 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1,4 @@
+ResourceReference_Folder=Folder
+ResourceReference_Global=Global
+ResourceReference_Page=Page
+ResourceReference_Project=Project
Modified: trunk/common/plugins/org.jboss.tools.common.resref.ui/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.ui/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.ui/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -4,4 +4,5 @@
org.eclipse.jdt.core.compiler.compliance=1.5
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
org.eclipse.jdt.core.compiler.source=1.5
Modified: trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Activator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Activator.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Activator.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -9,7 +9,7 @@
public class Activator extends AbstractUIPlugin {
// The plug-in ID
- public static final String PLUGIN_ID = "org.jboss.tools.common.resref.ui";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.resref.ui"; //$NON-NLS-1$
// The shared instance
private static Activator plugin;
Modified: trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/BaseAddReferenceSupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/BaseAddReferenceSupport.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/BaseAddReferenceSupport.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -69,7 +69,7 @@
if(initialPrefix != null) {
setAttributeValue(0, "prefix", initialPrefix); //$NON-NLS-1$
}
- if(getTarget().getModelEntity().getAttribute("scope") != null) {
+ if(getTarget().getModelEntity().getAttribute("scope") != null) { //$NON-NLS-1$
final XAttributeConstraintL scopeAttribute = ((XAttributeConstraintL) getTarget().getModelEntity().getAttribute("scope") //$NON-NLS-1$
.getConstraint());
if (scopeAttribute != null) {
Modified: trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Messages.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/Messages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -7,6 +7,13 @@
public static String AbstractResourceReferencesComposite_Add;
public static String AbstractResourceReferencesComposite_Edit;
public static String AbstractResourceReferencesComposite_Remove;
+ public static String ResourceReferencesTableProvider_CSSFilePath;
+ public static String ResourceReferencesTableProvider_ELExpression;
+ public static String ResourceReferencesTableProvider_ImageFolderPath;
+ public static String ResourceReferencesTableProvider_Prefix;
+ public static String ResourceReferencesTableProvider_Scope;
+ public static String ResourceReferencesTableProvider_URI;
+ public static String ResourceReferencesTableProvider_Value;
static {
// initialize resource bundle
NLS.initializeMessages(BUNDLE_NAME, Messages.class);
Modified: trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/ResourceReferencesTableProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/ResourceReferencesTableProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/ResourceReferencesTableProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,11 +19,11 @@
import org.jboss.tools.common.resref.core.ResourceReference;
public class ResourceReferencesTableProvider implements XTableProvider, XTableImageProvider {
- static String[] CSS_COLUMNS = new String[]{"Scope", "CSS File Path"};
- static String[] IMG_COLUMNS = new String[]{"Scope", "Image Folder Path"};
- static String[] TLD_COLUMNS = new String[]{"Scope", "URI", "Prefix"};
- static String[] EL_COLUMNS = new String[]{"Scope", "El Expression", "Value"};
- private final static String[] GLOBAL_EL_COLUMNS = new String[]{"Scope","El Expression", "Value"};
+ static String[] CSS_COLUMNS = new String[]{Messages.ResourceReferencesTableProvider_Scope, Messages.ResourceReferencesTableProvider_CSSFilePath};
+ static String[] IMG_COLUMNS = new String[]{Messages.ResourceReferencesTableProvider_Scope, Messages.ResourceReferencesTableProvider_ImageFolderPath};
+ static String[] TLD_COLUMNS = new String[]{Messages.ResourceReferencesTableProvider_Scope, Messages.ResourceReferencesTableProvider_URI, Messages.ResourceReferencesTableProvider_Prefix};
+ static String[] EL_COLUMNS = new String[]{Messages.ResourceReferencesTableProvider_Scope, Messages.ResourceReferencesTableProvider_ELExpression, Messages.ResourceReferencesTableProvider_Value};
+ private final static String[] GLOBAL_EL_COLUMNS = new String[]{Messages.ResourceReferencesTableProvider_Scope,Messages.ResourceReferencesTableProvider_ELExpression, Messages.ResourceReferencesTableProvider_Value};
int[] widths = new int[]{50, 200};
List dataList;
Modified: trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/messages.properties 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.resref.ui/src/org/jboss/tools/common/resref/ui/messages.properties 2009-06-26 07:56:07 UTC (rev 16218)
@@ -1,3 +1,10 @@
AbstractResourceReferencesComposite_Add=Add
AbstractResourceReferencesComposite_Edit=Edit
AbstractResourceReferencesComposite_Remove=Remove
+ResourceReferencesTableProvider_CSSFilePath=CSS File Path
+ResourceReferencesTableProvider_ELExpression=El Expression
+ResourceReferencesTableProvider_ImageFolderPath=Image Folder Path
+ResourceReferencesTableProvider_Prefix=Prefix
+ResourceReferencesTableProvider_Scope=Scope
+ResourceReferencesTableProvider_URI=URI
+ResourceReferencesTableProvider_Value=Value
Added: trunk/common/plugins/org.jboss.tools.common.text.ext/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/ExtensionsPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/ExtensionsPlugin.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/ExtensionsPlugin.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -29,7 +29,7 @@
//The shared instance.
private static ExtensionsPlugin plugin;
- public static final String PLUGIN_ID = "org.jboss.tools.common.text.ext";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.text.ext"; //$NON-NLS-1$
/**
* The constructor.
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -95,7 +95,7 @@
String wsRelativePath = structuredModel.getBaseLocation();
if (wsRelativePath == null)
return null;
- if (wsRelativePath.startsWith("/")) {
+ if (wsRelativePath.startsWith("/")) { //$NON-NLS-1$
while (true) {
int i = wsRelativePath.lastIndexOf('/');
if (i < 0)
@@ -130,7 +130,7 @@
if (wsRelativePath == null) {
return null;
}
- if (wsRelativePath.startsWith("/")) {
+ if (wsRelativePath.startsWith("/")) { //$NON-NLS-1$
IPath path = new Path(wsRelativePath);
IResource r = ModelPlugin.getWorkspace().getRoot().findMember(
path);
@@ -161,7 +161,7 @@
}
WorkbenchComponent[] modules = se.getWorkbenchModules();
for (int i = 0; i < modules.length; i++) {
- if (name.startsWith("/")) {
+ if (name.startsWith("/")) { //$NON-NLS-1$
member = findFileByAbsolutePath(project, modules[i], name);
} else {
member = findFileByRelativePath(project, modules[i],
@@ -170,7 +170,7 @@
// in some cases path having no leading "/" is
// nevertheless absolute
member = findFileByAbsolutePath(project, modules[i],
- "/" + name);
+ "/" + name); //$NON-NLS-1$
}
}
if (member != null && (member instanceof IFile)) {
@@ -188,7 +188,7 @@
return null;
ComponentResource[] resources = module.findResourcesBySourcePath(
- new Path("/"), 0);
+ new Path("/"), 0); //$NON-NLS-1$
IPath projectPath = project.getLocation();
IFile member = null;
@@ -223,7 +223,7 @@
private IFile findFileByAbsolutePath(IProject project,
WorkbenchComponent module, String path) {
ComponentResource[] resources = module.findResourcesBySourcePath(
- new Path("/"), 0);
+ new Path("/"), 0); //$NON-NLS-1$
IFile member = null;
@@ -249,7 +249,7 @@
}
protected IEditorInput createEditorInput(String fileString) {
- String jarName = fileString.substring(0,fileString.indexOf("!"));
+ String jarName = fileString.substring(0,fileString.indexOf("!")); //$NON-NLS-1$
IFile[] fs = ResourcesPlugin.getWorkspace().getRoot().findFilesForLocation(new Path(jarName));
if(fs == null || fs.length == 0) return null;
@@ -262,7 +262,7 @@
IPackageFragmentRoot root = jp.getPackageFragmentRoot(fs[0]);
- String entryName = fileString.substring(fileString.indexOf("!")+2,fileString.length());
+ String entryName = fileString.substring(fileString.indexOf("!")+2,fileString.length()); //$NON-NLS-1$
JarEntryFile f = new JarEntryFile(entryName);
f.setParent(root);
JarEntryEditorInput jarEditorInput = new JarEntryEditorInput(f) {
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/AbstractHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -121,7 +121,7 @@
Node node = Utils.findNodeForOffset(xmlDocument, superRegion.getOffset());
if (node instanceof Attr) {
Attr attr = (Attr)node;
- return Utils.getParentAxisForNode(xmlDocument, attr) + attr.getName() + "/";
+ return Utils.getParentAxisForNode(xmlDocument, attr) + attr.getName() + "/"; //$NON-NLS-1$
}
return Utils.getParentAxisForNode(xmlDocument, node);
} finally {
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/CSSClassHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/CSSClassHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/CSSClassHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -60,8 +60,8 @@
public class CSSClassHyperlink extends AbstractHyperlink {
// Qualifiers for CSSList
- public static final String QUALIFIER = "CSSListForm";
- public static final String LOCAL_NAME = "CSSList";
+ public static final String QUALIFIER = "CSSListForm"; //$NON-NLS-1$
+ public static final String LOCAL_NAME = "CSSList"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.AbstractHyperlink#doHyperlink(org.eclipse.jface.text.IRegion)
@@ -152,7 +152,7 @@
if (doSearchInProjectCSSList) {
String cssList = project.getPersistentProperty(new QualifiedName(QUALIFIER, LOCAL_NAME));
if (cssList != null) {
- StringTokenizer st = new StringTokenizer(cssList, ",");
+ StringTokenizer st = new StringTokenizer(cssList, ","); //$NON-NLS-1$
while (st.hasMoreTokens()) {
String fileName = st.nextToken().trim();
IPath path = new Path(fileName).removeFirstSegments(2);
@@ -200,7 +200,7 @@
TextScanner.TextToken tToken = (TextScanner.TextToken)token;
if (CSSTextScanner.CSS_CLASS_NAME.equals(tToken.getType())) {
String name = tToken.getText();
- if (("." + styleName).equalsIgnoreCase(name)) {
+ if (("." + styleName).equalsIgnoreCase(name)) { //$NON-NLS-1$
final int offset = startOffset + scanner.getTokenOffset();
final int length = scanner.getTokenLength();
return new Region (offset,length);
@@ -232,7 +232,7 @@
TextScanner.TextToken tToken = (TextScanner.TextToken)token;
if (CSSTextScanner.CSS_CLASS_NAME.equals(tToken.getType())) {
String name = tToken.getText();
- if (("." + styleName).equalsIgnoreCase(name)) {
+ if (("." + styleName).equalsIgnoreCase(name)) { //$NON-NLS-1$
final int offset = scanner.getTokenOffset();
final int length = scanner.getTokenLength();
return new Region (offset,length);
@@ -246,7 +246,7 @@
token = scanner.nextToken();
}
} catch (CoreException x) {
- ExtensionsPlugin.getPluginLog().logError("Error while looking for style region ", x);
+ ExtensionsPlugin.getPluginLog().logError("Error while looking for style region ", x); //$NON-NLS-1$
} finally {
try {
if(stream!=null) {
@@ -267,12 +267,12 @@
//String axis = JSPRootHyperlinkPartitioner.computeAxis(getDocument(), element.getStartOffset());
//axis = axis.toLowerCase();
- if ("link".equals(element.getNodeName())) {
- Node relAttr = element.getAttributes().getNamedItem("rel");
+ if ("link".equals(element.getNodeName())) { //$NON-NLS-1$
+ Node relAttr = element.getAttributes().getNamedItem("rel"); //$NON-NLS-1$
if (relAttr != null) {
String val = relAttr.getNodeValue().toLowerCase();
- if ("stylesheet".equalsIgnoreCase(val) || "\"stylesheet\"".equalsIgnoreCase(val)) {
- Node hrefAttr = element.getAttributes().getNamedItem("href");
+ if ("stylesheet".equalsIgnoreCase(val) || "\"stylesheet\"".equalsIgnoreCase(val)) { //$NON-NLS-1$ //$NON-NLS-2$
+ Node hrefAttr = element.getAttributes().getNamedItem("href"); //$NON-NLS-1$
if (hrefAttr != null) {
styleLinks.add(hrefAttr);
}
@@ -280,7 +280,7 @@
}
}
- if ("link".equals(element.getNodeName())) {
+ if ("link".equals(element.getNodeName())) { //$NON-NLS-1$
// String value = element.getNodeValue();
styleLinks.add(element);
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -160,7 +160,7 @@
return searchForClass(javaProject, className);
} catch (CoreException x) {
- ExtensionsPlugin.getPluginLog().logError("Error while looking for class " + className, x);
+ ExtensionsPlugin.getPluginLog().logError("Error while looking for class " + className, x); //$NON-NLS-1$
return null;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassMethodHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassMethodHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ClassMethodHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -141,7 +141,7 @@
protected IJavaElement searchForClassMethod(IJavaProject javaProject, String className, String methodName) {
try {
// Get the search pattern
- SearchPattern pattern = SearchPattern.createPattern(className + "." + methodName, IJavaSearchConstants.METHOD, IJavaSearchConstants.DECLARATIONS, SearchPattern.R_EXACT_MATCH | SearchPattern.R_CASE_SENSITIVE);
+ SearchPattern pattern = SearchPattern.createPattern(className + "." + methodName, IJavaSearchConstants.METHOD, IJavaSearchConstants.DECLARATIONS, SearchPattern.R_EXACT_MATCH | SearchPattern.R_CASE_SENSITIVE); //$NON-NLS-1$
// Get the search scope
IJavaSearchScope scope = SearchEngine.createJavaSearchScope(new IJavaElement[] { javaProject });
@@ -197,7 +197,7 @@
return searchForClassMethod(javaProject, className, methodName);
} catch (CoreException x) {
- ExtensionsPlugin.getPluginLog().logError("Error while looking for method " + methodName + " of class " + className, x);
+ ExtensionsPlugin.getPluginLog().logError("Error while looking for method " + methodName + " of class " + className, x); //$NON-NLS-1$ //$NON-NLS-2$
return null;
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/FilterNameHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/FilterNameHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/FilterNameHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,7 +19,7 @@
*/
public class FilterNameHyperlink extends JumpToHyperlink {
protected String getDestinationAxis() {
- return "/web-app/filter/filter-name/";
+ return "/web-app/filter/filter-name/"; //$NON-NLS-1$
}
/*
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkDetector.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkDetector.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkDetector.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
ArrayList<String> types = new ArrayList<String>();
region = (document instanceof IDocumentExtension3 ?
- ((IDocumentExtension3)document).getDocumentPartitioner("org.eclipse.wst.sse.core.default_structured_text_partitioning").getPartition(offset) :
+ ((IDocumentExtension3)document).getDocumentPartitioner("org.eclipse.wst.sse.core.default_structured_text_partitioning").getPartition(offset) : //$NON-NLS-1$
document.getDocumentPartitioner().getPartition(offset));
if (region != null) {
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerBuilder.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerBuilder.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerBuilder.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,19 +25,19 @@
*/
public class HyperlinkPartitionerBuilder extends RegistryReader {
- public static final String PL_HYPERLINK_PARTITIONER = "hyperlinkPartitioner";
+ public static final String PL_HYPERLINK_PARTITIONER = "hyperlinkPartitioner"; //$NON-NLS-1$
public static final String PLUGIN_ID = ExtensionsPlugin.PLUGIN_ID;
- public static final String TAG_HYPERLINK_PARTITIONER = "hyperlinkPartitioner";
- public static final String TAG_CONTENT_TYPE = "contentType";
- public static final String TAG_PARTITION_TYPE = "partitionType";
- public static final String TAG_AXIS = "axis";
+ public static final String TAG_HYPERLINK_PARTITIONER = "hyperlinkPartitioner"; //$NON-NLS-1$
+ public static final String TAG_CONTENT_TYPE = "contentType"; //$NON-NLS-1$
+ public static final String TAG_PARTITION_TYPE = "partitionType"; //$NON-NLS-1$
+ public static final String TAG_AXIS = "axis"; //$NON-NLS-1$
- public static final String ATT_ID = "id";
- public static final String ATT_CLASS = "class";
- public static final String ATT_PATH = "path";
- public static final String ATT_IGNORE_CASE = "ignoreCase";
+ public static final String ATT_ID = "id"; //$NON-NLS-1$
+ public static final String ATT_CLASS = "class"; //$NON-NLS-1$
+ public static final String ATT_PATH = "path"; //$NON-NLS-1$
+ public static final String ATT_IGNORE_CASE = "ignoreCase"; //$NON-NLS-1$
private static HyperlinkPartitionerBuilder fInstance;
private ArrayList fPartitionerDefs;
@@ -207,7 +207,7 @@
protected boolean isIgnoreCase(IConfigurationElement element) {
String value = element.getAttribute(ATT_IGNORE_CASE);
- if("true".equals(value)) {
+ if("true".equals(value)) { //$NON-NLS-1$
return true;
}
return false;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerDefinition.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerDefinition.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkPartitionerDefinition.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -146,7 +146,7 @@
* @param e
*/
private void handleCreateExecutableException(Object[] result, Exception x) {
- ExtensionsPlugin.getPluginLog().logError("Error in creating extension", x);
+ ExtensionsPlugin.getPluginLog().logError("Error in creating extension", x); //$NON-NLS-1$
result[0] = null;
}
@@ -337,7 +337,7 @@
this.fPath = getCorrectPath(path);
if(fPath.indexOf(ALL_TAGS)>-1) {
- StringTokenizer st = new StringTokenizer(fPath, "*" , false);
+ StringTokenizer st = new StringTokenizer(fPath, "*" , false); //$NON-NLS-1$
fStartDelim = fPath.startsWith(ALL_TAGS);
fEndDelim = fPath.endsWith(ALL_TAGS);
ArrayList<String> list = new ArrayList<String>();
@@ -354,8 +354,8 @@
}
}
- private static String ALL_TAGS = "/*/";
- private static String DELIM = "/";
+ private static String ALL_TAGS = "/*/"; //$NON-NLS-1$
+ private static String DELIM = "/"; //$NON-NLS-1$
public boolean containtsPath(String path) {
path = getCorrectPath(path);
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkRegion.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkRegion.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/HyperlinkRegion.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -48,7 +48,7 @@
}
public String toString() {
- return "IHyperlinkRegion [" + getOffset() +", " + getLength()+ "]:[[" + getContentType() + "]/[" + getType() + "]" + getAxis();
+ return "IHyperlinkRegion [" + getOffset() +", " + getLength()+ "]:[[" + getContentType() + "]/[" + getType() + "]" + getAxis(); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JSPStylesheetRelLinkHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JSPStylesheetRelLinkHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JSPStylesheetRelLinkHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
*/
public class JSPStylesheetRelLinkHyperlink extends RelativeLinkHyperlink {
- private static final String HREF_ATTRNAME = "href";
+ private static final String HREF_ATTRNAME = "href"; //$NON-NLS-1$
protected IRegion getRegion (int offset) {
StructuredModelWrapper smw = new StructuredModelWrapper();
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JumpToHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JumpToHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/JumpToHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -128,7 +128,7 @@
if (!(list.item(i) instanceof IDOMElement))
continue;
IDOMElement element = (IDOMElement)list.item(i);
- String currentAxis = XMLRootHyperlinkPartitioner.computeAxis(getDocument(), element.getStartOffset()) + "/";
+ String currentAxis = XMLRootHyperlinkPartitioner.computeAxis(getDocument(), element.getStartOffset()) + "/"; //$NON-NLS-1$
currentAxis = currentAxis.toLowerCase();
if (currentAxis.endsWith(requiredAxis)) {
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/RoleNameHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/RoleNameHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/RoleNameHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
*/
public class RoleNameHyperlink extends JumpToHyperlink {
protected String getDestinationAxis() {
- return "/web-app/security-role/role-name/";
+ return "/web-app/security-role/role-name/"; //$NON-NLS-1$
}
/*
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ServletNameHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ServletNameHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/ServletNameHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
*/
public class ServletNameHyperlink extends JumpToHyperlink {
protected String getDestinationAxis() {
- return "/web-app/servlet/servlet-name/";
+ return "/web-app/servlet/servlet-name/"; //$NON-NLS-1$
}
/*
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/TLDAttributeNameHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/TLDAttributeNameHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/TLDAttributeNameHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -29,7 +29,7 @@
*/
public class TLDAttributeNameHyperlink extends JumpToHyperlink {
protected String getDestinationAxis() {
- return "/taglib/tag/attribute/name/";
+ return "/taglib/tag/attribute/name/"; //$NON-NLS-1$
}
protected NodeList getRootElementsToSearch (IRegion region) {
@@ -44,7 +44,7 @@
Element tagElement = null;
while(n != null && tagElement == null) {
n = n.getParentNode();
- if (n instanceof Element && validAxis(n, "/taglib/tag/")) {
+ if (n instanceof Element && validAxis(n, "/taglib/tag/")) { //$NON-NLS-1$
tagElement = (Element)n;
}
}
@@ -59,7 +59,7 @@
private boolean validAxis(Node n, String validAxisEnding) {
if (validAxisEnding == null || validAxisEnding.lastIndexOf('/') == -1) return false;
- StringTokenizer st = new StringTokenizer(validAxisEnding, "/");
+ StringTokenizer st = new StringTokenizer(validAxisEnding, "/"); //$NON-NLS-1$
List<String> tokens = new ArrayList<String>();
while (st.hasMoreTokens()) {
tokens.add(st.nextToken());
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/XModelBasedHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/XModelBasedHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/XModelBasedHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -48,7 +48,7 @@
Properties p = getRequestProperties(region);
p.put(IPromptingProvider.FILE, documentFile);
- List list = provider.getList(xModel, getRequestMethod(), p.getProperty("prefix"), p);
+ List list = provider.getList(xModel, getRequestMethod(), p.getProperty("prefix"), p); //$NON-NLS-1$
if (list != null && list.size() >= 1) {
openFileInEditor((String)list.get(0));
return;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -33,13 +33,13 @@
*
*/
public class JSPBeanGetPropertyHyperlink extends ClassMethodHyperlink {
- private static final String USEBEAN_TAGNAME = "jsp:useBean";
- private static final String ID_ATTRNAME = "id";
- private static final String NAME_ATTRNAME = "name";
- private static final String CLASS_ATTRNAME = "class";
- private static final String TYPE_ATTRNAME = "type";
- protected static final String GET_METHOD_PREFIX = "get";
- protected static final String SET_METHOD_PREFIX = "set";
+ private static final String USEBEAN_TAGNAME = "jsp:useBean"; //$NON-NLS-1$
+ private static final String ID_ATTRNAME = "id"; //$NON-NLS-1$
+ private static final String NAME_ATTRNAME = "name"; //$NON-NLS-1$
+ private static final String CLASS_ATTRNAME = "class"; //$NON-NLS-1$
+ private static final String TYPE_ATTRNAME = "type"; //$NON-NLS-1$
+ protected static final String GET_METHOD_PREFIX = "get"; //$NON-NLS-1$
+ protected static final String SET_METHOD_PREFIX = "set"; //$NON-NLS-1$
protected String getMethodPrefix() {
return GET_METHOD_PREFIX;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanGetPropertyHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
* @author Jeremy
*/
public class JSPBeanGetPropertyHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_BEAN_GET_PROPERTY_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_BEAN_GET_PROPERTY";
+ public static final String JSP_BEAN_GET_PROPERTY_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_BEAN_GET_PROPERTY"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -60,7 +60,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanSetPropertyHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanSetPropertyHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPBeanSetPropertyHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,7 +26,7 @@
* @author Jeremy
*/
public class JSPBeanSetPropertyHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_BEAN_SET_PROPERTY_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_BEAN_SET_PROPERTY";
+ public static final String JSP_BEAN_SET_PROPERTY_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_BEAN_SET_PROPERTY"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -58,7 +58,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPCSSClassHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPCSSClassHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPCSSClassHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,7 +26,7 @@
* @author Jeremy
*/
public class JSPCSSClassHyperlinkPartitioner extends AbstractHyperlinkPartitioner /*implements IHyperlinkPartitionRecognizer */{
- public static final String JSP_CSS_CLASS_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_CSS_CLASS";
+ public static final String JSP_CSS_CLASS_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_CSS_CLASS"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -58,7 +58,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPClassHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPClassHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPClassHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
public class JSPClassHyperlinkPartitioner extends XMLClassHyperlinkPartitioner {
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementAttributeValueHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementAttributeValueHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementAttributeValueHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
public class JSPElementAttributeValueHyperlinkPartitioner extends XMLElementAttributeValueHyperlinkPartitioner {
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
public class JSPElementHyperlinkPartitioner extends XMLElementHyperlinkPartitioner {
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -108,8 +108,8 @@
// Ignore
return null;
}
- if (nodeName.indexOf(":") != -1) {
- String nodePrefix = nodeName.substring(0, nodeName.indexOf(":"));
+ if (nodeName.indexOf(":") != -1) { //$NON-NLS-1$
+ String nodePrefix = nodeName.substring(0, nodeName.indexOf(":")); //$NON-NLS-1$
if (nodePrefix != null && nodePrefix.length() > 0)
return nodePrefix;
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPElementNameHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
public class JSPElementNameHyperlinkPartitioner extends XMLElementNameHyperlinkPartitioner {
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
@@ -51,8 +51,8 @@
if (r == null) return false;
String nodeName = elem.getNodeName();
- if (nodeName.indexOf(":") == -1) return false;
- String nodePrefix = nodeName.substring(0, nodeName.indexOf(":"));
+ if (nodeName.indexOf(":") == -1) return false; //$NON-NLS-1$
+ String nodePrefix = nodeName.substring(0, nodeName.indexOf(":")); //$NON-NLS-1$
if (nodePrefix == null || nodePrefix.length() == 0) return false;
Map trackers = JSPRootHyperlinkPartitioner.getTrackersMap(document, region.getOffset());
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,8 +32,8 @@
* @author Jeremy
*/
public class JSPForBeanIdHyperlink extends AbstractHyperlink {
- private static final String USEBEAN_TAGNAME = "jsp:useBean";
- private static final String ID_ATTRNAME = "id";
+ private static final String USEBEAN_TAGNAME = "jsp:useBean"; //$NON-NLS-1$
+ private static final String ID_ATTRNAME = "id"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.AbstractHyperlink#doHyperlink(org.eclipse.jface.text.IRegion)
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPForBeanIdHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,7 +26,7 @@
* @author Jeremy
*/
public class JSPForBeanIdHyperlinkPartitioner extends AbstractHyperlinkPartitioner /*implements IHyperlinkPartitionRecognizer */{
- public static final String JSP_FOR_BEAN_ID_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_FOR_BEAN_ID";
+ public static final String JSP_FOR_BEAN_ID_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_FOR_BEAN_ID"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -58,7 +58,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPLinkHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPLinkHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPLinkHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,7 +19,7 @@
* @author Jeremy
*/
public class JSPLinkHyperlinkPartitioner extends XMLLinkHyperlinkPartitioner {
- public static final String JSP_LINK_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_LINK";
+ public static final String JSP_LINK_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_LINK"; //$NON-NLS-1$
/* (non-Javadoc)
* @see org.jboss.tools.common.text.ext.hyperlink.XMLLinkHyperlinkPartitioner#getPartitionType()
@@ -37,7 +37,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRelativeLinkHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRelativeLinkHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRelativeLinkHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,7 +19,7 @@
* @author Jeremy
*/
public class JSPRelativeLinkHyperlinkPartitioner extends XMLLinkHyperlinkPartitioner {
- public static final String JSP_RELATIVE_LINK_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_RELATIVE_LINK";
+ public static final String JSP_RELATIVE_LINK_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_RELATIVE_LINK"; //$NON-NLS-1$
/* (non-Javadoc)
* @see org.jboss.tools.common.text.ext.hyperlink.XMLLinkHyperlinkPartitioner#getPartitionType()
@@ -37,7 +37,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRootHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRootHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPRootHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -39,7 +39,7 @@
* @author Jeremy
*/
public class JSPRootHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_ROOT_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_ROOT";
+ public static final String JSP_ROOT_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_ROOT"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -47,7 +47,7 @@
protected IHyperlinkRegion parse(IDocument document, IHyperlinkRegion superRegion) {
if (!recognize(document, superRegion)) return null;
- String axis = computeAxis(document, superRegion.getOffset()) + "/";
+ String axis = computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
String contentType = superRegion.getContentType();
String type = JSP_ROOT_PARTITION;
int length = superRegion.getLength();
@@ -58,7 +58,7 @@
}
public static String computeAxis(IDocument document, int offset) {
- String axis = "";
+ String axis = ""; //$NON-NLS-1$
StructuredModelWrapper smw = new StructuredModelWrapper();
smw.init(document);
try {
@@ -81,14 +81,14 @@
// The node name extraction must be done by taking into account 'jsfc' attribute value
if (n instanceof Element) {
Element e = (Element)n;
- String jsfcAttrValue = e.getAttribute("jsfc");
+ String jsfcAttrValue = e.getAttribute("jsfc"); //$NON-NLS-1$
if (jsfcAttrValue != null && jsfcAttrValue.trim().length() > 0) {
name = jsfcAttrValue;
}
}
String nodeName = extractName(name, trackersMap, tm);
- axis = "/" + nodeName;
+ axis = "/" + nodeName; //$NON-NLS-1$
}
Node parent = (n instanceof Attr)? ((Attr)n).getOwnerElement() : n.getParentNode();
while (parent instanceof Element) {
@@ -98,7 +98,7 @@
// The node name extraction must be done by taking into account 'jsfc' attribute value
if (parent instanceof Element) {
Element e = (Element)parent;
- String jsfcAttrValue = e.getAttribute("jsfc");
+ String jsfcAttrValue = e.getAttribute("jsfc"); //$NON-NLS-1$
if (jsfcAttrValue != null && jsfcAttrValue.trim().length() > 0) {
name = jsfcAttrValue;
}
@@ -106,7 +106,7 @@
String nodeName = extractName(name, trackersMap, tm);
if (nodeName != null && nodeName.length() > 0)
- axis = "/" + nodeName + axis;
+ axis = "/" + nodeName + axis; //$NON-NLS-1$
parent = parent.getParentNode();
}
}
@@ -114,14 +114,14 @@
smw.dispose();
}
- if (axis == null || axis.length() == 0) axis = "";
+ if (axis == null || axis.length() == 0) axis = ""; //$NON-NLS-1$
return axis;
}
public static String extractName (String name, Map trackersMap, ITaglibMapping tm) {
if (trackersMap == null || trackersMap.size() == 0) return name;
if (name == null) return null;
- int column = name.indexOf(":");
+ int column = name.indexOf(":"); //$NON-NLS-1$
if (column == -1) return name;
String prefix = name.substring(0, column);
if (prefix == null || prefix.trim().length() == 0) return name;
@@ -131,7 +131,7 @@
String resolvedUri = (tm == null ? uri : tm.resolveURI(uri));
- return "[" + resolvedUri + "]" + name.substring(column);
+ return "[" + resolvedUri + "]" + name.substring(column); //$NON-NLS-1$ //$NON-NLS-2$
}
public static Map getTrackersMap(IDocument document, int offset) {
@@ -190,9 +190,9 @@
for (int j = 0; attrs != null && j < attrs.getLength(); j++) {
Attr a = (Attr)attrs.item(j);
String name = a.getName();
- if (name.startsWith("xmlns:")) {
+ if (name.startsWith("xmlns:")) { //$NON-NLS-1$
String uri = a.getValue();
- String prefix = name.substring("xmlns:".length());
+ String prefix = name.substring("xmlns:".length()); //$NON-NLS-1$
map.put(prefix.trim(), uri.trim());
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPStylesheetRelLinkHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPStylesheetRelLinkHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPStylesheetRelLinkHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -31,17 +31,17 @@
* @author Jeremy
*/
public class JSPStylesheetRelLinkHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_STYLESHEET_REL_LINK_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_STYLESHEET_REL_LINK";
+ public static final String JSP_STYLESHEET_REL_LINK_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_STYLESHEET_REL_LINK"; //$NON-NLS-1$
- private static final String LINK_TAGNAME = "link";
- private static final String REL_ATTRNAME = "rel";
- private static final String VALID_REL_ATTRVALUE = "stylesheet";
- private static final String HREF_ATTRNAME = "href";
+ private static final String LINK_TAGNAME = "link"; //$NON-NLS-1$
+ private static final String REL_ATTRNAME = "rel"; //$NON-NLS-1$
+ private static final String VALID_REL_ATTRVALUE = "stylesheet"; //$NON-NLS-1$
+ private static final String HREF_ATTRNAME = "href"; //$NON-NLS-1$
- private static final String IMPORT_DIRECTIVENAME = "@import";
- private static final String URL_METHODSTART = "url(";
- private static final String URL_METHODEND = ")";
- private static final String URL_METHODEND_2 = ";";
+ private static final String IMPORT_DIRECTIVENAME = "@import"; //$NON-NLS-1$
+ private static final String URL_METHODSTART = "url("; //$NON-NLS-1$
+ private static final String URL_METHODEND = ")"; //$NON-NLS-1$
+ private static final String URL_METHODEND_2 = ";"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -151,7 +151,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,10 +26,10 @@
* @author Jeremy
*/
public class JSPTagAttributeHyperlinkPartitioner extends JSPElementAttributeValueHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_TAG_ATTRIBUTE_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_TAG_ATTRIBUTE";
+ public static final String JSP_TAG_ATTRIBUTE_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_TAG_ATTRIBUTE"; //$NON-NLS-1$
- private static final String JSP_ATTRIBUTE_TAGNAME = "jsp:attribute";
- private static final String JSP_ELEMENT_TAGNAME = "jsp:element";
+ private static final String JSP_ATTRIBUTE_TAGNAME = "jsp:attribute"; //$NON-NLS-1$
+ private static final String JSP_ELEMENT_TAGNAME = "jsp:element"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -86,7 +86,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeValueHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeValueHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTagAttributeValueHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,7 +22,7 @@
public abstract class JSPTagAttributeValueHyperlinkPartitioner extends XMLTagAttributeValueHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -97,11 +97,11 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
if (n instanceof IDOMAttr) n = ((IDOMAttr)n).getOwnerElement();
if (!(n instanceof IDOMElement)) return null;
- if(!"jsp:directive.taglib".equals(n.getNodeName())) return null;
+ if(!"jsp:directive.taglib".equals(n.getNodeName())) return null; //$NON-NLS-1$
IDOMElement taglib = (IDOMElement)n;
- String uri = taglib.getAttribute("uri");
+ String uri = taglib.getAttribute("uri"); //$NON-NLS-1$
if (uri == null || uri.trim().length() == 0) return null;
return uri;
@@ -131,7 +131,7 @@
Node n = Utils.findNodeForOffset(xmlDocument, offset);
if (n instanceof Attr) n = ((Attr)n).getOwnerElement();
if (!(n instanceof IDOMElement)) return null;
- if (!"jsp:directive.taglib".equals(n.getNodeName())) return null;
+ if (!"jsp:directive.taglib".equals(n.getNodeName())) return null; //$NON-NLS-1$
IDOMElement taglib = (IDOMElement)n;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTaglibHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -26,7 +26,7 @@
* @author Jeremy
*/
public class JSPTaglibHyperlinkPartitioner extends JSPElementAttributeValueHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_TAGLIB_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_TAGLIB";
+ public static final String JSP_TAGLIB_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_TAGLIB"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -42,7 +42,7 @@
Node n = Utils.findNodeForOffset(xmlDocument, superRegion.getOffset());
if (n instanceof Attr) n = ((Attr)n).getOwnerElement();
if (!(n instanceof Element)) return null;
- if (!"jsp:directive.taglib".equals(n.getNodeName())) return null;
+ if (!"jsp:directive.taglib".equals(n.getNodeName())) return null; //$NON-NLS-1$
int start = Utils.getValueStart(n);
int end = Utils.getValueEnd(n);
@@ -76,7 +76,7 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
if (n instanceof Attr) n = ((Attr)n).getOwnerElement();
if (!(n instanceof Element)) return false;
- return ("jsp:directive.taglib".equals(n.getNodeName()));
+ return ("jsp:directive.taglib".equals(n.getNodeName())); //$NON-NLS-1$
} finally {
smw.dispose();
}
@@ -84,7 +84,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTextHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTextHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPTextHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,7 +21,7 @@
public class JSPTextHyperlinkPartitioner extends XMLTextHyperlinkPartitioner {
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -79,9 +79,9 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
if (!(n instanceof IDOMAttr)) return null;
Attr xmlnsAttr = (Attr)n;
- if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null;
+ if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null; //$NON-NLS-1$
Element rootElem = (Element)xmlnsAttr.getOwnerElement();
- if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null;
+ if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null; //$NON-NLS-1$ //$NON-NLS-2$
String uri = xmlnsAttr.getValue();
if (uri == null || uri.trim().length() == 0) return null;
@@ -111,9 +111,9 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
if (!(n instanceof IDOMAttr)) return null;
Attr xmlnsAttr = (Attr)n;
- if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null;
+ if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null; //$NON-NLS-1$
Element rootElem = (Element)xmlnsAttr.getOwnerElement();
- if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null;
+ if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null; //$NON-NLS-1$ //$NON-NLS-2$
String uri = xmlnsAttr.getValue();
if (uri == null || uri.trim().length() == 0) return null;
@@ -145,9 +145,9 @@
Node n = Utils.findNodeForOffset(xmlDocument, offset);
if (!(n instanceof IDOMAttr)) return null;
IDOMAttr xmlnsAttr = (IDOMAttr)n;
- if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null;
+ if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null; //$NON-NLS-1$
Element rootElem = xmlnsAttr.getOwnerElement();
- if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null;
+ if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null; //$NON-NLS-1$ //$NON-NLS-2$
final int taglibLength = xmlnsAttr.getValueRegionText().length();
final int taglibOffset = xmlnsAttr.getValueRegionStartOffset();
@@ -167,7 +167,7 @@
public String getHyperlinkText() {
String uri = getUri(fLastRegion);
if (uri == null)
- return MessageFormat.format(Messages.NotFound, "URI");
+ return MessageFormat.format(Messages.NotFound, "URI"); //$NON-NLS-1$
return MessageFormat.format(Messages.Open, uri);
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/jsp/JSPXmlNsHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
* @author Jeremy
*/
public class JSPXmlNsHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String JSP_XMLNS_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_XMLNS";
+ public static final String JSP_XMLNS_PARTITION = "org.jboss.tools.common.text.ext.jsp.JSP_XMLNS"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -42,9 +42,9 @@
Node n = Utils.findNodeForOffset(xmlDocument, superRegion.getOffset());
if (!(n instanceof IDOMAttr)) return null;
IDOMAttr xmlnsAttr = (IDOMAttr)n;
- if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null;
+ if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return null; //$NON-NLS-1$
Element rootElem = xmlnsAttr.getOwnerElement();
- if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null;
+ if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return null; //$NON-NLS-1$ //$NON-NLS-2$
String xmlns = xmlnsAttr.getValueRegionText();
String axis = getAxis(document, superRegion);
String contentType = superRegion.getContentType();
@@ -73,9 +73,9 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
if (!(n instanceof Attr)) return false;
Attr xmlnsAttr = (Attr)n;
- if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return false;
+ if (xmlnsAttr.getName() == null || !xmlnsAttr.getName().startsWith("xmlns:")) return false; //$NON-NLS-1$
Element rootElem = xmlnsAttr.getOwnerElement();
- if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return false;
+ if (!(rootElem.getNodeName().equals("jsp:root") || rootElem.getNodeName().equalsIgnoreCase("html"))) return false; //$NON-NLS-1$ //$NON-NLS-2$
return true;
} finally {
smw.dispose();
@@ -85,7 +85,7 @@
protected String getAxis(IDocument document, IHyperlinkRegion superRegion) {
if (superRegion.getAxis() == null || superRegion.getAxis().length() == 0) {
- return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/";
+ return JSPRootHyperlinkPartitioner.computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
}
return superRegion.getAxis();
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,8 +30,8 @@
import org.w3c.dom.Node;
public class PortletHyperlink extends AbstractHyperlink {
- private static final String PROP_EXTENSION = ".properties";
- private String hyperlinkText = "";
+ private static final String PROP_EXTENSION = ".properties"; //$NON-NLS-1$
+ private String hyperlinkText = ""; //$NON-NLS-1$
private String partitionType = null;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/PortletHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,14 +22,14 @@
import org.w3c.dom.Node;
public class PortletHyperlinkPartitioner extends AbstractHyperlinkPartitioner {
- public static final String PORTLET_CLASS_PARTITION = "org.jboss.tools.common.text.ext.hyperlink.xml.PORTLET_CLASS";
- public static final String PORTLET_RESOURCE_BUNDLE_PARTITION = "org.jboss.tools.common.text.ext.hyperlink.xml.PORTLET_RESOURCE";
+ public static final String PORTLET_CLASS_PARTITION = "org.jboss.tools.common.text.ext.hyperlink.xml.PORTLET_CLASS"; //$NON-NLS-1$
+ public static final String PORTLET_RESOURCE_BUNDLE_PARTITION = "org.jboss.tools.common.text.ext.hyperlink.xml.PORTLET_RESOURCE"; //$NON-NLS-1$
- static final String textNodeName = "#text";
+ static final String textNodeName = "#text"; //$NON-NLS-1$
- static final String portletNodeName = "portlet";
- static final String portletClassNodeName = "portlet-class";
- static final String portletResourceBundleNodeName = "resource-bundle";
+ static final String portletNodeName = "portlet"; //$NON-NLS-1$
+ static final String portletClassNodeName = "portlet-class"; //$NON-NLS-1$
+ static final String portletResourceBundleNodeName = "resource-bundle"; //$NON-NLS-1$
public static Node getNode(IDocument document, int superOffset) {
StructuredModelWrapper smw = new StructuredModelWrapper();
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/TLDAttributeNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/TLDAttributeNameHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/TLDAttributeNameHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,13 +17,13 @@
* Window - Preferences - Java - Code Style - Code Templates
*/
public class TLDAttributeNameHyperlinkPartitioner extends XMLJumpToHyperlinkPartitioner {
- public static final String TLD_ATTRIBUTE_NAME_PARTITION = "org.jboss.tools.common.text.ext.tld.TLD_ATTRIBUTE_NAME";
+ public static final String TLD_ATTRIBUTE_NAME_PARTITION = "org.jboss.tools.common.text.ext.tld.TLD_ATTRIBUTE_NAME"; //$NON-NLS-1$
protected String getPartitionType() {
return TLD_ATTRIBUTE_NAME_PARTITION;
}
protected String[] getValidAxisEndings() {
- return new String[] {"/tag/variable/name-from-attribute/"};
+ return new String[] {"/tag/variable/name-from-attribute/"}; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLClassHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLClassHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLClassHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
* @author Jeremy
*/
public class XMLClassHyperlinkPartitioner extends AbstractHyperlinkPartitioner {
- public static final String XML_CLASS_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_CLASS";
+ public static final String XML_CLASS_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_CLASS"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -41,14 +41,14 @@
DocumentType node = (DocumentType)n;
- String text = "";
+ String text = ""; //$NON-NLS-1$
try {
text = getDocument().get(start, end - start);
} catch (BadLocationException x) {
ExtensionsPlugin.getPluginLog().logError(x);
};
- String publicId = (node.getPublicId() == null ? "" : node.getPublicId());
- String systemId = (node.getSystemId() == null ? "" : node.getSystemId());
+ String publicId = (node.getPublicId() == null ? "" : node.getPublicId()); //$NON-NLS-1$
+ String systemId = (node.getSystemId() == null ? "" : node.getSystemId()); //$NON-NLS-1$
int valueStart = -1;
int valueLength = 0;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLDoctypeHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
*
*/
public class XMLDoctypeHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String XML_DOCTYPE_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_DOCTYPE";
+ public static final String XML_DOCTYPE_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_DOCTYPE"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -68,7 +68,7 @@
Node node = Utils.findNodeForOffset(xmlDocument, superRegion.getOffset());
if (node instanceof DocumentType) {
- return "/@DOCTYPE/" + node.getNodeName() + "/";
+ return "/@DOCTYPE/" + node.getNodeName() + "/"; //$NON-NLS-1$ //$NON-NLS-2$
}
return Utils.getParentAxisForNode(xmlDocument, node);
} finally {
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeValueHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeValueHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeValueHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
* @author Jeremy
*/
public class XMLElementAttributeValueHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer, IExclusiblePartitionerRecognition {
- public static final String XML_ATTRIBUTE_VALUE_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE";
+ public static final String XML_ATTRIBUTE_VALUE_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_VALUE"; //$NON-NLS-1$
protected String getPartitionType() {
return XML_ATTRIBUTE_VALUE_PARTITION;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -28,7 +28,7 @@
*
*/
public class XMLElementHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String XML_ELEMENT_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ELEMENT";
+ public static final String XML_ELEMENT_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ELEMENT"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementNameHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementNameHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -25,7 +25,7 @@
* @author Jeremy
*/
public class XMLElementNameHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String XML_ELEMENT_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ELEMENT_NAME";
+ public static final String XML_ELEMENT_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ELEMENT_NAME"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -68,7 +68,7 @@
IDOMElement elem = (IDOMElement)n;
String tagName = elem.getTagName();
int start = elem.getStartOffset();
- int nameStart = start + (elem.isEndTag() ? "</" : "<").length();
+ int nameStart = start + (elem.isEndTag() ? "</" : "<").length(); //$NON-NLS-1$ //$NON-NLS-2$
int nameEnd = nameStart + tagName.length();
if (nameStart > offset || nameEnd <= offset) return null;
@@ -97,7 +97,7 @@
IDOMElement elem = (IDOMElement)n;
String tagName = elem.getTagName();
int start = elem.getStartOffset();
- int nameStart = start + (elem.isEndTag() ? "<" : "</").length();
+ int nameStart = start + (elem.isEndTag() ? "<" : "</").length(); //$NON-NLS-1$ //$NON-NLS-2$
int nameEnd = nameStart + tagName.length();
return (region.getOffset() > nameStart && region.getOffset() <= nameEnd);
} finally {
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLFilterNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLFilterNameHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLFilterNameHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,13 +18,13 @@
* Window - Preferences - Java - Code Style - Code Templates
*/
public class XMLFilterNameHyperlinkPartitioner extends XMLJumpToHyperlinkPartitioner {
- public static final String XML_FILTER_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_FILTER_NAME";
+ public static final String XML_FILTER_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_FILTER_NAME"; //$NON-NLS-1$
protected String getPartitionType() {
return XML_FILTER_NAME_PARTITION;
}
protected String[] getValidAxisEndings() {
- return new String[] {"/filter-mapping/filter-name/"};
+ return new String[] {"/filter-mapping/filter-name/"}; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLJumpToHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLJumpToHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLJumpToHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -34,7 +34,7 @@
* @author Jeremy
*/
public class XMLJumpToHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String XML_JUMP_TO_PARTITION = "org.jboss.tools.common.text.xml.XML_JUMP_TO";
+ public static final String XML_JUMP_TO_PARTITION = "org.jboss.tools.common.text.xml.XML_JUMP_TO"; //$NON-NLS-1$
protected String getPartitionType() {
return XML_JUMP_TO_PARTITION;
@@ -124,7 +124,7 @@
private boolean validAxis(Node n, String validAxisEnding) {
if (validAxisEnding == null || validAxisEnding.lastIndexOf('/') == -1) return false;
- StringTokenizer st = new StringTokenizer(validAxisEnding, "/");
+ StringTokenizer st = new StringTokenizer(validAxisEnding, "/"); //$NON-NLS-1$
List<String> tokens = new ArrayList<String>();
while (st.hasMoreTokens()) {
tokens.add(st.nextToken());
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRoleNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRoleNameHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRoleNameHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -18,15 +18,15 @@
* Window - Preferences - Java - Code Style - Code Templates
*/
public class XMLRoleNameHyperlinkPartitioner extends XMLJumpToHyperlinkPartitioner {
- public static final String XML_ROLE_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ROLE_NAME";
+ public static final String XML_ROLE_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ROLE_NAME"; //$NON-NLS-1$
protected String getPartitionType() {
return XML_ROLE_NAME_PARTITION;
}
protected String[] getValidAxisEndings() {
- return new String[] {"/servlet/security-role-ref/role-link/",
- "/servlet/run-as/role-name/",
- "/security-constraint/auth-constraint/role-name/"};
+ return new String[] {"/servlet/security-role-ref/role-link/", //$NON-NLS-1$
+ "/servlet/run-as/role-name/", //$NON-NLS-1$
+ "/security-constraint/auth-constraint/role-name/"}; //$NON-NLS-1$
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRootHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRootHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLRootHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,7 +30,7 @@
*
*/
public class XMLRootHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String XML_ROOT_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ROOT";
+ public static final String XML_ROOT_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ROOT"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -38,7 +38,7 @@
protected IHyperlinkRegion parse(IDocument document, IHyperlinkRegion superRegion) {
if (!recognize(document, superRegion)) return null;
- String axis = computeAxis(document, superRegion.getOffset()) + "/";
+ String axis = computeAxis(document, superRegion.getOffset()) + "/"; //$NON-NLS-1$
String contentType = superRegion.getContentType();
String type = XML_ROOT_PARTITION;
int length = superRegion.getLength();
@@ -49,7 +49,7 @@
}
public static String computeAxis(IDocument document, int offset) {
- String axis = "";
+ String axis = ""; //$NON-NLS-1$
StructuredModelWrapper smw = new StructuredModelWrapper();
try {
smw.init(document);
@@ -67,14 +67,14 @@
// The node name extraction must be done by taking into account 'jsfc' attribute value
if (n instanceof Element) {
Element e = (Element)n;
- String jsfcAttrValue = e.getAttribute("jsfc");
+ String jsfcAttrValue = e.getAttribute("jsfc"); //$NON-NLS-1$
if (jsfcAttrValue != null && jsfcAttrValue.trim().length() > 0) {
name = jsfcAttrValue;
}
}
String nodeName = extractName(name, trackersMap);
- axis = "/" + nodeName;
+ axis = "/" + nodeName; //$NON-NLS-1$
}
Node parent = (n instanceof Attr)? ((Attr)n).getOwnerElement():n.getParentNode();
while (parent instanceof Element) {
@@ -84,7 +84,7 @@
// The node name extraction must be done by taking into account 'jsfc' attribute value
if (parent instanceof Element) {
Element e = (Element)parent;
- String jsfcAttrValue = e.getAttribute("jsfc");
+ String jsfcAttrValue = e.getAttribute("jsfc"); //$NON-NLS-1$
if (jsfcAttrValue != null && jsfcAttrValue.trim().length() > 0) {
name = jsfcAttrValue;
}
@@ -92,7 +92,7 @@
String nodeName = extractName(name, trackersMap);
if (nodeName != null && nodeName.length() > 0)
- axis = "/" + nodeName + axis;
+ axis = "/" + nodeName + axis; //$NON-NLS-1$
parent = parent.getParentNode();
}
}
@@ -100,14 +100,14 @@
smw.dispose();
}
- if (axis == null || axis.length() == 0) axis = "";
+ if (axis == null || axis.length() == 0) axis = ""; //$NON-NLS-1$
return axis;
}
public static String extractName (String name, Map trackersMap) {
if (trackersMap == null || trackersMap.size() == 0) return name;
if (name == null) return null;
- int column = name.indexOf(":");
+ int column = name.indexOf(":"); //$NON-NLS-1$
if (column == -1) return name;
String prefix = name.substring(0, column);
if (prefix == null || prefix.trim().length() == 0) return name;
@@ -115,7 +115,7 @@
String uri = (String)trackersMap.get(prefix);
if (uri == null || uri.length() == 0) return name;
- return "[" + uri + "]" + name.substring(column);
+ return "[" + uri + "]" + name.substring(column); //$NON-NLS-1$ //$NON-NLS-2$
}
/**
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLServletNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLServletNameHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLServletNameHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,13 +17,13 @@
* Window - Preferences - Java - Code Style - Code Templates
*/
public class XMLServletNameHyperlinkPartitioner extends XMLJumpToHyperlinkPartitioner {
- public static final String XML_SERVLET_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_SERVLET_NAME";
+ public static final String XML_SERVLET_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_SERVLET_NAME"; //$NON-NLS-1$
protected String getPartitionType() {
return XML_SERVLET_NAME_PARTITION;
}
protected String[] getValidAxisEndings() {
- return new String[] {"/filter-mapping/servlet-name/", "/servlet-mapping/servlet-name/"};
+ return new String[] {"/filter-mapping/servlet-name/", "/servlet-mapping/servlet-name/"}; //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -157,7 +157,7 @@
openFileInEditor(mappedSystemId);
} else {
String uri = getURI(region);
- if (uri != null && uri.toLowerCase().startsWith("http:")) {
+ if (uri != null && uri.toLowerCase().startsWith("http:")) { //$NON-NLS-1$
URL url = null;
url = new URL(uri);
IWorkbenchBrowserSupport browserSupport = PlatformUI.getWorkbench().getBrowserSupport();
@@ -224,8 +224,8 @@
}
protected IEditorInput createEditorInputAlternate(String fileString) {
- String jarName = fileString.substring(0,fileString.indexOf("!"));
- String entryName = fileString.substring(fileString.indexOf("!")+2,fileString.length());
+ String jarName = fileString.substring(0,fileString.indexOf("!")); //$NON-NLS-1$
+ String entryName = fileString.substring(fileString.indexOf("!")+2,fileString.length()); //$NON-NLS-1$
ZipFile jarFile = null;
try {
@@ -256,16 +256,16 @@
protected String getPublicId(IRegion region) {
String text = getURI(region);
if (text == null) return null;
- int spacer = text.indexOf(" ");
- if (spacer == -1) spacer = text.indexOf("\t");
+ int spacer = text.indexOf(" "); //$NON-NLS-1$
+ if (spacer == -1) spacer = text.indexOf("\t"); //$NON-NLS-1$
return (spacer == -1 ? text : text.substring(0, spacer));
}
protected String getSystemId(IRegion region) {
String text = getURI(region);
if (text == null) return null;
- int spacer = text.indexOf(" ");
- if (spacer == -1) spacer = text.indexOf("\t");
+ int spacer = text.indexOf(" "); //$NON-NLS-1$
+ if (spacer == -1) spacer = text.indexOf("\t"); //$NON-NLS-1$
if (spacer == -1) spacer = 0;
return text.substring(spacer).trim();
@@ -323,9 +323,9 @@
if (!(n instanceof IDOMAttr)) return null;
IDOMAttr xmlnsAttr = (IDOMAttr)n;
if (xmlnsAttr.getName() == null ||
- (!xmlnsAttr.getName().equals("xmlns") &&
- !xmlnsAttr.getName().startsWith("xmlns:") &&
- !xmlnsAttr.getName().endsWith(":schemaLocation")
+ (!xmlnsAttr.getName().equals("xmlns") && //$NON-NLS-1$
+ !xmlnsAttr.getName().startsWith("xmlns:") && //$NON-NLS-1$
+ !xmlnsAttr.getName().endsWith(":schemaLocation") //$NON-NLS-1$
)) return null;
String text = xmlnsAttr.getValueRegionText();
@@ -371,7 +371,7 @@
public String getHyperlinkText() {
String uri = getURI(fLastRegion);
if (uri == null)
- return MessageFormat.format(Messages.NotFound, "URI");
+ return MessageFormat.format(Messages.NotFound, "URI"); //$NON-NLS-1$
return MessageFormat.format(Messages.Open, uri);
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlinkPartitioner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLXmlNsHyperlinkPartitioner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,7 +27,7 @@
* @author Jeremy
*/
public class XMLXmlNsHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer {
- public static final String XML_XMLNS_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_XMLNS";
+ public static final String XML_XMLNS_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_XMLNS"; //$NON-NLS-1$
/**
* @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
@@ -44,8 +44,8 @@
IDOMAttr xmlnsAttr = (IDOMAttr)n;
if (xmlnsAttr.getName() == null ||
// (!xmlnsAttr.getName().equals("xmlns") &&
- (!xmlnsAttr.getName().startsWith("xmlns:") &&
- !xmlnsAttr.getName().endsWith(":schemaLocation")
+ (!xmlnsAttr.getName().startsWith("xmlns:") && //$NON-NLS-1$
+ !xmlnsAttr.getName().endsWith(":schemaLocation") //$NON-NLS-1$
)) return null;
String xmlns = xmlnsAttr.getValueRegionText();
String axis = getAxis(document, superRegion);
@@ -76,9 +76,9 @@
if (!(n instanceof IDOMAttr)) return false;
IDOMAttr xmlnsAttr = (IDOMAttr)n;
if (xmlnsAttr.getName() == null ||
- (!xmlnsAttr.getName().equals("xmlns") &&
- !xmlnsAttr.getName().startsWith("xmlns:") &&
- !xmlnsAttr.getName().endsWith(":schemaLocation")
+ (!xmlnsAttr.getName().equals("xmlns") && //$NON-NLS-1$
+ !xmlnsAttr.getName().startsWith("xmlns:") && //$NON-NLS-1$
+ !xmlnsAttr.getName().endsWith(":schemaLocation") //$NON-NLS-1$
)) return false;
Element rootElement = xmlnsAttr.getOwnerElement();
if(!(rootElement instanceof IDOMElement)) return false;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/AbstractBaseHyperlink.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/AbstractBaseHyperlink.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/AbstractBaseHyperlink.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -143,8 +143,8 @@
private static IStatus createStatus(Exception ex) {
return new Status(
- IStatus.ERROR,"org.jboss.tools.common.text.ext",0,
- ex.getMessage()+"",ex);
+ IStatus.ERROR,"org.jboss.tools.common.text.ext",0, //$NON-NLS-1$
+ ex.getMessage()+"",ex); //$NON-NLS-1$
}
/**
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/HyperlinkDefinition.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/HyperlinkDefinition.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xpl/HyperlinkDefinition.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -151,7 +151,7 @@
* @param e
*/
private void handleCreateExecutableException(Object[] result, Exception x) {
- ExtensionsPlugin.getPluginLog().logError("Error in creating extension", x);
+ ExtensionsPlugin.getPluginLog().logError("Error in creating extension", x); //$NON-NLS-1$
result[0] = null;
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/CSSTextScanner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/CSSTextScanner.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/CSSTextScanner.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -21,10 +21,10 @@
*
*/
public class CSSTextScanner extends TextScanner {
- public static final String CSS_CLASS_NAME = "___css_class_name";
- public static final String CSS_CLASS_NAME_SEPARATOR = "___css_class_name_separator";
- public static final String CSS_CLASS_BODY = "___css_class_body";
- public static final String CSS_CLASS_COMMENT = "___css_class_comment";
+ public static final String CSS_CLASS_NAME = "___css_class_name"; //$NON-NLS-1$
+ public static final String CSS_CLASS_NAME_SEPARATOR = "___css_class_name_separator"; //$NON-NLS-1$
+ public static final String CSS_CLASS_BODY = "___css_class_body"; //$NON-NLS-1$
+ public static final String CSS_CLASS_COMMENT = "___css_class_comment"; //$NON-NLS-1$
private static final int STATE_START = 0;
private static final int STATE_NAME = 1;
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/TaglibManagerWrapper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/TaglibManagerWrapper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/TaglibManagerWrapper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -55,7 +55,7 @@
}
public String getCorePrefix() {
- return getPrefix("http://java.sun.com/jsf/core");
+ return getPrefix("http://java.sun.com/jsf/core"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/Utils.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/Utils.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/util/Utils.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -89,38 +89,38 @@
}
public static String getParentAxisForNode(Document xmlDocument, Node node) {
- String axis = "";
+ String axis = ""; //$NON-NLS-1$
if (node == null) return null;
Node parent = (node instanceof Attr)? ((Attr)node).getOwnerElement():node.getParentNode();
while (parent instanceof Element) {
String nodeName = parent.getNodeName();
- axis = "/" + nodeName + axis;
+ axis = "/" + nodeName + axis; //$NON-NLS-1$
parent = parent.getParentNode();
}
if (axis == null || axis.length() == 0)
axis = null;
- return axis + "/";
+ return axis + "/"; //$NON-NLS-1$
}
public static String trimFilePath(String name) {
if(name == null) return null;
- StringTokenizer st = new StringTokenizer(name.replace('\\', '/'), "/");
- String result = "";
+ StringTokenizer st = new StringTokenizer(name.replace('\\', '/'), "/"); //$NON-NLS-1$
+ String result = ""; //$NON-NLS-1$
while(st.hasMoreTokens()) {
String token = st.nextToken();
- if (!".".equals(token)){
- result += (result.length() == 0 ? token : "/" + token);
+ if (!".".equals(token)){ //$NON-NLS-1$
+ result += (result.length() == 0 ? token : "/" + token); //$NON-NLS-1$
}
}
- if (name.startsWith("/"))
- result = "/" + result;
+ if (name.startsWith("/")) //$NON-NLS-1$
+ result = "/" + result; //$NON-NLS-1$
return result;
}
public static IPath getRelativePath (final IPath base, final IPath path) {
// Make web-root path to be relative to project
- IPath relativePath = new Path("/");
+ IPath relativePath = new Path("/"); //$NON-NLS-1$
String last = path.lastSegment();
IPath absolutePath = path.removeLastSegments(1);
Added: trunk/common/plugins/org.jboss.tools.common.text.xml/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XMLTextViewerConfiguration.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XMLTextViewerConfiguration.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XMLTextViewerConfiguration.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -126,7 +126,7 @@
}
private IHyperlinkDetector getTextEditorsExtensionsHyperlinkDetector() {
- Plugin plugin = Platform.getPlugin("org.jboss.tools.common.text.ext");
+ Plugin plugin = Platform.getPlugin("org.jboss.tools.common.text.ext"); //$NON-NLS-1$
return (plugin != null && plugin instanceof IAdaptable ? (IHyperlinkDetector)((IAdaptable)plugin).getAdapter(IHyperlinkDetector.class):null);
}
@@ -136,7 +136,7 @@
//and its subclasses
if(!(initial instanceof StructuredTextViewerConfiguration)) return null;
try {
- Method m = findDeclaredMethod(initial.getClass(), "getContentAssistProcessors", new Class[]{ISourceViewer.class, String.class});
+ Method m = findDeclaredMethod(initial.getClass(), "getContentAssistProcessors", new Class[]{ISourceViewer.class, String.class}); //$NON-NLS-1$
if(m == null) return null;
m.setAccessible(true);
return (IContentAssistProcessor[])m.invoke(initial, new Object[]{sourceViewer, partitionType});
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XmlEditorPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XmlEditorPlugin.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/XmlEditorPlugin.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -42,7 +42,7 @@
//Resource bundle.
private ResourceBundle resourceBundle;
- public static final String PLUGIN_ID = "org.jboss.tools.common.text.xml";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.text.xml"; //$NON-NLS-1$
/**
@@ -51,7 +51,7 @@
public XmlEditorPlugin() {
plugin = this;
try {
- resourceBundle= ResourceBundle.getBundle("org.jboss.tools.common.text.xml.XmlEditorPluginResources");
+ resourceBundle= ResourceBundle.getBundle("org.jboss.tools.common.text.xml.XmlEditorPluginResources"); //$NON-NLS-1$
} catch (MissingResourceException x) {
resourceBundle = null;
}
@@ -99,7 +99,7 @@
Method m;
try {
- m = AbstractUIPlugin.class.getDeclaredMethod("initializeDefaultPluginPreferences", new Class[0]);
+ m = AbstractUIPlugin.class.getDeclaredMethod("initializeDefaultPluginPreferences", new Class[0]); //$NON-NLS-1$
m.setAccessible(true);
m.invoke(JavaPlugin.getDefault(), new Object[0]);
} catch (NoSuchMethodException e) {
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/contentassist/ContentAssistProcessorDefinition.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/contentassist/ContentAssistProcessorDefinition.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/contentassist/ContentAssistProcessorDefinition.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -137,7 +137,7 @@
* @param e
*/
private void handleCreateExecutableException(Object[] result, Exception x) {
- XmlEditorPlugin.getPluginLog().logError("Error in creating extension", x);
+ XmlEditorPlugin.getPluginLog().logError("Error in creating extension", x); //$NON-NLS-1$
result[0] = null;
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/BasePreferenceConstants.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/BasePreferenceConstants.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/BasePreferenceConstants.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -89,9 +89,9 @@
store.setDefault(getItemBoldKey(item), bold);
}
- public final static String EDITOR_TAB_WIDTH = "org.jboss.tools.common.text.xml.ui.tab.width";
+ public final static String EDITOR_TAB_WIDTH = "org.jboss.tools.common.text.xml.ui.tab.width"; //$NON-NLS-1$
- public final static String EDITOR_REPLACE_TAB_WITH_WHITESPACE = "org.jboss.tools.common.text.xml.ui.tab.replace";
+ public final static String EDITOR_REPLACE_TAB_WITH_WHITESPACE = "org.jboss.tools.common.text.xml.ui.tab.replace"; //$NON-NLS-1$
}
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/XmlPreferenceConstants.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/XmlPreferenceConstants.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/ui/xpl/XmlPreferenceConstants.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -146,24 +146,24 @@
store.setDefault(BasePreferenceConstants.EDITOR_TAB_WIDTH, 4);
store.setDefault(BasePreferenceConstants.EDITOR_REPLACE_TAB_WITH_WHITESPACE, false);
- setDefault(store, "errorIndicationColor", new RGB(255,175,175), new RGB(255, 255, 255), false, false);
+ setDefault(store, "errorIndicationColor", new RGB(255,175,175), new RGB(255, 255, 255), false, false); //$NON-NLS-1$
initializeTextEditorValues(store);
}
static String[] BOOLEAN_PROPERTIES = new String[]{
- EDITOR_CURRENT_LINE, EDITOR_LINE_NUMBER_RULER, EDITOR_PRINT_MARGIN, "overviewRuler"
+ EDITOR_CURRENT_LINE, EDITOR_LINE_NUMBER_RULER, EDITOR_PRINT_MARGIN, "overviewRuler" //$NON-NLS-1$
};
static String[] STRING_PROPERTIES = new String[]{
EDITOR_CURRENT_LINE_COLOR, EDITOR_LINE_NUMBER_RULER_COLOR, EDITOR_PRINT_MARGIN_COLOR,
- "errorIndicationColor", "warningIndicationColor", "infoIndicationColor", "taskIndicationColor", "bookmarkIndicationColor"
+ "errorIndicationColor", "warningIndicationColor", "infoIndicationColor", "taskIndicationColor", "bookmarkIndicationColor" //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
};
static String[] INT_PROPERTIES = new String[]{EDITOR_PRINT_MARGIN_COLUMN};
private static void initializeTextEditorValues(final IPreferenceStore store) {
- Plugin plugin = Platform.getPlugin("org.eclipse.ui.editors");
+ Plugin plugin = Platform.getPlugin("org.eclipse.ui.editors"); //$NON-NLS-1$
try {
- Method m = AbstractUIPlugin.class.getDeclaredMethod("initializeDefaultPluginPreferences", new Class[0]);
+ Method m = AbstractUIPlugin.class.getDeclaredMethod("initializeDefaultPluginPreferences", new Class[0]); //$NON-NLS-1$
m.setAccessible(true);
m.invoke(plugin, new Object[0]);
} catch (NoSuchMethodException e1) {
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/xpl/ToggleOccurencesMarkUpAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/xpl/ToggleOccurencesMarkUpAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/common/text/xml/xpl/ToggleOccurencesMarkUpAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -173,7 +173,7 @@
private static URL makeIconFileURL(String prefix, String name) throws MalformedURLException {
URL base = null;
try {
- base = FileLocator.resolve(XmlEditorPlugin.getDefault().getBundle().getEntry("/"));
+ base = FileLocator.resolve(XmlEditorPlugin.getDefault().getBundle().getEntry("/")); //$NON-NLS-1$
} catch (IOException e) {
XmlEditorPlugin.getPluginLog().logError(e);
return null;
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/LabelFieldEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/LabelFieldEditor.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/LabelFieldEditor.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
* @param parent
*/
public LabelFieldEditor(String value, Composite parent) {
- super("label", value, parent);
+ super("label", value, parent); //$NON-NLS-1$
}
/**
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/PreferenceConstants.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/PreferenceConstants.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/PreferenceConstants.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -60,7 +60,7 @@
*
* @since 3.0
*/
- public static String EDITOR_MARK_TEXT_NODE_OCCURRENCES = "markTextNodeOccurrences";
+ public static String EDITOR_MARK_TEXT_NODE_OCCURRENCES = "markTextNodeOccurrences"; //$NON-NLS-1$
/**
* A named preference that controls whether attribute occurrences are marked.
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencePreferenceConstants.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencePreferenceConstants.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencePreferenceConstants.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -55,7 +55,7 @@
public static void initializeDefaultValues(IPreferenceStore store) {
// set the default values from AbstractDecoratedTextEditor
- PreferenceConverter.setDefault(store, "occurrenceIndicationColor", new RGB(128, 255, 255));
+ PreferenceConverter.setDefault(store, "occurrenceIndicationColor", new RGB(128, 255, 255)); //$NON-NLS-1$
store.setDefault(PreferenceKeyGenerator.generateKey(EDITOR_MARK_OCCURRENCES,XMLUIPlugin.ID), false);
store.setDefault(PreferenceKeyGenerator.generateKey(EDITOR_STICKY_OCCURRENCES,XMLUIPlugin.ID), true);
store.setDefault(PreferenceKeyGenerator.generateKey(EDITOR_OCCURRENCE_PROVIDER,XMLUIPlugin.ID), "org.jboss.tools.common.text.xml.defaultOccurrenceProvider"); //$NON-NLS-1$
Modified: trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencesPreferencePage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencesPreferencePage.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.text.xml/src/org/jboss/tools/jst/jsp/preferences/xpl/XMLOccurrencesPreferencePage.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -85,8 +85,8 @@
XMLOccurrencePreferenceConstants.EDITOR_MARK_OCCURRENCES,
fEditorID),
Messages
- .getString("OccurrencesPreferencePage.Mark.occurrences.in.file"),
- getFieldEditorParent()); //$NON-NLS-1$
+ .getString("OccurrencesPreferencePage.Mark.occurrences.in.file"), //$NON-NLS-1$
+ getFieldEditorParent());
addField(mark);
markNode = new VarBooleanFieldEditor(
@@ -94,8 +94,8 @@
.generateKey(
XMLOccurrencePreferenceConstants.EDITOR_MARK_NODE_OCCURRENCES,
fEditorID), Messages
- .getString("OccurrencesPreferencePage.Mark.Tags"),
- getFieldEditorParent()); //$NON-NLS-1$
+ .getString("OccurrencesPreferencePage.Mark.Tags"), //$NON-NLS-1$
+ getFieldEditorParent());
markNode.offset(getFieldEditorParent(), 10); // offset 10
addField(markNode);
@@ -105,8 +105,8 @@
XMLOccurrencePreferenceConstants.EDITOR_MARK_ATTRIBUTE_OCCURRENCES,
fEditorID),
Messages
- .getString("OccurrencesPreferencePage.Mark.Attribute.Names"),
- getFieldEditorParent()); //$NON-NLS-1$
+ .getString("OccurrencesPreferencePage.Mark.Attribute.Names"), //$NON-NLS-1$
+ getFieldEditorParent());
markAttribute.offset(getFieldEditorParent(), 10); // offset 10
addField(markAttribute);
@@ -116,8 +116,8 @@
XMLOccurrencePreferenceConstants.EDITOR_MARK_ATTRIBUTE_VALUE_OCCURRENCES,
fEditorID),
Messages
- .getString("OccurrencesPreferencePage.Mark.Attribute.Values"),
- getFieldEditorParent()); //$NON-NLS-1$
+ .getString("OccurrencesPreferencePage.Mark.Attribute.Values"), //$NON-NLS-1$
+ getFieldEditorParent());
markAttributeValue.offset(getFieldEditorParent(), 10); // offset 10
addField(markAttributeValue);
@@ -126,7 +126,7 @@
.generateKey(
XMLOccurrencePreferenceConstants.EDITOR_MARK_TEXT_OCCURRENCES,
fEditorID), Messages
- .getString("OccurrencesPreferencePage.Mark.Text"),
+ .getString("OccurrencesPreferencePage.Mark.Text"), //$NON-NLS-1$
getFieldEditorParent());
markText.offset(getFieldEditorParent(), 10); // offset 10
addField(markText);
@@ -140,8 +140,8 @@
.generateKey(
XMLOccurrencePreferenceConstants.EDITOR_STICKY_OCCURRENCES,
fEditorID), Messages
- .getString("OccurrencesPreferencePage.Sticky"),
- getFieldEditorParent()); //$NON-NLS-1$
+ .getString("OccurrencesPreferencePage.Sticky"), //$NON-NLS-1$
+ getFieldEditorParent());
sticky.offset(getFieldEditorParent(), 10); // offset 10
addField(sticky);
}
Added: trunk/common/plugins/org.jboss.tools.common.verification/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.verification/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Added: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/Messages.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/Messages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1,16 @@
+package org.jboss.tools.common.verification;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.verification.messages"; //$NON-NLS-1$
+ public static String VerifyRulesAllHandler_ApplyVerificationRules;
+ public static String VerifyRulesAllHandler_ApplyVerificationRulesForObject;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
Added: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/messages.properties (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/messages.properties 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1,2 @@
+VerifyRulesAllHandler_ApplyVerificationRules=Apply Verification Rules
+VerifyRulesAllHandler_ApplyVerificationRulesForObject=Apply Verification Rules for
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VHelper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VHelper.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VHelper.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -35,7 +35,7 @@
if(managerModel == null) {
managerModel = mgr;
} else if(managerModel != mgr) {
- VerificationPlugin.getPluginLog().logInfo("Warning: VManager already exists.");
+ VerificationPlugin.getPluginLog().logInfo("Warning: VManager already exists."); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResult.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResult.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResult.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -12,10 +12,10 @@
*/
public class VResult {
- public static final String TYPE_ERROR = "error";
- public static final String TYPE_WARN = "warning";
- public static final String TYPE_INFO = "info";
- public static final String TYPE_HIDDEN = "hidden";
+ public static final String TYPE_ERROR = "error"; //$NON-NLS-1$
+ public static final String TYPE_WARN = "warning"; //$NON-NLS-1$
+ public static final String TYPE_INFO = "info"; //$NON-NLS-1$
+ public static final String TYPE_HIDDEN = "hidden"; //$NON-NLS-1$
public static final int SIGN_ERROR = 10;
public static final int SIGN_WARN = 5;
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResultTemplate.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResultTemplate.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/VResultTemplate.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -42,7 +42,7 @@
public void setId(String id) {
String old = this.id;
this.id = id;
- propertyChangeSupport.firePropertyChange("id", old, id);
+ propertyChangeSupport.firePropertyChange("id", old, id); //$NON-NLS-1$
}
/** Returns this template name.
@@ -60,7 +60,7 @@
public void setName(String name) {
String old = this.name;
this.name = name;
- propertyChangeSupport.firePropertyChange("name", old, name);
+ propertyChangeSupport.firePropertyChange("name", old, name); //$NON-NLS-1$
}
/** Returns this template description.
@@ -78,7 +78,7 @@
public void setDescription(String description) {
String old = this.description;
this.description = description;
- propertyChangeSupport.firePropertyChange("description", old, description);
+ propertyChangeSupport.firePropertyChange("description", old, description); //$NON-NLS-1$
}
/** Returns this template type.
@@ -96,7 +96,7 @@
public void setType(String type) {
String old = this.type;
this.type = type;
- propertyChangeSupport.firePropertyChange("type", old, type);
+ propertyChangeSupport.firePropertyChange("type", old, type); //$NON-NLS-1$
}
/** Returns this template significance.
@@ -120,7 +120,7 @@
} else {
this.significance = significance;
}
- propertyChangeSupport.firePropertyChange("significance", old, significance);
+ propertyChangeSupport.firePropertyChange("significance", old, significance); //$NON-NLS-1$
}
/** Returns this template format.
@@ -138,7 +138,7 @@
public void setFormat(VMessageFormat format) {
VMessageFormat old = this.format;
this.format = format;
- propertyChangeSupport.firePropertyChange("format", old, format);
+ propertyChangeSupport.firePropertyChange("format", old, format); //$NON-NLS-1$
}
/** Creates new VResult object.
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VTaskListenerImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VTaskListenerImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VTaskListenerImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -115,13 +115,13 @@
protected int getErrorCountLimit() {
if(limit != -2) return limit;
- String path = "%Options%/Struts Studio/Verification";
- String attr = "Reported Errors Number Limit";
+ String path = "%Options%/Struts Studio/Verification"; //$NON-NLS-1$
+ String attr = "Reported Errors Number Limit"; //$NON-NLS-1$
XModelObject o = PreferenceModelUtilities.getPreferenceModel().getByPath(path);
if(o == null) return limit = -1;
String s = o.getAttributeValue(attr);
limit = -1;
- if(!"unlimited".equals(s) && s != null && s.length() > 0) try {
+ if(!"unlimited".equals(s) && s != null && s.length() > 0) try { //$NON-NLS-1$
limit = Integer.parseInt(s);
} catch (NumberFormatException e) {
ModelPlugin.getPluginLog().logError(e);
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VerifyBuilder.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VerifyBuilder.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/core/resources/VerifyBuilder.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -23,7 +23,7 @@
public class VerifyBuilder extends IncrementalProjectBuilder
{
- public static final String BUILDER_ID = VerificationPlugin.PLUGIN_ID + ".verifybuilder";
+ public static final String BUILDER_ID = VerificationPlugin.PLUGIN_ID + ".verifybuilder"; //$NON-NLS-1$
GlobalBuilderImpl builderImpl = null;
protected IProject[] build(int kind, Map args, IProgressMonitor monitor)
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyConfigurationHandler.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyConfigurationHandler.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyConfigurationHandler.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -20,7 +20,7 @@
* @deprecated
*/
public class VerifyConfigurationHandler extends AbstractHandler {
- SpecialWizard wizard = SpecialWizardFactory.createSpecialWizard("org.jboss.tools.common.verification.ui.vrules.wizard.config.VRulesConfigurationWizard");
+ SpecialWizard wizard = SpecialWizardFactory.createSpecialWizard("org.jboss.tools.common.verification.ui.vrules.wizard.config.VRulesConfigurationWizard"); //$NON-NLS-1$
public VerifyConfigurationHandler() {}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyHandler.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyHandler.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyHandler.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -62,7 +62,7 @@
}
}
if (results == null || results.length == 0) {
- model.getOut().println(rule.getName()+": OK: "+source);
+ model.getOut().println(rule.getName()+": OK: "+source); //$NON-NLS-1$
} else {
for (int i = 0; i < results.length; i++) {
if (results[i].getSignificance() < sign) continue;
@@ -71,7 +71,7 @@
//resultModel.setResult(results[i]);
//ruleModel.addChild(resultModel);
- model.getOut().println(rule.getName()+": "+results[i].getMessage());
+ model.getOut().println(rule.getName()+": "+results[i].getMessage()); //$NON-NLS-1$
}
}
((VRuleImpl)rule).setResults((VResult[])list.toArray(new VResult[list.size()]));
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRuleSetHandler.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRuleSetHandler.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRuleSetHandler.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -28,17 +28,17 @@
VModel vmodel = VModelFactory.getModel(object.getModel());
VObject vobject = vmodel.getObjectByPath(object.getPath());
VRule[] rules = vobject.getEntity().getRules();
- object.getModel().getOut().println(ruleSet.getName()+":");
+ object.getModel().getOut().println(ruleSet.getName()+":"); //$NON-NLS-1$
for (int i = 0; i < rules.length; i++) {
VRule rule = rules[i];
VAction vaction = rule.getAction();
if (!rule.isEnabled() || rule.getRuleSet() != ruleSet || vaction == null) continue;
VResult[] results = vaction.check(vobject);
if (results == null || results.length == 0) {
- object.getModel().getOut().println(rule.getName()+": OK");
+ object.getModel().getOut().println(rule.getName()+": OK"); //$NON-NLS-1$
} else {
for (int j = 0; j < results.length; j++) {
- object.getModel().getOut().println(rule.getName()+": "+results[j].getMessage());
+ object.getModel().getOut().println(rule.getName()+": "+results[j].getMessage()); //$NON-NLS-1$
}
}
mergeResults(object.getModel(), rule, vobject, results);
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesAllHandler.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesAllHandler.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesAllHandler.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -6,6 +6,8 @@
package org.jboss.tools.common.verification.vrules.handler;
+import org.eclipse.osgi.util.NLS;
+import org.jboss.tools.common.verification.Messages;
import org.jboss.tools.common.verification.vrules.*;
import org.jboss.tools.common.verification.vrules.layer.VModelFactory;
import org.jboss.tools.common.model.*;
@@ -62,13 +64,14 @@
private void executeHandlerGUI(XModelObject object, Properties p) throws XModelException {
- SpecialWizard wizard = SpecialWizardFactory.createSpecialWizard("org.jboss.tools.common.verification.ui.vrules.wizard.runtime2.VerifyWizard");
+ SpecialWizard wizard = SpecialWizardFactory.createSpecialWizard("org.jboss.tools.common.verification.ui.vrules.wizard.runtime2.VerifyWizard"); //$NON-NLS-1$
if(p == null) p = new Properties();
- String title = "Apply Verification Rules";
- if(!object.getModelEntity().getName().equals("FileSystems"))
- title += " for " + object.getPresentationString();
- p.setProperty("title", title);
- p.setProperty("help", "ApplyVerificationRules");
+ String title = Messages.VerifyRulesAllHandler_ApplyVerificationRules;
+ if(!object.getModelEntity().getName().equals("FileSystems")) //$NON-NLS-1$
+ title = NLS.bind(Messages.VerifyRulesAllHandler_ApplyVerificationRulesForObject,
+ object.getPresentationString());
+ p.setProperty("title", title); //$NON-NLS-1$
+ p.setProperty("help", "ApplyVerificationRules"); //$NON-NLS-1$ //$NON-NLS-2$
wizard.setObject(new Object[]{object, p});
wizard.execute();
/*
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesHandler.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesHandler.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/handler/VerifyRulesHandler.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,10 +32,10 @@
if (!rule.isEnabled() || !rule.getRuleSet().isEnabled() || vaction == null) continue;
VResult[] results = vaction.check(vobject);
if (results == null || results.length == 0) {
- object.getModel().getOut().println(rule.getName()+": OK");
+ object.getModel().getOut().println(rule.getName()+": OK"); //$NON-NLS-1$
} else {
for (int j = 0; j < results.length; j++) {
- object.getModel().getOut().println(rule.getName()+": "+results[j].getMessage());
+ object.getModel().getOut().println(rule.getName()+": "+results[j].getMessage()); //$NON-NLS-1$
}
}
mergeResults(object.getModel(), rule, vobject, results);
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VManagerImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VManagerImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VManagerImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -118,7 +118,7 @@
public void setMinSignificance(int significance) {
int oldSignificance = this.significance;
this.significance = significance;
- propertyChangeSupport.firePropertyChange("minSignificance", oldSignificance, significance);
+ propertyChangeSupport.firePropertyChange("minSignificance", oldSignificance, significance); //$NON-NLS-1$
}
public VMessageFormat getMessageFormat() {
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -83,7 +83,7 @@
public void setEnabled(boolean enabled) {
boolean oldEnabled = this.enabled;
this.enabled = enabled;
- propertyChangeSupport.firePropertyChange("enabled", oldEnabled, enabled);
+ propertyChangeSupport.firePropertyChange("enabled", oldEnabled, enabled); //$NON-NLS-1$
}
public void setDefaultEnabled(boolean b) {
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleSetImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleSetImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VRuleSetImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -87,7 +87,7 @@
public void setEnabled(boolean enabled) {
boolean oldEnabled = this.enabled;
this.enabled = enabled;
- propertyChangeSupport.firePropertyChange("enabled", oldEnabled, enabled);
+ propertyChangeSupport.firePropertyChange("enabled", oldEnabled, enabled); //$NON-NLS-1$
}
public void setDefaultEnabled(boolean b) {
@@ -126,10 +126,10 @@
if (bundle == null) return null;
String pattern = null;
try {
- pattern = bundle.getString("message."+id);
+ pattern = bundle.getString("message."+id); //$NON-NLS-1$
} catch (MissingResourceException e) {
- VerificationPlugin.getPluginLog().logError("Cannot find message-id " + id);
- pattern = "";
+ VerificationPlugin.getPluginLog().logError("Cannot find message-id " + id); //$NON-NLS-1$
+ pattern = ""; //$NON-NLS-1$
}
if (pattern == null) return null;
VMessageFormat format = new VMessageFormat(pattern);
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VTaskImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VTaskImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/impl/VTaskImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -49,7 +49,7 @@
public void start() {
if (thread == null) {
- thread = new Thread(this, "VTask");
+ thread = new Thread(this, "VTask"); //$NON-NLS-1$
thread.start();
} else {
if(sleeping) {
@@ -158,7 +158,7 @@
}
private void logListener(VTaskListener listener, Throwable e) {
- VerificationPlugin.getPluginLog().logInfo("Exception in listener "+listener+" ignored: "+e, e);
+ VerificationPlugin.getPluginLog().logInfo("Exception in listener "+listener+" ignored: "+e, e); //$NON-NLS-1$ //$NON-NLS-2$
}
private void notifyApplied(VRule rule, VObject object, VResult[] results) {
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VEntityImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VEntityImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VEntityImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -77,7 +77,7 @@
if(modelEntity == null) {
modelEntity = meta.getEntity(entityName);
if(modelEntity == null) {
- VerificationPlugin.getPluginLog().logInfo("VModelImpl:Cannot find entity " + entityName);
+ VerificationPlugin.getPluginLog().logInfo("VModelImpl:Cannot find entity " + entityName); //$NON-NLS-1$
}
}
return modelEntity;
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VModelImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VModelImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VModelImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,7 +30,7 @@
public VModelImpl(XModel model) {
this.model = model;
meta = model.getMetaData();
- project = (IProject)model.getProperties().get("project");
+ project = (IProject)model.getProperties().get("project"); //$NON-NLS-1$
this.entities = new HashMap<String,VEntity>();
}
@@ -67,9 +67,9 @@
};
public XActionListImpl createGlobalActionList(XModelEntity entity) {
- XActionList global = (XActionList)model.getMetaData().getGlobalActions().getItem("VerifyActions");
+ XActionList global = (XActionList)model.getMetaData().getGlobalActions().getItem("VerifyActions"); //$NON-NLS-1$
XActionListImpl entityActions = (XActionListImpl)entity.getActionList();
- XActionListImpl verifyActions = (XActionListImpl)entityActions.getItem("VerifyActions");
+ XActionListImpl verifyActions = (XActionListImpl)entityActions.getItem("VerifyActions"); //$NON-NLS-1$
if (verifyActions == null) {
verifyActions = (XActionListImpl)global.copy(acceptor1);
entityActions.addActionItem(verifyActions);
@@ -78,7 +78,7 @@
}
public XActionListImpl getGlobalActionList(XModelEntity entity) {
- XActionListImpl verifyActions = (XActionListImpl)entity.getActionList().getItem("VerifyActions");
+ XActionListImpl verifyActions = (XActionListImpl)entity.getActionList().getItem("VerifyActions"); //$NON-NLS-1$
return verifyActions;
}
@@ -124,7 +124,7 @@
XActionListImpl verifyActions = getGlobalActionList(entity);
if (verifyActions == null) return null;
- XActionListImpl dynamicList = (XActionListImpl)verifyActions.getItem("DynamicActions");
+ XActionListImpl dynamicList = (XActionListImpl)verifyActions.getItem("DynamicActions"); //$NON-NLS-1$
XActionListImpl ruleSetList = (XActionListImpl)dynamicList.getItem(ruleSetName);
return ruleSetList;
}
@@ -144,7 +144,7 @@
XActionListImpl ruleSetList = getRuleSetActionList(entity, ruleSetName);
if (ruleSetList == null) return null;
- XActionListImpl dynamicList2 = (XActionListImpl)ruleSetList.getItem("DynamicActions");
+ XActionListImpl dynamicList2 = (XActionListImpl)ruleSetList.getItem("DynamicActions"); //$NON-NLS-1$
XActionImpl ruleAction = (XActionImpl)dynamicList2.getItem(ruleName);
return ruleAction;
}
@@ -173,7 +173,7 @@
// Eclipse does not have type in this case,
// so we return something instead of null
// This is ok while result is only compared to null
- return EclipseResourceUtil.getValidType(project, "java.lang.Class");
+ return EclipseResourceUtil.getValidType(project, "java.lang.Class"); //$NON-NLS-1$
}
return null;
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VObjectImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VObjectImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/layer/VObjectImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,10 +36,10 @@
static VObject[] EMPTY_CHILDREN = new VObject[0];
public VObject[] getChildren() {
- if("true".equals(modelObject.get("overlapped"))) return EMPTY_CHILDREN;
+ if("true".equals(modelObject.get("overlapped"))) return EMPTY_CHILDREN; //$NON-NLS-1$ //$NON-NLS-2$
//Takes too much time, do not verify in jars
- if(modelObject.getModelEntity().getName().equals("FileSystemJar")) {
+ if(modelObject.getModelEntity().getName().equals("FileSystemJar")) { //$NON-NLS-1$
return EMPTY_CHILDREN;
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/RuleSetResourceLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/RuleSetResourceLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/RuleSetResourceLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -27,14 +27,14 @@
Bundle bundle = Platform.getBundle(es[i].getNamespaceIdentifier());
IConfigurationElement[] elements = es[i].getConfigurationElements();
for (int j = 0; j < elements.length; j++) {
- String path = elements[j].getAttribute("path");
+ String path = elements[j].getAttribute("path"); //$NON-NLS-1$
if(path != null) {
URL url = bundle.getResource(path);
if(url != null) {
resources.add(url);
} else {
if(ModelPlugin.isDebugEnabled()) {
- VerificationPlugin.getPluginLog().logInfo("Warning: meta resource " + path + " not found.");
+ VerificationPlugin.getPluginLog().logInfo("Warning: meta resource " + path + " not found."); //$NON-NLS-1$ //$NON-NLS-2$
}
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VManagerModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VManagerModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VManagerModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -50,9 +50,9 @@
manager = new VManagerImpl();
manager.setModel(new VModelImpl(getModel()));
VHelper.setManager(this);
- manager.setMessageFormat(new VMessageFormat(getBundle(getAttributeValue("bundle")).getString(getAttributeValue("format id"))));
+ manager.setMessageFormat(new VMessageFormat(getBundle(getAttributeValue("bundle")).getString(getAttributeValue("format id")))); //$NON-NLS-1$ //$NON-NLS-2$
manager.setRuleSets(getRuleSets());
- String s = getAttributeValue("minimum significance");
+ String s = getAttributeValue("minimum significance"); //$NON-NLS-1$
try {
if(s != null && s.length() > 0) {
manager.setMinSignificance(Integer.parseInt(s));
@@ -60,7 +60,7 @@
} catch (NumberFormatException e) {
ModelPlugin.getPluginLog().logError(e);
}
- developer = "developer".equals(getAttributeValue("mode"));
+ developer = "developer".equals(getAttributeValue("mode")); //$NON-NLS-1$ //$NON-NLS-2$
manager.addPropertyChangeListener(this);
}
@@ -68,13 +68,13 @@
private ResourceBundle getBundle(String baseName) {
if (baseName == null || baseName.length() == 0) return null;
- if("null".equals(bundles.get(baseName))) return null;
+ if("null".equals(bundles.get(baseName))) return null; //$NON-NLS-1$
ResourceBundle bundle = (ResourceBundle)bundles.get(baseName);
if(bundle != null) {
return bundle;
}
bundle = ResourceBundle.getBundle(baseName);
- Object bo = (bundle == null) ? (Object)"null" : bundle;
+ Object bo = (bundle == null) ? (Object)"null" : bundle; //$NON-NLS-1$
bundles.put(baseName, bo);
return bundle;
}
@@ -117,9 +117,9 @@
public String setAttributeValue(String name, String value) {
String result = super.setAttributeValue(name, value);
if (manager != null) {
- if ("mode".equals(name)) {
- developer = "developer".equals(getAttributeValue("mode"));
- } else if ("minimum significance".equals(name)) {
+ if ("mode".equals(name)) { //$NON-NLS-1$
+ developer = "developer".equals(getAttributeValue("mode")); //$NON-NLS-1$ //$NON-NLS-2$
+ } else if ("minimum significance".equals(name)) { //$NON-NLS-1$
try {
if(result != null && result.length() > 0) {
manager.setMinSignificance(Integer.parseInt(result));
@@ -141,15 +141,15 @@
}
public boolean isAttributeEditable(String name) {
- return "mode".equals(name) || "minimum significance".equals(name) || super.isAttributeEditable(name);
+ return "mode".equals(name) || "minimum significance".equals(name) || super.isAttributeEditable(name); //$NON-NLS-1$ //$NON-NLS-2$
}
public void propertyChange(PropertyChangeEvent evt) {
String name = evt.getPropertyName();
- String value = "" + evt.getNewValue();
- if ("minSignificance".equals(name)) {
- if (!value.equals(getAttributeValue("minimum significance"))) {
- setAttributeValue("minimum significance", value);
+ String value = "" + evt.getNewValue(); //$NON-NLS-1$
+ if ("minSignificance".equals(name)) { //$NON-NLS-1$
+ if (!value.equals(getAttributeValue("minimum significance"))) { //$NON-NLS-1$
+ setAttributeValue("minimum significance", value); //$NON-NLS-1$
setModified(true);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -32,28 +32,28 @@
public void setResult(VResult result) {
this.result = result;
- setAttributeValue("message", result.getMessage());
- setAttributeValue("significance", ""+result.getSignificance());
- setAttributeValue("source object", result.getSourceObject().getPath());
- setAttributeValue("source position", ""+result.getSourcePosition());
- setAttributeValue("target object", result.getTargetObject().getPath());
- setAttributeValue("target position", ""+result.getTargetPosition());
- setAttributeValue("type", result.getType());
+ setAttributeValue("message", result.getMessage()); //$NON-NLS-1$
+ setAttributeValue("significance", ""+result.getSignificance()); //$NON-NLS-1$ //$NON-NLS-2$
+ setAttributeValue("source object", result.getSourceObject().getPath()); //$NON-NLS-1$
+ setAttributeValue("source position", ""+result.getSourcePosition()); //$NON-NLS-1$ //$NON-NLS-2$
+ setAttributeValue("target object", result.getTargetObject().getPath()); //$NON-NLS-1$
+ setAttributeValue("target position", ""+result.getTargetPosition()); //$NON-NLS-1$ //$NON-NLS-2$
+ setAttributeValue("type", result.getType()); //$NON-NLS-1$
}
public String getPathPart() {
- return ""+System.identityHashCode(this);
+ return ""+System.identityHashCode(this); //$NON-NLS-1$
}
public String getPresentationString() {
- String msg = getAttributeValue("message");
+ String msg = getAttributeValue("message"); //$NON-NLS-1$
return msg;
}
public String getMainIconName() {
- String type = getAttributeValue("type");
+ String type = getAttributeValue("type"); //$NON-NLS-1$
if (type != null && type.length() > 0) {
- return "main.vrules.result-"+type;
+ return "main.vrules.result-"+type; //$NON-NLS-1$
} else {
return super.getMainIconName();
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultTemplateModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultTemplateModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VResultTemplateModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -30,17 +30,17 @@
public VResultTemplate getTemplate(VRule rule) {
if (template == null) {
template = new VResultTemplate();
- template.setId(getAttributeValue("id"));
- template.setName(getAttributeValue("name"));
- template.setDescription(getAttributeValue("description"));
- template.setType(getAttributeValue("type"));
- String s = getAttributeValue("significance");
+ template.setId(getAttributeValue("id")); //$NON-NLS-1$
+ template.setName(getAttributeValue("name")); //$NON-NLS-1$
+ template.setDescription(getAttributeValue("description")); //$NON-NLS-1$
+ template.setType(getAttributeValue("type")); //$NON-NLS-1$
+ String s = getAttributeValue("significance"); //$NON-NLS-1$
try {
template.setSignificance(Integer.parseInt(s));
} catch (NumberFormatException e) {
//ignore
}
- template.setFormat(getFormat(getAttributeValue("message id"), rule));
+ template.setFormat(getFormat(getAttributeValue("message id"), rule)); //$NON-NLS-1$
template.addPropertyChangeListener(this);
}
return template;
@@ -53,21 +53,21 @@
public String setAttributeValue(String name, String value) {
String result = super.setAttributeValue(name, value);
if (template != null) {
- if ("id".equals(name)) {
+ if ("id".equals(name)) { //$NON-NLS-1$
template.setId(result);
- } else if ("name".equals(name)) {
+ } else if ("name".equals(name)) { //$NON-NLS-1$
template.setName(result);
- } else if ("description".equals(name)) {
+ } else if ("description".equals(name)) { //$NON-NLS-1$
template.setDescription(result);
- } else if ("type".equals(name)) {
+ } else if ("type".equals(name)) { //$NON-NLS-1$
template.setType(result);
- } else if ("significance".equals(name)) {
+ } else if ("significance".equals(name)) { //$NON-NLS-1$
try {
template.setSignificance(Integer.parseInt(result));
} catch (NumberFormatException e) {
//ignore
}
- } else if ("message id".equals(name)) {
+ } else if ("message id".equals(name)) { //$NON-NLS-1$
template.setFormat(getFormat(result, ((VRuleModel)getParent()).getRule(null)));
}
}
@@ -75,29 +75,29 @@
}
public String getPathPart() {
- return getAttributeValue("id");
+ return getAttributeValue("id"); //$NON-NLS-1$
}
public String getPresentationString() {
- return getAttributeValue("name");
+ return getAttributeValue("name"); //$NON-NLS-1$
}
public void propertyChange(PropertyChangeEvent evt) {
String name = evt.getPropertyName();
- if ("id".equals(name) || "name".equals(name)
- || "description".equals(name) || "type".equals(name)
- || "significance".equals(name)) {
- String value = "" + evt.getNewValue();
+ if ("id".equals(name) || "name".equals(name) //$NON-NLS-1$ //$NON-NLS-2$
+ || "description".equals(name) || "type".equals(name) //$NON-NLS-1$ //$NON-NLS-2$
+ || "significance".equals(name)) { //$NON-NLS-1$
+ String value = "" + evt.getNewValue(); //$NON-NLS-1$
if (!value.equals(getAttributeValue(name))) {
setAttributeValue(name, value);
setModified(true);
}
- } else if ("format".equals(name)) {
+ } else if ("format".equals(name)) { //$NON-NLS-1$
VMessageFormat format = (VMessageFormat)evt.getNewValue();
if (format != null) {
String value = format.getId();
- if (!value.equals(getAttributeValue("message id"))) {
- setAttributeValue("message id", value);
+ if (!value.equals(getAttributeValue("message id"))) { //$NON-NLS-1$
+ setAttributeValue("message id", value); //$NON-NLS-1$
setModified(true);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -47,21 +47,21 @@
if (rule == null) {
rule = new VRuleImpl();
rule.setRuleSet(ruleSet);
- rule.setName(getAttributeValue("name"));
- rule.setDescription(getAttributeValue("description"));
- rule.setCategory(getAttributeValue("category"));
- rule.setEnabled(Boolean.valueOf(getAttributeValue("enabled")).booleanValue());
- String defaultEnabled = get("default-enabled");
- if("false".equals(defaultEnabled)) {
+ rule.setName(getAttributeValue("name")); //$NON-NLS-1$
+ rule.setDescription(getAttributeValue("description")); //$NON-NLS-1$
+ rule.setCategory(getAttributeValue("category")); //$NON-NLS-1$
+ rule.setEnabled(Boolean.valueOf(getAttributeValue("enabled")).booleanValue()); //$NON-NLS-1$
+ String defaultEnabled = get("default-enabled"); //$NON-NLS-1$
+ if("false".equals(defaultEnabled)) { //$NON-NLS-1$
rule.setDefaultEnabled(false);
}
rule.setResults(new VResult[0]);
- VEntity[] entities = getEntities(getAttributeValue("entities"));
+ VEntity[] entities = getEntities(getAttributeValue("entities")); //$NON-NLS-1$
rule.setEntities(entities);
- String act = getAttributeValue("action");
+ String act = getAttributeValue("action"); //$NON-NLS-1$
rule.setAction(getAction(act));
try {
- rule.setSignificance(Integer.parseInt(getAttributeValue("significance")));
+ rule.setSignificance(Integer.parseInt(getAttributeValue("significance"))); //$NON-NLS-1$
} catch (NumberFormatException e) {
rule.setSignificance(10);
}
@@ -75,9 +75,9 @@
if (sign > 0) {
rule.setSignificance(sign);
}
- String p = getAttributeValue("properties");
+ String p = getAttributeValue("properties"); //$NON-NLS-1$
if(p != null && p.length() > 0) {
- StringTokenizer st = new StringTokenizer(p, ",");
+ StringTokenizer st = new StringTokenizer(p, ","); //$NON-NLS-1$
Properties properties = new Properties();
while(st.hasMoreTokens()) {
String t = st.nextToken();
@@ -104,7 +104,7 @@
}
public VEntity[] getEntities(String list) {
- StringTokenizer tok = new StringTokenizer(list, ",");
+ StringTokenizer tok = new StringTokenizer(list, ","); //$NON-NLS-1$
int count = tok.countTokens();
VEntity[] entities = new VEntity[count];
VModel model = VModelFactory.getModel(getModel());
@@ -123,8 +123,8 @@
public void set(String name, String value) {
super.set(name, value);
if (rule != null) {
- if ("default-enabled".equals(name)) {
- if("false".equals(value)) {
+ if ("default-enabled".equals(name)) { //$NON-NLS-1$
+ if("false".equals(value)) { //$NON-NLS-1$
rule.setDefaultEnabled(false);
}
}
@@ -134,22 +134,22 @@
public String setAttributeValue(String name, String value) {
String result = super.setAttributeValue(name, value);
if (rule != null) {
- if ("enabled".equals(name)) {
+ if ("enabled".equals(name)) { //$NON-NLS-1$
rule.setEnabled(Boolean.valueOf(result).booleanValue());
- } else if ("name".equals(name)) {
+ } else if ("name".equals(name)) { //$NON-NLS-1$
String oldName = rule.getName();
rule.setName(result);
VModel vmodel = VModelFactory.getModel(getModel());
((VModelImpl)vmodel).updateRuleAction(rule, oldName);
- } else if ("action".equals(name)) {
+ } else if ("action".equals(name)) { //$NON-NLS-1$
rule.setAction(getAction(result));
- } else if ("significance".equals(name)) {
+ } else if ("significance".equals(name)) { //$NON-NLS-1$
try {
rule.setSignificance(Integer.parseInt(result));
} catch (NumberFormatException e) {
//ignore
}
- } else if ("entities".equals(name)) {
+ } else if ("entities".equals(name)) { //$NON-NLS-1$
VEntity[] oldEntities = rule.getEntities();
VEntity[] newEntities = getEntities(result);
rule.setEntities(newEntities);
@@ -193,7 +193,7 @@
public XModelObject[] getChildrenForSave() {
// Do not save results
- return getChildren("VResultTemplate");
+ return getChildren("VResultTemplate"); //$NON-NLS-1$
}
// TODO: override
@@ -207,21 +207,21 @@
}
public boolean isAttributeEditable(String name) {
- return "enabled".equals(name) || super.isAttributeEditable(name);
+ return "enabled".equals(name) || super.isAttributeEditable(name); //$NON-NLS-1$
}
public String getPathPart() {
- return getAttributeValue("name");
+ return getAttributeValue("name"); //$NON-NLS-1$
}
public String getPresentationString() {
- return getAttributeValue("name");
+ return getAttributeValue("name"); //$NON-NLS-1$
}
public void propertyChange(PropertyChangeEvent evt) {
String name = evt.getPropertyName();
- String value = "" + evt.getNewValue();
- if ("enabled".equals(name)) {
+ String value = "" + evt.getNewValue(); //$NON-NLS-1$
+ if ("enabled".equals(name)) { //$NON-NLS-1$
if (!value.equals(getAttributeValue(name))) {
setAttributeValue(name, value);
setModified(true);
@@ -261,7 +261,7 @@
action = (VAction)ModelFeatureFactory.getInstance().createFeatureInstance(classname);
} catch (ClassCastException th) {
if(VerificationPlugin.isDebugEnabled()) {
- VerificationPlugin.getPluginLog().logError("Unable to create action \""+classname+"\": " + "VRuleModel:getAction");
+ VerificationPlugin.getPluginLog().logError("Unable to create action \""+classname+"\": " + "VRuleModel:getAction"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
classname = null;
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetModel.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetModel.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetModel.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -48,20 +48,20 @@
if (ruleSet == null) {
ruleSet = new VRuleSetImpl();
ruleSet.setManagerKey(getModel());
- ruleSet.setName(getAttributeValue("name"));
- ruleSet.setDescription(getAttributeValue("description"));
- ruleSet.setEnabled(Boolean.valueOf(getAttributeValue("enabled")).booleanValue());
- String defaultEnabled = get("default-enabled");
- if("false".equals(defaultEnabled)) {
+ ruleSet.setName(getAttributeValue("name")); //$NON-NLS-1$
+ ruleSet.setDescription(getAttributeValue("description")); //$NON-NLS-1$
+ ruleSet.setEnabled(Boolean.valueOf(getAttributeValue("enabled")).booleanValue()); //$NON-NLS-1$
+ String defaultEnabled = get("default-enabled"); //$NON-NLS-1$
+ if("false".equals(defaultEnabled)) { //$NON-NLS-1$
ruleSet.setDefaultEnabled(false);
}
- ruleSet.setURL(getAttributeValue("url"));
- ruleSet.setVendor(getAttributeValue("vendor"));
- ruleSet.setVersion(getAttributeValue("version"));
- ruleSet.setResourceBundle(getBundle(getAttributeValue("bundle")));
+ ruleSet.setURL(getAttributeValue("url")); //$NON-NLS-1$
+ ruleSet.setVendor(getAttributeValue("vendor")); //$NON-NLS-1$
+ ruleSet.setVersion(getAttributeValue("version")); //$NON-NLS-1$
+ ruleSet.setResourceBundle(getBundle(getAttributeValue("bundle"))); //$NON-NLS-1$
ruleSet.setRules(getRules());
ruleSet.setRuleSets(getRuleSets());
- installed = Boolean.valueOf(getAttributeValue("installed")).booleanValue();
+ installed = Boolean.valueOf(getAttributeValue("installed")).booleanValue(); //$NON-NLS-1$
ruleSet.addPropertyChangeListener(this);
}
if(parent != null && ruleSet.getParentRuleSet() == null) ruleSet.setParentRuleSet(parent);
@@ -69,7 +69,7 @@
}
private VRule[] getRules() {
- XModelObject[] c = getChildren("VRule");
+ XModelObject[] c = getChildren("VRule"); //$NON-NLS-1$
VRule[] rules = new VRule[c.length];
for (int i = 0; i < c.length; i++) {
rules[i] = ((VRuleModel)c[i]).getRule(ruleSet);
@@ -78,7 +78,7 @@
}
private VRuleSet[] getRuleSets() {
- XModelObject[] c = getChildren("VRuleSet");
+ XModelObject[] c = getChildren("VRuleSet"); //$NON-NLS-1$
VRuleSet ruleSet = getRuleSet();
VRuleSet[] ruleSets = new VRuleSet[c.length];
for (int i = 0; i < c.length; i++) {
@@ -95,7 +95,7 @@
if(bundles.get(baseName) == NULL) return null;
ResourceBundle resourceBundle = (ResourceBundle)bundles.get(baseName);
if(resourceBundle != null) return resourceBundle;
- String bundleLoaderClassName = baseName.substring(0, baseName.lastIndexOf('.') + 1) + "BundleLoader";
+ String bundleLoaderClassName = baseName.substring(0, baseName.lastIndexOf('.') + 1) + "BundleLoader"; //$NON-NLS-1$
Class c = ModelFeatureFactory.getInstance().getFeatureClass(bundleLoaderClassName);
if(c != null) {
try {
@@ -110,7 +110,7 @@
}
bundles.put(baseName, NULL);
if(VerificationPlugin.isDebugEnabled()) {
- VerificationPlugin.getPluginLog().logInfo("Resource not found: " + baseName + " by org.jboss.tools.common.verification.vrules.model.VRuleSetModel:getBundle()");
+ VerificationPlugin.getPluginLog().logInfo("Resource not found: " + baseName + " by org.jboss.tools.common.verification.vrules.model.VRuleSetModel:getBundle()"); //$NON-NLS-1$ //$NON-NLS-2$
}
return null;
}
@@ -118,8 +118,8 @@
public void set(String name, String value) {
super.set(name, value);
if (ruleSet != null) {
- if ("default-enabled".equals(name)) {
- if("false".equals(value)) {
+ if ("default-enabled".equals(name)) { //$NON-NLS-1$
+ if("false".equals(value)) { //$NON-NLS-1$
ruleSet.setDefaultEnabled(false);
}
}
@@ -129,16 +129,16 @@
public String setAttributeValue(String name, String value) {
String result = super.setAttributeValue(name, value);
if (ruleSet != null) {
- if ("enabled".equals(name)) {
+ if ("enabled".equals(name)) { //$NON-NLS-1$
ruleSet.setEnabled(Boolean.valueOf(result).booleanValue());
- } else if ("name".equals(name)) {
+ } else if ("name".equals(name)) { //$NON-NLS-1$
String oldName = ruleSet.getName();
ruleSet.setName(result);
VModel vmodel = VModelFactory.getModel(getModel());
((VModelImpl)vmodel).updateRuleSetActionList(ruleSet, oldName);
- } else if ("installed".equals(name)) {
+ } else if ("installed".equals(name)) { //$NON-NLS-1$
installed = Boolean.valueOf(result).booleanValue();
- } else if ("bundle".equals(name)) {
+ } else if ("bundle".equals(name)) { //$NON-NLS-1$
ruleSet.setResourceBundle(getBundle(result));
}
}
@@ -184,21 +184,21 @@
}
public boolean isAttributeEditable(String name) {
- return "enabled".equals(name) || super.isAttributeEditable(name);
+ return "enabled".equals(name) || super.isAttributeEditable(name); //$NON-NLS-1$
}
public String getPathPart() {
- return getAttributeValue("name");
+ return getAttributeValue("name"); //$NON-NLS-1$
}
public String getPresentationString() {
- return getAttributeValue("name");
+ return getAttributeValue("name"); //$NON-NLS-1$
}
public void propertyChange(PropertyChangeEvent evt) {
String name = evt.getPropertyName();
- String value = "" + evt.getNewValue();
- if ("enabled".equals(name)) {
+ String value = "" + evt.getNewValue(); //$NON-NLS-1$
+ if ("enabled".equals(name)) { //$NON-NLS-1$
if (!value.equals(getAttributeValue(name))) {
setAttributeValue(name, value);
setModified(true);
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetsLoader.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetsLoader.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRuleSetsLoader.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -34,11 +34,11 @@
}
public void load(XModelObject object) {
- if("true".equals(object.getModel().getProperties().getProperty("initialModel"))) return;
+ if("true".equals(object.getModel().getProperties().getProperty("initialModel"))) return; //$NON-NLS-1$ //$NON-NLS-2$
super.load(object);
Set<String> installed = new HashSet<String>();
- Set resources = RuleSetResourceLoader.getResources("org.jboss.tools.common.verification.rules");
+ Set resources = RuleSetResourceLoader.getResources("org.jboss.tools.common.verification.rules"); //$NON-NLS-1$
ArrayList<URL> l = new ArrayList<URL>();
Iterator it = resources.iterator();
@@ -72,7 +72,7 @@
} else {
mergeRules(c, nc[j]);
}
- c.setAttributeValue("installed", "true");
+ c.setAttributeValue("installed", "true"); //$NON-NLS-1$ //$NON-NLS-2$
installed.add(c.getPathPart());
}
} catch (XModelException e) {
@@ -83,8 +83,8 @@
}
XModelObject[] ch = object.getChildren();
for (int i = 0; i < ch.length; i++) {
- String ins = ch[i].getAttributeValue("installed");
- if ("true".equals(ins)) {
+ String ins = ch[i].getAttributeValue("installed"); //$NON-NLS-1$
+ if ("true".equals(ins)) { //$NON-NLS-1$
if (!installed.contains(ch[i].getPathPart())) {
ch[i].removeFromParent();
}
@@ -98,11 +98,11 @@
org.jboss.tools.common.meta.XAttribute[] as = object.getModelEntity().getAttributes();
for (int i = 0; i < as.length; i++) {
String n = as[i].getName();
- if ("enabled".equals(n)) {
+ if ("enabled".equals(n)) { //$NON-NLS-1$
String nv = update.getAttributeValue(n);
- object.set("default-enabled", nv);
+ object.set("default-enabled", nv); //$NON-NLS-1$
}
- if ("enabled".equals(n) || "installed".equals(n)) continue;
+ if ("enabled".equals(n) || "installed".equals(n)) continue; //$NON-NLS-1$ //$NON-NLS-2$
String ov = object.getAttributeValue(n);
String nv = update.getAttributeValue(n);
if (ov.equals(nv)) continue;
@@ -131,7 +131,7 @@
}
protected String fileName(XModelObject object) {
- return ".rule-sets.xml";
+ return ".rule-sets.xml"; //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRulesTree.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRulesTree.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/model/VRulesTree.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -24,12 +24,12 @@
public void dispose() {}
public XModelObject getRoot() {
- XModelObject[] prjs = model.getRoot().getChildren("VManager");
+ XModelObject[] prjs = model.getRoot().getChildren("VManager"); //$NON-NLS-1$
if (prjs.length == 0) return null;
VManagerModel man = (VManagerModel)prjs[0];
if (!man.developer && first) {
// bad luck :)
- throw new IllegalStateException("Members only");
+ throw new IllegalStateException("Members only"); //$NON-NLS-1$
}
first = false;
return man;
Modified: trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/plugin/VerificationPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/plugin/VerificationPlugin.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification/src/org/jboss/tools/common/verification/vrules/plugin/VerificationPlugin.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -16,7 +16,7 @@
public class VerificationPlugin extends BaseUIPlugin implements IModelPlugin {
static VerificationPlugin plugin;
- public static final String PLUGIN_ID = "org.jboss.tools.common.verification";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.verification"; //$NON-NLS-1$
public VerificationPlugin() {
super();
plugin = this;
Added: trunk/common/plugins/org.jboss.tools.common.verification.ui/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Added: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/Messages.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/Messages.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1,19 @@
+package org.jboss.tools.common.verification.ui;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.verification.ui.messages"; //$NON-NLS-1$
+ public static String SignificanceView_Any;
+ public static String SignificanceView_GreaterThanN;
+ public static String SignificanceView_OnlyTen;
+ public static String SignificanceView_VerificationLevelLabel;
+ public static String VerifyWizardView_VerifyTask;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
Added: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/messages.properties (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/messages.properties 2009-06-26 07:56:07 UTC (rev 16218)
@@ -0,0 +1,5 @@
+SignificanceView_Any=any
+SignificanceView_GreaterThanN=greater than {0}
+SignificanceView_OnlyTen=only 10
+SignificanceView_VerificationLevelLabel=Verification Level:
+VerifyWizardView_VerifyTask=Verify {0}
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VRulesConfigurationAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VRulesConfigurationAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VRulesConfigurationAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,7 +36,7 @@
public VRulesPreferenceDialog() {
super(ModelPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell(),
ModelPlugin.getDefault().getWorkbench().getPreferenceManager());
- setSelectedNodePreference("org.jboss.tools.common.verification.ui");
+ setSelectedNodePreference("org.jboss.tools.common.verification.ui"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VerifyAllAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VerifyAllAction.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/action/VerifyAllAction.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -22,7 +22,7 @@
public void doRun() throws XModelException {
Properties p = new Properties();
- p.put("shell", window.getShell());
+ p.put("shell", window.getShell()); //$NON-NLS-1$
XActionInvoker.invoke(getActionPath(), object, p);
}
@@ -30,15 +30,15 @@
XModelObject adapter = getAdapter(selection);
if(adapter == null) return;
object = adapter;
- object = (object == null) ? null : object.getModel().getByPath("FileSystems");
+ object = (object == null) ? null : object.getModel().getByPath("FileSystems"); //$NON-NLS-1$
}
protected boolean computeEnabled() {
return true;
}
- String path1 = "VerifyActions.StaticActions.VerifyAll";
- String path2 = "ProcessVerifyActions.StaticActions.VerifyAll";
+ String path1 = "VerifyActions.StaticActions.VerifyAll"; //$NON-NLS-1$
+ String path2 = "ProcessVerifyActions.StaticActions.VerifyAll"; //$NON-NLS-1$
protected String getActionPath() {
if(object.getModelEntity().getActionList().getAction(path2) != null) return path2;
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/SignificanceView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/SignificanceView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/SignificanceView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,9 +10,11 @@
******************************************************************************/
package org.jboss.tools.common.verification.ui.vrules.wizard;
+import java.text.MessageFormat;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.*;
import org.eclipse.swt.widgets.*;
+import org.jboss.tools.common.verification.ui.Messages;
import org.jboss.tools.common.verification.vrules.VManager;
public abstract class SignificanceView {
@@ -34,7 +36,7 @@
control.setLayoutData(gd);
Label label = new Label(control, SWT.NONE);
- label.setText("Verification Level: ");
+ label.setText(Messages.SignificanceView_VerificationLevelLabel);
// Control sc =
createSignificanceControl(control);
return control;
@@ -43,7 +45,9 @@
protected abstract Control createSignificanceControl(Composite parent);
public String getMinSignificancePresentation(int i) {
- return (i == 0) ? "any" : (i == 9) ? "only 10" : "greater than " + i;
+ return (i == 0) ? Messages.SignificanceView_Any :
+ (i == 9) ? Messages.SignificanceView_OnlyTen :
+ MessageFormat.format(Messages.SignificanceView_GreaterThanN, i);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/VRuleTipFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/VRuleTipFactory.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/VRuleTipFactory.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -19,23 +19,23 @@
VResultTemplate[] ts = f.getTemplates();
if(ts == null) return null;
StringBuffer sb = new StringBuffer();
- sb.append("<html><body>").append(rule.getDescription()).append("<br>");
+ sb.append("<html><body>").append(rule.getDescription()).append("<br>"); //$NON-NLS-1$ //$NON-NLS-2$
for (int i = 0; i < ts.length; i++) {
int si = ts[i].getSignificance();
- sb.append(" ");
- if(si <= minignificance) sb.append("<font color=\"#7f7f7f\">");
+ sb.append(" "); //$NON-NLS-1$
+ if(si <= minignificance) sb.append("<font color=\"#7f7f7f\">"); //$NON-NLS-1$
/// sb.append('@'); //works swing only
- sb.append(" - "); //for eclipse only
+ sb.append(" - "); //for eclipse only //$NON-NLS-1$
sb.append(si).append(' ').append(ts[i].getDescription());
- if(si <= minignificance) sb.append("</font>");
- sb.append("<br>");
+ if(si <= minignificance) sb.append("</font>"); //$NON-NLS-1$
+ sb.append("<br>"); //$NON-NLS-1$
}
- sb.append("</body></html>");
+ sb.append("</body></html>"); //$NON-NLS-1$
return sb.toString();
}
public static String getRuleTip(VRuleSet set) {
- return ("<html><body>" + set.getDescription() + "</body></html>");
+ return ("<html><body>" + set.getDescription() + "</body></html>"); //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/ConfigRulesProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/ConfigRulesProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/ConfigRulesProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -17,8 +17,8 @@
import org.jboss.tools.common.model.util.*;
public class ConfigRulesProvider extends LabelProvider implements ITreeContentProvider, ILabelProvider, IColorProvider {
- public Image IMAGE_ENABLED = EclipseResourceUtil.getImage("images/common/check.gif");
- public Image IMAGE_DISABLED = EclipseResourceUtil.getImage("images/common/uncheck.gif");
+ public Image IMAGE_ENABLED = EclipseResourceUtil.getImage("images/common/check.gif"); //$NON-NLS-1$
+ public Image IMAGE_DISABLED = EclipseResourceUtil.getImage("images/common/uncheck.gif"); //$NON-NLS-1$
protected RuleSetWrapper[] ruleSets = new RuleSetWrapper[0];
public RuleSetWrapper[] getRuleSets() {
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/VRulesConfigurationWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/VRulesConfigurationWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/config/VRulesConfigurationWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -36,9 +36,9 @@
protected DescriptionManager tip = new DescriptionManager();
public VRulesConfigurationWizardView() {
- this.setMessage(WizardKeys.getString("VRulesConfigurationWizardView.Message"));
- this.setTitle(WizardKeys.getString("VRulesConfigurationWizardView.Title"));
- this.setWindowTitle(WizardKeys.getString("VRulesConfigurationWizardView.WindowTitle"));
+ this.setMessage(WizardKeys.getString("VRulesConfigurationWizardView.Message")); //$NON-NLS-1$
+ this.setTitle(WizardKeys.getString("VRulesConfigurationWizardView.Title")); //$NON-NLS-1$
+ this.setWindowTitle(WizardKeys.getString("VRulesConfigurationWizardView.WindowTitle")); //$NON-NLS-1$
}
public Control createControl(Composite parent) {
@@ -72,7 +72,7 @@
public void setObject(Object data) {
Properties p = findProperties(data);
if(p != null) {
- String key = p.getProperty("help");
+ String key = p.getProperty("help"); //$NON-NLS-1$
setHelpKey(key);
}
// Object model = ((Properties)data).get("model");
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/RuntimeRulesProvider.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/RuntimeRulesProvider.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/RuntimeRulesProvider.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -15,9 +15,9 @@
import org.jboss.tools.common.model.util.*;
public class RuntimeRulesProvider extends LabelProvider implements ITreeContentProvider, ILabelProvider {
- public Image IMAGE_0 = EclipseResourceUtil.getImage("images/struts/pro/validator_constant.gif");
- public Image IMAGE_1 = EclipseResourceUtil.getImage("images/java/attr.gif");
- public Image IMAGE_2 = EclipseResourceUtil.getImage("images/struts/exception.gif");
+ public Image IMAGE_0 = EclipseResourceUtil.getImage("images/struts/pro/validator_constant.gif"); //$NON-NLS-1$
+ public Image IMAGE_1 = EclipseResourceUtil.getImage("images/java/attr.gif"); //$NON-NLS-1$
+ public Image IMAGE_2 = EclipseResourceUtil.getImage("images/struts/exception.gif"); //$NON-NLS-1$
protected RuntimeRuleSetWrapper[] ruleSets = new RuntimeRuleSetWrapper[0];
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VTaskListenerImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VTaskListenerImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VTaskListenerImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -42,7 +42,7 @@
if(results != null) {
for (int i = 0; i < results.length; i++) {
if(results[i] == null) {
- XStudioVerificationPlugin.getPluginLog().logInfo("Result in rule " + rule.getName() + " is null.");
+ XStudioVerificationPlugin.getPluginLog().logInfo("Result in rule " + rule.getName() + " is null."); //$NON-NLS-1$ //$NON-NLS-2$
continue;
}
if (results[i].getSignificance() <= VHelper.getManager(/*view.model*/).getMinSignificance()) continue;
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VerifyWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VerifyWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime/VerifyWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -47,9 +47,15 @@
import org.jboss.tools.common.verification.vrules.layer.VModelFactory;
public class VerifyWizardView extends AbstractQueryWizardView {
- static String[] INITIAL_COMMANDS = new String[]{"Run All", "Run Selected", "Close", HELP};
- static String[] RUNNING_COMMANDS = new String[]{"Pause", "Stop", "Close", HELP};
- static String[] PAUSE_COMMANDS = new String[]{"Resume", "Stop", "Close", HELP};
+ private static final String COMMAND_RESUME = "Resume"; //$NON-NLS-1$
+ private static final String COMMAND_PAUSE = "Pause"; //$NON-NLS-1$
+ private static final String COMMAND_STOP = "Stop"; //$NON-NLS-1$
+ private static final String COMMAND_RUN_SELECTED = "Run Selected"; //$NON-NLS-1$
+ private static final String COMMAND_RUN_ALL = "Run All"; //$NON-NLS-1$
+ static final String COMMAND_CLOSE = "Close"; //$NON-NLS-1$
+ static String[] INITIAL_COMMANDS = new String[]{COMMAND_RUN_ALL, COMMAND_RUN_SELECTED, COMMAND_CLOSE, HELP};
+ static String[] RUNNING_COMMANDS = new String[]{COMMAND_PAUSE, COMMAND_STOP, COMMAND_CLOSE, HELP};
+ static String[] PAUSE_COMMANDS = new String[]{COMMAND_RESUME, COMMAND_STOP, COMMAND_CLOSE, HELP};
protected RuntimeSignificanceView significance = new RuntimeSignificanceView();
protected RuntimeRulesProvider provider = new RuntimeRulesProvider();
protected TreeViewer treeViewer;
@@ -61,9 +67,9 @@
protected DescriptionManager tip = new DescriptionManager();
public VerifyWizardView() {
- this.setMessage(WizardKeys.getString("VerifyWizardView.Message"));
- this.setTitle(WizardKeys.getString("VerifyWizardView.Title"));
- this.setWindowTitle(WizardKeys.getString("VerifyWizardView.WindowTitle"));
+ this.setMessage(WizardKeys.getString("VerifyWizardView.Message")); //$NON-NLS-1$
+ this.setTitle(WizardKeys.getString("VerifyWizardView.Title")); //$NON-NLS-1$
+ this.setWindowTitle(WizardKeys.getString("VerifyWizardView.WindowTitle")); //$NON-NLS-1$
}
private VManager getRulesManager() {
@@ -98,7 +104,7 @@
public void setObject(Object data) {
Properties p = findProperties(data);
if(p != null) {
- String key = p.getProperty("help");
+ String key = p.getProperty("help"); //$NON-NLS-1$
setHelpKey(key);
}
Object[] os = (Object[])data;
@@ -188,13 +194,13 @@
public void action(String command) {
stopEditing();
- if("Run All".equals(command)) {
+ if(COMMAND_RUN_ALL.equals(command)) {
clearStatus();
if(task != null) task.removeTaskListener(listener);
task = getRulesManager().createTask(vobject);
task.addTaskListener(listener);
task.start();
- } else if("Run Selected".equals(command)) {
+ } else if(COMMAND_RUN_SELECTED.equals(command)) {
clearStatus();
VRule[] rs = getSelectedRules();
if(rs == null) return;
@@ -202,7 +208,7 @@
task = getRulesManager().createTask(vobject, rs);
task.addTaskListener(listener);
task.start();
- } else if("Close".equals(command)) {
+ } else if(COMMAND_CLOSE.equals(command)) {
if(task != null) {
task.removeTaskListener(listener);
task.stop();
@@ -210,11 +216,11 @@
}
setCode(0);
dispose();
- } else if("Stop".equals(command)) {
+ } else if(COMMAND_STOP.equals(command)) {
if(task != null) task.stop();
- } else if("Pause".equals(command)) {
+ } else if(COMMAND_PAUSE.equals(command)) {
if(task != null) task.pause();
- } else if("Resume".equals(command)) {
+ } else if(COMMAND_RESUME.equals(command)) {
if(task != null) task.start();
} else if(HELP.equals(command)) {
super.action(command);
@@ -228,7 +234,7 @@
if(o == null) return -1;
String s = o.getAttributeValue(VerificationPreferencePage.ATTR_ERRORS_NUMBER_LIMIT);
int limit = -1;
- if(!"unlimited".equals(s) && s != null && s.length() > 0) try {
+ if(!"unlimited".equals(s) && s != null && s.length() > 0) try { //$NON-NLS-1$
limit = Integer.parseInt(s);
} catch (NumberFormatException e) {
XStudioVerificationPlugin.getPluginLog().logError(e);
@@ -244,7 +250,7 @@
new Runnable() {
public void run() {
ServiceDialog d = model.getService();
- d.showDialog(VerificationUIMessages.WARNING, NLS.bind(VerificationUIMessages.LIMIT_OF_REPORTED_ERRORS_IS_REACHED, ""+getErrorCountLimit()), new String[]{VerificationUIMessages.OK}, null, ServiceDialog.WARNING);
+ d.showDialog(VerificationUIMessages.WARNING, NLS.bind(VerificationUIMessages.LIMIT_OF_REPORTED_ERRORS_IS_REACHED, ""+getErrorCountLimit()), new String[]{VerificationUIMessages.OK}, null, ServiceDialog.WARNING); //$NON-NLS-1$
limitLock = false;
task.stop();
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VTaskListenerImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VTaskListenerImpl.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VTaskListenerImpl.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -46,7 +46,7 @@
} catch (InterruptedException e) {
//ignore
}
- view.action("Close");
+ view.action(VerifyWizardView.COMMAND_CLOSE);
task.removeTaskListener(this);
}
Modified: trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VerifyWizardView.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VerifyWizardView.java 2009-06-26 07:21:07 UTC (rev 16217)
+++ trunk/common/plugins/org.jboss.tools.common.verification.ui/src/org/jboss/tools/common/verification/ui/vrules/wizard/runtime2/VerifyWizardView.java 2009-06-26 07:56:07 UTC (rev 16218)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.verification.ui.vrules.wizard.runtime2;
+import java.text.MessageFormat;
import java.util.*;
import org.eclipse.swt.*;
import org.eclipse.swt.events.*;
@@ -19,6 +20,7 @@
import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.jface.wizard.ProgressMonitorPart;
+import org.jboss.tools.common.verification.ui.Messages;
import org.jboss.tools.common.verification.ui.vrules.wizard.runtime.VTaskListenerSafeImpl;
import org.jboss.tools.common.meta.key.*;
import org.jboss.tools.common.model.*;
@@ -27,6 +29,9 @@
import org.jboss.tools.common.verification.vrules.layer.VObjectImpl;
public class VerifyWizardView extends AbstractQueryWizardView {
+ static final String COMMAND_CANCEL = "Cancel"; //$NON-NLS-1$
+ static final String COMMAND_RUN = "Run"; //$NON-NLS-1$
+ static final String COMMAND_CLOSE = "Close"; //$NON-NLS-1$
protected XModel model;
protected VObject vobject;
protected VTask task = null;
@@ -35,9 +40,9 @@
ProgressMonitorPart progressMonitorPart;
public VerifyWizardView() {
- this.setMessage(WizardKeys.getString("VerifyWizardView.Message"));
- this.setTitle(WizardKeys.getString("VerifyWizardView.Title"));
- this.setWindowTitle(WizardKeys.getString("VerifyWizardView.WindowTitle"));
+ this.setMessage(WizardKeys.getString("VerifyWizardView.Message")); //$NON-NLS-1$
+ this.setTitle(WizardKeys.getString("VerifyWizardView.Title")); //$NON-NLS-1$
+ this.setWindowTitle(WizardKeys.getString("VerifyWizardView.WindowTitle")); //$NON-NLS-1$
}
private VManager getRulesManager() {
@@ -54,7 +59,7 @@
public void shellActivated(ShellEvent e) {
if(activated) return;
activated = true;
- action("Run");
+ action(COMMAND_RUN);
}
}
@@ -83,7 +88,7 @@
public void setObject(Object data) {
Properties p = findProperties(data);
if(p != null) {
- String key = p.getProperty("help");
+ String key = p.getProperty("help"); //$NON-NLS-1$
setHelpKey(key);
}
Object[] os = (Object[])data;
@@ -104,16 +109,19 @@
public void action(String command) {
- if("Run".equals(command)) {
+ if(COMMAND_RUN.equals(command)) {
if(task != null) task.removeTaskListener(listener);
taskListener.setModel(model);
task = getRulesManager().createTask(vobject);
taskListener.setTask(task);
task.addTaskListener(listener);
- progressMonitorPart.beginTask("Verify " + ((VObjectImpl)vobject).getModelObject().getPresentationString(), PROGRESS_TOTAL_SIZE);
+ progressMonitorPart.beginTask(
+ MessageFormat.format(Messages.VerifyWizardView_VerifyTask,
+ ((VObjectImpl)vobject).getModelObject().getPresentationString()),
+ PROGRESS_TOTAL_SIZE);
progressMonitorPart.worked(PROGRESS_INIT_SIZE);
task.start();
- } else if("Cancel".equals(command)) {
+ } else if(COMMAND_CANCEL.equals(command)) {
if(task != null) {
task.removeTaskListener(listener);
task.stop();
@@ -121,7 +129,7 @@
}
setCode(0);
dispose();
- } else if("Close".equals(command)) {
+ } else if(COMMAND_CLOSE.equals(command)) {
setCode(0);
dispose();
}
15 years, 6 months
JBoss Tools SVN: r16217 - in trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider: .settings and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: sflanigan
Date: 2009-06-26 03:21:07 -0400 (Fri, 26 Jun 2009)
New Revision: 16217
Added:
trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/.settings/
trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/.settings/org.eclipse.jdt.core.prefs
Modified:
trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/Activator.java
trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/EclipseSourceContainerType.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3557 Externalize English strings
Added: trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/.settings/org.eclipse.jdt.core.prefs 2009-06-26 07:21:07 UTC (rev 16217)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/Activator.java
===================================================================
--- trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/Activator.java 2009-06-26 07:16:16 UTC (rev 16216)
+++ trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/Activator.java 2009-06-26 07:21:07 UTC (rev 16217)
@@ -9,7 +9,7 @@
public class Activator extends AbstractUIPlugin {
// The plug-in ID
- public static final String PLUGIN_ID = "org.jboss.ide.eclipse.labs.pde.sourceprovider";
+ public static final String PLUGIN_ID = "org.jboss.ide.eclipse.labs.pde.sourceprovider"; //$NON-NLS-1$
// The shared instance
private static Activator plugin;
Modified: trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/EclipseSourceContainerType.java
===================================================================
--- trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/EclipseSourceContainerType.java 2009-06-26 07:16:16 UTC (rev 16216)
+++ trunk/labs/plugins/org.jboss.tools.labs.pde.sourceprovider/src/org/jboss/tools/labs/pde/sourceprovider/EclipseSourceContainerType.java 2009-06-26 07:21:07 UTC (rev 16217)
@@ -51,7 +51,7 @@
}
public static class EclipseSourceContainer extends AbstractSourceContainer {
- public static final String TYPE_ID = "org.jboss.tools.labs.pde.sourceprovider.eclipseSourceContainerType";
+ public static final String TYPE_ID = "org.jboss.tools.labs.pde.sourceprovider.eclipseSourceContainerType"; //$NON-NLS-1$
protected File root;
protected HashMap<String,ExternalArchiveSourceContainer> pathToContainer;
public EclipseSourceContainer(File f) {
@@ -66,7 +66,7 @@
for( int i = 0; i < kids.length; i++ ) {
if( kids[i].isDirectory()) {
search(kids[i]);
- } else if( kids[i].getName().endsWith("src.zip")) {
+ } else if( kids[i].getName().endsWith("src.zip")) { //$NON-NLS-1$
// add the match
pathToContainer.put(kids[i].toString(), new ExternalArchiveSourceContainer(kids[i].getAbsolutePath(), true));
}
@@ -108,7 +108,7 @@
String s = d.open();
if( s != null ) {
IPath p = new Path(s);
- if( p.append("plugins").toFile().exists()) {
+ if( p.append("plugins").toFile().exists()) { //$NON-NLS-1$
return new ISourceContainer[] {new EclipseSourceContainer(p.toFile())};
}
}
15 years, 6 months
JBoss Tools SVN: r16216 - trunk/as/tests/org.jboss.ide.eclipse.as.test/src/org/jboss/ide/eclipse/as/test/publishing.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2009-06-26 03:16:16 -0400 (Fri, 26 Jun 2009)
New Revision: 16216
Modified:
trunk/as/tests/org.jboss.ide.eclipse.as.test/src/org/jboss/ide/eclipse/as/test/publishing/JBIDE2512bTest.java
Log:
the failing method was an old @FailureExpected due to upstream bugs which have been fixed
Modified: trunk/as/tests/org.jboss.ide.eclipse.as.test/src/org/jboss/ide/eclipse/as/test/publishing/JBIDE2512bTest.java
===================================================================
--- trunk/as/tests/org.jboss.ide.eclipse.as.test/src/org/jboss/ide/eclipse/as/test/publishing/JBIDE2512bTest.java 2009-06-26 04:36:09 UTC (rev 16215)
+++ trunk/as/tests/org.jboss.ide.eclipse.as.test/src/org/jboss/ide/eclipse/as/test/publishing/JBIDE2512bTest.java 2009-06-26 07:16:16 UTC (rev 16216)
@@ -15,9 +15,6 @@
super(new String[] { "JBIDE2512b-ear", "JBIDE2512b-ejb"}, new String[] {null, null});
}
- /**
- * @FailureExpected This bug upstream means this failure is expected
- */
public void testJBIDE2512b() throws Exception {
IModuleArtifact[] earArtifacts = ServerPlugin.getModuleArtifacts(workspaceProject[0]);
assertNotNull(earArtifacts);
@@ -37,14 +34,8 @@
.loadAdapter(IEnterpriseApplication.class, null);
assertNotNull(enterpriseApplication);
- // Failure is expected here
- try {
- String uri = enterpriseApplication.getURI(ejbModule);
- assertNotNull(uri);
- assertFalse("JBIDE2512b-ejb.jar".equals(uri));
- } catch( AssertionFailedError afe) {
- return;
- }
- assertTrue(false);
+ String uri = enterpriseApplication.getURI(ejbModule);
+ assertNotNull("URI is null", uri);
+ assertTrue("URI does not have the expected value", "JBIDE2512b-ejb.jar".equals(uri));
}
}
15 years, 6 months
JBoss Tools SVN: r16215 - in trunk/maven/features: org.jboss.tools.maven.sdk.feature and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2009-06-26 00:36:09 -0400 (Fri, 26 Jun 2009)
New Revision: 16215
Added:
trunk/maven/features/org.jboss.tools.maven.sdk.feature/
trunk/maven/features/org.jboss.tools.maven.sdk.feature/.project
trunk/maven/features/org.jboss.tools.maven.sdk.feature/build.properties
trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.properties
trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.xml
trunk/maven/features/org.jboss.tools.maven.sdk.feature/license.html
Log:
add missing maven.sdk feature... again.
Added: trunk/maven/features/org.jboss.tools.maven.sdk.feature/.project
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.sdk.feature/.project (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.sdk.feature/.project 2009-06-26 04:36:09 UTC (rev 16215)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.jboss.tools.maven.feature</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.pde.FeatureBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.FeatureNature</nature>
+ </natures>
+</projectDescription>
Added: trunk/maven/features/org.jboss.tools.maven.sdk.feature/build.properties
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.sdk.feature/build.properties (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.sdk.feature/build.properties 2009-06-26 04:36:09 UTC (rev 16215)
@@ -0,0 +1,3 @@
+bin.includes = feature.xml,\
+ license.html,\
+ feature.properties
Added: trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.properties
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.properties (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.properties 2009-06-26 04:36:09 UTC (rev 16215)
@@ -0,0 +1,43 @@
+###############################################################################
+# Copyright (c) 2008 JBoss by Red Hat and others.
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License v1.0
+# which accompanies this distribution, and is available at
+# http://www.eclipse.org/legal/epl-v10.html
+#
+# Contributors:
+# JBoss by Red Hat - Initial implementation.
+##############################################################################
+# feature.properties
+# contains externalized strings for feature.xml
+# "%foo" in feature.xml corresponds to the key "foo" in this file
+# java.io.Properties file (ISO 8859-1 with "\" escapes)
+# This file should be translated.
+
+# "featureName" property - name of the feature
+featureName=JBoss Maven SDK Feature
+
+# "providerName" property - name of the company that provides the feature
+providerName=JBoss by Red Hat
+
+# "updateSiteName" property - label for the update site
+updateSiteName=JBossTools Update Site
+
+# "description" property - description of the feature
+description=JBoss Maven Integration
+
+# "copyright" property - text of the "Feature Update Copyright"
+copyright=Copyright (c) 2008 JBoss by Red Hat and others.\nAll rights reserved. This program and the accompanying materials\n
+are made available under the terms of the Eclipse Public License v1.0\nwhich accompanies this distribution, and is available at\nhttp\://www.eclipse.org/legal/epl-v10.html\n\nContributors\:\nJBoss by Red Hat - Initial implementation.\n
+ ############### end of copyright property ####################################
+
+# "licenseURL" property - URL of the "Feature License"
+# do not translate value - just change to point to a locale-specific HTML page
+licenseURL=license.html
+
+# START NON-TRANSLATABLE
+# "license" property - text of the "Feature Update License"
+# should be plain text version of license agreement pointed to be "licenseURL"
+license=ECLIPSE FOUNDATION SOFTWARE USER AGREEMENT\nMarch 17, 2005\n\nUsage Of Content\n\nTHE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\nOTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\nUSE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\nAGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\nNOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\nAGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\nAND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\nOR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\nTERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\nOF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\nBELOW, THEN YOU MAY NOT USE THE CONTENT.\n\nApplicable Licenses\n\nUnless otherwise indicated, all Content made available by the Eclipse Foundation\nis provided to you under the terms and conditio!
ns of the Eclipse Public\nLicense Version 1.0 ("EPL"). A copy of the EPL is provided with this\nContent and is also available at http\://www.eclipse.org/legal/epl-v10.html.\nFor purposes of the EPL, "Program" will mean the Content.\n\nContent includes, but is not limited to, source code, object code,\ndocumentation and other files maintained in the Eclipse.org CVS\nrepository ("Repository") in CVS modules ("Modules") and made available\nas downloadable archives ("Downloads").\n\n- Content may be structured and packaged into modules to facilitate delivering,\nextending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\nplug-in fragments ("Fragments"), and features ("Features").\n- Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java? ARchive)\nin a directory named "plugins".\n- A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\nEach Feature may be packaged as a sub-directory in a directory!
named "features".\nWithin a Feature, files named "feature.xml!
" may co
ntain a list of the names and version\nnumbers of the Plug-ins and/or Fragments associated with that Feature.\n- Features may also include other Features ("Included Features"). Within a Feature, files\nnamed "feature.xml" may contain a list of the names and version numbers of Included Features.\n\nFeatures may also include other Features ("Included Features"). Files named\n"feature.xml" may contain a list of the names and version numbers of\nIncluded Features.\n\nThe terms and conditions governing Plug-ins and Fragments should be\ncontained in files named "about.html" ("Abouts"). The terms and\nconditions governing Features and Included Features should be contained\nin files named "license.html" ("Feature Licenses"). Abouts and Feature\nLicenses may be located in any directory of a Download or Module\nincluding, but not limited to the following locations\:\n\n- The top-level (root) directory\n- Plug-in and Fragment directories\n- Inside Plug-ins and Fragments packaged as JAR!
s\n- Sub-directories of the directory named "src" of certain Plug-ins\n- Feature directories\n\nNote\: if a Feature made available by the Eclipse Foundation is installed using the\nEclipse Update Manager, you must agree to a license ("Feature Update\nLicense") during the installation process. If the Feature contains\nIncluded Features, the Feature Update License should either provide you\nwith the terms and conditions governing the Included Features or inform\nyou where you can locate them. Feature Update Licenses may be found in\nthe "license" property of files named "feature.properties". Such Abouts,\nFeature Licenses and Feature Update Licenses contain the terms and\nconditions (or references to such terms and conditions) that govern your\nuse of the associated Content in that directory.\n\nTHE ABOUTS, FEATURE LICENSES AND FEATURE UPDATE LICENSES MAY REFER\nTO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\nSOME OF THESE OTHER LICENSE AGREEMENTS MA!
Y INCLUDE (BUT ARE NOT LIMITED TO)\:\n\n- Common Public Licens!
e Versio
n 1.0 (available at http\://www.eclipse.org/legal/cpl-v10.html)\n- Apache Software License 1.1 (available at http\://www.apache.org/licenses/LICENSE)\n- Apache Software License 2.0 (available at http\://www.apache.org/licenses/LICENSE-2.0)\n- IBM Public License 1.0 (available at http\://oss.software.ibm.com/developerworks/opensource/license10.html)\n- Metro Link Public License 1.00 (available at http\://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n- Mozilla Public License Version 1.1 (available at http\://www.mozilla.org/MPL/MPL-1.1.html)\n\nIT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\nTO USE OF THE CONTENT. If no About, Feature License or Feature Update License\nis provided, please contact the Eclipse Foundation to determine what terms and conditions\ngovern that particular Content.\n\nCryptography\n\nContent may contain encryption software. The country in which you are\ncurrently may have restrictions on the import, posse!
ssion, and use,\nand/or re-export to another country, of encryption software. BEFORE\nusing any encryption software, please check the country's laws,\nregulations and policies concerning the import, possession, or use,\nand re-export of encryption software, to see if this is permitted.\n\nJava and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.\n
+# END NON-TRANSLATABLE
+########### end of license property ##########################################
Added: trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.xml
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.xml (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.sdk.feature/feature.xml 2009-06-26 04:36:09 UTC (rev 16215)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<feature
+ id="org.jboss.tools.maven.sdk.feature"
+ label="%featureName"
+ version="1.0.0.qualifier"
+ provider-name="%providerName">
+
+ <description>
+ %description
+ </description>
+
+ <copyright>
+ %copyright
+ </copyright>
+
+ <license url="%licenseURL">
+ %license
+ </license>
+
+ <url>
+ <update label="%updateSiteName" url="http://download.jboss.org/jbosstools/updates/stable"/>
+ </url>
+
+ <includes
+ id="org.jboss.tools.maven.feature" version="0.0.0"/>
+
+ <includes
+ id="org.jboss.tools.maven.source.feature" version="0.0.0"/>
+
+ <includes
+ id="org.jboss.tools.maven.seam.feature" version="0.0.0"/>
+
+ <includes
+ id="org.jboss.tools.maven.seam.source.feature" version="0.0.0"/>
+
+</feature>
Added: trunk/maven/features/org.jboss.tools.maven.sdk.feature/license.html
===================================================================
--- trunk/maven/features/org.jboss.tools.maven.sdk.feature/license.html (rev 0)
+++ trunk/maven/features/org.jboss.tools.maven.sdk.feature/license.html 2009-06-26 04:36:09 UTC (rev 16215)
@@ -0,0 +1,79 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<html>
+<head>
+<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
+<title>Eclipse.org Software User Agreement</title>
+</head>
+
+<body lang="EN-US" link=blue vlink=purple>
+<h2>Eclipse Foundation Software User Agreement</h2>
+<p>March 17, 2005</p>
+
+<h3>Usage Of Content</h3>
+
+<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
+ (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
+ CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
+ OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
+ NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
+ CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
+
+<h3>Applicable Licenses</h3>
+
+<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
+ ("EPL"). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+ For purposes of the EPL, "Program" will mean the Content.</p>
+
+<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository ("Repository") in CVS
+ modules ("Modules") and made available as downloadable archives ("Downloads").</p>
+
+<ul>
+ <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").</li>
+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>
+ <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins
+ and/or Fragments associated with that Feature.</li>
+ <li>Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.</li>
+</ul>
+
+<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and
+Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module
+including, but not limited to the following locations:</p>
+
+<ul>
+ <li>The top-level (root) directory</li>
+ <li>Plug-in and Fragment directories</li>
+ <li>Inside Plug-ins and Fragments packaged as JARs</li>
+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>
+ <li>Feature directories</li>
+</ul>
+
+<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license ("Feature Update License") during the
+installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
+inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature.
+Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
+that directory.</p>
+
+<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
+OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
+
+<ul>
+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
+</ul>
+
+<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
+contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
+
+<h3>Cryptography</h3>
+
+<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
+ another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
+ possession, or use, and re-export of encryption software, to see if this is permitted.</p>
+
+<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
+</body>
+</html>
15 years, 6 months