Diffstat (limited to 'noncore/graphics/opie-eye/gui/iconview.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/graphics/opie-eye/gui/iconview.cpp | 61 |
1 files changed, 41 insertions, 20 deletions
diff --git a/noncore/graphics/opie-eye/gui/iconview.cpp b/noncore/graphics/opie-eye/gui/iconview.cpp index de2cdf0..4ced52d 100644 --- a/noncore/graphics/opie-eye/gui/iconview.cpp +++ b/noncore/graphics/opie-eye/gui/iconview.cpp @@ -37,5 +37,8 @@ using Opie::Ui::OKeyConfigItem; +/* + * The Icons, Request Cache and IconViewItem for the IconView + */ namespace { - QPixmap* _dirPix = 0; - QPixmap* _unkPix = 0; + static QPixmap* _dirPix = 0; + static QPixmap* _unkPix = 0; class IconViewItem : public QIconViewItem { @@ -61,4 +64,4 @@ namespace { */ - QMap<QString, IconViewItem*> g_stringInf; - QMap<QString, IconViewItem*> g_stringPix; + static QMap<QString, IconViewItem*> g_stringInf; + static QMap<QString, IconViewItem*> g_stringPix; @@ -103,2 +106,6 @@ namespace { +/* + * Set up the GUI.. initialize the slave set up gui + * and also load a dir + */ PIconView::PIconView( QWidget* wid, Opie::Core::OConfig* cfg ) @@ -138,2 +145,5 @@ PIconView::PIconView( QWidget* wid, Opie::Core::OConfig* cfg ) +/* + * Unref the slave and save the keyboard manager + */ PIconView::~PIconView() { @@ -150,2 +160,7 @@ Opie::Ui::OKeyConfigManager* PIconView::manager() { + +/* + * init the KeyBoard Shortcuts + * called from the c'tor + */ void PIconView::initKeys() { @@ -180,2 +195,6 @@ void PIconView::initKeys() { + +/* + * change one dir up + */ void PIconView::slotDirUp() { @@ -187,2 +206,5 @@ void PIconView::slotDirUp() { +/* + * change the dir + */ void PIconView::slotChangeDir(const QString& path) { @@ -286,5 +308,5 @@ void PIconView::addFolders( const QStringList& lst) { - for(it=lst.begin(); it != lst.end(); ++it ) { + for(it=lst.begin(); it != lst.end(); ++it ) (void)new IconViewItem( m_view, m_path+"/"+(*it), (*it), true ); - } + @@ -307,3 +329,3 @@ void PIconView::slotClicked(QIconViewItem* _it) { else // view image - ; + slotShowImage(); } @@ -362,3 +384,2 @@ void PIconView::slotStart() { m_view->viewport()->setUpdatesEnabled( false ); - qWarning( "Sig Start" ); } @@ -366,3 +387,2 @@ void PIconView::slotStart() { void PIconView::slotEnd() { - qWarning( "SLot End" ); if ( m_updatet ) @@ -373,4 +393,5 @@ void PIconView::slotEnd() { -void PIconView::slotShowImage() { - qDebug("image show"); +void PIconView::slotShowImage() +{ + qWarning( "SLotShowImage" ); bool isDir = false; @@ -378,10 +399,10 @@ void PIconView::slotShowImage() { if (isDir) return; - ImageDlg dlg(name); - QPEApplication::execDialog(&dlg); -} -void PIconView::slotShowImage( const QString& ) { + slotShowImage( name ); +} +void PIconView::slotShowImage( const QString& name) { + emit sig_display( name ); } void PIconView::slotImageInfo() { - qDebug("image info"); + qWarning( "SlotImageInfo" ); bool isDir = false; @@ -389,8 +410,8 @@ void PIconView::slotImageInfo() { if (isDir) return; - infoDlg dlg(name); - QPEApplication::execDialog(&dlg); + + slotImageInfo( name ); } -void PIconView::slotImageInfo( const QString& ) { - +void PIconView::slotImageInfo( const QString& name) { + emit sig_showInfo( name ); } |