QTfrontend/model/playerslistmodel.cpp
changeset 7765 1e162c1d6dc7
parent 7764 28613382e3f3
child 7833 20e3bd929f07
--- a/QTfrontend/model/playerslistmodel.cpp	Wed Oct 17 23:09:16 2012 +0400
+++ b/QTfrontend/model/playerslistmodel.cpp	Wed Oct 17 23:33:33 2012 +0400
@@ -186,6 +186,7 @@
             setData(mi, "0", RoomFilterRole);
             setData(mi, false, RoomAdmin);
             setData(mi, false, Ready);
+            setData(mi, false, InGame);
 
             updateSortData(mi);
             updateIcon(mi);
@@ -205,6 +206,7 @@
         << index.data(Registered).toBool()
         << index.data(Friend).toBool()
         << index.data(Ignore).toBool()
+        << index.data(InGame).toBool()
         << (index.data(RoomFilterRole).toString() == "1")
         ;
 
@@ -224,10 +226,13 @@
         QPainter painter(&result);
 
         if(index.data(RoomFilterRole).toString() == "1")
-            if(index.data(Ready).toBool())
-                painter.drawPixmap(0, 0, 16, 16, QPixmap(":/res/chat/lamp.png"));
+            if(index.data(InGame).toBool())
+                painter.drawPixmap(0, 0, 16, 16, QPixmap(":/res/chat/ingame.png"));
             else
-                painter.drawPixmap(0, 0, 16, 16, QPixmap(":/res/chat/lamp_off.png"));
+                if(index.data(Ready).toBool())
+                    painter.drawPixmap(0, 0, 16, 16, QPixmap(":/res/chat/lamp.png"));
+                else
+                    painter.drawPixmap(0, 0, 16, 16, QPixmap(":/res/chat/lamp_off.png"));
 
         QString mainIconName(":/res/chat/");