mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 18:32:50 +00:00
generic: misc cleanups
This commit is contained in:
parent
59461bdfe6
commit
598b724c4b
7 changed files with 43 additions and 42 deletions
|
@ -47,9 +47,8 @@ QString BacktraceParser::parsedBacktrace() const
|
|||
|
||||
QString result;
|
||||
if (d) {
|
||||
QList<BacktraceLine>::const_iterator i;
|
||||
for (i = d->m_linesList.constBegin(); i != d->m_linesList.constEnd(); ++i) {
|
||||
result += i->toString();
|
||||
foreach(const BacktraceLine i, d->m_linesList) {
|
||||
result += i.toString();
|
||||
}
|
||||
}
|
||||
return result;
|
||||
|
|
|
@ -251,17 +251,16 @@ QString BacktraceParserGdb::parsedBacktrace() const
|
|||
|
||||
QString result;
|
||||
if (d) {
|
||||
QList<BacktraceLine>::const_iterator i;
|
||||
for (i = d->m_linesList.constBegin(); i != d->m_linesList.constEnd(); ++i) {
|
||||
foreach(const BacktraceLine i, d->m_linesList) {
|
||||
//if there is only one thread, we can omit the thread indicator,
|
||||
//the thread header and all the empty lines.
|
||||
if (d->m_threadsCount == 1 && ((*i).type() == BacktraceLine::ThreadIndicator
|
||||
|| (*i).type() == BacktraceLine::ThreadStart
|
||||
|| (*i).type() == BacktraceLine::EmptyLine))
|
||||
if (d->m_threadsCount == 1 && (i.type() == BacktraceLine::ThreadIndicator
|
||||
|| i.type() == BacktraceLine::ThreadStart
|
||||
|| i.type() == BacktraceLine::EmptyLine))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
result += i->toString();
|
||||
result += i.toString();
|
||||
}
|
||||
}
|
||||
return result;
|
||||
|
@ -273,17 +272,16 @@ QList<BacktraceLine> BacktraceParserGdb::parsedBacktraceLines() const
|
|||
|
||||
QList<BacktraceLine> result;
|
||||
if (d) {
|
||||
QList<BacktraceLine>::const_iterator i;
|
||||
for (i = d->m_linesList.constBegin(); i != d->m_linesList.constEnd(); ++i) {
|
||||
foreach(const BacktraceLine i, d->m_linesList) {
|
||||
//if there is only one thread, we can omit the thread indicator,
|
||||
//the thread header and all the empty lines.
|
||||
if (d->m_threadsCount == 1 && ((*i).type() == BacktraceLine::ThreadIndicator
|
||||
|| (*i).type() == BacktraceLine::ThreadStart
|
||||
|| (*i).type() == BacktraceLine::EmptyLine))
|
||||
if (d->m_threadsCount == 1 && (i.type() == BacktraceLine::ThreadIndicator
|
||||
|| i.type() == BacktraceLine::ThreadStart
|
||||
|| i.type() == BacktraceLine::EmptyLine))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
result.append(*i);
|
||||
result.append(i);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
|
|
|
@ -210,11 +210,9 @@ bool ClientApp::doCopy( int firstArg )
|
|||
void ClientApp::slotEntries(KIO::Job* job, const KIO::UDSEntryList& list)
|
||||
{
|
||||
KUrl url = static_cast<KIO::ListJob*>( job )->url();
|
||||
KIO::UDSEntryList::ConstIterator it=list.begin();
|
||||
for (; it != list.end(); ++it) {
|
||||
foreach(const KIO::UDSEntry it, list) {
|
||||
// For each file...
|
||||
QString name = (*it).stringValue( KIO::UDSEntry::UDS_NAME );
|
||||
std::cout << qPrintable(name) << std::endl;
|
||||
std::cout << qPrintable(it.stringValue( KIO::UDSEntry::UDS_NAME )) << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -3,25 +3,28 @@
|
|||
set(SAMBA_REQUIRE_SMBC_SET_CONTEXT TRUE)
|
||||
set(SAMBA_REQUIRE_SMBC_OPTION_SET TRUE)
|
||||
macro_optional_find_package(Samba)
|
||||
set_package_properties(Samba PROPERTIES DESCRIPTION "the SMB client library, a version with smbc_set_context() and smbc_option_set()"
|
||||
URL "http://www.samba.org"
|
||||
TYPE OPTIONAL
|
||||
PURPOSE "Needed to build the SMB kioslave"
|
||||
)
|
||||
set_package_properties(Samba PROPERTIES
|
||||
DESCRIPTION "the SMB client library, a version with smbc_set_context() and smbc_option_set()"
|
||||
URL "http://www.samba.org"
|
||||
TYPE OPTIONAL
|
||||
PURPOSE "Needed to build the SMB kioslave"
|
||||
)
|
||||
|
||||
macro_optional_find_package(LibSSH 0.6.0)
|
||||
set_package_properties(LibSSH PROPERTIES DESCRIPTION "the SSH library with SFTP support"
|
||||
URL "http://www.libssh.org/"
|
||||
TYPE OPTIONAL
|
||||
PURPOSE "Needed to build the SFTP kioslave"
|
||||
)
|
||||
set_package_properties(LibSSH PROPERTIES
|
||||
DESCRIPTION "the SSH library with SFTP support"
|
||||
URL "http://www.libssh.org/"
|
||||
TYPE OPTIONAL
|
||||
PURPOSE "Needed to build the SFTP kioslave"
|
||||
)
|
||||
|
||||
macro_optional_find_package(Mtp)
|
||||
set_package_properties(Mtp PROPERTIES DESCRIPTION "the library implementation of the Media Transfer Protocol"
|
||||
URL "http://libmtp.sourceforge.net/"
|
||||
TYPE OPTIONAL
|
||||
PURPOSE "Needed to build the MTP kioslave"
|
||||
)
|
||||
set_package_properties(Mtp PROPERTIES
|
||||
DESCRIPTION "the library implementation of the Media Transfer Protocol"
|
||||
URL "http://libmtp.sourceforge.net/"
|
||||
TYPE OPTIONAL
|
||||
PURPOSE "Needed to build the MTP kioslave"
|
||||
)
|
||||
|
||||
add_subdirectory( about )
|
||||
add_subdirectory( bookmarks )
|
||||
|
@ -42,20 +45,21 @@ add_subdirectory( thumbnail )
|
|||
add_subdirectory( docfilter )
|
||||
if (LIBSSH_FOUND)
|
||||
add_subdirectory(sftp)
|
||||
endif (LIBSSH_FOUND)
|
||||
endif()
|
||||
if (MTP_FOUND)
|
||||
add_subdirectory(mtp)
|
||||
endif (MTP_FOUND)
|
||||
endif()
|
||||
|
||||
add_subdirectory( floppy )
|
||||
add_subdirectory( finger )
|
||||
check_include_files(rpc/rpc.h HAVE_RPC_RPC_H)
|
||||
add_feature_info("NFS kioslave" HAVE_RPC_RPC_H "The RPC library is needed to build the NFS kioslave")
|
||||
if(HAVE_RPC_RPC_H)
|
||||
add_subdirectory( nfs )
|
||||
endif(HAVE_RPC_RPC_H)
|
||||
add_subdirectory(nfs)
|
||||
endif()
|
||||
|
||||
if(SAMBA_FOUND)
|
||||
add_subdirectory(smb)
|
||||
endif(SAMBA_FOUND)
|
||||
endif()
|
||||
|
||||
# add_subdirectory(audiocd)
|
||||
|
|
|
@ -176,7 +176,7 @@ bool KPartSaver::openUrl( const KUrl &url )
|
|||
closeUrl();
|
||||
|
||||
// find mime type
|
||||
QString mime = KMimeType::findByUrl( url )->name();
|
||||
const QString mime = KMimeType::findByUrl( url )->name();
|
||||
|
||||
// load part
|
||||
m_part = KMimeTypeTrader::createPartInstanceFromQuery<KParts::ReadOnlyPart>(
|
||||
|
|
|
@ -192,7 +192,7 @@ int kScreenSaverMain( int argc, char** argv, KScreenSaverInterface& screenSaverI
|
|||
#ifdef Q_WS_X11 //FIXME
|
||||
if (args->isSet("root"))
|
||||
{
|
||||
QX11Info inf;
|
||||
QX11Info inf;
|
||||
saveWin = RootWindow(QX11Info::display(), inf.screen());
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
PROJECT (kephal)
|
||||
ADD_SUBDIRECTORY(client)
|
||||
ADD_SUBDIRECTORY(service)
|
||||
ADD_SUBDIRECTORY(tests)
|
||||
IF(ENABLE_TESTING)
|
||||
ADD_SUBDIRECTORY(tests)
|
||||
ENDIF()
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue