2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-16 16:56:04 +00:00

98_GOOGLECAST: fix umlauts for device name readings

git-svn-id: https://svn.fhem.de/fhem/trunk@16386 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
dominikkarall 2018-03-11 19:37:47 +00:00
parent 80cf7308d0
commit 2cd50573bd

View File

@ -7,10 +7,13 @@
# FHEM module to communicate with Google Cast devices # FHEM module to communicate with Google Cast devices
# e.g. Chromecast Video, Chromecast Audio, Google Home # e.g. Chromecast Video, Chromecast Audio, Google Home
# #
# Version: 2.1.2 # Version: 2.1.3
# #
############################################################# #############################################################
# #
# v2.1.3 - 20180311
# - BUGFIX: fix umlauts for device name readings
#
# v2.1.2 - 20180310 # v2.1.2 - 20180310
# - BUGFIX: fix speak, play, displayWebsite # - BUGFIX: fix speak, play, displayWebsite
# - FEATURE: added German commandref (thx@Sailor) # - FEATURE: added German commandref (thx@Sailor)
@ -150,7 +153,7 @@ sub GOOGLECAST_Initialize($) {
$hash->{AttrList} = "favoriteURL_1 favoriteURL_2 favoriteURL_3 favoriteURL_4 ". $hash->{AttrList} = "favoriteURL_1 favoriteURL_2 favoriteURL_3 favoriteURL_4 ".
"favoriteURL_5 ".$readingFnAttributes; "favoriteURL_5 ".$readingFnAttributes;
Log3 $hash, 3, "GOOGLECAST: GoogleCast v2.1.2"; Log3 $hash, 3, "GOOGLECAST: GoogleCast v2.1.3";
return undef; return undef;
} }
@ -626,7 +629,7 @@ sub GOOGLECAST_Read {
} }
GOOGLECAST_updateReading($hash, "presence", "online"); GOOGLECAST_updateReading($hash, "presence", "online");
GOOGLECAST_updateReading($hash, "name", $hash->{helper}{ccdevice}->{name}); GOOGLECAST_updateReading($hash, "name", Encode::encode("UTF-8", $hash->{helper}{ccdevice}->{name}));
GOOGLECAST_updateReading($hash, "model", $hash->{helper}{ccdevice}->{model_name}); GOOGLECAST_updateReading($hash, "model", $hash->{helper}{ccdevice}->{model_name});
GOOGLECAST_updateReading($hash, "uuid", $hash->{helper}{ccdevice}->{uuid}); GOOGLECAST_updateReading($hash, "uuid", $hash->{helper}{ccdevice}->{uuid});
GOOGLECAST_updateReading($hash, "castType", $hash->{helper}{ccdevice}->{cast_type}); GOOGLECAST_updateReading($hash, "castType", $hash->{helper}{ccdevice}->{cast_type});