summaryrefslogtreecommitdiffstats
path: root/src/multimedia
diff options
context:
space:
mode:
authorJustin McPherson <justin.mcpherson@nokia.com>2009-09-02 05:39:39 (GMT)
committerJustin McPherson <justin.mcpherson@nokia.com>2009-09-02 05:39:39 (GMT)
commitfb530ac0a12b90527b9792b31e08043518dd8bd7 (patch)
tree07255270f9a0a577c4cc1fe39905ad7733cf79ce /src/multimedia
parent441fcb027ddbe4a34c67af8cfbda14b9edafbcfd (diff)
downloadQt-fb530ac0a12b90527b9792b31e08043518dd8bd7.zip
Qt-fb530ac0a12b90527b9792b31e08043518dd8bd7.tar.gz
Qt-fb530ac0a12b90527b9792b31e08043518dd8bd7.tar.bz2
Copy ctor and assignment operator for QAudioFormatPrivate (QSharedData derived class).
Reviewed-by: bill king
Diffstat (limited to 'src/multimedia')
-rw-r--r--src/multimedia/audio/qaudioformat.cpp24
1 files changed, 23 insertions, 1 deletions
diff --git a/src/multimedia/audio/qaudioformat.cpp b/src/multimedia/audio/qaudioformat.cpp
index 71bbf83..6ae230f 100644
--- a/src/multimedia/audio/qaudioformat.cpp
+++ b/src/multimedia/audio/qaudioformat.cpp
@@ -57,10 +57,32 @@ public:
sampleType = QAudioFormat::Unknown;
}
+ QAudioFormatPrivate(const QAudioFormatPrivate &other):
+ QSharedData(other),
+ codec(other.codec),
+ byteOrder(other.byteOrder),
+ sampleType(other.sampleType),
+ frequency(other.frequency),
+ channels(other.channels),
+ sampleSize(other.sampleSize)
+ {
+ }
+
+ QAudioFormatPrivate& operator=(const QAudioFormatPrivate &other)
+ {
+ codec = other.codec;
+ byteOrder = other.byteOrder;
+ sampleType = other.sampleType;
+ frequency = other.frequency;
+ channels = other.channels;
+ sampleSize = other.sampleSize;
+
+ return *this;
+ }
+
QString codec;
QAudioFormat::Endian byteOrder;
QAudioFormat::SampleType sampleType;
-
int frequency;
int channels;
int sampleSize;