kexi
KexiMacroView Class Reference
#include <keximacroview.h>

Detailed Description
The KexiMacroView implements KexiViewBase to provide a base KexiView instance for Macros.The KexiMacroDesignView and the KexiMacroTextView are inherited from this class.
Definition at line 42 of file keximacroview.h.
Public Slots | |
void | execute (QObject *sender=0) |
Public Member Functions | |
KexiMacroView (KexiMainWindow *mainwin, QWidget *parent,::KoMacro::Macro *const macro, const char *name=0) | |
virtual | ~KexiMacroView () |
KSharedPtr< KoMacro::Macro > | macro () const |
virtual bool | loadData () |
virtual KexiDB::SchemaData * | storeNewData (const KexiDB::SchemaData &sdata, bool &cancel) |
virtual tristate | storeData (bool dontAsk=false) |
Protected Member Functions | |
virtual tristate | beforeSwitchTo (int mode, bool &dontstore) |
virtual tristate | afterSwitchFrom (int mode) |
Constructor & Destructor Documentation
KexiMacroView::KexiMacroView | ( | KexiMainWindow * | mainwin, | |
QWidget * | parent, | |||
::KoMacro::Macro *const | macro, | |||
const char * | name = 0 | |||
) |
Constructor.
- Parameters:
-
mainwin The KexiMainWindow instance this KexiViewBase belongs to. parent The parent widget this widget should be displayed in. macro The KoMacro::Macro instance this view is for.
KexiMacroView::~KexiMacroView | ( | ) | [virtual] |
Member Function Documentation
KSharedPtr< KoMacro::Macro > KexiMacroView::macro | ( | ) | const |
bool KexiMacroView::loadData | ( | ) | [virtual] |
Load the data from XML source and fill the internally used KoMacro::Macro instance.
Reimplemented in KexiMacroDesignView, and KexiMacroTextView.
Definition at line 97 of file keximacroview.cpp.
KexiDB::SchemaData * KexiMacroView::storeNewData | ( | const KexiDB::SchemaData & | sdata, | |
bool & | cancel | |||
) | [virtual] |
Try to call storeData with new data we like to store.
On success the matching KexiDB::SchemaData is returned.
- Parameters:
-
sdata The source KexiDB::SchemaData instance. cancel Cancel on failure and don't try to clean possible temporary created data up.
- Returns:
- The matching KexiDB::SchemaData instance or NULL if storing failed.
Reimplemented from KexiViewBase.
Definition at line 129 of file keximacroview.cpp.
tristate KexiMacroView::storeData | ( | bool | dontAsk = false |
) | [virtual] |
Try to store the modified data in the already opened and currently used KexiDB::SchemaData instance.
Reimplemented from KexiViewBase.
Reimplemented in KexiMacroTextView.
Definition at line 151 of file keximacroview.cpp.
void KexiMacroView::execute | ( | QObject * | sender = 0 |
) | [slot] |
This slot will be invoked if Kexi's menuitem Data=>Execute got activated and will execute the Macro.
Definition at line 162 of file keximacroview.cpp.
tristate KexiMacroView::beforeSwitchTo | ( | int | mode, | |
bool & | dontstore | |||
) | [protected, virtual] |
Called by KexiDialogBase::switchToViewMode() right before dialog is switched to new mode.
- Parameters:
-
mode The viewmode to which should be switched. This could be either Kexi::DataViewMode, Kexi::DesignViewMode or Kexi::TextViewMode. donstore This call-by-reference boolean value defines if storeData should be called for the old but still selected viewmode. Set dontstore to true (it's false by default) if you want to avoid data storing.
- Returns:
- true if you accept or false if a error occupied and view shouldn't change. If there is no error but switching should be just cancelled (probably after showing some info messages), you need to return cancelled.
Reimplemented from KexiViewBase.
Definition at line 84 of file keximacroview.cpp.
tristate KexiMacroView::afterSwitchFrom | ( | int | mode | ) | [protected, virtual] |
Called by KexiDialogBase::switchToViewMode() right after dialog is switched to new mode.
- Parameters:
-
mode The viewmode to which we switched. This could be either Kexi::DataViewMode, Kexi::DesignViewMode or Kexi::TextViewMode.
- Returns:
- true if you accept or false if a error occupied and view shouldn't change. If there is no error but switching should be just cancelled (probably after showing some info messages), you need to return cancelled.
Reimplemented from KexiViewBase.
Definition at line 90 of file keximacroview.cpp.
The documentation for this class was generated from the following files: