       if @isActive()
         @selectItemForRow(@findRowForNormalItem(0, 'next'))
       @setModifiedState(false)
-      unless @hasItems()
+      unless @hasNormalItem()
         @selectedItem = null
         @previouslySelectedItem = null
         @rowMarker?.destroy()

      @vmpActivateInsertMode() if @vmpIsNormalMode()

  observeStopChangingActivePaneItem: ->
    atom.workspace.onDidStopChangingActivePaneItem (item) =>
      @syncSubcriptions?.dispose()
      return if item is @editor

      @rowMarker?.destroy()
      # Only sync to text-editor which meet following conditions
      # - Not narrow-editor
      # - Contained in different pane from narrow-editor is contained.
      if (not isTextEditor(item)) or isNarrowEditor(item) or (paneForItem(item) is @getPane())
        return

      if @provider.boundToEditor
        if @provider.editor is item

      @moveToSelectedItem(ignoreCursorMove: false)
      return

    # Fallback to selected item in case there is only single filePath in all items
    # But want to move to item from query-prompt.
    if item = @findDifferentFileItem(direction) ? @getSelectedItem()
      @selectItem(item)
      @moveToSelectedItem(ignoreCursorMove: false)
