diff options
| author | Carl Hetherington <cth@carlh.net> | 2022-03-16 22:10:55 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2022-03-18 00:12:44 +0100 |
| commit | c36cc02c31740f6676e31df2c36001e5d082c71c (patch) | |
| tree | e0919a64234f5958855a576b6e7b68d2fbf53bd5 /src/wx/screens_panel.h | |
| parent | ff474f597a40366d4232e1d5a43de824538f08c1 (diff) | |
Use the ICU library to sort cinemas rather than strcoll() (part of #2208).
strcoll() just doesn't really seem to work at all on Windows.
Diffstat (limited to 'src/wx/screens_panel.h')
| -rw-r--r-- | src/wx/screens_panel.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/wx/screens_panel.h b/src/wx/screens_panel.h index c0b90dfcf..4b7a80141 100644 --- a/src/wx/screens_panel.h +++ b/src/wx/screens_panel.h @@ -36,6 +36,7 @@ namespace dcpomatic { class Cinema; +class UCollator; class ScreensPanel : public wxPanel @@ -90,10 +91,13 @@ private: class Comparator : public wxTreeListItemComparator { public: - int Compare (wxTreeListCtrl* tree_list, unsigned, wxTreeListItem a, wxTreeListItem b) override - { - return strcoll(wx_to_std(tree_list->GetItemText(a)).c_str(), wx_to_std(tree_list->GetItemText(b)).c_str()); - } + Comparator (); + ~Comparator (); + + int Compare (wxTreeListCtrl* tree_list, unsigned, wxTreeListItem a, wxTreeListItem b) override; + + private: + UCollator* _collator; }; Comparator _comparator; |
