kexi

kexiformeventhandler.h
1/* This file is part of the KDE project
2 Copyright (C) 2005-2006 Jaroslaw Staniek <js@iidea.pl>
3
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public
6 License as published by the Free Software Foundation; either
7 version 2 of the License, or (at your option) any later version.
8
9 This library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Library General Public License for more details.
13
14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
18*/
19
20#ifndef KEXIFORMEVENTHANDLER_H
21#define KEXIFORMEVENTHANDLER_H
22
23#include <tqwidget.h>
24#include <tdeaction.h>
25
26class KexiMainWindow;
27namespace KexiPart {
28 class Info;
29}
30
32
39class KEXIFORMUTILS_EXPORT KexiFormEventHandler
40{
41 public:
42 KexiFormEventHandler();
43 virtual ~KexiFormEventHandler();
44
50 void setMainWidgetForEventHandling(KexiMainWindow *mainWin, TQWidget* mainWidget);
51
52 protected:
53 TQWidget *m_mainWidget;
54};
55
57class KEXIFORMUTILS_EXPORT KexiFormEventAction : public TDEAction
58{
59 public:
61 class KEXIFORMUTILS_EXPORT ActionData
62 {
63 public:
64 ActionData();
65
75 KexiPart::Info* decodeString(TQString& actionType, TQString& actionArg, bool& ok) const;
76
78 bool isEmpty() const;
79
80 TQString string;
81
82 TQString option;
85 };
86
87 KexiFormEventAction(KexiMainWindow *mainWin, TQObject* parent, const TQString& actionName,
88 const TQString& objectName, const TQString& actionOption);
89 virtual ~KexiFormEventAction();
90
91 public slots:
94 virtual void activate();
95
96 private:
97 KexiMainWindow *m_mainWin;
98 TQString m_actionName, m_objectName, m_actionOption;
99};
100
101#endif
KexiPart::Info * decodeString(TQString &actionType, TQString &actionArg, bool &ok) const
TQString string
action string with prefix, like "tdeaction:edit_copy" or "table:<tableName>"
void setMainWidgetForEventHandling(KexiMainWindow *mainWin, TQWidget *mainWidget)
Kexi's main window interface This interface is implemented by KexiMainWindowImpl class.
Information about a Kexi Part (plugin).