Skip to content

Commit 812fc59

Browse files
committed
Change some lists to vectors if they are used to created RPC::IteratorType
1 parent cfbb470 commit 812fc59

7 files changed

Lines changed: 12 additions & 12 deletions

File tree

DeviceInfo/DeviceInfoImplementation.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ namespace Plugin {
7575
{
7676
AudioOutputList audioOutputList;
7777

78-
std::transform(_audioOutputMap.begin(), _audioOutputMap.end(), std::front_inserter(audioOutputList),
78+
std::transform(_audioOutputMap.begin(), _audioOutputMap.end(), std::back_inserter(audioOutputList),
7979
[](decltype(_audioOutputMap)::value_type const &pair) {
8080
return pair.first;
8181
});

DeviceInfo/DeviceInfoImplementation.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ namespace Plugin {
151151
std::list<IDeviceAudioCapabilities::MS12Profile> MS12Profiles;
152152
};
153153
using AudioOutputMap = std::map<Exchange::IDeviceAudioCapabilities::AudioOutput, AudioOutputCapability>;
154-
using AudioOutputList = std::list<Exchange::IDeviceAudioCapabilities::AudioOutput>;
154+
using AudioOutputList = std::vector<Exchange::IDeviceAudioCapabilities::AudioOutput>;
155155
using AudioOutputIteratorImplementation = RPC::IteratorType<Exchange::IDeviceAudioCapabilities::IAudioOutputIterator>;
156156

157157
struct VideoOutputCapability {
@@ -160,7 +160,7 @@ namespace Plugin {
160160
IDeviceVideoCapabilities::CopyProtection CopyProtection;
161161
};
162162
using VideoOutputMap = std::map<Exchange::IDeviceVideoCapabilities::VideoOutput, VideoOutputCapability>;
163-
using VideoOutputList = std::list<Exchange::IDeviceVideoCapabilities::VideoOutput>;
163+
using VideoOutputList = std::vector<Exchange::IDeviceVideoCapabilities::VideoOutput>;
164164
using VideoOutputIteratorImplementation = RPC::IteratorType<Exchange::IDeviceVideoCapabilities::IVideoOutputIterator>;
165165

166166
public:

DisplayInfo/DeviceSettings/PlatformImplementation.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ class DisplayInfoImplementation :
584584

585585
uint32_t Colorimetry(IColorimetryIterator*& colorimetry /* @out */) const override
586586
{
587-
std::list<Exchange::IDisplayProperties::ColorimetryType> colorimetryCaps;
587+
std::vector<Exchange::IDisplayProperties::ColorimetryType> colorimetryCaps;
588588
vector<uint8_t> edidVec;
589589
uint32_t ret = GetEdidBytes(edidVec);
590590
if (ret == Core::ERROR_NONE)
@@ -665,7 +665,7 @@ class DisplayInfoImplementation :
665665
// @return HDRType: array of HDR formats
666666
uint32_t TVCapabilities(IHDRIterator*& type /* out */) const override
667667
{
668-
std::list<Exchange::IHDRProperties::HDRType> hdrCapabilities;
668+
std::vector<Exchange::IHDRProperties::HDRType> hdrCapabilities;
669669

670670
int capabilities = static_cast<int>(dsHDRSTANDARD_NONE);
671671
try
@@ -699,7 +699,7 @@ class DisplayInfoImplementation :
699699
// @return HDRType: array of HDR formats
700700
uint32_t STBCapabilities(IHDRIterator*& type /* out */) const override
701701
{
702-
std::list<Exchange::IHDRProperties::HDRType> hdrCapabilities;
702+
std::vector<Exchange::IHDRProperties::HDRType> hdrCapabilities;
703703

704704
int capabilities = static_cast<int>(dsHDRSTANDARD_NONE);
705705
try

MessageControl/MessageControl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ namespace Plugin {
432432

433433
Core::hresult Controls(const string& module, Exchange::IMessageControl::IControlIterator*& controls) const override
434434
{
435-
std::list<Exchange::IMessageControl::Control> list;
435+
std::vector<Exchange::IMessageControl::Control> list;
436436
Messaging::MessageUnit::Iterator index;
437437
_client.Controls(index, module);
438438

PlayerInfo/DeviceSettings/PlatformImplementation.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -483,8 +483,8 @@ class PlayerInfoImplementation : public Exchange::IPlayerProperties, public Exch
483483
}
484484

485485
private:
486-
std::list<Exchange::IPlayerProperties::AudioCodec> _audioCodecs;
487-
std::list<Exchange::IPlayerProperties::VideoCodec> _videoCodecs;
486+
std::vector<Exchange::IPlayerProperties::AudioCodec> _audioCodecs;
487+
std::vector<Exchange::IPlayerProperties::VideoCodec> _videoCodecs;
488488
std::map<string, Exchange::IPlayerProperties::PlaybackResolution> _resolutions =
489489
{
490490
{"480i24", RESOLUTION_480I24},

PlayerInfo/GStreamer/PlatformImplementation.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -191,8 +191,8 @@ class PlayerInfoImplementation : public Exchange::IPlayerProperties {
191191
}
192192

193193
private:
194-
std::list<Exchange::IPlayerProperties::AudioCodec> _audioCodecs;
195-
std::list<Exchange::IPlayerProperties::VideoCodec> _videoCodecs;
194+
std::vector<Exchange::IPlayerProperties::AudioCodec> _audioCodecs;
195+
std::vector<Exchange::IPlayerProperties::VideoCodec> _videoCodecs;
196196
#if DOLBY_SUPPORT
197197
Exchange::Dolby::IOutput* _dolbyOut;
198198
#endif

WebKitBrowser/WebKitBrowser.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ namespace Plugin {
331331
Core::JSON::ArrayType<Core::JSON::String> array;
332332
array.FromString(languagesList);
333333

334-
std::list<string> list;
334+
std::vector<string> list;
335335
auto iterator = array.Elements();
336336

337337
while (iterator.Next() == true) {

0 commit comments

Comments
 (0)