Changeset 11169 for trunk/FACT++/gui
- Timestamp:
- 06/24/11 13:16:04 (14 years ago)
- Location:
- trunk/FACT++/gui
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/gui/FactGui.h
r11166 r11169 391 391 DimStampedInfo fDimFadFwVersion; 392 392 DimStampedInfo fDimFadPllLock; 393 DimStampedInfo fDimFadDrsEnabled; 393 394 DimStampedInfo fDimFadStatistics; 394 395 … … 1116 1117 void handleFadPllLock(const DimData &d) 1117 1118 { 1118 if (!CheckSize(d, 4 3*sizeof(uint8_t)))1119 if (!CheckSize(d, 41*sizeof(uint8_t))) 1119 1120 return; 1120 1121 … … 1135 1136 { 1136 1137 tip << "<td>" 1137 << (int)(ptr[c*10+b+ 3]&8)1138 << (int)(ptr[c*10+b+ 3]&4)1139 << (int)(ptr[c*10+b+ 3]&2)1140 << (int)(ptr[c*10+b+ 3]&1)1138 << (int)(ptr[c*10+b+1]&8) 1139 << (int)(ptr[c*10+b+1]&4) 1140 << (int)(ptr[c*10+b+1]&2) 1141 << (int)(ptr[c*10+b+1]&1) 1141 1142 << "</td>"; 1142 1143 } … … 1146 1147 1147 1148 fFadLedPllLock->setToolTip(tip.str().c_str()); 1149 } 1150 1151 void handleFadDrsEnabled(const DimData &d) 1152 { 1153 if (!CheckSize(d, 41*sizeof(uint8_t))) 1154 return; 1155 1156 const uint8_t *ptr = d.ptr<uint8_t>(); 1157 1158 SetLedColor(fFadLedDrsEnabled, d.qos?(ptr[0]?kLedGreen:kLedRed):kLedOrange, d.time); 1159 1160 ostringstream tip; 1161 tip << "<table border='1'><tr><th colspan='11'>" << Time().GetAsStr() << "</th></tr><tr><th></th>"; 1162 for (int b=0; b<10; b++) 1163 tip << "<th>" << b << "</th>"; 1164 tip << "</tr>"; 1165 1166 for (int c=0; c<4; c++) 1167 { 1168 tip << "<tr><th>" << c << "</th>"; 1169 for (int b=0; b<10; b++) 1170 { 1171 tip << "<td>" 1172 << (ptr[c*10+b+1]?"on":"off") 1173 << "</td>"; 1174 } 1175 tip << "</tr>"; 1176 } 1177 tip << "</table>"; 1178 1179 fFadLedDrsEnabled->setToolTip(tip.str().c_str()); 1180 1148 1181 } 1149 1182 … … 1946 1979 return PostInfoHandler(&FactGui::handleFadPllLock); 1947 1980 1981 if (getInfo()==&fDimFadDrsEnabled) 1982 return PostInfoHandler(&FactGui::handleFadDrsEnabled); 1983 1948 1984 if (getInfo()==&fDimFadStatistics) 1949 1985 return PostInfoHandler(&FactGui::handleFadStatistics); … … 2388 2424 fDimFadFwVersion ("FAD_CONTROL/FIRMWARE_VERSION", (void*)NULL, 0, this), 2389 2425 fDimFadPllLock ("FAD_CONTROL/PLL_LOCK", (void*)NULL, 0, this), 2426 fDimFadDrsEnabled ("FAD_CONTROL/DRS_ENABLED", (void*)NULL, 0, this), 2390 2427 fDimFadStatistics ("FAD_CONTROL/STATISTICS", (void*)NULL, 0, this) 2391 2428 { -
trunk/FACT++/gui/design.ui
r11167 r11169 3088 3088 <layout class="QGridLayout" name="gridLayout_37"> 3089 3089 <item row="1" column="0"> 3090 <widget class="QPushButton" name="fFadLedD enable">3090 <widget class="QPushButton" name="fFadLedDrsEnabled"> 3091 3091 <property name="enabled"> 3092 3092 <bool>true</bool>
Note:
See TracChangeset
for help on using the changeset viewer.