kexi

KexiBrowser Class Reference

#include <kexibrowser.h>

List of all members.


Detailed Description

The Main Kexi navigator widget.

Definition at line 51 of file kexibrowser.h.


Public Types

enum  Features {
  Writable = 1, ContextMenus = 2, Toolbar = 4, SingleClickOpensItemOptionEnabled = 8,
  DefaultFeatures
}

Public Slots

KexiBrowserItemaddGroup (KexiPart::Info &info)
KexiBrowserItemaddItem (KexiPart::Item &item)
void slotRemoveItem (const KexiPart::Item &item)
virtual void setFocus ()
void updateItemName (KexiPart::Item &item, bool dirty)
void selectItem (KexiPart::Item &item)
void clearSelection ()
void clear ()
void setReadOnly (bool set)
bool isReadOnly () const

Signals

void openItem (KexiPart::Item *, int viewMode)
void openOrActivateItem (KexiPart::Item *, int viewMode)
void newItem (KexiPart::Info *)
void removeItem (KexiPart::Item *)
void renameItem (KexiPart::Item *item, const QString &_newName, bool &succes)
void selectionChanged (KexiPart::Item *item)
void executeItem (KexiPart::Item *)
void exportItemAsDataTable (KexiPart::Item *)
void printItem (KexiPart::Item *)
void pageSetupForItem (KexiPart::Item *)

Public Member Functions

 KexiBrowser (QWidget *parent, KexiMainWindow *mainWin, int features=DefaultFeatures)
virtual ~KexiBrowser ()
void setProject (KexiProject *prj, const QString &itemsMimeType=QString::null, QString *partManagerErrorMessages=0)
QString itemsMimeType () const
KexiPart::ItemselectedPartItem () const
void installEventFilter (const QObject *filterObj)
virtual bool eventFilter (QObject *o, QEvent *e)
bool actionEnabled (const QCString &actionName) const

Protected Slots

void slotContextMenu (KListView *, QListViewItem *i, const QPoint &point)
void slotExecuteItem (QListViewItem *item)
void slotSelectionChanged (QListViewItem *i)
void slotSettingsChanged (int)
void slotNewObjectPopupAboutToShow ()
void slotNewObject ()
void slotOpenObject ()
void slotDesignObject ()
void slotEditTextObject ()
void slotRemove ()
void slotCut ()
void slotCopy ()
void slotPaste ()
void slotRename ()
void slotExecuteObject ()
void slotExportAsDataTable ()
void slotPrintItem ()
void slotPageSetupForItem ()

Protected Member Functions

void itemRenameDone ()
KexiBrowserItemaddItem (KexiPart::Item &item, KexiBrowserItem *parent, KexiPart::Info *info)

Protected Attributes

KexiMainWindowm_mainWin
int m_features
KexiBrowserListView * m_list
KActionCollection * m_actions
QAsciiDict< KexiBrowserItemm_baseItems
QIntDict< KexiBrowserItemm_normalItems
KPopupMenu * m_itemPopup
KPopupMenu * m_partPopup
KAction * m_deleteAction
KAction * m_renameAction
KAction * m_newObjectAction
KAction * m_openAction
KAction * m_designAction
KAction * m_editTextAction
KAction * m_executeAction
KAction * m_dataExportAction
KAction * m_printAction
KAction * m_pageSetupAction
KActionMenu * m_exportActionMenu
KPopupMenu * m_newObjectPopup
int m_itemPopupTitle_id
int m_partPopupTitle_id
int m_openAction_id
int m_designAction_id
int m_editTextAction_id
int m_executeAction_id
int m_exportActionMenu_id
int m_exportActionMenu_id_sep
int m_printAction_id
int m_pageSetupAction_id
int m_pageSetupAction_id_sep
KexiPart::Partm_prevSelectedPart
KToolBar * m_toolbar
KexiSmallToolButtonm_newObjectToolButton
KexiSmallToolButtonm_deleteObjectToolButton
QString m_itemsMimeType
bool m_singleClick: 1
bool m_readOnly: 1

Member Enumeration Documentation

Enumerator:
Writable  the browser supports actions that modify the project (e.g. delete, rename)
ContextMenus  the browser supports context menu
Toolbar  the browser displays
SingleClickOpensItemOptionEnabled  enables "SingleClickOpensItem" option
DefaultFeatures  the default

Definition at line 56 of file kexibrowser.h.


Constructor & Destructor Documentation

KexiBrowser::KexiBrowser ( QWidget *  parent,
KexiMainWindow mainWin,
int  features = DefaultFeatures 
)

Definition at line 71 of file kexibrowser.cpp.


Member Function Documentation

void KexiBrowser::setProject ( KexiProject prj,
const QString &  itemsMimeType = QString::null,
QString *  partManagerErrorMessages = 0 
)

Sets project prj for this browser. If partManagerErrorMessages is not NULL it will be set to error message if there's a problem with loading any KexiPart. If itemsMimeType is empty (the default), items of all mime types are displayed, items for only one mime type are displayed. In the latter case, no group (parent) items are displayed. Previous items are removed.

Todo:
FUTURE - don't do that when DESIGN MODE is OFF

Todo:
FUTURE - don't do that when DESIGN MODE is OFF

Definition at line 291 of file kexibrowser.cpp.

QString KexiBrowser::itemsMimeType (  )  const

Returns:
items' mime type previously set by setProject. Returns empty string if setProject() was not executed yet or itemsMimeType argument of setProject() was empty (i.e. all mime types are displayed).

Definition at line 354 of file kexibrowser.cpp.

void KexiBrowser::setReadOnly ( bool  set  )  [slot]

Sets by main window to disable actions that may try to modify the project.

Does not disable actions like opening objects.

Definition at line 828 of file kexibrowser.cpp.

void KexiBrowser::openOrActivateItem ( KexiPart::Item ,
int  viewMode 
) [signal]

this signal is emmited when user double clicked (or single -depending on settings) or pressed return ky on the part item. This signal differs from openItem() signal in that if the object is already opened in view mode other than viewMode, the mode is not changed.

void KexiBrowser::slotNewObjectPopupAboutToShow (  )  [protected, slot]

Definition at line 758 of file kexibrowser.cpp.


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys