summaryrefslogtreecommitdiffstats
path: root/interfaces/ktexteditor/codecompletioninterface.cpp
blob: 51250d2d63751d928754cfbbb7468e32447d12b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51

#include "codecompletioninterface.h"
#include "view.h"

using namespace KTextEditor;

namespace KTextEditor
{
  class PrivateCodeCompletionInterface
  {
    public:
      PrivateCodeCompletionInterface() {}
      ~PrivateCodeCompletionInterface(){}

  };
}

unsigned int CodeCompletionInterface::globalCodeCompletionInterfaceNumber = 0;

CodeCompletionInterface::CodeCompletionInterface()
{
  globalCodeCompletionInterfaceNumber++;
  myCodeCompletionInterfaceNumber = globalCodeCompletionInterfaceNumber++;

  d = new PrivateCodeCompletionInterface();
}

CodeCompletionInterface::~CodeCompletionInterface()
{
  delete d;
}

unsigned int CodeCompletionInterface::codeCompletionInterfaceNumber () const
{
  return myCodeCompletionInterfaceNumber;
}

void CodeCompletionInterface::setCodeCompletionInterfaceDCOPSuffix (const QCString &/*suffix*/)
{
  //d->interface->setObjId ("CodeCompletionInterface#"+suffix);
}

CodeCompletionInterface *KTextEditor::codeCompletionInterface (View *view)
{                
  if (!view)
    return 0;

  return static_cast<CodeCompletionInterface*>(view->qt_cast("KTextEditor::CodeCompletionInterface"));
}