Line | |
---|
1 | #ifndef QT_CLEAN_NAMESPACE
|
---|
2 | #define QT_CLEAN_NAMESPACE
|
---|
3 | #endif
|
---|
4 |
|
---|
5 | #include <qimageformatplugin.h>
|
---|
6 |
|
---|
7 | #ifndef QT_NO_IMAGEFORMATPLUGIN
|
---|
8 |
|
---|
9 | #ifdef QT_NO_IMAGEIO_MNG
|
---|
10 | #undef QT_NO_IMAGEIO_MNG
|
---|
11 | #endif
|
---|
12 | #include "../../../../src/kernel/qmngio.cpp"
|
---|
13 |
|
---|
14 | class MNGFormat : public QImageFormatPlugin
|
---|
15 | {
|
---|
16 | public:
|
---|
17 | MNGFormat();
|
---|
18 |
|
---|
19 | QStringList keys() const;
|
---|
20 | bool loadImage( const QString &format, const QString &filename, QImage *image );
|
---|
21 | bool saveImage( const QString &format, const QString &filename, const QImage &image );
|
---|
22 | bool installIOHandler( const QString & );
|
---|
23 | };
|
---|
24 |
|
---|
25 | MNGFormat::MNGFormat()
|
---|
26 | {
|
---|
27 | }
|
---|
28 |
|
---|
29 |
|
---|
30 | QStringList MNGFormat::keys() const
|
---|
31 | {
|
---|
32 | QStringList list;
|
---|
33 | list << "MNG";
|
---|
34 |
|
---|
35 | return list;
|
---|
36 | }
|
---|
37 |
|
---|
38 | bool MNGFormat::loadImage( const QString &, const QString &, QImage * )
|
---|
39 | {
|
---|
40 | return FALSE;
|
---|
41 | }
|
---|
42 |
|
---|
43 | bool MNGFormat::saveImage( const QString &, const QString &, const QImage& )
|
---|
44 | {
|
---|
45 | return FALSE;
|
---|
46 | }
|
---|
47 |
|
---|
48 | bool MNGFormat::installIOHandler( const QString &name )
|
---|
49 | {
|
---|
50 | if ( name != "MNG" )
|
---|
51 | return FALSE;
|
---|
52 |
|
---|
53 | qInitMngIO();
|
---|
54 | return TRUE;
|
---|
55 | }
|
---|
56 |
|
---|
57 | Q_EXPORT_PLUGIN( MNGFormat )
|
---|
58 |
|
---|
59 | #endif // QT_NO_IMAGEFORMATPLUGIN
|
---|
Note:
See
TracBrowser
for help on using the repository browser.