1/* This file is part of the KDE project
2 Copyright (C) 1999-2006 David Faure <faure@kde.org>
3
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public
6 License version 2 as published by the Free Software Foundation.
7
8 This library is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 Library General Public License for more details.
12
13 You should have received a copy of the GNU Library General Public License
14 along with this library; see the file COPYING.LIB. If not, write to
15 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16 Boston, MA 02110-1301, USA.
17*/
18
19#ifndef __kioclient_h
20#define __kioclient_h
21
22#include <QApplication>
23#include <kio/udsentry.h>
24class KUrl;
25class KJob;
26namespace KIO { class Job; }
27
28class ClientApp : public QApplication
29{
30 Q_OBJECT
31public:
32 ClientApp(int &argc, char **argv );
33
34 /** Parse command-line arguments and "do it" */
35 static bool doIt();
36
37private Q_SLOTS:
38 void slotPrintData(KIO::Job *job, const QByteArray &data);
39 void slotEntries(KIO::Job* job, const KIO::UDSEntryList& );
40 void slotResult( KJob * );
41 void delayedQuit();
42 void slotDialogCanceled();
43 void deref();
44
45private:
46 bool kde_open( const KUrl& url, const QString& mimeType, bool allowExec );
47 bool doCopy( int firstArg );
48 bool doMove( int firstArg );
49 bool doList( int firstArg );
50 bool doRemove( int firstArg );
51
52 static bool m_ok;
53};
54
55#endif
56