2005-03-18 16:11:24 +00:00
|
|
|
/*************************************************************************
|
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* OpenOffice.org - a multi-platform office productivity suite
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* $RCSfile: animationcommandnode.cxx,v $
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2006-09-17 07:33:51 +00:00
|
|
|
* $Revision: 1.6 $
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2006-09-17 07:33:51 +00:00
|
|
|
* last change: $Author: obo $ $Date: 2006-09-17 08:33:51 $
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* The Contents of this file are made available subject to
|
|
|
|
* the terms of GNU Lesser General Public License Version 2.1.
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* GNU Lesser General Public License Version 2.1
|
|
|
|
* =============================================
|
|
|
|
* Copyright 2005 by Sun Microsystems, Inc.
|
|
|
|
* 901 San Antonio Road, Palo Alto, CA 94303, USA
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License version 2.1, as published by the Free Software Foundation.
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
2005-09-07 19:40:33 +00:00
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
|
|
|
* MA 02111-1307 USA
|
2005-03-18 16:11:24 +00:00
|
|
|
*
|
|
|
|
************************************************************************/
|
|
|
|
|
2006-09-17 07:33:51 +00:00
|
|
|
// MARKER(update_precomp.py): autogen include statement, do not remove
|
|
|
|
#include "precompiled_slideshow.hxx"
|
|
|
|
|
2005-03-18 16:11:24 +00:00
|
|
|
// must be first
|
2006-07-26 06:30:55 +00:00
|
|
|
#include "canvas/debug.hxx"
|
|
|
|
#include "canvas/verbosetrace.hxx"
|
|
|
|
#include "com/sun/star/presentation/EffectCommands.hpp"
|
|
|
|
#include "animationcommandnode.hxx"
|
|
|
|
#include "delayevent.hxx"
|
|
|
|
#include "tools.hxx"
|
|
|
|
#include "nodetools.hxx"
|
|
|
|
|
|
|
|
namespace presentation {
|
|
|
|
namespace internal {
|
|
|
|
|
|
|
|
void AnimationCommandNode::dispose()
|
2005-03-18 16:11:24 +00:00
|
|
|
{
|
2006-07-26 06:30:55 +00:00
|
|
|
mxCommandNode.clear();
|
|
|
|
BaseNode::dispose();
|
|
|
|
}
|
2005-03-18 16:11:24 +00:00
|
|
|
|
2006-07-26 06:30:55 +00:00
|
|
|
void AnimationCommandNode::activate_()
|
|
|
|
{
|
|
|
|
namespace EffectCommands = com::sun::star::presentation::EffectCommands;
|
|
|
|
|
|
|
|
switch( mxCommandNode->getCommand() ) {
|
|
|
|
// the command is user defined
|
|
|
|
case EffectCommands::CUSTOM: break;
|
|
|
|
// the command is an ole verb.
|
|
|
|
case EffectCommands::VERB: break;
|
|
|
|
// the command starts playing on a media object
|
|
|
|
case EffectCommands::PLAY: break;
|
|
|
|
// the command toggles the pause status on a media object
|
|
|
|
case EffectCommands::TOGGLEPAUSE: break;
|
|
|
|
// the command stops the animation on a media object
|
|
|
|
case EffectCommands::STOP: break;
|
|
|
|
// the command stops all currently running sound effects
|
|
|
|
case EffectCommands::STOPAUDIO:
|
|
|
|
getContext().mrEventMultiplexer.notifyCommandStopAudio( getSelf() );
|
|
|
|
break;
|
|
|
|
}
|
2005-03-18 16:11:24 +00:00
|
|
|
|
2006-07-26 06:30:55 +00:00
|
|
|
// deactivate ASAP:
|
|
|
|
scheduleDeactivationEvent(
|
|
|
|
makeEvent( boost::bind( &AnimationNode::deactivate, getSelf() ) ) );
|
|
|
|
}
|
2005-03-18 16:11:24 +00:00
|
|
|
|
2006-07-26 06:30:55 +00:00
|
|
|
bool AnimationCommandNode::hasPendingAnimation() const
|
|
|
|
{
|
|
|
|
return false;
|
2005-03-18 16:11:24 +00:00
|
|
|
}
|
2006-07-26 06:30:55 +00:00
|
|
|
|
|
|
|
} // namespace internal
|
|
|
|
} // namespace presentation
|