1
#ifndef EXISTING_WINDOW_CONDITION_H
2
#define EXISTING_WINDOW_CONDITION_H
3
/* Copyright (C) 2009 Michael Jansen <kde@michael-jansen.biz>
4
Copyright (C) 1999-2001 Lubos Lunak <l.lunak@kde.org>
6
This library is free software; you can redistribute it and/or
7
modify it under the terms of the GNU Library General Public
8
License version 2 as published by the Free Software Foundation.
10
This library is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY; without even the implied warranty of
12
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
Library General Public License for more details.
15
You should have received a copy of the GNU Library General Public License
16
along with this library; see the file COPYING.LIB. If not, write to
17
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18
Boston, MA 02110-1301, USA.
21
#include "conditions/condition.h"
23
#include <QtCore/QObject>
24
#include <QtCore/QString>
25
#include <QtGui/qwindowdefs.h>
27
#include <KDE/KConfig> // Needed because of some Qt Status redefinitions
28
#include <KDE/KConfigGroup> // Needed because of some Qt Status redefinitions
30
#include <kdemacros.h>
41
class Condition_list_base;
46
* @author Michael Jansen <kde@michael-jansen.biz>
48
class KDE_EXPORT Existing_window_condition
49
: public QObject, public Condition
52
typedef Condition base;
54
Existing_window_condition( Windowdef_list* window_P, Condition_list_base* parent = NULL );
55
Existing_window_condition( KConfigGroup& cfg_P, Condition_list_base* parent_P );
56
virtual ~Existing_window_condition();
57
virtual bool match() const;
58
virtual void cfg_write( KConfigGroup& cfg_P ) const;
59
const Windowdef_list* window() const;
60
Windowdef_list* window();
61
virtual Existing_window_condition* copy() const;
62
virtual const QString description() const;
64
void window_added( WId w_P );
65
void window_removed( WId w_P );
68
void set_match( WId w_P = None );
69
Windowdef_list* _window;
74
} // namespace KHotKeys
76
#endif /* #ifndef EXISTING_WINDOW_CONDITION_H */