Author: andrei_exadel
Date: 2008-03-25 13:56:52 -0400 (Tue, 25 Mar 2008)
New Revision: 7224
Modified:
trunk/ui/fileUpload/src/main/java/org/richfaces/component/UIFileUpload.java
trunk/ui/fileUpload/src/main/java/org/richfaces/renderkit/FileUploadRendererBase.java
trunk/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/js/FileUpload.js
trunk/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx
Log:
roll back
Modified: trunk/ui/fileUpload/src/main/java/org/richfaces/component/UIFileUpload.java
===================================================================
--- trunk/ui/fileUpload/src/main/java/org/richfaces/component/UIFileUpload.java 2008-03-25
17:56:45 UTC (rev 7223)
+++ trunk/ui/fileUpload/src/main/java/org/richfaces/component/UIFileUpload.java 2008-03-25
17:56:52 UTC (rev 7224)
@@ -50,8 +50,6 @@
private String localContentType;
private String localFileName;
-
- private String fileName;
private Integer localFileSize;
@@ -81,18 +79,6 @@
return localFileName;
}
- public String getFileName() {
- return fileName;
- }
-
-
-
- public void setFileName(String fileName) {
- this.fileName = fileName;
- }
-
-
-
public void setLocalFileName(String localFileName) {
this.localFileName = localFileName;
}
Modified:
trunk/ui/fileUpload/src/main/java/org/richfaces/renderkit/FileUploadRendererBase.java
===================================================================
---
trunk/ui/fileUpload/src/main/java/org/richfaces/renderkit/FileUploadRendererBase.java 2008-03-25
17:56:45 UTC (rev 7223)
+++
trunk/ui/fileUpload/src/main/java/org/richfaces/renderkit/FileUploadRendererBase.java 2008-03-25
17:56:52 UTC (rev 7224)
@@ -112,7 +112,6 @@
.getSession(false);
String uid = request.getParameter(Filter.UPLOAD_FILES_ID);
String id = request.getParameter("id");
- String fullName = request.getParameter(clientId + ":fileName");
decreaseFileCounter(session, id);
Map<String, MultipartRequest> map = (Map<String, MultipartRequest>)
session
.getAttribute(Filter.REQUESTS_SESSIONS_BEAN_NAME);
@@ -122,8 +121,7 @@
clientId = clientId + ":file";
String fileName = multipartRequest.getFileName(clientId);
Object file = multipartRequest.getFile(clientId);
- fileUpload.setLocalFileName(fullName);
- fileUpload.setFileName(fileName);
+ fileUpload.setLocalFileName(fileName);
onUploadComplete(context, file, fileUpload);
}
@@ -354,7 +352,7 @@
Object file) {
ValueExpression data = fileUpload
.getValueExpression(_FILES_UPLOADED_ATTRIBUTE_NAME);
- UploadItem item = new UploadItem(fileUpload.getFileName(),
fileUpload.getLocalFileName(),file);
+ UploadItem item = new UploadItem(fileUpload.getLocalFileName(),file);
if (data != null) {
if (data.getValue(context.getELContext()) instanceof Collection) {
Collection collection = (Collection) data.getValue(context
Modified:
trunk/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/js/FileUpload.js
===================================================================
---
trunk/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/js/FileUpload.js 2008-03-25
17:56:45 UTC (rev 7223)
+++
trunk/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/js/FileUpload.js 2008-03-25
17:56:52 UTC (rev 7224)
@@ -394,7 +394,6 @@
this.labelMarkup = label;
this.disabled = disabled;
- this.fileNameElement = $(this.id + ":fileName");
this.element.component = this;
this.acceptedTypes = acceptedTypes;
@@ -790,7 +789,6 @@
this.clear(this.activeEntry);
}
this.activeEntry = null;
- this.fileNameElement.value = '';
this.deleteFrame();
},
@@ -951,7 +949,6 @@
function (state) {
this.updateViewState(state);
}.bind(this));
- this.fileNameElement.value = entryInput.value;
parentForm.submit();
}
Modified: trunk/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx
===================================================================
--- trunk/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx 2008-03-25
17:56:45 UTC (rev 7223)
+++ trunk/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx 2008-03-25
17:56:52 UTC (rev 7224)
@@ -67,8 +67,6 @@
]]>
</jsp:scriptlet>
</span>
-
- <input type="hidden" name="#{clientId}:fileName"
style="display: none;" id="#{clientId}:fileName"/>
<table class="upload_toolbar_decor">
<tr>
<td>
Show replies by date