kexi
KexiConnSelectorWidget Class Reference
#include <KexiConnSelector.h>
Detailed Description
Widget that allows to select a database connection (without choosing database itself)
Definition at line 55 of file KexiConnSelector.h.
Public Types | |
FileBased = 1 | |
ServerBased = 2 | |
enum | ConnType { FileBased = 1, ServerBased = 2 } |
Public Slots | |
void | showSimpleConn () |
void | showAdvancedConn () |
virtual void | setFocus () |
void | hideHelpers () |
void | hideConnectonIcon () |
Signals | |
void | connectionItemExecuted (ConnectionDataLVItem *item) |
void | connectionItemHighlighted (ConnectionDataLVItem *item) |
Public Member Functions | |
KexiConnSelectorWidget (KexiDBConnectionSet &conn_set, const QString &startDirOrVariable, QWidget *parent=0, const char *name=0) | |
virtual | ~KexiConnSelectorWidget () |
int | selectedConnectionType () const |
KexiDB::ConnectionData * | selectedConnectionData () const |
QString | selectedFileName () |
void | setSelectedFileName (const QString &fileName) |
QListView * | connectionsList () const |
void | setConfirmOverwrites (bool set) |
bool | confirmOverwrites () const |
Public Attributes | |
KexiConnSelectorBase * | m_remote |
KexiStartupFileDialog * | m_fileDlg |
Protected Slots | |
void | slotConnectionItemExecuted (QListViewItem *item) |
void | slotRemoteAddBtnClicked () |
void | slotRemoteEditBtnClicked () |
void | slotRemoteRemoveBtnClicked () |
void | slotConnectionSelectionChanged () |
void | slotPrjTypeSelected (int id) |
Constructor & Destructor Documentation
KexiConnSelectorWidget::KexiConnSelectorWidget | ( | KexiDBConnectionSet & | conn_set, | |
const QString & | startDirOrVariable, | |||
QWidget * | parent = 0 , |
|||
const char * | name = 0 | |||
) |
Constructs a KexiConnSelector which contain conn_set as connection set. conn_set can be altered, because Add/Edit/Remove buttons are available to users. startDirOrVariable can be provided to specify a start dir for file browser (it can also contain a configuration variable name with ":" prefix as described in KRecentDirs documentation).
Definition at line 103 of file KexiConnSelector.cpp.
Member Function Documentation
void KexiConnSelectorWidget::hideHelpers | ( | ) | [slot] |
Hides helpers on the server based connection page (sometimes it's convenient not to have these):
- "Select existing database server's connection..." (label at the top)
- "Click "Back" button" (label at the bottom)
- "Back" button itself
Definition at line 336 of file KexiConnSelector.cpp.
KexiDB::ConnectionData * KexiConnSelectorWidget::selectedConnectionData | ( | ) | const |
- Returns:
- data of selected connection, if server-based connection was selected. Returns NULL if no selection has been made or file-based connection has been selected.
- See also:
- selectedConnectionType()
Definition at line 272 of file KexiConnSelector.cpp.
int KexiConnSelectorWidget::selectedConnectionType | ( | ) | const |
After accepting this dialog this method returns wherher user selected file- or server- based connection (ConnType enum).
Definition at line 252 of file KexiConnSelector.cpp.
QString KexiConnSelectorWidget::selectedFileName | ( | ) |
- Returns:
- the name of database file, if file-based connection was selected. Returns null string if no selection has been made or server-based connection has been selected.
- See also:
- selectedConnectionType()
Definition at line 280 of file KexiConnSelector.cpp.
void KexiConnSelectorWidget::setConfirmOverwrites | ( | bool | set | ) |
If true, user will be asked to accept overwriting existing project. This is true by default.
Definition at line 350 of file KexiConnSelector.cpp.
void KexiConnSelectorWidget::setSelectedFileName | ( | const QString & | fileName | ) |
Sets selected filename to fileName. Only works when selectedConnectionType()==FileBased.
Definition at line 287 of file KexiConnSelector.cpp.
void KexiConnSelectorWidget::slotRemoteAddBtnClicked | ( | ) | [protected, slot] |
Definition at line 369 of file KexiConnSelector.cpp.
void KexiConnSelectorWidget::slotRemoteEditBtnClicked | ( | ) | [protected, slot] |
Definition at line 392 of file KexiConnSelector.cpp.
The documentation for this class was generated from the following files: