NetTree Class Reference

#include <nettree.h>

Inheritance diagram for NetTree:
MythScreenType MythUIType XMLParseBase

List of all members.

Public Member Functions

 NetTree (DialogType type, MythScreenStack *parent, const char *name=0)
 ~NetTree ()
bool Create (void)
bool keyPressEvent (QKeyEvent *)
 Key event handler.
void populateResultList (ResultItem::resultList list)

Protected Member Functions

void createBusyDialog (QString title)

Static Protected Attributes

static const QString RSSNode = tr("RSS Feeds")
static const QString SearchNode = tr("Searches")
static const QString DownloadNode = tr("Downloaded Files")

Private Slots

void streamWebVideo (void)
void showWebVideo (void)
void doDownloadAndPlay (void)
void doPlayVideo (QString filename)
void showMenu (void)
MythMenucreateShowViewMenu (void)
MythMenucreateShowManageMenu (void)
void runTreeEditor (void)
void runRSSEditor (void)
void loadData (void)
void handleSelect (MythUIButtonListItem *item)
void switchTreeView (void)
void switchGalleryView (void)
void switchBrowseView (void)
void updateRSS ()
void updateTrees ()
void toggleRSSUpdates ()
void toggleTreeUpdates ()
void slotDeleteVideo (void)
void doDeleteVideo (bool remove)
void slotItemChanged ()
void doTreeRefresh ()
void TreeRefresh ()
void customEvent (QEvent *levent)
void DownloadVideo (QString url, QString dest)

Private Member Functions

virtual void Load ()
 Load data which will ultimately be displayed on-screen or used to determine what appears on-screen (See Warning).
virtual void Init ()
 Used after calling Load() to assign data to widgets and other UI initilisation which is prohibited in Load().
void fillTree (void)
void SetCurrentNode (MythGenericTree *node)
void handleDirSelect (MythGenericTree *node)
bool goBack ()
void UpdateItem (MythUIButtonListItem *item)
void buildGenericTree (MythGenericTree *dst, QDomElement &domElem)
void buildGenericTree (MythGenericTree *dst, QStringList paths, QString dirthumb, QList< ResultItem * > videos)
void cleanCacheDir (void)
void initProgressDialog ()
MythGenericTreeAddDirNode (MythGenericTree *where_to_add, QString name, QString thumbnail)
int AddFileNode (MythGenericTree *where_to_add, ResultItem *video)
void switchView (void)

Private Attributes

QList< ResultItem * > m_videos
MythUIButtonTreem_siteMap
MythUIButtonListm_siteButtonList
MythGenericTreem_siteGeneric
MythGenericTreem_rssGeneric
MythGenericTreem_searchGeneric
MythGenericTreem_currentNode
MythUITextm_noSites
MythUIImagem_thumbImage
MythUIStateTypem_downloadable
MythUIBusyDialogm_busyPopup
MythDialogBoxm_menuPopup
MythScreenStackm_popupStack
MythUIProgressDialogm_progressDialog
MetadataImageDownloadm_imageDownload
GrabberDownloadThreadm_gdt
QString m_downloadFile
QFile * m_file
GrabberScript::scriptList m_grabberList
RSSSite::rssList m_rssList
DialogType m_type
uint m_updateFreq
bool m_rssAutoUpdate
bool m_treeAutoUpdate

Detailed Description

Definition at line 41 of file nettree.h.


Constructor & Destructor Documentation

NetTree::NetTree ( DialogType  type,
MythScreenStack parent,
const char *  name = 0 
)

Definition at line 45 of file nettree.cpp.

Referenced by switchView().

NetTree::~NetTree (  ) 

Definition at line 159 of file nettree.cpp.


Member Function Documentation

bool NetTree::Create ( void   )  [virtual]

Reimplemented from MythScreenType.

Definition at line 66 of file nettree.cpp.

Referenced by RunNetTree(), and switchView().

bool NetTree::keyPressEvent ( QKeyEvent *   )  [virtual]

Key event handler.

Parameters:
event Keypress event

Reimplemented from MythScreenType.

Definition at line 411 of file nettree.cpp.

void NetTree::populateResultList ( ResultItem::resultList  list  ) 
void NetTree::createBusyDialog ( QString  title  )  [protected]

Definition at line 448 of file nettree.cpp.

Referenced by updateRSS(), and updateTrees().

void NetTree::Load ( void   )  [private, virtual]

Load data which will ultimately be displayed on-screen or used to determine what appears on-screen (See Warning).

Warning:
This method should only load data, it should NEVER perform UI routines or segfaults WILL result. This includes assinging data to any widgets, calling methods on a widget or anything else which triggers redraws. The safest and recommended approach is to avoid any interaction with a libmythui class or class member.

Reimplemented from MythScreenType.

Definition at line 138 of file nettree.cpp.

void NetTree::Init ( void   )  [private, virtual]

Used after calling Load() to assign data to widgets and other UI initilisation which is prohibited in Load().

Warning:
Do NOT confuse this with Load(), they serve very different purposes and most often both should be used when creating a new screen.

Reimplemented from MythScreenType.

Definition at line 154 of file nettree.cpp.

void NetTree::fillTree ( void   )  [private]

Definition at line 584 of file nettree.cpp.

Referenced by Load(), and TreeRefresh().

void NetTree::SetCurrentNode ( MythGenericTree node  )  [private]

Definition at line 146 of file nettree.cpp.

Referenced by goBack(), handleDirSelect(), and loadData().

void NetTree::handleDirSelect ( MythGenericTree node  )  [private]

Definition at line 380 of file nettree.cpp.

Referenced by handleSelect().

bool NetTree::goBack (  )  [private]

Definition at line 389 of file nettree.cpp.

Referenced by handleSelect(), and keyPressEvent().

void NetTree::UpdateItem ( MythUIButtonListItem item  )  [private]

Definition at line 262 of file nettree.cpp.

Referenced by loadData().

void NetTree::buildGenericTree ( MythGenericTree dst,
QDomElement &  domElem 
) [private]

Referenced by buildGenericTree(), and fillTree().

void NetTree::buildGenericTree ( MythGenericTree dst,
QStringList  paths,
QString  dirthumb,
QList< ResultItem * >  videos 
) [private]

Definition at line 666 of file nettree.cpp.

void NetTree::cleanCacheDir ( void   )  [private]

Definition at line 194 of file nettree.cpp.

Referenced by ~NetTree().

void NetTree::initProgressDialog (  )  [private]

Definition at line 960 of file nettree.cpp.

Referenced by DownloadVideo().

MythGenericTree * NetTree::AddDirNode ( MythGenericTree where_to_add,
QString  name,
QString  thumbnail 
) [private]

Definition at line 709 of file nettree.cpp.

int NetTree::AddFileNode ( MythGenericTree where_to_add,
ResultItem video 
) [private]

Definition at line 720 of file nettree.cpp.

Referenced by buildGenericTree(), and fillTree().

void NetTree::switchView ( void   )  [private]

Definition at line 567 of file nettree.cpp.

Referenced by switchBrowseView(), switchGalleryView(), switchTreeView(), and TreeRefresh().

void NetTree::streamWebVideo ( void   )  [private, slot]

Definition at line 731 of file nettree.cpp.

Referenced by Create(), handleSelect(), and showMenu().

void NetTree::showWebVideo ( void   )  [private, slot]

Definition at line 762 of file nettree.cpp.

Referenced by showMenu(), and streamWebVideo().

void NetTree::doDownloadAndPlay ( void   )  [private, slot]

Definition at line 914 of file nettree.cpp.

Referenced by showMenu().

void NetTree::doPlayVideo ( QString  filename  )  [private, slot]

Definition at line 843 of file nettree.cpp.

Referenced by customEvent(), and doDownloadAndPlay().

void NetTree::showMenu ( void   )  [private, slot]

Definition at line 467 of file nettree.cpp.

Referenced by keyPressEvent().

MythMenu * NetTree::createShowViewMenu ( void   )  [private, slot]

Definition at line 510 of file nettree.cpp.

Referenced by showMenu().

MythMenu * NetTree::createShowManageMenu ( void   )  [private, slot]

Definition at line 526 of file nettree.cpp.

Referenced by showMenu().

void NetTree::runTreeEditor ( void   )  [private, slot]

Definition at line 1136 of file nettree.cpp.

Referenced by createShowManageMenu(), and loadData().

void NetTree::runRSSEditor ( void   )  [private, slot]

Definition at line 1155 of file nettree.cpp.

Referenced by createShowManageMenu().

void NetTree::loadData ( void   )  [private, slot]

Definition at line 213 of file nettree.cpp.

Referenced by goBack(), handleDirSelect(), Init(), and TreeRefresh().

void NetTree::handleSelect ( MythUIButtonListItem item  )  [private, slot]

Definition at line 359 of file nettree.cpp.

Referenced by Create().

void NetTree::switchTreeView ( void   )  [private, slot]

Definition at line 549 of file nettree.cpp.

Referenced by createShowViewMenu().

void NetTree::switchGalleryView ( void   )  [private, slot]

Definition at line 555 of file nettree.cpp.

Referenced by createShowViewMenu().

void NetTree::switchBrowseView ( void   )  [private, slot]

Definition at line 561 of file nettree.cpp.

Referenced by createShowViewMenu().

void NetTree::updateRSS (  )  [private, slot]

Definition at line 1198 of file nettree.cpp.

Referenced by createShowManageMenu(), and runRSSEditor().

void NetTree::updateTrees (  )  [private, slot]

Definition at line 1213 of file nettree.cpp.

Referenced by createShowManageMenu().

void NetTree::toggleRSSUpdates (  )  [private, slot]

Definition at line 1223 of file nettree.cpp.

void NetTree::toggleTreeUpdates (  )  [private, slot]

Definition at line 1230 of file nettree.cpp.

Referenced by createShowManageMenu().

void NetTree::slotDeleteVideo ( void   )  [private, slot]

Definition at line 864 of file nettree.cpp.

void NetTree::doDeleteVideo ( bool  remove  )  [private, slot]

Definition at line 881 of file nettree.cpp.

Referenced by slotDeleteVideo().

void NetTree::slotItemChanged ( void   )  [private, slot]

Definition at line 977 of file nettree.cpp.

Referenced by Create(), handleSelect(), and loadData().

void NetTree::doTreeRefresh (  )  [private, slot]

Definition at line 1174 of file nettree.cpp.

Referenced by customEvent(), runTreeEditor(), and updateRSS().

void NetTree::TreeRefresh (  )  [private, slot]

Definition at line 1185 of file nettree.cpp.

Referenced by doTreeRefresh().

void NetTree::customEvent ( QEvent *  levent  )  [private, virtual, slot]

Reimplemented from MythUIType.

Definition at line 1237 of file nettree.cpp.

void NetTree::DownloadVideo ( QString  url,
QString  dest 
) [private, slot]

Definition at line 954 of file nettree.cpp.

Referenced by doDownloadAndPlay().


Member Data Documentation

QList<ResultItem*> NetTree::m_videos [private]

Definition at line 89 of file nettree.h.

Referenced by AddFileNode(), and ~NetTree().

Definition at line 93 of file nettree.h.

Referenced by Create(), fillTree(), goBack(), keyPressEvent(), loadData(), TreeRefresh(), and ~NetTree().

Definition at line 94 of file nettree.h.

Referenced by fillTree().

Definition at line 95 of file nettree.h.

Definition at line 96 of file nettree.h.

Referenced by Create(), goBack(), keyPressEvent(), loadData(), SetCurrentNode(), and TreeRefresh().

Definition at line 98 of file nettree.h.

Referenced by Create(), and loadData().

Definition at line 100 of file nettree.h.

Referenced by Create(), customEvent(), and slotItemChanged().

Definition at line 102 of file nettree.h.

Referenced by Create(), and slotItemChanged().

Definition at line 104 of file nettree.h.

Referenced by createBusyDialog(), and doTreeRefresh().

Definition at line 106 of file nettree.h.

Definition at line 107 of file nettree.h.

Referenced by createBusyDialog(), initProgressDialog(), NetTree(), showMenu(), and slotDeleteVideo().

Definition at line 108 of file nettree.h.

Referenced by customEvent(), and initProgressDialog().

Definition at line 110 of file nettree.h.

Referenced by goBack(), handleDirSelect(), NetTree(), UpdateItem(), and ~NetTree().

Definition at line 111 of file nettree.h.

Referenced by NetTree(), updateTrees(), and ~NetTree().

QString NetTree::m_downloadFile [private]

Definition at line 112 of file nettree.h.

Referenced by customEvent(), and DownloadVideo().

QFile* NetTree::m_file [private]

Definition at line 114 of file nettree.h.

Definition at line 116 of file nettree.h.

Referenced by fillTree(), Load(), TreeRefresh(), updateTrees(), and ~NetTree().

Definition at line 117 of file nettree.h.

Referenced by fillTree(), Load(), TreeRefresh(), and ~NetTree().

Definition at line 121 of file nettree.h.

Referenced by NetTree().

Definition at line 122 of file nettree.h.

Referenced by NetTree(), and toggleRSSUpdates().

Definition at line 123 of file nettree.h.

Referenced by createShowManageMenu(), NetTree(), and toggleTreeUpdates().

const QString NetTree::RSSNode = tr("RSS Feeds") [static, protected]

Definition at line 159 of file nettree.h.

Referenced by fillTree().

const QString NetTree::SearchNode = tr("Searches") [static, protected]

Definition at line 160 of file nettree.h.

const QString NetTree::DownloadNode = tr("Downloaded Files") [static, protected]

Definition at line 161 of file nettree.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends
Generated on Mon May 28 06:42:18 2012 for MythTV by  doxygen 1.6.3