/***********************************************************
** Copyright (c) 2009 NGuide
** 
** Contact: vasa_pmr@mail.ru
**
** This file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file.  Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** If you are unsure which license is appropriate for your use, please
** contact me   
 **********************************************************/

#include <QtGui/QApplication>
#include <QtGui/QLabel>

#include "itaskbar.h"

int main(int argc, char *argv[])
{
    QApplication a(argc, argv);
    QLabel l("ftp");
    l.show();

    Windows7Support::ITaskBar *tb = new Windows7Support::ITaskBar();

    l.setWindowIcon(QIcon(":/demo/window.png"));

    // This Code crashes
    // See itaskbar.cpp, line 62-69 for details.

    // icon not null, all is ok
    tb->setOverlayIcon(l.winId(), QIcon(":/demo/overlay.png"), "required for winapi");

    // try to pass null icon to function....crash
    tb->setOverlayIcon(l.winId(), QIcon(), "required for winapi");


    return a.exec();
}
