Browse Source

Adapted to Corrade and Magnum changes.

pull/34/head
Vladimír Vondruš 13 years ago
parent
commit
af18c8d65d
  1. 14
      src/Plugins/TgaImporter/Test/TgaImporterTest.cpp
  2. 8
      src/Plugins/TgaImporter/TgaImporter.h

14
src/Plugins/TgaImporter/Test/TgaImporterTest.cpp

@ -36,13 +36,13 @@ class TgaImporterTest: public Corrade::TestSuite::Tester {
}; };
TgaImporterTest::TgaImporterTest() { TgaImporterTest::TgaImporterTest() {
addTests(&TgaImporterTest::openInexistent, addTests({&TgaImporterTest::openInexistent,
&TgaImporterTest::openShort, &TgaImporterTest::openShort,
&TgaImporterTest::paletted, &TgaImporterTest::paletted,
&TgaImporterTest::nonRgb, &TgaImporterTest::nonRgb,
&TgaImporterTest::bits16, &TgaImporterTest::bits16,
&TgaImporterTest::bits24, &TgaImporterTest::bits24,
&TgaImporterTest::bits32); &TgaImporterTest::bits32});
} }
void TgaImporterTest::openInexistent() { void TgaImporterTest::openInexistent() {

8
src/Plugins/TgaImporter/TgaImporter.h

@ -40,8 +40,12 @@ namespace Magnum { namespace Trade { namespace TgaImporter {
/** @brief TGA importer plugin */ /** @brief TGA importer plugin */
class TGAIMPORTER_EXPORT TgaImporter: public AbstractImporter { class TGAIMPORTER_EXPORT TgaImporter: public AbstractImporter {
public: public:
/** @copydoc AbstractImporter::AbstractImporter() */ /** @brief Default constructor */
TgaImporter(Corrade::PluginManager::AbstractPluginManager* manager = 0, const std::string& plugin = ""): AbstractImporter(manager, plugin), _image(nullptr) {} inline explicit TgaImporter(): _image(nullptr) {}
/** @brief Plugin manager constructor */
inline explicit TgaImporter(Corrade::PluginManager::AbstractPluginManager* manager, std::string plugin): AbstractImporter(manager, std::move(plugin)), _image(nullptr) {}
inline virtual ~TgaImporter() { close(); } inline virtual ~TgaImporter() { close(); }
inline Features features() const override { return Feature::OpenFile|Feature::OpenStream; } inline Features features() const override { return Feature::OpenFile|Feature::OpenStream; }

Loading…
Cancel
Save