blob: 4053f871d2e1c6cc77f7516bd64da76a178d620a (
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
52
53
54
55
56
57
58
59
60
|
#include "core.h"
#include "codemodel.h"
#include "partcontroller.h"
#include "plugincontroller.h"
#include "toplevel.h"
#include "api.h"
API *API::s_instance = 0;
TDevMainWindow *API::mainWindow() const
{
return TopLevel::getInstance();
}
TDevPartController *API::partController() const
{
return PartController::getInstance();
}
TDevCore *API::core() const
{
return Core::getInstance();
}
CodeModel *API::codeModel() const
{
return m_classStore;
}
API *API::getInstance()
{
if (!s_instance)
s_instance = new API;
return s_instance;
}
API::API()
: TDevApi()
{
m_classStore = new CodeModel();
}
API::~API()
{
delete( m_classStore );
m_classStore = 0;
}
TDevPluginController * API::pluginController() const
{
return PluginController::getInstance();
}
|