 class NFinderItem extends JTreeItemView
-
-  JView.mixin @prototype
 
   constructor:(options = {},data)->
 

    @on "ItemBeingDeleted", =>
      data.removeLocalFileInfo()

    @on "viewAppended", =>
      fileInfo = data.getLocalFileInfo()
      if fileInfo.lastUploadedChunk
        {lastUploadedChunk, totalChunks} = fileInfo
        data.removeLocalFileInfo() if lastUploadedChunk is totalChunks
        @showProgressView 100 * lastUploadedChunk / totalChunks

  getChildConstructor: (type) ->
    switch type

    then @setClass "progress"
    else @utils.wait 1000, =>
      @resetView()
  viewAppended:->

    @addSubView @childView

    file = @getData()
    fileInfo = file.getLocalFileInfo()

    if fileInfo.lastUploadedChunk

      {lastUploadedChunk, totalChunks} = fileInfo

      if lastUploadedChunk is totalChunks
        file.removeLocalFileInfo()

      @showProgressView
        percentage : 100 * lastUploadedChunk / totalChunks
