libqutim 0.3.1.0
|
00001 /**************************************************************************** 00002 ** 00003 ** qutIM - instant messenger 00004 ** 00005 ** Copyright © 2011 Ruslan Nigmatullin <euroelessar@yandex.ru> 00006 ** 00007 ***************************************************************************** 00008 ** 00009 ** $QUTIM_BEGIN_LICENSE$ 00010 ** This program is free software: you can redistribute it and/or modify 00011 ** it under the terms of the GNU General Public License as published by 00012 ** the Free Software Foundation, either version 3 of the License, or 00013 ** (at your option) any later version. 00014 ** 00015 ** This program is distributed in the hope that it will be useful, 00016 ** but WITHOUT ANY WARRANTY; without even the implied warranty of 00017 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00018 ** See the GNU General Public License for more details. 00019 ** 00020 ** You should have received a copy of the GNU General Public License 00021 ** along with this program. If not, see http://www.gnu.org/licenses/. 00022 ** $QUTIM_END_LICENSE$ 00023 ** 00024 ****************************************************************************/ 00025 00026 #ifndef ICON_H 00027 #define ICON_H 00028 00029 #include "libqutim_global.h" 00030 #include <QIcon> 00031 00032 namespace qutim_sdk_0_3 00033 { 00034 class LIBQUTIM_EXPORT Icon : public QIcon 00035 { 00036 public: 00037 // Qt 4.6 has ability for getting icons from system themes 00038 // but has no one for getting client-specific icons like 00039 // status icons and client icons (except installed clients) 00040 // so we create our own imlp of icon engine, which has wrapper 00041 // around QIcon::fromTheme 00042 enum Type { System, Status }; 00043 00044 // There is also another way: i.e. give names for icons 00045 // like "user-online-jabber", "user-online-icq" and so on, 00046 // names for clients should be like "miranda" or "qutim" 00047 Icon(const QString &name); 00048 00049 Icon(const QIcon &icon); 00050 00051 QString name() const; 00052 }; 00053 } 00054 00055 #endif // ICON_H 00056