def _cleanup(self) -> None:
    self._stop_timer('update_candidates')
    self._stop_timer('update_buffer')
    if (self._vim.current.buffer.number == self._bufnr):
        self._cursor = self._vim.call('line', '.')
    self._vim.call('denite#filter#_close_filter_window')
    if (not self._context['has_preview_window']):
        self._vim.command('pclose!')
    for bufnr in self._vim.vars['denite#_previewed_buffers'].keys():
        if (not self._vim.call('win_findbuf', bufnr)):
            self._vim.command(('silent bdelete ' + str(bufnr)))
    self._vim.vars['denite#_previewed_buffers'] = {}
    self._vim.command('highlight! link CursorLine CursorLine')
    if (self._floating or self._filter_floating):
        self._vim.options['titlestring'] = self._titlestring
        self._vim.options['ruler'] = self._ruler
def _cleanup(self) -> None:
    self._stop_timer('update_candidates')
    self._stop_timer('update_buffer')
    if (self._vim.current.buffer.number == self._bufnr):
        self._cursor = self._vim.call('line', '.')
    self._vim.call('denite#filter#_close_filter_window')
    if (not self._context['has_preview_window']):
        self._vim.command('pclose!')
    for bufnr in self._vim.vars['denite#_previewed_buffers'].keys():
        if (not self._vim.call('win_findbuf', bufnr)):
            self._vim.command(('silent bdelete ' + str(bufnr)))
    self._vim.vars['denite#_previewed_buffers'] = {}
    self._vim.command('highlight! link CursorLine CursorLine')
    if (self._floating or self._filter_floating):
        self._vim.options['titlestring'] = self._titlestring
        self._vim.options['ruler'] = self._ruler