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

libkonq

konq_events.h

Go to the documentation of this file.
00001 /* This file is part of the KDE project
00002    Copyright (C) 2000      Simon Hausmann <hausmann@kde.org>
00003    Copyright (C) 2000-2007 David Faure <faure@kde.org>
00004 
00005    This library is free software; you can redistribute it and/or
00006    modify it under the terms of the GNU Library General Public
00007    License as published by the Free Software Foundation; either
00008    version 2 of the License, or (at your option) any later version.
00009 
00010    This library is distributed in the hope that it will be useful,
00011    but WITHOUT ANY WARRANTY; without even the implied warranty of
00012    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013    Library General Public License for more details.
00014 
00015    You should have received a copy of the GNU Library General Public License
00016    along with this library; see the file COPYING.LIB.  If not, write to
00017    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00018    Boston, MA 02110-1301, USA.
00019 */
00020 
00021 #ifndef __konq_events_h__
00022 #define __konq_events_h__
00023 
00024 #include <kparts/event.h>
00025 #include <QtCore/QList>
00026 #include <libkonq_export.h>
00027 #include <kfileitem.h>
00028 
00029 namespace KParts
00030 {
00031   class ReadOnlyPart;
00032 }
00033 
00034 class KConfig;
00035 
00036 class LIBKONQ_EXPORT KonqFileSelectionEvent : public KParts::Event
00037 {
00038 public:
00039   KonqFileSelectionEvent( const KFileItemList&selection, KParts::ReadOnlyPart *part ) : KParts::Event( s_fileItemSelectionEventName ), m_selection( selection ), m_part( part ) {}
00040 
00041   KFileItemList selection() const { return m_selection; }
00042   KParts::ReadOnlyPart *part() const { return m_part; }
00043 
00044   static bool test( const QEvent *event ) { return KParts::Event::test( event, s_fileItemSelectionEventName ); }
00045 
00046 private:
00047   static const char *s_fileItemSelectionEventName;
00048 
00049   KFileItemList m_selection;
00050   KParts::ReadOnlyPart *m_part;
00051 };
00052 
00053 class LIBKONQ_EXPORT KonqFileMouseOverEvent : public KParts::Event
00054 {
00055 public:
00056   KonqFileMouseOverEvent( const KFileItem& item, KParts::ReadOnlyPart *part ) : KParts::Event( s_fileItemMouseOverEventName ), m_item( item ), m_part( part ) {}
00057 
00058   const KFileItem& item() const { return m_item; }
00059   KParts::ReadOnlyPart *part() const { return m_part; }
00060 
00061   static bool test( const QEvent *event ) { return KParts::Event::test( event, s_fileItemMouseOverEventName ); }
00062 
00063 private:
00064   static const char *s_fileItemMouseOverEventName;
00065 
00066   KFileItem m_item;
00067   KParts::ReadOnlyPart *m_part;
00068 };
00069 
00070 class LIBKONQ_EXPORT KonqConfigEvent : public KParts::Event
00071 {
00072 public:
00073   KonqConfigEvent( KConfigBase *config, const QString &prefix, bool save ) : KParts::Event( s_configEventName ), m_config( config ), m_prefix( prefix ), m_save( save ) {}
00074 
00075   KConfigBase * config() const { return m_config; }
00076   QString prefix() const { return m_prefix; }
00077   bool save() const { return m_save; }
00078 
00079   static bool test( const QEvent *event ) { return KParts::Event::test( event, s_configEventName ); }
00080 private:
00081   static const char *s_configEventName;
00082 
00083   KConfigBase *m_config;
00084   QString m_prefix;
00085   bool m_save;
00086 };
00087 
00088 #endif

libkonq

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

API Reference

Skip menu "API Reference"
  • Konsole
  • Libraries
  •   libkonq
Generated for API Reference by doxygen 1.5.4
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