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

KIO

kpropertiesdialog.h

Go to the documentation of this file.
00001 /* This file is part of the KDE project
00002    Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
00003    Copyright (c) 1999, 2000 Preston Brown <pbrown@kde.org>
00004    Copyright (c) 2000 Simon Hausmann <hausmann@kde.org>
00005    Copyright (c) 2000 David Faure <faure@kde.org>
00006 
00007    This library is free software; you can redistribute it and/or
00008    modify it under the terms of the GNU Library General Public
00009    License as published by the Free Software Foundation; either
00010    version 2 of the License, or (at your option) any later version.
00011 
00012    This library is distributed in the hope that it will be useful,
00013    but WITHOUT ANY WARRANTY; without even the implied warranty of
00014    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00015    Library General Public License for more details.
00016 
00017    You should have received a copy of the GNU Library General Public License
00018    along with this library; see the file COPYING.LIB.  If not, write to
00019    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00020    Boston, MA 02110-1301, USA.
00021 */
00022 
00023 
00024 #ifndef KPROPERTIESDIALOG_H
00025 #define KPROPERTIESDIALOG_H
00026 
00027 #include <QtCore/QString>
00028 
00029 #include <kdemacros.h>
00030 #include <kurl.h>
00031 #include <kfileitem.h>
00032 #include <kpagedialog.h>
00033 
00034 class KPropertiesDialogPlugin;
00035 
00036 class KJob;
00037 namespace KIO { class Job; }
00038 
00057 class KIO_EXPORT KPropertiesDialog : public KPageDialog
00058 {
00059   Q_OBJECT
00060 
00061 public:
00062 
00069   static bool canDisplay( const KFileItemList& _items );
00070 
00082   explicit KPropertiesDialog( const KFileItem& item,
00083                               QWidget* parent = 0 );
00084 
00097   explicit KPropertiesDialog( const KFileItemList& _items,
00098                               QWidget *parent = 0 );
00099 
00116   explicit KPropertiesDialog( const KUrl& _url,
00117                               QWidget* parent = 0 );
00118 
00131   KPropertiesDialog( const KUrl& _tempUrl, const KUrl& _currentDir,
00132                      const QString& _defaultName,
00133                      QWidget* parent = 0 );
00134 
00144   explicit KPropertiesDialog(const QString& title,
00145                              QWidget* parent = 0);
00146 
00152   virtual ~KPropertiesDialog();
00153 
00162   static bool showDialog(const KFileItem& item, QWidget* parent = 0,
00163                          bool modal = true);
00164 
00173   static bool showDialog(const KUrl& _url, QWidget* parent = 0,
00174                          bool modal = true);
00175 
00185   static bool showDialog(const KFileItemList& _items, QWidget* parent = 0,
00186                          bool modal = true);
00187 
00201   void insertPlugin (KPropertiesDialogPlugin *plugin);
00202 
00210   KUrl kurl() const;
00211 
00219   KFileItem& item();
00220 
00224   KFileItemList items() const;
00225 
00233   KUrl currentDir() const;
00234 
00241   QString defaultName() const;
00242 
00249   void updateUrl( const KUrl& _newUrl );
00250 
00257   void rename( const QString& _name );
00258 
00262   void abortApplying();
00263 
00270   void showFileSharingPage();
00271 
00279   void setFileSharingPage(QWidget* page);
00280 
00286   void setFileNameReadOnly( bool ro );
00287 
00288 public Q_SLOTS:
00292   virtual void slotOk();      // Deletes the PropertiesDialog instance
00296   virtual void slotCancel();     // Deletes the PropertiesDialog instance
00297 
00298 Q_SIGNALS:
00303   void propertiesClosed();
00304 
00309   void applied();
00310 
00316   void canceled();
00322   void saveAs(const KUrl &oldUrl, KUrl &newUrl);
00323 
00324 Q_SIGNALS:
00325   void leaveModality();
00326 private:
00327   class KPropertiesDialogPrivate;
00328   KPropertiesDialogPrivate* const d;
00329 
00330     Q_DISABLE_COPY(KPropertiesDialog)
00331 };
00332 
00347 class KIO_EXPORT KPropertiesDialogPlugin : public QObject
00348 {
00349   Q_OBJECT
00350 public:
00356   KPropertiesDialogPlugin( KPropertiesDialog *_props );
00357   virtual ~KPropertiesDialogPlugin();
00358 
00364   virtual void applyChanges();
00365 
00371   static KDE_DEPRECATED bool isDesktopFile( const KFileItem& _item );
00372 
00373   void setDirty( bool b );
00374   bool isDirty() const;
00375 
00376 public Q_SLOTS:
00377   void setDirty(); // same as setDirty( true )
00378 
00379 Q_SIGNALS:
00385   void changed();
00386 
00387 protected:
00391   KPropertiesDialog *properties;
00392 
00396   int fontHeight() const;
00397 
00398 private:
00399   class KPropertiesDialogPluginPrivate;
00400   KPropertiesDialogPluginPrivate* const d;
00401 };
00402 
00403 
00404 #endif
00405 

KIO

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

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.6.1
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal