[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdelibs/kio
From: David Faure <faure () kde ! org>
Date: 2004-11-09 19:47:44
Message-ID: 20041109194744.A803716C1C () office ! kde ! org
[Download RAW message or body]
CVS commit by faure:
Support for X-KDE-HasTempFileOption in the .desktop file, telling KRun to pass
--tempfile to the application. For #91410 and #62555.
M +3 -0 application.desktop 1.152
M +10 -2 kio/krun.cpp 1.264
--- kdelibs/kio/application.desktop #1.151:1.152
@@ -106,2 +106,5 @@
[PropertyDef::X-KDE-ParentApp]
Type=QString
+
+[PropertyDef::X-KDE-HasTempFileOption]
+Type=bool
--- kdelibs/kio/kio/krun.cpp #1.263:1.264
@@ -346,4 +346,5 @@ QStringList KRun::processDesktopExec(con
QString exec = _service.exec();
QStringList result;
+ bool appHasTempFileOption;
KRunMX1 mx1( _service );
@@ -373,5 +374,6 @@ QStringList KRun::processDesktopExec(con
// Check if we need "tempexec" (kioexec in fact)
- if( tempFiles ) {
+ appHasTempFileOption = tempFiles && _service.property("X-KDE-HasTempFileOption").toBool();
+ if( tempFiles && !appHasTempFileOption ) {
result << "kioexec" << "--tempfiles" << exec;
result += _urls.toStringList();
@@ -386,5 +388,8 @@ QStringList KRun::processDesktopExec(con
if ( !(*it).isLocalFile() && !KProtocolInfo::isHelperProtocol(*it) ) {
// We need to run the app through kioexec
- result << "kioexec" << exec;
+ result << "kioexec";
+ if ( tempFiles )
+ result << "--tempfiles";
+ result << exec;
result += _urls.toStringList();
if (has_shell)
@@ -394,4 +399,7 @@ QStringList KRun::processDesktopExec(con
}
+ if ( appHasTempFileOption )
+ exec += " --tempfile";
+
// Did the user forget to append something like '%f'?
// If so, then assume that '%f' is the right choice => the application
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic