[jbosstools-commits] JBoss Tools SVN: r22852 - in trunk/jst/plugins/org.jboss.tools.jst.css: src/org/jboss/tools/jst/css/common and 1 other directory.
jbosstools-commits at lists.jboss.org
jbosstools-commits at lists.jboss.org
Thu Jun 17 07:45:01 EDT 2010
Author: yzhishko
Date: 2010-06-17 07:45:01 -0400 (Thu, 17 Jun 2010)
New Revision: 22852
Modified:
trunk/jst/plugins/org.jboss.tools.jst.css/META-INF/MANIFEST.MF
trunk/jst/plugins/org.jboss.tools.jst.css/src/org/jboss/tools/jst/css/common/CSSStyleListener.java
Log:
https://jira.jboss.org/browse/JBIDE-5979 - fixed
Modified: trunk/jst/plugins/org.jboss.tools.jst.css/META-INF/MANIFEST.MF
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.css/META-INF/MANIFEST.MF 2010-06-17 11:37:43 UTC (rev 22851)
+++ trunk/jst/plugins/org.jboss.tools.jst.css/META-INF/MANIFEST.MF 2010-06-17 11:45:01 UTC (rev 22852)
@@ -15,7 +15,8 @@
org.eclipse.debug.ui,
org.eclipse.wst.sse.core,
org.eclipse.jface.text,
- org.eclipse.wst.xml.core
+ org.eclipse.wst.xml.core,
+ org.eclipse.wst.sse.ui
Bundle-RequiredExecutionEnvironment: J2SE-1.5
Bundle-ActivationPolicy: lazy
Export-Package: org.jboss.tools.jst.css,
Modified: trunk/jst/plugins/org.jboss.tools.jst.css/src/org/jboss/tools/jst/css/common/CSSStyleListener.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.css/src/org/jboss/tools/jst/css/common/CSSStyleListener.java 2010-06-17 11:37:43 UTC (rev 22851)
+++ trunk/jst/plugins/org.jboss.tools.jst.css/src/org/jboss/tools/jst/css/common/CSSStyleListener.java 2010-06-17 11:45:01 UTC (rev 22852)
@@ -20,9 +20,13 @@
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.views.contentoutline.ContentOutline;
+import org.eclipse.ui.views.properties.IPropertySheetPage;
import org.eclipse.wst.css.core.internal.provisional.document.ICSSStyleDeclItem;
+import org.eclipse.wst.css.core.internal.provisional.document.ICSSStyleDeclaration;
import org.eclipse.wst.sse.core.internal.provisional.INodeAdapter;
import org.eclipse.wst.sse.core.internal.provisional.INodeNotifier;
+import org.eclipse.wst.sse.ui.StructuredTextEditor;
+import org.eclipse.wst.sse.ui.internal.properties.ConfigurablePropertySheetPage;
import org.jboss.tools.jst.css.CssPlugin;
@SuppressWarnings("restriction")
@@ -150,6 +154,17 @@
public void notifyChanged(INodeNotifier notifier, int eventType,
Object changedFeature, Object oldValue, Object newValue, int pos) {
+ /*
+ * Fixed by yzhishko. See https://jira.jboss.org/jira/browse/JBIDE-.
+ */
+ IEditorPart editorPart = PlatformUI.getWorkbench()
+ .getActiveWorkbenchWindow().getActivePage().getActiveEditor();
+ StructuredTextEditor structuredTextEditor = (StructuredTextEditor) editorPart;
+ Object page = structuredTextEditor.getAdapter(IPropertySheetPage.class);
+ if (page instanceof ConfigurablePropertySheetPage) {
+ ((ConfigurablePropertySheetPage) page).refresh();
+ }
+
clearListeners(newValue);
clearListeners(oldValue);
Object[] array = listeners.getListeners();
@@ -166,21 +181,21 @@
}
}
-
+
/*
* Fixed by yzhishko. See https://jira.jboss.org/jira/browse/JBIDE-5954.
*/
- private void clearListeners(Object node){
+ private void clearListeners(Object node) {
if (!(node instanceof ICSSStyleDeclItem)) {
return;
}
if (!(node instanceof INodeNotifier)) {
return;
}
- ((INodeNotifier)node).removeAdapter(this);
- ((INodeNotifier)node).addAdapter(this);
+ ((INodeNotifier) node).removeAdapter(this);
+ ((INodeNotifier) node).addAdapter(this);
}
-
+
public void partActivated(IWorkbenchPart part) {
currentPart = part;
Object[] array = listeners.getListeners();
More information about the jbosstools-commits
mailing list