Skip to content

Commit

Permalink
Move setting of transfer handler for CSV button
Browse files Browse the repository at this point in the history
  • Loading branch information
techncl committed Nov 8, 2024
1 parent 88262a9 commit 18f91a6
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,7 @@ object CsvValidatorUi extends SimpleSwingApplication {
false
}

txtCsvFile.setTransferHandler(fileHandler)
final class FileDropHandler extends TransferHandler {
override def canImport(support: TransferHandler.TransferSupport): Boolean = support.getDataFlavors.exists(_.isFlavorJavaFileListType)

Expand Down Expand Up @@ -277,7 +278,7 @@ object CsvValidatorUi extends SimpleSwingApplication {
}
}
}
txtCsvFile.setTransferHandler(fileHandler)

private val csvFileChooser = new FileChooser(loadSettings match {
case Some(s) =>
s.lastCsvPath.toFile
Expand Down

0 comments on commit 18f91a6

Please sign in to comment.