46 #include <QMessageBox>
47 #include <QInputDialog>
49 #include <QCloseEvent>
50 #include <QFileDialog>
57 #include <QPrintDialog>
58 #include <QProgressBar>
59 #include <QStyleFactory>
62 #include <QDesktopServices>
65 #include <QGraphicsView>
66 #include <QGraphicsScene>
93 m_betweenevents(true),
95 m_dummyemptycontroller(
new QWidget(0)),
98 m_settingsfile(QDir::homePath()+QDir::separator()+
".atlasvp1"),
99 m_userRequestedExit(false),
100 m_streamMenuUpdater(0),
101 m_mutex(
new QMutex()),
108 #if defined BUILDVP1LIGHT
114 if (!checkShowAllCruiseAndEventControls) {
115 pushButton_eventseek->setVisible(
false);
116 groupBox_cruise->setVisible(
false);
129 menubar->addAction(
menu_file->menuAction());
135 #ifndef BUILDVP1LIGHT
136 pushButton_previousevent->setVisible(
false);
137 pushButton_eventselect->setVisible(
false);
139 pushButton_eventselect->setVisible(
true);
140 pushButton_eventselect->setText(
"Event: 0/0");
141 pushButton_eventselect->setEnabled(
false);
142 pushButton_previousevent->setEnabled(
false);
146 pushButton_quicksetup_trackingstudies->setEnabled(
false);
147 pushButton_quicksetup_trackingstudies->setToolTip(
"Not available in VP1Light");
148 pushButton_quicksetup_calostudies->setEnabled(
false);
149 pushButton_quicksetup_calostudies->setToolTip(
"Not available in VP1Light");
150 action_quicklaunch_Tracking_studies->setEnabled(
false);
151 action_quicklaunch_Tracking_studies->setToolTip(
"Not available in VP1Light");
152 action_quicklaunch_Calo_studies->setEnabled(
false);
153 action_quicklaunch_Calo_studies->setToolTip(
"Not available in VP1Light");
154 action_quicklaunch_Storegate_browser->setEnabled(
false);
155 action_quicklaunch_Storegate_browser->setToolTip(
"Not available in VP1Light");
156 action_quicklaunch_trackcalo_commis->setEnabled(
false);
157 action_quicklaunch_trackcalo_commis->setToolTip(
"Not available in VP1Light");
166 QStringList inputdirs;
170 if (availLocal&&!inputdirs.isEmpty()) {
176 QMenu * menu_inputdir =
new QMenu(menubar);
177 menu_inputdir->setObjectName(
"menu_inputdir");
178 menu_inputdir->setTitle(
"&Stream");
180 menubar->addAction(menu_inputdir->menuAction());
182 QActionGroup * inputdir_actiongroup =
new QActionGroup(menu_inputdir);
183 QAction*action_inputdir_current(0);
184 foreach (QString
inputdir, inputdirs) {
188 QAction * action_inputdir =
new QAction(
this);
189 action_inputdir->setObjectName(
"action_inputdir_"+
dirname);
191 action_inputdir->setStatusTip(
"Get input files from: "+
inputdir);
192 action_inputdir->setCheckable(
true);
195 action_inputdir_current = action_inputdir;
196 menu_inputdir->addAction(action_inputdir);
197 inputdir_actiongroup->addAction(action_inputdir);
201 if (action_inputdir_current) {
202 action_inputdir_current->blockSignals(
true);
203 action_inputdir_current->setChecked(
true);
204 action_inputdir_current->blockSignals(
false);
218 QTimer *
timer =
new QTimer(
this);
233 for (
int i=0;
i<stackedWidget_central->count();++
i)
234 stackedWidget_central->widget(
i)->layout()->setContentsMargins(0,0,0,0);
237 frame_instructions->setFrameShape(QFrame::StyledPanel);
240 #ifndef BUILDVP1LIGHT
270 connect(pushButton_channelfullscreen,SIGNAL(clicked()),
m_tabmanager,SLOT(showCurrentChannelFullScreen()));
285 connect(action_exit_VP1,SIGNAL(triggered(
bool)),
this,SLOT(close()));
291 menuConfiguration->addSeparator();
301 QActionGroup * styleGroup =
new QActionGroup(
this);
302 QAction * laststyleact(0);
303 bool foundplastique=
false;
305 QString defaultstyle=
s.value(
"style/defaultstyle",
"Fusion").toString();
308 act->setStatusTip(
"Change application style to "+
style);
310 act->setCheckable(
true);
311 styleGroup->addAction(act);
313 if (act->text()==defaultstyle) {
314 act->setChecked(
true);
319 if (!foundplastique) {
320 laststyleact->setChecked(
true);
326 savedgoal =
s.value(
"font/pixelsize_diff", 0).toInt();
328 savedgoal =
s.value(
"font/pointsize_relativepercent", 0).toInt();
331 QList<int> fontoptions;
333 fontoptions <<15<<10<<+5<<+3<<+2<<+1<<0<<-1<<-2<<-3<<-5<<-10<<-20<<-30;
335 fontoptions <<150<<100<<50<<30<<20<<10<<5<<0<<-5<<-10<<-20<<-30<<-50;
337 QActionGroup * fontGroup =
new QActionGroup(
this);
338 bool foundsavedgoal(
false);
339 QAction * normalfontact(0);
340 foreach (
int fontopt,fontoptions) {
345 act->setStatusTip(
"Change overall font size of application to "+
text);
346 act->setData(fontopt);
347 act->setCheckable(
true);
348 fontGroup->addAction(act);
352 if (savedgoal==fontopt) {
353 act->setChecked(
true);
358 if (!foundsavedgoal) {
359 normalfontact->setChecked(
true);
365 menuConfiguration->addSeparator();
373 menuConfiguration->addSeparator();
382 connect(pushButton_previousevent,SIGNAL(clicked()),
this,SLOT(goToPreviousEvent()));
383 connect(pushButton_eventselect,SIGNAL(clicked()),
this,SLOT(chooseEvent()));
403 QMenu* menu_help =
new QMenu(menubar);
404 menu_help->setObjectName(
"menu_help");
405 menu_help->setTitle(
"&Help");
406 menubar->addAction(menu_help->menuAction());
410 menu_help->addSeparator();
423 #ifndef BUILDVP1LIGHT
424 menubar->setEnabled(
false);
444 QDesktopServices::openUrl(QUrl(
"http://atlas-vp1.web.cern.ch/atlas-vp1/doc/"));
456 QDesktopServices::openUrl(QUrl(
"http://atlas-vp1.web.cern.ch/atlas-vp1/vp1_users_support/"));
468 QDesktopServices::openUrl(QUrl(
"http://atlas-vp1.web.cern.ch/atlas-vp1/"));
480 QDesktopServices::openUrl(QUrl(
"https://atlas-vp1.web.cern.ch/atlas-vp1/doc_new/about_vp1/CREDITS.html"));
490 int sum1 = splitter_tabwidget_messagebox->sizes().at(0) + splitter_tabwidget_messagebox->sizes().at(1);
491 QList<int> sizes1; sizes1 << sum1 << 0;
492 splitter_tabwidget_messagebox->setSizes ( sizes1 );
494 while (splitter_tabwidget_messagebox->sizes().at(1)==0&&bottom<50000) {
495 QList<int> sizes2; sizes2 << sum1-bottom << bottom;
496 splitter_tabwidget_messagebox->setSizes ( sizes2 );
500 int sum2 = splitter_leftright->sizes().at(0) + splitter_leftright->sizes().at(1);
502 QList<int> sizes3; sizes3 << left << sum2-left;
503 splitter_leftright->setSizes ( sizes3 );
504 while (splitter_leftright->sizes().at(0)==0&&left<50000) {
505 QList<int> sizes4; sizes4 << left << sum2-left;
506 splitter_leftright->setSizes ( sizes4 );
510 int prefwidths = std::max<int>(left,widget_controlsContainer->sizeHint().width());
511 prefwidths = std::max<int>(prefwidths,groupBox_channelcontrols->sizeHint().width());
512 prefwidths = std::max<int>(prefwidths,groupBox_cruise->sizeHint().width());
513 prefwidths = std::max<int>(prefwidths,groupBox_event->sizeHint().width());
514 prefwidths = std::max<int>(prefwidths,stackedWidget_customcontrols->sizeHint().width());
515 widget_controlsContainer->setMaximumWidth(50+prefwidths);
532 statusBar()->setStyleSheet(
"QStatusBar::item { border-width: 0 }");
573 m_statusbarlabel->setPixmap(QIcon(
l?
":/vp1/icons/icons/network_64x64.png":
":/vp1/icons/icons/network_disconnect_64x64.png")
576 :
"VP1 is presently NOT listening for incoming messages");
586 if (!
err.isEmpty()) {
587 QMessageBox::critical(0,
"Error - could not load plugin file: "+
filename,
588 "Could not load plugin file: "
589 +
filename+
"\n\nReason: "+
err,QMessageBox::Ok,QMessageBox::Ok);
598 QString newtabname = QInputDialog::getText( 0,
"New Tab Name",
"New tab name:",
600 if (!ok||newtabname.isEmpty())
610 groupBox_cruise->setEnabled(
true);
613 groupBox_cruise->setEnabled(
false);
616 radioButton_cruise_tab->setEnabled(
true);
617 radioButton_cruise_both->setEnabled(
true);
619 if (radioButton_cruise_tab->isChecked()||radioButton_cruise_both->isChecked())
620 radioButton_cruise_event->setChecked(
true);
621 radioButton_cruise_tab->setEnabled(
false);
622 radioButton_cruise_both->setEnabled(
false);
629 for (
int i = 0;
i<
n; ++
i) {
631 if (!icontext.isEmpty())
632 cb->setItemIcon (
i, QIcon(icontext) );
643 groupBox_channelcontrols->setTitle(
"Controls: "+cw->
unique_name());
644 groupBox_channelcontrols->setEnabled(
true);
649 if (stackedWidget_customcontrols->indexOf(controller)==-1)
650 stackedWidget_customcontrols->addWidget(controller);
651 stackedWidget_customcontrols->setCurrentWidget(controller);
654 groupBox_channelcontrols->setTitle(
"Controls: no channel selected");
655 groupBox_channelcontrols->setEnabled(
false);
660 menubar->setEnabled(
true);
663 menubar->setEnabled(
true);
669 QString
filename = QFileDialog::getSaveFileName(
this,
"Select configuration file to save",
671 "VP1 Configuration files (*.vp1)",0,QFileDialog::DontResolveSymlinks);
695 QString
filename = QFileDialog::getOpenFileName(
this,
"Select configuration file to load",
697 "VP1 configuration files (*.vp1)",0,QFileDialog::DontResolveSymlinks);
708 QString sharedlibsuffix =
"dylib";
710 QString sharedlibsuffix =
"so";
714 QString
filename = QFileDialog::getOpenFileName(
this,
"Select plugin file to load",
716 "VP1 plugin files (*VP1*."+sharedlibsuffix+
")",0,QFileDialog::DontResolveSymlinks);
725 const QString& pathvar,
726 const QString& instareasubdir,
727 const QString& extradirenvvar,
731 qDebug() <<
"VP1MainWindow::availableFiles()";
732 qDebug() <<
"extension:" << extension <<
"pathvar:" << pathvar <<
"instareasubdir:" << instareasubdir <<
"extradirenvvar:" << extradirenvvar <<
"currentdir:" <<
currentdir;
736 QStringList vp1pluginpath =
737 extradirenvvar.isEmpty() ?
739 QString(::
getenv(extradirenvvar.toStdString().c_str())) .
740 #
if QTCORE_VERSION >= 0x050E00
741 split(
":",Qt::SkipEmptyParts);
743 split(
":",QString::SkipEmptyParts);
746 qDebug() <<
"extradirenvvar:" << extradirenvvar;
747 qDebug() <<
"vp1pluginpath:" << vp1pluginpath;
753 vp1pluginpath<<QCoreApplication::applicationDirPath()+
"/../lib";
761 vp1pluginpath<<QDir::currentPath();
767 QProcessEnvironment
env = QProcessEnvironment::systemEnvironment();
769 QString
path =
env.value(pathvar);
772 if (!
path.isEmpty()) {
773 #if QTCORE_VERSION >= 0x050E00
775 QStringList
tmp =
path.split(
":",Qt::SkipEmptyParts);
778 QStringList
tmp =
path.split(
":",QString::SkipEmptyParts);
780 for (
const QString&
dir :
tmp) {
781 vp1pluginpath << ( instareasubdir.isEmpty() ?
dir :
dir+QDir::separator()+instareasubdir );
786 int nDuplicatesRemoved = vp1pluginpath.removeDuplicates();
791 for (
const auto& plugindir : vp1pluginpath) {
793 QFileInfo
fi(plugindir);
794 if (!
fi.exists()||!
fi.isDir()) {
796 if (vp1pluginpath.contains(plugindir)) {
797 vp1pluginpath.removeAt(
idx);
801 VP1Msg::messageDebug(
"plugindir not present; perhaps, it has been removed already. Skipping it...");
808 QMap<QString,QString> plugins2fullpath;
809 for (
const QString& plugindir : vp1pluginpath) {
810 QStringList plugins = QDir(plugindir).entryList((QStringList()<<(
"*"+extension)),QDir::CaseSensitive |
QDir::Files | QDir::Readable,
QDir::Name);
811 for (QString
plugin : plugins) {
813 if (!plugins2fullpath.contains(
plugin)) {
819 return plugins2fullpath;
828 QString sharedlibsuffix =
"dylib";
830 QString sharedlibsuffix =
"so";
833 return availableFiles(
"."+sharedlibsuffix,
"LD_LIBRARY_PATH",
"vp1plugins",
"VP1PLUGINPATH" );
853 for (
const QString&
bn : bns) {
869 QMessageBox::critical(0,
"Error - problems unloading plugin file: "+
filename,
870 "Problems encountered while attempting to unload plugin file: "+
filename,QMessageBox::Ok,QMessageBox::Ok);
888 addToMessageBox(
"ERROR: Going to next event, but one is not available!");
899 #if defined BUILDVP1LIGHT
900 std::cout <<
"goToNextEvent: \n"
901 <<
"m_scheduler->getEvtNr()+2: " <<
m_scheduler->getEvtNr()+2
902 <<
"\nm_scheduler->getTotEvtNr(): " <<
m_scheduler->getTotEvtNr() << std::endl;
904 std::cout <<
"First case" << std::endl;
910 std::cout <<
"Second case" << std::endl;
921 #if defined BUILDVP1LIGHT
923 void VP1MainWindow::goToPreviousEvent() {
942 bool checkEnableAskOnClose;
943 #if defined BUILDVP1LIGHT
949 if (checkEnableAskOnClose) {
950 int ret = QMessageBox::warning(
this,
952 "You are about to close VP1 and end the job.\nProceed?",
953 QMessageBox::Ok| QMessageBox::Cancel,
954 QMessageBox::Cancel );
955 if (ret!=QMessageBox::Ok) {
996 QString expandedevtstr = evtstr
997 + QString(trighex.isEmpty()?QString(
""):
", triggerType: "+trighex)
1001 #ifdef BUILDVP1LIGHT
1002 setWindowTitle(
"VP1Light ["+expandedevtstr+
"]");
1004 setWindowTitle(
"VP1 (Virtual Point 1) ["+expandedevtstr+
"]");
1005 #endif // BUILDVP1LIGHT
1007 groupBox_event->setTitle(
"Event [loaded]");
1008 label_run_event->setText(
"["+evtstr+
"]");
1018 const QString&
title,
const QString& titleextrastyleopts )
1021 if (
title.isEmpty())
1027 QString titlepart = (
title.isEmpty() ?
"" : ( titleextrastyleopts.isEmpty() ?
title
1028 :
"<span style=\"font-style:italic;"+titleextrastyleopts+
";\">["+
title+
"]</span> "));
1030 textBrowser_channelmessages->append(titlepart
1031 + ( extrastyleopts.isEmpty() ?
m
1032 :
"<span style=\"font-style:italic;"+extrastyleopts+
";\">"+
m+
"</span>"));
1033 textBrowser_channelmessages->verticalScrollBar()->setSliderPosition(textBrowser_channelmessages->verticalScrollBar()->maximum());
1041 addToMessageBox(
"VP1MainWindow::systemAddToMessageBox Error: Only prints system messages!");
1044 if (!
sys->channel()) {
1045 addToMessageBox(
"VP1MainWindow::systemAddToMessageBox Error: System does not know its channel!");
1056 addToMessageBox(
"VP1MainWindow::channelAddToMessageBox Error: Only prints channelwidget messages!");
1076 out +=
"Systems:\n\n";
1079 out +=
" ==> System "+(*itsys)->name()+
"\n";
1080 out +=
" Contact: "+(*itsys)->contact_info()+
"\n";
1081 out +=
" Information: "+(*itsys)->information()+
"\n";
1093 QList<QPixmap>
list;
1094 QStringList listNames;
1095 QList<unsigned long long> listRunEventNumberTimestamp;
1126 if (allTabs.isEmpty()) {
1141 channelname.replace(
' ',
'_');
1153 listNames << channelname;
1166 std::cout <<
"tab: " << tab << std::endl;
1181 if (snap.isNull()) {
1196 if (allTabs.isEmpty()) {
1205 channelname.replace(
' ',
'_');
1207 if (channelname == tabName) {
1231 if (allTabs.isEmpty()) {
1253 QString
filename = QFileDialog::getSaveFileName(0,
"Select target image file",
base,
1254 "Image (*.png *.bmp)",
1255 0,QFileDialog::DontResolveSymlinks);
1264 QStringList tab_save_files;
1273 QString channelname = widg->name().toLower();
1274 channelname.replace(
' ',
'_');
1281 QPixmap snap = widg->getSnapshot();
1282 if (snap.isNull()) {
1289 if (!(tabfilename.endsWith(
".png",Qt::CaseInsensitive)||tabfilename.endsWith(
".bmp",Qt::CaseInsensitive)))
1290 tabfilename +=
".png";
1293 snap.save(tabfilename);
1295 tab_save_files << tabfilename;
1301 QMessageBox::information(
this, tr(
"Snapshots saved."),
1302 "All tabs have been saved as snapshots in the following files:\n\n"+tab_save_files.join(
"\n"),
1346 chnlname.replace(
' ',
'_');
1368 QString
filename = QFileDialog::getSaveFileName(0,
"Select target image file", guess,
1369 "Image (*.png *.bmp)",
1370 0,QFileDialog::DontResolveSymlinks);
1376 if (!(
filename.endsWith(
".png",Qt::CaseInsensitive)||
filename.endsWith(
".bmp",Qt::CaseInsensitive)))
1396 QPrintDialog dialog(&printer,
this);
1402 painter.begin(&printer);
1403 painter.drawPixmap(0,0,pm);
1427 qDebug(
"%s",
err.toStdString().c_str());
1477 if (pushButton_cruise->isChecked()) {
1478 if (radioButton_cruise_event->isChecked()) {
1480 groupBox_cruise->setTitle(
"Cruise Mode [event]");
1481 }
else if (radioButton_cruise_tab->isChecked()) {
1483 groupBox_cruise->setTitle(
"Cruise Mode [tab]");
1484 }
else if (radioButton_cruise_both->isChecked()) {
1486 groupBox_cruise->setTitle(
"Cruise Mode [event && tab]");
1487 }
else { assert(0); }
1490 groupBox_cruise->setTitle(
"Cruise Mode [off]");
1501 if (plugins2fullpath.empty()) {
1506 QStringList pluglist(plugins2fullpath.keys());
1510 for(
const QString& plug : pluglist) {
1512 assert(plugins2fullpath.contains(plug));
1513 QString
fullpath = plugins2fullpath[plug];
1514 if (currentpluginfiles.contains(
fullpath)) {
1515 act->setEnabled(
false);
1525 act_browse->setStatusTip(
"Browse filesystem for VP1 plugin files");
1533 QAction * act =
static_cast<QAction*
>(sender());
1546 QMap<QString,QString> conffile2fullpath =
availableFiles(
".vp1",
"DATAPATH",
"",
"VP1CONFIGFILEPATH",
true );
1548 #ifndef BUILDVP1LIGHT
1549 if (conffile2fullpath.empty()) {
1554 QStringList
filelist(conffile2fullpath.keys());
1559 assert(conffile2fullpath.contains(
file));
1569 act_browse->setStatusTip(
"Browse filesystem for .vp1 config file");
1578 QAction * act =
static_cast<QAction*
>(sender());
1588 QAction * act =
static_cast<QAction*
>(sender());
1597 s.setValue(
"style/defaultstyle",act->text());
1604 QAction * act =
static_cast<QAction*
>(sender());
1609 int goal = act->data().toInt(&ok);
1629 s.setValue(
"font/pixelsize_diff",goal);
1632 double fact = (goal+100.0)/100.0;
1633 if (fact<0.01||fact>50)
1638 newfont.setPointSizeF(newpointsize);
1639 s.setValue(
"font/pointsize_relativepercent",goal);
1641 QApplication::setFont(newfont);
1648 QWidget * targetpage = tabWidget_central->count() ? page_tabwidget : page_instructions;
1649 if (stackedWidget_central->currentWidget() != targetpage)
1650 stackedWidget_central->setCurrentWidget(targetpage);
1658 QSettings settings(
"ATLAS",
"VP1Light");
1660 QString plugfile, channelname, tabname;
1662 if (sender()==pushButton_quicksetup_geometrystudies||sender()==action_quicklaunch_Geometry_studies) {
1665 #ifdef BUILDVP1LIGHT
1666 if(settings.value(
"db/dbByEnv").toString().isEmpty()){
1669 if(!dbSelection.result())
1672 #endif // BUILDVP1LIGHT
1674 plugfile=
"libVP1GeometryPlugin.so";
1675 channelname=
"Geometry";
1676 tabname =
"Geometry";
1677 }
else if (sender()==pushButton_quicksetup_trackingstudies||sender()==action_quicklaunch_Tracking_studies) {
1678 plugfile=
"libVP1TrackPlugin.so";
1679 channelname=
"Tracking";
1680 tabname =
"Tracking";
1681 }
else if (sender()==pushButton_quicksetup_calostudies||sender()==action_quicklaunch_Calo_studies) {
1682 plugfile=
"libVP1CaloPlugin.so";
1683 channelname=
"Calo Cells";
1684 tabname =
"Calorimeter";
1685 }
else if (sender()==action_quicklaunch_Storegate_browser) {
1686 plugfile=
"libVP1BanksPlugin.so";
1687 channelname=
"Banks";
1688 tabname =
"StoreGate";
1689 }
else if (sender()==pushButton_quicksetup_3dcocktail||sender()==action_quicklaunch_3dcocktail) {
1690 #ifndef BUILDVP1LIGHT
1691 plugfile=
"libVP13DCocktailPlugin.so";
1692 channelname=
"3DCocktail";
1693 tabname =
"3D Cocktail";
1696 if(settings.value(
"aod/aodByEnv").toString().isEmpty()){
1698 aodSelection.exec();
1699 if(!aodSelection.result())
1702 if(settings.value(
"db/dbByEnv").toString().isEmpty()){
1705 if(!dbSelection.result())
1710 pushButton_eventselect->setEnabled(
true);
1711 plugfile=
"libVP1LightPlugin.so";
1712 channelname=
"VP1Light";
1713 tabname =
"Geometry/AOD";
1714 #endif // BUILDVP1LIGHT
1715 }
else if (sender()==action_quicklaunch_trackcalo_commis) {
1716 plugfile=
"libVP13DCocktailPlugin.so";
1717 channelname=
"TrackCalo";
1718 tabname =
"Track/Calo";
1719 }
else if (sender()==pushButton_quicksetup_analysisstudies||sender()==action_quicklaunch_analysisstudies) {
1722 #ifdef BUILDVP1LIGHT
1723 if(settings.value(
"aod/aodByEnv").toString().isEmpty()){
1725 aodSelection.exec();
1726 if(!aodSelection.result())
1730 pushButton_eventselect->setEnabled(
true);
1731 #endif // BUILDVP1LIGHT
1733 plugfile=
"libVP1AODPlugin.so";
1735 tabname =
"Analysis";
1742 if (plugfile.endsWith(
".so"))
1743 plugfile = plugfile.left(plugfile.count()-3)+
".dylib";
1750 qDebug() <<
"plugins2fullpath: " << plugins2fullpath;
1753 if (!plugins2fullpath.contains(plugfile)) {
1754 QMessageBox::critical(0,
"Error - could not locate plugin file: "+plugfile,
1755 "could not locate plugin file: "
1756 +plugfile,QMessageBox::Ok,QMessageBox::Ok);
1759 QString plugfile_fullpath = plugins2fullpath[plugfile];
1766 QMessageBox::critical(0,
"Error - could not load plugin file: "+plugfile_fullpath,
1767 "Could not load plugin file: "
1768 +plugfile_fullpath+
"\n\nReason: "+
err,QMessageBox::Ok,QMessageBox::Ok);
1776 QMessageBox::critical(0,
"Error - did not find necessary channel: "+channelname,
1777 "Could not find channel: "+channelname+
" in loaded plugin "+plugfile_fullpath,
1778 QMessageBox::Ok,QMessageBox::Ok);
1782 bool save = updatesEnabled();
1783 setUpdatesEnabled(
false);
1790 QMessageBox::critical(0,
"Error - could not create tab: "+newtabname,
1791 "Could not create tab: "+newtabname,
1792 QMessageBox::Ok,QMessageBox::Ok);
1793 setUpdatesEnabled(
save);
1801 QMessageBox::critical(0,
"Error - problems launching channel: "+channelname,
1802 "Problems launching channel: "+channelname,
1803 QMessageBox::Ok,QMessageBox::Ok);
1804 setUpdatesEnabled(
save);
1812 setUpdatesEnabled(
save);
1819 #if defined BUILDVP1LIGHT
1827 if(!
m_mutex->tryLock())
return;
1835 QString
inputdir(act->data().toString());
1837 act->setEnabled(dirstatus.
enabled);
1838 act->setFont(dirstatus.
bold?fb:
f);
1848 QAction * act =
dynamic_cast<QAction*
>(sender());
1854 QString
inputdir(act->data().toString());
1856 if (
fi.exists()&&
fi.isDir()) {
1859 <<
"VP1Message: inputdirectory changed to "
1878 QString newEventFile = QFileDialog::getOpenFileName(NULL
1879 ,tr(
"Open Event File")
1881 ,tr(
"All files (*.*)"));
1882 if(newEventFile.isEmpty())
return;
1885 addToMessageBox(newEventFile +
" will be appended to the list of input files");
1888 QMessageBox::critical(0, newEventFile +
" either does not exist or is not readable",
1889 newEventFile +
" either does not exist or is not readable",
1890 QMessageBox::Ok,QMessageBox::Ok);
1894 #ifdef BUILDVP1LIGHT
1895 void VP1MainWindow::request_expertSettings(){
1900 void VP1MainWindow::chooseEvent(){
1904 int newEvtNr = selectEvent.result()-1;
1906 if( (newEvtNr >= 0) && (newEvtNr <= m_scheduler->getTotEvtNr()-1) ){
1912 #endif // BUILDVP1LIGHT