diff options
author | B Stack <bgstack15@gmail.com> | 2020-09-01 00:24:17 +0000 |
---|---|---|
committer | B Stack <bgstack15@gmail.com> | 2020-09-01 00:24:17 +0000 |
commit | 5a3f52b016581a6a0cb4513614b6c620d365dde2 (patch) | |
tree | acfdfb3e1046db87040477033fda0df76d92916a /wx+/choice_enum.h | |
parent | Merge branch '11.0' into 'master' (diff) | |
parent | add upstream 11.1 (diff) | |
download | FreeFileSync-5a3f52b016581a6a0cb4513614b6c620d365dde2.tar.gz FreeFileSync-5a3f52b016581a6a0cb4513614b6c620d365dde2.tar.bz2 FreeFileSync-5a3f52b016581a6a0cb4513614b6c620d365dde2.zip |
Merge branch '11.1' into 'master'11.1
add upstream 11.1
See merge request opensource-tracking/FreeFileSync!25
Diffstat (limited to 'wx+/choice_enum.h')
-rw-r--r-- | wx+/choice_enum.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/wx+/choice_enum.h b/wx+/choice_enum.h index e11b9991..626aa39a 100644 --- a/wx+/choice_enum.h +++ b/wx+/choice_enum.h @@ -104,7 +104,7 @@ Enum getEnumVal(const EnumDescrList<Enum>& mapping, const wxChoice& ctrl) { const int selectedPos = ctrl.GetSelection(); - if (0 <= selectedPos && selectedPos < static_cast<int>(mapping.descrList.size())) + if (0 <= selectedPos && selectedPos < std::ssize(mapping.descrList)) return mapping.descrList[selectedPos].first; else { @@ -117,7 +117,7 @@ template <class Enum> void updateTooltipEnumVal(const EnumDescrList<Enum>& mappi { const int selectedPos = ctrl.GetSelection(); - if (0 <= selectedPos && selectedPos < static_cast<int>(mapping.descrList.size())) + if (0 <= selectedPos && selectedPos < std::ssize(mapping.descrList)) { if (const auto& [text, tooltip] = mapping.descrList[selectedPos].second; !tooltip.empty()) |