- // this is the colour to use for the wxANIM_TOBACKGROUND disposal.
- // if not specified by the animation, it's set to wxNullColour
- wxColour m_background;
+ virtual bool Load( wxInputStream& stream ) = 0;
+
+ bool CanRead( wxInputStream& stream ) const
+ {
+ // NOTE: this code is the same of wxImageHandler::CallDoCanRead
+
+ if ( !stream.IsSeekable() )
+ return false; // can't test unseekable stream
+
+ wxFileOffset posOld = stream.TellI();
+ bool ok = DoCanRead(stream);
+
+ // restore the old position to be able to test other formats and so on
+ if ( stream.SeekI(posOld) == wxInvalidOffset )
+ {
+ wxLogDebug(wxT("Failed to rewind the stream in wxAnimationDecoder!"));