properly sort port-names
authorRobin Gareus <robin@gareus.org>
Thu, 14 Jul 2016 14:47:27 +0000 (16:47 +0200)
committerRobin Gareus <robin@gareus.org>
Thu, 14 Jul 2016 14:52:43 +0000 (16:52 +0200)
libs/backends/alsa/alsa_audiobackend.h
libs/backends/coreaudio/coreaudio_backend.h
libs/backends/dummy/dummy_audiobackend.h

index f7f7f693bb2e176d019d932473796c33947c0b26..d8dfb31725453f1e6490e26be51f94b697fb040d 100644 (file)
@@ -30,6 +30,7 @@
 
 #include <boost/shared_ptr.hpp>
 
+#include "pbd/natsort.h"
 #include "ardour/audio_backend.h"
 #include "ardour/dsp_load_calculator.h"
 #include "ardour/system_exec.h"
@@ -413,7 +414,7 @@ class AlsaAudioBackend : public AudioBackend {
                {
                        bool operator ()(const AlsaPort* lhs, const AlsaPort* rhs) const
                        {
-                               return lhs->name () < rhs->name ();
+                               return PBD::naturally_less (lhs->name ().c_str (), rhs->name ().c_str ());
                        }
                };
 
index 643604030bcd5613df5efb1cd9b2de5dfba6b5d9..d37ef6c19a92f5878fe543655a17c085f24c911a 100644 (file)
@@ -30,6 +30,7 @@
 
 #include <boost/shared_ptr.hpp>
 
+#include "pbd/natsort.h"
 #include "ardour/audio_backend.h"
 #include "ardour/dsp_load_calculator.h"
 #include "ardour/types.h"
@@ -470,7 +471,7 @@ class CoreAudioBackend : public AudioBackend {
        {
                bool operator ()(const CoreBackendPort* lhs, const CoreBackendPort* rhs) const
                {
-                       return lhs->name () < rhs->name ();
+                       return PBD::naturally_less (lhs->name ().c_str (), rhs->name ().c_str ());
                }
        };
 
index bd597e3301995c6ccea48186ba0ae9d7d7862e18..db4f191cd814378cbc8ab60d53ee8ec955cf6de7 100644 (file)
@@ -30,6 +30,7 @@
 
 #include <boost/shared_ptr.hpp>
 
+#include "pbd/natsort.h"
 #include "ardour/types.h"
 #include "ardour/audio_backend.h"
 #include "ardour/dsp_load_calculator.h"
@@ -455,7 +456,7 @@ class DummyAudioBackend : public AudioBackend {
                {
                        bool operator ()(const DummyPort* lhs, const DummyPort* rhs) const
                        {
-                               return lhs->name () < rhs->name ();
+                               return PBD::naturally_less (lhs->name ().c_str (), rhs->name ().c_str ());
                        }
                };