1 /**************************************************************************
3 ** This file is part of Qt Creator
5 ** Copyright (c) 2011 Nokia Corporation and/or its subsidiary(-ies).
6 ** Copyright (c) 2010 Denis Mingulov.
8 ** Contact: Nokia Corporation (qt-info@nokia.com)
10 ** No Commercial Usage
12 ** This file contains pre-release code and may not be distributed.
13 ** You may use this file in accordance with the terms and conditions
14 ** contained in the Technology Preview License Agreement accompanying
17 ** GNU Lesser General Public License Usage
19 ** Alternatively, this file may be used under the terms of the GNU Lesser
20 ** General Public License version 2.1 as published by the Free Software
21 ** Foundation and appearing in the file LICENSE.LGPL included in the
22 ** packaging of this file. Please review the following information to
23 ** ensure the GNU Lesser General Public License version 2.1 requirements
24 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
26 ** In addition, as a special exception, Nokia gives you certain additional
27 ** rights. These rights are described in the Nokia Qt LGPL Exception
28 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
30 ** If you have questions regarding the use of this file, please contact
31 ** Nokia at qt-info@nokia.com.
33 **************************************************************************/
35 #ifndef IMAGEVIEWERFACTORY_H
36 #define IMAGEVIEWERFACTORY_H
38 #include <coreplugin/editormanager/ieditorfactory.h>
39 #include <coreplugin/editormanager/ieditor.h>
40 #include <coreplugin/ifile.h>
42 #include <QtCore/QScopedPointer>
44 namespace ImageViewer {
47 class ImageViewerFactory : public Core::IEditorFactory
51 explicit ImageViewerFactory(QObject *parent = 0);
52 ~ImageViewerFactory();
54 Core::IEditor *createEditor(QWidget *parent);
56 QStringList mimeTypes() const;
59 QString displayName() const;
61 Core::IFile *open(const QString &fileName);
63 void extensionsInitialized();
66 QScopedPointer<struct ImageViewerFactoryPrivate> d_ptr;
69 } // namespace Internal
70 } // namespace ImageViewer
72 #endif // IMAGEVIEWERFACTORY_H