QTfrontend/pages.cpp
changeset 3141 70d65353bd60
parent 3074 271cfcb2bcda
child 3159 e5eff81d7635
equal deleted inserted replaced
3140:749682ae8926 3141:70d65353bd60
  1042         item = new QTableWidgetItem(list[i + 4].left(15)); // name of host
  1042         item = new QTableWidgetItem(list[i + 4].left(15)); // name of host
  1043         item->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable);
  1043         item->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable);
  1044         item->setToolTip(tr("%1 is the host. He may adjust settings and start the game.").arg(list[i + 4]));
  1044         item->setToolTip(tr("%1 is the host. He may adjust settings and start the game.").arg(list[i + 4]));
  1045         roomsList->setItem(r, 3, item);
  1045         roomsList->setItem(r, 3, item);
  1046 
  1046 
  1047         if(list[i + 5].compare("+rnd+"))
  1047         if(list[i + 5] == "+rnd+")
       
  1048             item = new QTableWidgetItem(tr("Random Map")); // selected map (is randomized)
       
  1049         else if (list[i+5] == "+maze+")
       
  1050             item = new QTableWidgetItem(tr("Random Maze"));
       
  1051         else
  1048         {
  1052         {
  1049             item = new QTableWidgetItem(list[i + 5]); // selected map
  1053             item = new QTableWidgetItem(list[i + 5]); // selected map
  1050             
  1054             
  1051             // check to see if we've got this map
  1055             // check to see if we've got this map
  1052             // not perfect but a start
  1056             // not perfect but a start
  1053             if(!mapList->contains(list[i + 5]))
  1057             if(!mapList->contains(list[i + 5]))
  1054                 item->setForeground(QBrush(QColor(255, 0, 0)));
  1058                 item->setForeground(QBrush(QColor(255, 0, 0)));
  1055         }
  1059         }
  1056         else
       
  1057             item = new QTableWidgetItem(tr("Random Map")); // selected map (is randomized)
       
  1058         
  1060         
  1059         item->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable);
  1061         item->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable);
  1060         item->setToolTip(tr("Games may be played on precreated or randomized maps."));
  1062         item->setToolTip(tr("Games may be played on precreated or randomized maps."));
  1061         roomsList->setItem(r, 4, item);
  1063         roomsList->setItem(r, 4, item);
  1062 
  1064