kexi

kexiscriptdesignview.h
1/* This file is part of the KDE project
2 Copyright (C) 2003 Lucijan Busch <lucijan@gmx.at>
3 Copyright (C) 2004-2005 Jaroslaw Staniek <js@iidea.pl>
4 Copyright (C) 2005 Cedric Pasteur <cedric.pasteur@free.fr>
5 Copyright (C) 2005 Sebastian Sauer <mail@dipe.org>
6
7 This program is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with this program; see the file COPYING. If not, write to
19 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 * Boston, MA 02110-1301, USA.
21*/
22
23#ifndef KEXISCRIPTDESIGNVIEW_H
24#define KEXISCRIPTDESIGNVIEW_H
25
26#include <kexiviewbase.h>
27
28#include <koproperty/set.h>
29#include <koproperty/property.h>
30
31// Forward declarations.
32class KexiScriptContainer;
34class KexiScriptDesignViewPrivate;
35
36namespace Kross { namespace Api {
37 class ScriptAction;
38}}
39
46class KexiScriptDesignView : public KexiViewBase
47{
48 TQ_OBJECT
49
50
51 public:
52
56 KexiScriptDesignView(KexiMainWindow *mainWin, TQWidget *parent, Kross::Api::ScriptAction* scriptaction);
57
61 virtual ~KexiScriptDesignView();
62
67 Kross::Api::ScriptAction* scriptAction() const;
68
72 virtual KoProperty::Set* propertySet();
73
84 virtual KexiDB::SchemaData* storeNewData(const KexiDB::SchemaData& sdata, bool &cancel);
85
90 virtual tristate storeData(bool dontAsk = false);
91
92 private slots:
93
97 void initialize();
98
102 void slotPropertyChanged(KoProperty::Set& set, KoProperty::Property& property);
103
108 void updateProperties();
109
113 void execute();
114
115 private:
116 KexiScriptDesignViewPrivate* d;
117
122 bool loadData();
123};
124
125#endif
Kexi's main window interface This interface is implemented by KexiMainWindowImpl class.
virtual KexiDB::SchemaData * storeNewData(const KexiDB::SchemaData &sdata, bool &cancel)
Try to call storeData with new data we like to store.
virtual KoProperty::Set * propertySet()
KexiScriptDesignView(KexiMainWindow *mainWin, TQWidget *parent, Kross::Api::ScriptAction *scriptaction)
Constructor.
virtual tristate storeData(bool dontAsk=false)
Try to store the modified data in the already opened and currently used KexiDB::SchemaData instance.
Kross::Api::ScriptAction * scriptAction() const
virtual ~KexiScriptDesignView()
Destructor.
The KexiEditor class embeds text editor for editing scripting code.
KexiMainWindow * mainWin() const
3-state logical type with three values: true, false and cancelled and convenient operators.
Definition tristate.h:100