remotes/origin/HEAD
Tobias Weiss 7 years ago
parent a9b237f182
commit 9f03443034

@ -105,7 +105,7 @@ void lc::Client::Boot() {
GotStatusChanged( state_t::BOOTING );
}
void lc::Client::DeactiveScreensaver() {
/*void lc::Client::DeactiveScreensaver() {
QStringList arguments;
arguments << "-i" << settings->pkeyPathUser
<< QString{ settings->userNameOnClients + "@" + ip }
@ -119,7 +119,7 @@ void lc::Client::DeactiveScreensaver() {
// Output message via the debug messages tab
qDebug() << settings->sshCmd << arguments.join( " " );
}
}*/
void lc::Client::GotStatusChanged( state_t argState ) {
if ( ( protectedCycles > 0 ) && ( state == state_t::BOOTING ) && ( argState != state_t::RESPONDING ) ) {

@ -81,7 +81,7 @@ void lc::MainWindow::DisableDisfunctionalWidgets() {
ui->CBClientNames->setEnabled( false );
ui->CBWebcamChooser->setEnabled( false );
ui->GBClientActions->setEnabled( false );
ui->GBzTree->setEnabled( false );
//ui->GBzTree->setEnabled( false );
ui->LEFilePath->setEnabled( false );
ui->LFakeName->setEnabled( false );
ui->LWebcamChooser->setEnabled( false );
@ -117,7 +117,7 @@ void lc::MainWindow::DisableDisfunctionalWidgets() {
ui->LFakeName->setEnabled( false );
ui->PBBeamFile->setEnabled( false );
ui->PBChooseFile->setEnabled( false );
ui->PBDeactivateScreensaver->setEnabled( false );
//ui->PBDeactivateScreensaver->setEnabled( false );
ui->PBKillzLeaf->setEnabled( false );
ui->PBRunzLeaf->setEnabled( false );
ui->PBShutdown->setEnabled( false );
@ -171,7 +171,7 @@ void lc::MainWindow::DisableDisfunctionalWidgets() {
ui->CBClientNames->setEnabled( false );
ui->LFakeName->setEnabled( false );
ui->PBRunzLeaf->setEnabled( false );
ui->PBStartSession->setEnabled( false );
//ui->PBStartSession->setEnabled( false );
ui->PBStartLocalzLeaf->setEnabled( false );
ui->PBStartzLeaf->setEnabled( false );
}
@ -184,7 +184,7 @@ void lc::MainWindow::DisableDisfunctionalWidgets() {
// Disable 'PBViewDesktop' if 'vnc_viewer' was not set
if ( settings->vncViewer.isEmpty() ) {
ui->PBViewDesktop->setEnabled( false );
//ui->PBViewDesktop->setEnabled( false );
}
// Disable 'PBBoot' if 'wakeonlan_command' was not set
@ -203,21 +203,21 @@ void lc::MainWindow::DisableDisfunctionalWidgets() {
ui->CBClientNames->setEnabled( false );
ui->LFakeName->setEnabled( false );
ui->PBRunzLeaf->setEnabled( false );
ui->PBStartSession->setEnabled( false );
//ui->PBStartSession->setEnabled( false );
ui->PBStartLocalzLeaf->setEnabled( false );
ui->PBStartzLeaf->setEnabled( false );
}
// Disable the disable screensaver function if the 'xset_command' was not set
if ( settings->xsetCmd.isEmpty() ) {
ui->PBDeactivateScreensaver->setEnabled( false );
}
//if ( settings->xsetCmd.isEmpty() ) {
// ui->PBDeactivateScreensaver->setEnabled( false );
//}
if ( settings->zTreeInstDir.isEmpty() ) {
ui->CBClientNames->setEnabled( false );
ui->LFakeName->setEnabled( false );
ui->PBRunzLeaf->setEnabled( false );
ui->PBStartSession->setEnabled( false );
//ui->PBStartSession->setEnabled( false );
ui->PBStartLocalzLeaf->setEnabled( false );
ui->PBStartzLeaf->setEnabled( false );
}
@ -297,12 +297,12 @@ void lc::MainWindow::on_PBChooseFile_clicked() {
delete file_dialog;
}
void lc::MainWindow::on_PBDeactivateScreensaver_clicked() {
/*void lc::MainWindow::on_PBDeactivateScreensaver_clicked() {
for ( auto s : settings->GetClients() ) {
if ( s->GetClientState() >= state_t::RESPONDING )
s->DeactiveScreensaver();
}
}
}*/
void lc::MainWindow::on_PBExecute_clicked() {
// This will be set to false, if the command shall be executed only on the chosen clients (that's if not all clients are up)
@ -615,7 +615,7 @@ void lc::MainWindow::SetupWidgets() {
const QStringList &zTreeEntries = settings->installedZTreeVersions;
if ( zTreeEntries.isEmpty() ) {
ui->CBClientNames->setEnabled( false );
ui->GBzTree->setEnabled( false );
//ui->GBzTree->setEnabled( false );
ui->LFakeName->setEnabled( false );
ui->PBRunzLeaf->setEnabled( false );
ui->PBStartLocalzLeaf->setEnabled( false );

@ -61,7 +61,6 @@ private slots:
void on_PBBeamFile_clicked();
void on_PBBoot_clicked();
void on_PBChooseFile_clicked();
void on_PBDeactivateScreensaver_clicked();
void on_PBExecute_clicked();
void on_PBKillLocalzLeaf_clicked();
void on_PBKillzLeaf_clicked();

@ -40,62 +40,57 @@
<layout class="QHBoxLayout" name="HLExperimenterTab" stretch="1,1">
<item>
<layout class="QVBoxLayout" name="VLzTreeClientActions">
<item alignment="Qt::AlignTop">
<widget class="QGroupBox" name="GBzTree">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<item>
<widget class="QGroupBox" name="GBLocalActions">
<property name="title">
<string>z-Tree</string>
</property>
<property name="flat">
<bool>false</bool>
<string>Experiment preparation / server actions</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4" stretch="0,0,0,0,0,0,0">
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPushButton" name="PBStartSession">
<property name="toolTip">
<string>Start a new session. A new window will be opened to enter all required parameters.</string>
</property>
<widget class="QPushButton" name="PBShowORSEE">
<property name="text">
<string>Start session</string>
<string>Show ORSEE</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBShowSessions">
<property name="enabled">
<bool>true</bool>
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBShowPreprints">
<property name="text">
<string>Show sessions</string>
<string>Show preprints</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBKillzTree">
<widget class="QPushButton" name="PBPrintPaymentFileManually">
<property name="toolTip">
<string>Kill all local z-Tree instances</string>
<string>Choose a payment file manually, which will then be printed.</string>
</property>
<property name="text">
<string>Terminate z-Tree</string>
<string>Print payment file manually</string>
</property>
</widget>
</item>
<item>
<widget class="Line" name="line_4">
<widget class="Line" name="line_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="label">
<widget class="QPushButton" name="PBKillzTree">
<property name="toolTip">
<string>Stop all local z-Tree instances</string>
</property>
<property name="text">
<string>Session recovery:</string>
<string>Stop z-Tree</string>
</property>
</widget>
</item>
@ -107,74 +102,104 @@
</widget>
</item>
<item>
<widget class="QPushButton" name="PBPrintPaymentFileManually">
<property name="toolTip">
<string>Choose a payment file manually, which will then be printed.</string>
</property>
<property name="text">
<string>Print payment file manually</string>
<widget class="Line" name="line_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="GBClientActions">
<property name="title">
<string>Client actions</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QPushButton" name="PBBoot">
<property name="toolTip">
<string>Boots the selected clients.</string>
</property>
<property name="text">
<string>Boot</string>
<layout class="QHBoxLayout" name="HLLocalzLeaf">
<item>
<widget class="QPushButton" name="PBStartLocalzLeaf">
<property name="text">
<string>Start local z-Leaf</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBKillLocalzLeaf">
<property name="text">
<string>Stop local z-Leaf</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="Line" name="line_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBShutdown">
<property name="toolTip">
<string>Turns off the selected clients.</string>
<widget class="QLabel" name="LFakeName">
<property name="enabled">
<bool>true</bool>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>16777215</height>
</size>
</property>
<property name="text">
<string>Shutdown</string>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Run zLeaf with another name than the client's:&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::RichText</enum>
</property>
<property name="scaledContents">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBStartzLeaf">
<property name="toolTip">
<string>Starts zLeaf on the selected clients with the port given in the 'zTree' groupbox.</string>
</property>
<property name="text">
<string>Start z-Leaf</string>
<widget class="QComboBox" name="CBClientNames">
<property name="editable">
<bool>true</bool>
</property>
<item>
<property name="text">
<string>Choose the name the z-Leaf shall have</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBKillzLeaf">
<property name="toolTip">
<string>Kills zLeaf on all selected clients.</string>
</property>
<widget class="QPushButton" name="PBRunzLeaf">
<property name="text">
<string>Terminate z-Leaf</string>
<string>Run z-Leaf with chosen name</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBViewDesktop">
<property name="toolTip">
<string>Shows the desktop of the selected clients.</string>
<widget class="Line" name="line_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="LWebcamChooser">
<property name="text">
<string>View desktop</string>
<string>Show webcams:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="CBWebcamChooser">
<item>
<property name="text">
<string>Choose webcam</string>
</property>
</item>
</widget>
</item>
</layout>
</widget>
</item>
@ -186,174 +211,173 @@
<number>6</number>
</property>
<item>
<widget class="QGroupBox" name="GBFurtherLocalActions">
<widget class="QGroupBox" name="GBClientActions">
<property name="title">
<string>Further local actions</string>
<string>Client actions</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<layout class="QVBoxLayout" name="verticalLayout_5">
<item>
<widget class="QPushButton" name="PBShowORSEE">
<property name="text">
<string>Show ORSEE</string>
<widget class="QPushButton" name="PBBoot">
<property name="toolTip">
<string>Boots the selected clients.</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBShowPreprints">
<property name="text">
<string>Show preprints</string>
<string>Boot</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="HLLocalzLeaf">
<item>
<widget class="QPushButton" name="PBStartLocalzLeaf">
<property name="text">
<string>Start local z-Leaf</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBKillLocalzLeaf">
<property name="text">
<string>Kill local z-Leaf</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="GBSpecialActions">
<property name="title">
<string>Special actions</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_5">
<item>
<widget class="QLabel" name="LWebcamChooser">
<widget class="QPushButton" name="PBShutdown">
<property name="toolTip">
<string>Turns off the selected clients.</string>
</property>
<property name="text">
<string>Show webcam:</string>
<string>Shutdown</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="CBWebcamChooser">
<item>
<property name="text">
<string>Choose webcam</string>
</property>
</item>
<widget class="Line" name="line_6">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Horizontal</enum>
<widget class="QPushButton" name="PBStartzLeaf">
<property name="toolTip">
<string>Starts zLeaf on the selected clients with the port given in the 'zTree' groupbox.</string>
</property>
<property name="text">
<string>Start z-Leaf on selected clients</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBDeactivateScreensaver">
<widget class="QPushButton" name="PBKillzLeaf">
<property name="toolTip">
<string>Deactivates the screensavers on the selected clients.</string>
<string>Stops zLeaf on all selected clients</string>
</property>
<property name="text">
<string>Deactivate screensaver</string>
<string>Stop z-Leaf on selected clients</string>
</property>
</widget>
</item>
<item>
<widget class="Line" name="line_2">
<widget class="Line" name="line_7">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="LFakeName">
<property name="enabled">
<bool>true</bool>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>16777215</height>
</size>
<widget class="QPushButton" name="PBViewDesktopViewOnly">
<property name="toolTip">
<string>Shows the desktop of the selected clients.</string>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Run zLeaf with another name than the client's:&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<string>View desktop of selected clients (viel only)</string>
</property>
<property name="textFormat">
<enum>Qt::RichText</enum>
</property>
<property name="scaledContents">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="CBClientNames">
<property name="editable">
<bool>true</bool>
</property>
<item>
<property name="text">
<string>Choose the name the z-Leaf shall have</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QPushButton" name="PBRunzLeaf">
<widget class="QPushButton" name="PBViewDesktopFullControl">
<property name="text">
<string>Run z-Leaf with chosen name</string>
<string>View desktop of selected clients (full control)</string>
</property>
</widget>
</item>
<item>
<widget class="Line" name="line_3">
<widget class="Line" name="line_8">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="LUploadFolder">
<property name="text">
<string>Upoad folder:</string>
</property>
</widget>
</item>
<item>
<layout class="QVBoxLayout" name="VLFileBeamer">
<layout class="QHBoxLayout" name="HLFileChooser">
<item>
<layout class="QHBoxLayout" name="HLFileChooser">
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QPushButton" name="PBChooseFile">
<widget class="QLabel" name="label">
<property name="text">
<string>Choose folder</string>
<string>Upload folder to all selected clients:</string>
</property>
<property name="alignment">
<set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="LEFilePath">
<property name="readOnly">
<bool>true</bool>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QPushButton" name="PBChooseFile">
<property name="text">
<string>Choose folder</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="LEFilePath">
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QPushButton" name="PBBeamFile">
<property name="text">
<string>Start to upload folder</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</item>
<item>
<widget class="Line" name="line_9">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="LStartBrowser">
<property name="text">
<string>Start browser on all selected clients:</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="LURL">
<property name="text">
<string>URL:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit"/>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<widget class="QPushButton" name="PBBeamFile">
<widget class="QPushButton" name="pushButton">
<property name="text">
<string>Beam folder to ~/media4zTree on all clients</string>
<string>Start browser</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButton_2">
<property name="text">
<string>Stop browser</string>
</property>
</widget>
</item>
@ -366,6 +390,30 @@
</item>
</layout>
</widget>
<widget class="QWidget" name="TSessionStart">
<property name="enabled">
<bool>true</bool>
</property>
<attribute name="title">
<string>Start session</string>
</attribute>
<widget class="QWidget" name="verticalLayoutWidget_2">
<property name="geometry">
<rect>
<x>9</x>
<y>9</y>
<width>761</width>
<height>411</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2"/>
</widget>
</widget>
<widget class="QWidget" name="tab">
<attribute name="title">
<string>Settings</string>
</attribute>
</widget>
<widget class="QWidget" name="TAdminActions">
<property name="enabled">
<bool>false</bool>
@ -507,6 +555,9 @@
</item>
<item>
<widget class="QTableView" name="TVClients">
<property name="enabled">
<bool>true</bool>
</property>
<property name="minimumSize">
<size>
<width>0</width>

Loading…
Cancel
Save