  }
  
  bool FileInputType::canChangeFromAnotherType() const
-@@ -217,7 +217,7 @@ bool FileInputType::canChangeFromAnotherType() const
+@@ -217,7 +218,7 @@ bool FileInputType::canChangeFromAnotherType() const
      // field's value to something like /etc/passwd and then change it to a file input.
      // I don't think this would actually occur in WebKit, but this rule still may be
      // important for compatibility.

 }
 
 FileList* FileInputType::files()
@@ -247,7 +247,10 @@ bool FileInputType::getTypeSpecificValue(String& value)
     // decided to try to parse the value by looking for backslashes
     // (because that's what Windows file paths use). To be compatible
     // with that code, we make up a fake path for the file.

         readonly attribute Date lastModifiedDate;
 #endif
diff --git a/Source/WebCore/html/FileInputType.cpp b/Source/WebCore/html/FileInputType.cpp
index f7896ba..f16aa36 100644
--- a/Source/WebCore/html/FileInputType.cpp
+++ b/Source/WebCore/html/FileInputType.cpp
@@ -184,6 +184,7 @@ void FileInputType::handleDOMActivateEvent(Event* event)
         FileChooserSettings settings;
         HTMLInputElement* input = element();
 #if ENABLE(DIRECTORY_UPLOAD)
+        settings.directoryChooser = input->fastHasAttribute(nwdirectoryAttr);
         settings.allowsDirectoryUpload = input->fastHasAttribute(webkitdirectoryAttr);
         settings.allowsMultipleFiles = settings.allowsDirectoryUpload || input->fastHasAttribute(multipleAttr);
 #else
@@ -207,7 +208,7 @@ RenderObject* FileInputType::createRenderer(RenderArena* arena, RenderStyle*) co
 
 bool FileInputType::canSetStringValue() const
 {
