Changeset 10917 for trunk/FACT++/gui
- Timestamp:
- 06/07/11 17:10:28 (13 years ago)
- Location:
- trunk/FACT++/gui
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/gui/FactGui.h
r10781 r10917 1219 1219 break; 1220 1220 } 1221 1222 const int cnt = count(&fFtuStatus[0], &fFtuStatus[40], 0); 1223 fFtuAllOn->setEnabled(cnt!=0); 1224 fFtuAllOff->setEnabled(cnt!=40); 1221 1225 } 1222 1226 … … 1325 1329 } 1326 1330 1327 f Ping->setChecked(false);1331 fFtuPing->setChecked(false); 1328 1332 1329 1333 const FTM::DimFtuList &sdata = *reinterpret_cast<const FTM::DimFtuList*>(d.ptr()); -
trunk/FACT++/gui/MainWindow.cc
r10916 r10917 285 285 } 286 286 287 void MainWindow::on_f Ping_toggled(bool checked)287 void MainWindow::on_fFtuPing_toggled(bool checked) 288 288 { 289 289 if (checked) … … 291 291 } 292 292 293 void MainWindow::on_fFtuAllOn_clicked() 294 { 295 static const struct Data { int32_t id; char on; } __attribute__((__packed__)) d = { -1, 1 }; 296 Dim::SendCommand("FTM_CONTROL/ENABLE_FTU", &d, sizeof(d)); 297 } 298 299 void MainWindow::on_fFtuAllOff_clicked() 300 { 301 static const struct Data { int32_t id; char on; } __attribute__((__packed__)) d = { -1, 0 }; 302 Dim::SendCommand("FTM_CONTROL/ENABLE_FTU", &d, sizeof(d)); 303 } 304 293 305 void MainWindow::on_fChatSend_clicked() 294 306 { -
trunk/FACT++/gui/MainWindow.h
r10916 r10917 80 80 // Tab: FTUs 81 81 void slot_fFtuLED_clicked(); 82 void on_fPing_toggled(bool); 82 void on_fFtuPing_toggled(bool); 83 void on_fFtuAllOn_clicked(); 84 void on_fFtuAllOff_clicked(); 83 85 84 86 // Tab: Rates -
trunk/FACT++/gui/design.ui
r10916 r10917 52 52 </property> 53 53 <property name="currentIndex"> 54 <number> 4</number>54 <number>1</number> 55 55 </property> 56 56 <property name="documentMode"> … … 2089 2089 </property> 2090 2090 <layout class="QGridLayout" name="gridLayout_32"> 2091 <item row="1" column="0" colspan=" 3">2091 <item row="1" column="0" colspan="6"> 2092 2092 <layout class="QGridLayout" name="fFtuLedLayout" rowstretch="0,1,1,1,1" columnstretch="0,1,1,1,1,1,1,1,1,1,1,0"> 2093 2093 <property name="margin"> … … 2342 2342 </layout> 2343 2343 </item> 2344 <item row="2" column=" 1">2345 <widget class="QPushButton" name="f Ping">2344 <item row="2" column="4"> 2345 <widget class="QPushButton" name="fFtuPing"> 2346 2346 <property name="text"> 2347 2347 <string> Ping </string> … … 2352 2352 </widget> 2353 2353 </item> 2354 <item row="2" column="0"> 2354 <item row="2" column="1"> 2355 <widget class="QPushButton" name="fFtuAllOn"> 2356 <property name="text"> 2357 <string>All on</string> 2358 </property> 2359 </widget> 2360 </item> 2361 <item row="2" column="3"> 2355 2362 <spacer name="horizontalSpacer_13"> 2356 2363 <property name="orientation"> … … 2364 2371 </property> 2365 2372 </spacer> 2373 </item> 2374 <item row="2" column="2"> 2375 <widget class="QPushButton" name="fFtuAllOff"> 2376 <property name="text"> 2377 <string>All off</string> 2378 </property> 2379 </widget> 2366 2380 </item> 2367 2381 </layout>
Note:
See TracChangeset
for help on using the changeset viewer.