• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

KDE3Support

  • sources
  • kde-4.14
  • kdelibs
  • kde3support
  • kdecore
k3urldrag.h
Go to the documentation of this file.
1 /* This file is part of the KDE project
2  Copyright (C) 2000 David Faure <faure@kde.org>
3 
4  This program is free software; you can redistribute it and/or
5  modify it under the terms of the GNU Library General Public
6  License as published by the Free Software Foundation; either
7  version 2 of the License.
8 
9  This program is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Library General Public License for more details.
13 
14  You should have received a copy of the GNU Library General Public License
15  along with this program; see the file COPYING. If not, write to
16  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  Boston, MA 02110-1301, USA.
18 */
19 
20 #ifndef KUrlDRAG_H
21 #define KUrlDRAG_H
22 
23 #include <kde3support_export.h>
24 #include <kurl.h>
25 
26 #include <QtCore/QStringList>
27 #include <Qt3Support/Q3ColorDrag>
28 
29 class QMimeSource;
30 
31 class K3URLDragPrivate;
46 class KDE3SUPPORT_EXPORT K3URLDrag : public Q3UriDrag
47 {
48 public:
58  K3URLDrag( const KUrl::List &urls, QWidget* dragSource = 0 );
68  K3URLDrag( const KUrl::List &urls, const QMap<QString, QString>& metaData,
69  QWidget* dragSource = 0 );
70 
71  virtual ~K3URLDrag();
72 
79  void setExportAsText( bool exp );
80 
84  static K3URLDrag * newDrag( const KUrl::List &urls, QWidget* dragSource = 0 );
85 
89  static K3URLDrag * newDrag( const KUrl::List &urls,
90  const QMap<QString, QString>& metaData,
91  QWidget* dragSource = 0 );
92 
100  QMap<QString, QString> &metaData();
101 
110  static bool decode( const QMimeSource *e, KUrl::List &urls );
111 
122  static bool decode( const QMimeSource *e, KUrl::List &urls, QMap<QString,QString>& metaData );
123 
127  static QString urlToString(const KUrl &url);
128 
132  static KUrl stringToUrl(const QByteArray &s);
133 
134 #ifdef Q_WS_QWS
135 
140  static bool decode( QStringList const &e, KUrl::List &uris );
141 #endif
142 
144  virtual const char * format( int i ) const;
146  virtual QByteArray encodedData( const char* mime ) const;
147 
148 protected:
152  K3URLDrag( const Q3StrList & urls, const QMap<QString,QString>& metaData,
153  QWidget * dragSource );
154 
155 private:
156  void init(const KUrl::List &urls);
157 
158  Q3StrList m_urls;
159  QMap<QString,QString> m_metaData;
160  K3URLDragPrivate* d;
161 };
162 
163 #endif
164 
QWidget
Q3StoredDrag::format
virtual const char * format(int i) const
kurl.h
QByteArray
Q3StoredDrag::encodedData
virtual QByteArray encodedData(const char *format) const
QMap< QString, QString >
Q3UriDrag
KUrl
K3URLDrag
This class is to be used instead of Q3UriDrag when using KUrl.
Definition: k3urldrag.h:46
kde3support_export.h
QString
QStringList
Q3StrList
KUrl::List
Q3UriDrag::decode
bool decode(const QMimeSource *source, Q3StrList &list)
QMimeSource
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:26:48 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDE3Support

Skip menu "KDE3Support"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal