Author: abelevich
Date: 2007-12-18 10:59:10 -0500 (Tue, 18 Dec 2007)
New Revision: 4898
Modified:
trunk/ui/drag-drop/src/main/java/org/richfaces/renderkit/DraggableRendererContributor.java
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-draggable.js
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-dropzone.js
Log:
fix cursors behavior
Modified:
trunk/ui/drag-drop/src/main/java/org/richfaces/renderkit/DraggableRendererContributor.java
===================================================================
---
trunk/ui/drag-drop/src/main/java/org/richfaces/renderkit/DraggableRendererContributor.java 2007-12-18
15:58:30 UTC (rev 4897)
+++
trunk/ui/drag-drop/src/main/java/org/richfaces/renderkit/DraggableRendererContributor.java 2007-12-18
15:59:10 UTC (rev 4898)
@@ -92,7 +92,9 @@
if(cursors != null){
String [] entries = cursors.split(",");
for (int i = 0; i < entries.length; i++) {
- cursorStyle.append("cursor: " + entries[i] + ";");
+ if (!entries[i].equals("")) {
+ cursorStyle.append("cursor: " + entries[i] + ";");
+ }
}
}
return cursorStyle.toString();
Modified:
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-draggable.js
===================================================================
---
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-draggable.js 2007-12-18
15:58:30 UTC (rev 4897)
+++
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-draggable.js 2007-12-18
15:59:10 UTC (rev 4898)
@@ -23,9 +23,7 @@
this.form = this.form.parentNode;
}
- if (this.options.grab || this.options.grabbing) {
- this.enableDraggableCursors();
- }
+ this.enableDraggableCursors(this.options.grab, this.options.grabbing);
},
getDnDDragParams: function() {
Modified:
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-dropzone.js
===================================================================
---
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-dropzone.js 2007-12-18
15:58:30 UTC (rev 4897)
+++
trunk/ui/drag-drop/src/main/resources/org/richfaces/renderkit/html/scripts/simple-dropzone.js 2007-12-18
15:59:10 UTC (rev 4898)
@@ -40,11 +40,8 @@
this.options = options || {};
+ this.enableDropzoneCursors(options.acceptCursor,options.rejectCursor);
- if (options.acceptCursor || options.rejectCursor) {
- this.enableDropzoneCursors();
- }
-
},
getDropzoneOptions: function() {
Show replies by date