Skip to content

Commit

Permalink
Merge pull request xbmc#24009 from mglae/omega_python_getregion
Browse files Browse the repository at this point in the history
[python] Fix xmbc.getRegion("time")
  • Loading branch information
enen92 authored Nov 1, 2023
2 parents 9d68f98 + d6d64da commit 6700236
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
9 changes: 6 additions & 3 deletions xbmc/interfaces/legacy/ModuleXbmc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -446,11 +446,14 @@ namespace XBMCAddon
else
{
StringUtils::Replace(result, "H", "%H");
StringUtils::Replace(result, "hh", "%I");
StringUtils::Replace(result, "h", "%I");
StringUtils::Replace(result, "mm", "%M");
StringUtils::Replace(result, "ss", "%S");
StringUtils::Replace(result, "xx", "%p");
}
StringUtils::Replace(result, "mm", "%M");
StringUtils::Replace(result, "m", "%M");
StringUtils::Replace(result, "ss", "%S");
StringUtils::Replace(result, "s", "%S");
StringUtils::Replace(result, "xx", "%p");
}
else if (StringUtils::CompareNoCase(id, "meridiem") == 0)
{
Expand Down
6 changes: 4 additions & 2 deletions xbmc/interfaces/legacy/ModuleXbmc.h
Original file line number Diff line number Diff line change
Expand Up @@ -649,9 +649,11 @@ namespace XBMCAddon
/// @param id string - id of setting to return
/// @return Region setting
///
/// @note choices are (dateshort, datelong, time, meridiem, tempunit, speedunit)
/// You can use the above as keywords for arguments.
/// @note choices are (dateshort, datelong, time, meridiem, tempunit, speedunit,
/// datelongraw, dateshortraw, timeraw)
/// You can use the above as keywords for arguments.
///
/// @warning an empty string is returned if the provided Id is not supported
///
/// ------------------------------------------------------------------------
///
Expand Down

0 comments on commit 6700236

Please sign in to comment.