MythTV  0.26-pre
Signals | Public Member Functions | Private Slots | Private Attributes
MythUISearchDialog Class Reference

Provide a dialog to quickly find an entry in a list. More...

#include <mythdialogbox.h>

Inheritance diagram for MythUISearchDialog:
MythScreenType MythUIType XMLParseBase

List of all members.

Signals

void haveResult (QString)

Public Member Functions

 MythUISearchDialog (MythScreenStack *parent, const QString &message, const QStringList &list, bool matchAnywhere=false, const QString &defaultValue="")
 the classes constructor
bool Create (void)
void SetReturnEvent (QObject *retobject, const QString &resultid)

Private Slots

void slotSendResult (void)
void slotUpdateList (void)

Private Attributes

MythUIButtonListm_itemList
MythUITextEditm_textEdit
MythUITextm_titleText
MythUITextm_matchesText
QString m_title
QString m_defaultValue
QStringList m_list
bool m_matchAnywhere
QObject * m_retObject
QString m_id

Detailed Description

Provide a dialog to quickly find an entry in a list.

You pass a QStringList containing the list you want to search. As the user enters a text string in the edit the list of entries changes to show only the entries that match the input string. You have the option to search anywhere in the string or only the start.

When the user either clicks an entry in the list or presses the OK button the dialog will either send a DialogCompletionEvent or an haveResult(QString) signal will be generated. Both pass the selected string back to the caller.

Definition at line 266 of file mythdialogbox.h.


Constructor & Destructor Documentation

MythUISearchDialog::MythUISearchDialog ( MythScreenStack parent,
const QString &  message,
const QStringList &  list,
bool  matchAnywhere = false,
const QString &  defaultValue = "" 
)

the classes constructor

Parameters:
parentthe MythScreenStack this widget belongs to
titlethe text to show as the title
listthe list of text strings to search
matchAnywhereif true will match the input text anywhere in the string. if false will match only strings that start with the input text. Default is false.
defaultValueThe initial value for the input text. Default is ""

Definition at line 711 of file mythdialogbox.cpp.


Member Function Documentation

void MythUISearchDialog::SetReturnEvent ( QObject *  retobject,
const QString &  resultid 
)

Definition at line 776 of file mythdialogbox.cpp.

Referenced by MusicCommon::customEvent().

void MythUISearchDialog::haveResult ( QString  ) [signal]

Referenced by slotSendResult().

Definition at line 783 of file mythdialogbox.cpp.

Referenced by Create().

Definition at line 802 of file mythdialogbox.cpp.

Referenced by Create().


Member Data Documentation

Definition at line 284 of file mythdialogbox.h.

Referenced by Create(), MythUISearchDialog(), slotSendResult(), and slotUpdateList().

Definition at line 285 of file mythdialogbox.h.

Referenced by Create(), MythUISearchDialog(), and slotUpdateList().

Definition at line 286 of file mythdialogbox.h.

Referenced by Create(), and MythUISearchDialog().

Definition at line 287 of file mythdialogbox.h.

Referenced by Create(), MythUISearchDialog(), and slotUpdateList().

QString MythUISearchDialog::m_title [private]

Definition at line 289 of file mythdialogbox.h.

Referenced by Create(), and MythUISearchDialog().

Definition at line 290 of file mythdialogbox.h.

Referenced by Create(), and MythUISearchDialog().

QStringList MythUISearchDialog::m_list [private]

Definition at line 291 of file mythdialogbox.h.

Referenced by MythUISearchDialog(), and slotUpdateList().

Definition at line 292 of file mythdialogbox.h.

Referenced by MythUISearchDialog(), and slotUpdateList().

QObject* MythUISearchDialog::m_retObject [private]

Definition at line 294 of file mythdialogbox.h.

Referenced by MythUISearchDialog(), SetReturnEvent(), and slotSendResult().

QString MythUISearchDialog::m_id [private]

Definition at line 295 of file mythdialogbox.h.

Referenced by MythUISearchDialog(), SetReturnEvent(), and slotSendResult().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends