Kaydet (Commit) d082cb20 authored tarafından Muthu Subramanian's avatar Muthu Subramanian

n747499: Wav/Audio files import - stub.

üst d5786543
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
#include <com/sun/star/geometry/IntegerRectangle2D.hpp> #include <com/sun/star/geometry/IntegerRectangle2D.hpp>
#include "oox/drawingml/color.hxx" #include "oox/drawingml/color.hxx"
#include "oox/helper/helper.hxx" #include "oox/helper/helper.hxx"
#include "oox/drawingml/embeddedwavaudiofile.hxx"
namespace oox { namespace oox {
class GraphicHelper; class GraphicHelper;
...@@ -135,7 +136,8 @@ struct FillProperties ...@@ -135,7 +136,8 @@ struct FillProperties
struct GraphicProperties struct GraphicProperties
{ {
BlipFillProperties maBlipProps; /// Properties for the graphic. BlipFillProperties maBlipProps; /// Properties for the graphic.
EmbeddedWAVAudioFile maAudio; /// Audio file details
/** Overwrites all members that are explicitly set in rSourceProps. */ /** Overwrites all members that are explicitly set in rSourceProps. */
void assignUsed( const GraphicProperties& rSourceProps ); void assignUsed( const GraphicProperties& rSourceProps );
......
...@@ -444,6 +444,10 @@ void GraphicProperties::pushToPropMap( PropertyMap& rPropMap, const GraphicHelpe ...@@ -444,6 +444,10 @@ void GraphicProperties::pushToPropMap( PropertyMap& rPropMap, const GraphicHelpe
sal_Int16 nContrast = getLimitedValue< sal_Int16, sal_Int32 >( maBlipProps.moContrast.get( 0 ) / PER_PERCENT, -100, 100 ); sal_Int16 nContrast = getLimitedValue< sal_Int16, sal_Int32 >( maBlipProps.moContrast.get( 0 ) / PER_PERCENT, -100, 100 );
if( nContrast != 0 ) if( nContrast != 0 )
rPropMap[ PROP_AdjustContrast ] <<= nContrast; rPropMap[ PROP_AdjustContrast ] <<= nContrast;
// TODO: Audio content, yet to be implemented
if( !maAudio.msEmbed.isEmpty() )
rPropMap[ PROP_Sound ] <<= maAudio.msEmbed;
} }
// ============================================================================ // ============================================================================
......
...@@ -76,6 +76,9 @@ Reference< XFastContextHandler > GraphicShapeContext::createFastChildContext( sa ...@@ -76,6 +76,9 @@ Reference< XFastContextHandler > GraphicShapeContext::createFastChildContext( sa
case XML_blipFill: case XML_blipFill:
xRet.set( new BlipFillContext( *this, xAttribs, mpShapePtr->getGraphicProperties().maBlipProps ) ); xRet.set( new BlipFillContext( *this, xAttribs, mpShapePtr->getGraphicProperties().maBlipProps ) );
break; break;
case XML_wavAudioFile:
getEmbeddedWAVAudioFile( getRelations(), xAttribs, mpShapePtr->getGraphicProperties().maAudio );
break;
} }
if ((getNamespace( aElementToken ) == NMSP_vml) && mpShapePtr) if ((getNamespace( aElementToken ) == NMSP_vml) && mpShapePtr)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment