From d67452ec7a71b140ef85149b07355df8e1cf2e90 Mon Sep 17 00:00:00 2001 From: Michael Ziegler Date: Thu, 13 May 2010 23:18:03 +0200 Subject: [PATCH] show talking players with the red lips icon in the channel viewer --- htdocs/mumble/talking_on.png | Bin 0 -> 598 bytes pyweb/mumble/mmobjects.py | 3 +++ pyweb/mumble/templates/mumble/player.html | 6 +++++- 3 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 htdocs/mumble/talking_on.png diff --git a/htdocs/mumble/talking_on.png b/htdocs/mumble/talking_on.png new file mode 100644 index 0000000000000000000000000000000000000000..defc296c746ef5633557e660bb9ebf709dce84d9 GIT binary patch literal 598 zcmV-c0;&CpP)yQCLGl3*Nx+x z{glhu-Jv1G%Vk8$WhiEB7Ygu;MOgFmP_wf-Y*`NmdwWmQ(o#SI5Q@cnqV=RO!w^Bo zVyHEnsJ7cs%t$#7Qnn4$s>6kL+{+#E94_=yvWHPYaFxUvX zn;!uoP>&1G^WcB(VEfq%%wL(o&PGF`vDif$B8SdbtL9dt5gvHEic?dQDCD!)lS(2Q zb-(~RTOF)#)baB58{EEg7n{u{jz*(2qtqElsdO?Z6!eXO0of4>34lN163Nv>LSA_u zFDH{XNdQa6$Dcy$!!51lQL{**Jge! z#*8pC*cj;VXbq(`lrhjETdwO)rE9e(zY{5@Mb0&pI#CUR%sZvxKC_i3>h310^jX$| k4P5K5R@eW&)Bh}A0ljt-Y6;1%r2qf`07*qoM6N<$f@voaVE_OC literal 0 HcmV?d00001 diff --git a/pyweb/mumble/mmobjects.py b/pyweb/mumble/mmobjects.py index 549737b..6595c78 100644 --- a/pyweb/mumble/mmobjects.py +++ b/pyweb/mumble/mmobjects.py @@ -268,6 +268,9 @@ class mmPlayer( object ): doc="True if this player is in the Admin group in the ACL." ) + # Totally ripped from Pimmetje + isTalking = property( lambda self: self.idlesecs == 0, doc="True if this player is currently talking." ) + is_server = False is_channel = False is_player = True diff --git a/pyweb/mumble/templates/mumble/player.html b/pyweb/mumble/templates/mumble/player.html index d494625..9d00d60 100644 --- a/pyweb/mumble/templates/mumble/player.html +++ b/pyweb/mumble/templates/mumble/player.html @@ -29,7 +29,11 @@ - Player + {% if Player.isTalking %} + Player + {% else %} + Player + {% endif %} {{ Player.name|trunc:30 }}