def _start(self, sources: typing.List[typing.Any], context: UserContext) -> None:
    from denite.ui.map import do_map
    self._vim.command('silent! autocmd! denite')
    if re.search('\\[Command Line\\]$', self._vim.current.buffer.name):
        return
    resume = (self._initialized and context['resume'])
    if resume:
        update = ('immediately', 'immediately_1', 'cursor_pos', 'prev_winid', 'start_filter', 'quick_move')
        for key in update:
            self._context[key] = context[key]
        self._check_move_option()
        if self._check_do_option():
            return
        self._init_buffer()
        if context['refresh']:
            self.redraw()
        self._move_to_pos(self._cursor)
    else:
        if (self._context != context):
            self._context.clear()
            self._context.update(context)
        self._context['sources'] = sources
        self._context['is_redraw'] = False
        self._is_multi = (len(sources) > 1)
        if (not sources):
            error(self._vim, 'Empty sources')
            return
        self._init_denite()
        self._gather_candidates()
        self._update_candidates()
        self._init_cursor()
        self._check_move_option()
        if self._check_do_option():
            return
        self._init_buffer()
    self._update_displayed_texts()
    self._update_buffer()
    self._move_to_pos(self._cursor)
    if (self._context['quick_move'] and do_map(self, 'quick_move', [])):
        return
    if self._context['start_filter']:
        do_map(self, 'open_filter_buffer', [])
def _start(self, sources: typing.List[typing.Any], context: UserContext) -> None:
    from denite.ui.map import do_map
    self._vim.command('silent! autocmd! denite')
    if re.search('\\[Command Line\\]$', self._vim.current.buffer.name):
        return
    resume = (self._initialized and context['resume'])
    if resume:
        update = ('immediately', 'immediately_1', 'cursor_pos', 'prev_winid', 'start_filter', 'quick_move')
        for key in update:
            self._context[key] = context[key]
        self._check_move_option()
        if self._check_do_option():
            return
        self._init_buffer()
        if context['refresh']:
            self.redraw()
        self._move_to_pos(self._cursor)
    else:
        if (self._context != context):
            self._context.clear()
            self._context.update(context)
        self._context['sources'] = sources
        self._context['is_redraw'] = False
        self._is_multi = (len(sources) > 1)
        if (not sources):
            error(self._vim, 'Empty sources')
            return
        self._init_denite()
        self._gather_candidates()
        self._update_candidates()
        self._init_cursor()
        self._check_move_option()
        if self._check_do_option():
            return
        self._init_buffer()
    self._update_displayed_texts()
    self._update_buffer()
    self._move_to_pos(self._cursor)
    if (self._context['quick_move'] and do_map(self, 'quick_move', [])):
        return
    if self._context['start_filter']:
        do_map(self, 'open_filter_buffer', [])