summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/advancedfm/advancedfm.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/noncore/apps/advancedfm/advancedfm.cpp b/noncore/apps/advancedfm/advancedfm.cpp
index d7bad51..b6e7a30 100644
--- a/noncore/apps/advancedfm/advancedfm.cpp
+++ b/noncore/apps/advancedfm/advancedfm.cpp
@@ -726,5 +726,7 @@ void AdvancedFm::showFileMenu() {
MimeType mt( curApp );
+
const AppLnk* app = mt.application();
+
QFile fi(curApp);
@@ -734,14 +736,15 @@ void AdvancedFm::showFileMenu() {
m->insertItem( tr( "Show Hidden Files" ), this, SLOT( showHidden() ));
- if ( !QFileInfo(fi).isDir() ) {
-// m->insertSeparator();
-// m->insertItem( tr( "Change Directory" ), this, SLOT( doLocalCd() ));
-// } else {
+
+ if ( QFileInfo(fi).isDir() ) {
+ m->insertSeparator();
+ m->insertItem( tr( "Change Directory" ), this, SLOT( doLocalCd() ));
+ } else {
if ( app )
m->insertItem( app->pixmap(), tr( "Open in "
+ app->name() ), this, SLOT( runThis() ) );
- else if( QFileInfo(fi).isExecutable() )
- m->insertItem( Resource::loadPixmap( app->name()), tr( "Execute" ), this, SLOT( runThis() ) );
+ else if( QFileInfo(fi).isExecutable() ) //damn opie doesnt like this
+ m->insertItem( /*Resource::loadPixmap( app->name()),*/ tr( "Execute" ), this, SLOT( runThis() ) );
m->insertItem( Resource::loadPixmap( "txt" ), tr( "Open as text" ),this, SLOT( runText() ) );