From 9931e0888b2419326ae10ebbfae532261c5c125f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20Ko=C4=8D=C3=AD?= Date: Thu, 30 Jun 2016 16:11:56 +0200 Subject: Fix submodules --- vim/bundle/YouCompleteMe | 1 + .../python/ycm/client/omni_completion_request.py | 71 ---------------------- 2 files changed, 1 insertion(+), 71 deletions(-) create mode 160000 vim/bundle/YouCompleteMe delete mode 100644 vim/bundle/YouCompleteMe/python/ycm/client/omni_completion_request.py (limited to 'vim/bundle/YouCompleteMe/python/ycm/client/omni_completion_request.py') diff --git a/vim/bundle/YouCompleteMe b/vim/bundle/YouCompleteMe new file mode 160000 index 0000000..0de1c0c --- /dev/null +++ b/vim/bundle/YouCompleteMe @@ -0,0 +1 @@ +Subproject commit 0de1c0c9bb13ce82172b472c676035cd47cf6a6a diff --git a/vim/bundle/YouCompleteMe/python/ycm/client/omni_completion_request.py b/vim/bundle/YouCompleteMe/python/ycm/client/omni_completion_request.py deleted file mode 100644 index 2bcb291..0000000 --- a/vim/bundle/YouCompleteMe/python/ycm/client/omni_completion_request.py +++ /dev/null @@ -1,71 +0,0 @@ -# Copyright (C) 2013 Google Inc. -# -# This file is part of YouCompleteMe. -# -# YouCompleteMe is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# YouCompleteMe is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with YouCompleteMe. If not, see . - -from __future__ import unicode_literals -from __future__ import print_function -from __future__ import division -from __future__ import absolute_import -from future import standard_library -standard_library.install_aliases() -from builtins import * # noqa - -from ycm.client.completion_request import CompletionRequest - - -class OmniCompletionRequest( CompletionRequest ): - def __init__( self, omni_completer, request_data ): - super( OmniCompletionRequest, self ).__init__( request_data ) - self._omni_completer = omni_completer - - - def Start( self ): - self._results = self._omni_completer.ComputeCandidates( self.request_data ) - - - def Done( self ): - return True - - - def RawResponse( self ): - return _ConvertVimDatasToCompletionDatas( self._results ) - - - def Response( self ): - return self._results - - -def ConvertVimDataToCompletionData( vim_data ): - # see :h complete-items for a description of the dictionary fields - completion_data = {} - - if 'word' in vim_data: - completion_data[ 'insertion_text' ] = vim_data[ 'word' ] - if 'abbr' in vim_data: - completion_data[ 'menu_text' ] = vim_data[ 'abbr' ] - if 'menu' in vim_data: - completion_data[ 'extra_menu_info' ] = vim_data[ 'menu' ] - if 'kind' in vim_data: - completion_data[ 'kind' ] = [ vim_data[ 'kind' ] ] - if 'info' in vim_data: - completion_data[ 'detailed_info' ] = vim_data[ 'info' ] - - return completion_data - - -def _ConvertVimDatasToCompletionDatas( response_data ): - return [ ConvertVimDataToCompletionData( x ) - for x in response_data ] -- cgit v1.2.3