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

KFile

  • sources
  • kde-4.14
  • kdelibs
  • kfile
kfileplacesview.h
Go to the documentation of this file.
1 /* This file is part of the KDE project
2  Copyright (C) 2007 Kevin Ottens <ervin@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 KFILEPLACESVIEW_H
20 #define KFILEPLACESVIEW_H
21 
22 #include <kfile_export.h>
23 
24 #include <QtGui/QListView>
25 
26 #include <kurl.h>
27 
28 class QResizeEvent;
29 class QContextMenuEvent;
30 
34 class KFILE_EXPORT KFilePlacesView : public QListView
35 {
36  Q_OBJECT
37 public:
38  KFilePlacesView(QWidget *parent = 0);
39  ~KFilePlacesView();
40 
50  void setDropOnPlaceEnabled(bool enabled);
51  bool isDropOnPlaceEnabled() const;
52 
59  void setAutoResizeItemsEnabled(bool enabled);
60  bool isAutoResizeItemsEnabled() const;
61 
62 public Q_SLOTS:
63  void setUrl(const KUrl &url);
64  void setShowAll(bool showAll);
65  virtual QSize sizeHint() const;
66  virtual void setModel(QAbstractItemModel *model);
67 
68 protected:
69  virtual void keyPressEvent(QKeyEvent *event);
70  virtual void contextMenuEvent(QContextMenuEvent *event);
71  virtual void resizeEvent(QResizeEvent *event);
72  virtual void showEvent(QShowEvent *event);
73  virtual void hideEvent(QHideEvent *event);
74  virtual void dragEnterEvent(QDragEnterEvent *event);
75  virtual void dragLeaveEvent(QDragLeaveEvent *event);
76  virtual void dragMoveEvent(QDragMoveEvent *event);
77  virtual void dropEvent(QDropEvent *event);
78  virtual void paintEvent(QPaintEvent *event);
79 
80 protected Q_SLOTS:
81  void rowsInserted(const QModelIndex &parent, int start, int end);
82  void dataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight);
83 
84 Q_SIGNALS:
85  void urlChanged(const KUrl &url);
86 
92  void urlsDropped(const KUrl &dest, QDropEvent *event, QWidget *parent);
93 
94 private:
95  Q_PRIVATE_SLOT(d, void adaptItemSize())
96  Q_PRIVATE_SLOT(d, void _k_placeClicked(const QModelIndex &))
97  Q_PRIVATE_SLOT(d, void _k_placeEntered(const QModelIndex &))
98  Q_PRIVATE_SLOT(d, void _k_placeLeft(const QModelIndex &))
99  Q_PRIVATE_SLOT(d, void _k_storageSetupDone(const QModelIndex &, bool))
100  Q_PRIVATE_SLOT(d, void _k_adaptItemsUpdate(qreal))
101  Q_PRIVATE_SLOT(d, void _k_itemAppearUpdate(qreal))
102  Q_PRIVATE_SLOT(d, void _k_itemDisappearUpdate(qreal))
103  Q_PRIVATE_SLOT(d, void _k_enableSmoothItemResizing())
104  Q_PRIVATE_SLOT(d, void _k_trashUpdated(KJob *))
105  Q_PRIVATE_SLOT(d, void _k_capacityBarFadeValueChanged())
106  Q_PRIVATE_SLOT(d, void _k_triggerDevicePolling())
107 
108  class Private;
109  Private * const d;
110  friend class Private;
111 };
112 
113 #endif
QHideEvent
QModelIndex
QResizeEvent
QWidget
QListView::dataChanged
virtual void dataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight)
kurl.h
QDragMoveEvent
QAbstractItemView::setModel
virtual void setModel(QAbstractItemModel *model)
KFilePlacesView
This class allows to display a KFilePlacesModel.
Definition: kfileplacesview.h:34
QAbstractScrollArea::contextMenuEvent
virtual void contextMenuEvent(QContextMenuEvent *e)
QAbstractScrollArea::sizeHint
virtual QSize sizeHint() const
KUrl
QListView
QWidget::showEvent
virtual void showEvent(QShowEvent *event)
QListView::rowsInserted
virtual void rowsInserted(const QModelIndex &parent, int start, int end)
QShowEvent
QContextMenuEvent
QWidget::hideEvent
virtual void hideEvent(QHideEvent *event)
QDropEvent
QAbstractItemView::dragEnterEvent
virtual void dragEnterEvent(QDragEnterEvent *event)
QSize
QListView::paintEvent
virtual void paintEvent(QPaintEvent *e)
QDragLeaveEvent
QListView::dragMoveEvent
virtual void dragMoveEvent(QDragMoveEvent *e)
QListView::resizeEvent
virtual void resizeEvent(QResizeEvent *e)
QKeyEvent
QListView::dropEvent
virtual void dropEvent(QDropEvent *e)
QListView::dragLeaveEvent
virtual void dragLeaveEvent(QDragLeaveEvent *e)
QDragEnterEvent
QAbstractItemModel
QAbstractItemView::keyPressEvent
virtual void keyPressEvent(QKeyEvent *event)
QPaintEvent
end
const KShortcut & end()
KJob
kfile_export.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:27:26 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KFile

Skip menu "KFile"
  • Main Page
  • 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