diff --git a/Makefile.am b/Makefile.am index 0f7b5d3ee1..807ae25ea2 100644 --- a/Makefile.am +++ b/Makefile.am @@ -20,7 +20,6 @@ EXTRA_DIST = \ install.txt \ m4 \ postinstall-pak \ - tcutils \ vrplayer if XRDP_NEUTRINORDP diff --git a/README.md b/README.md index 7380c40c2c..66f957fade 100644 --- a/README.md +++ b/README.md @@ -140,7 +140,6 @@ xrdp |├── chansrv ···· channel server for xrdp |├── libscp ····· authorization library |└── tools ······ session management tools for sys admins -├── tcutils ····· QT based utility program for thin clients ├── tests ······· tests for the code ├┬─ tools ······· tools |└┬─ devel ······ development tools diff --git a/tcutils/README.txt b/tcutils/README.txt deleted file mode 100644 index 342dc8911f..0000000000 --- a/tcutils/README.txt +++ /dev/null @@ -1,29 +0,0 @@ -A QT based utility program for thin clients using xrdp and NeutrinoRDP - -This program sends commands to NeutrinoRDP to do something -useful on the client end (such as unmounting a USB drive, -or powering down the client) - -Required packages to build tcutils: ------------------------------------ -libqt4-gui -qt4-dev-tools - -to build tcutils: ------------------ -qmake -make - -To run tcutils: ---------------- -include xrdpapi/.libs in your LD_LIBRARY_PATH - -Example: --------- -export LD_LIBRARY_PATH=../xrdpapi/.libs -run tcutils inside the xfreerdp session - -this is how we run xfreerdp: ----------------------------- -./xfreerdp --sec rdp --plugin tcutils 192.168.2.149 - diff --git a/tcutils/main.cpp b/tcutils/main.cpp deleted file mode 100644 index d951345f49..0000000000 --- a/tcutils/main.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include "mainwindow.h" - -int main(int argc, char *argv[]) -{ - QApplication a(argc, argv); - MainWindow w; - w.show(); - - return a.exec(); -} diff --git a/tcutils/mainwindow.cpp b/tcutils/mainwindow.cpp deleted file mode 100644 index 8cc0a98834..0000000000 --- a/tcutils/mainwindow.cpp +++ /dev/null @@ -1,234 +0,0 @@ -#include "mainwindow.h" -#include "ui_mainwindow.h" - -MainWindow::MainWindow(QWidget *parent) : - QMainWindow(parent), - ui(new Ui::MainWindow) -{ - ui->setupUi(this); - - wtsChannel = NULL; - okToQuit = false; - savedGeometry = this->geometry(); - - /* setup tab to unmount drives */ - ui->tabWidget->setTabText(0, "Unmount drives"); - connect(ui->btnRefresh, SIGNAL(clicked()), this, SLOT(onBtnRefreshClicked())); - connect(ui->btnUnmount, SIGNAL(clicked()), this, SLOT(onBtnUnmountClicked())); - - ui->tabWidget->setTabText(1, ""); - if (initWtsChannel()) - { - okToQuit = true; - QTimer::singleShot(10, qApp, SLOT(quit())); - return; - } - setupSystemTray(); - - /* set up status bar to display messages */ - statusBar = new QStatusBar; - this->setStatusBar(statusBar); - setStatusMsg("Connected to client"); -} - -MainWindow::~MainWindow() -{ - delete ui; -} - -void MainWindow::setupSystemTray() -{ - trayMenu = new QMenu(this); - trayMenu->addAction("Launch Thinclient Utils", this, SLOT(onActionLaunch())); - trayMenu->addSeparator(); - trayMenu->addAction("Quit", this, SLOT(onActionQuit())); - - trayIcon = new QSystemTrayIcon; - trayIcon->setContextMenu(trayMenu); - trayIcon->setIcon(QIcon(":/images/resources/images/tools.gif")); - - trayIcon->show(); - - trayIcon->showMessage("TCutils", "Click on the tcutils icon to launch tcutils", - QSystemTrayIcon::Information, 3000); - - connect(trayIcon, SIGNAL(activated(QSystemTrayIcon::ActivationReason)), - this, SLOT(onSystemTrayClicked(QSystemTrayIcon::ActivationReason))); -} - -/** - * - *****************************************************************************/ - -int MainWindow::initWtsChannel() -{ - /* init the channel just once */ - if (wtsChannel) - return 0; - - /* open a WTS channel and connect to remote client */ - wtsChannel = WTSVirtualChannelOpenEx(WTS_CURRENT_SESSION, "tcutils", 0); - if (wtsChannel == NULL) - { - QMessageBox::information(this, "Open virtual channel", "Error " - "connecting to remote client. This program " - "can only be used when connected via " - "NeutrinoRDP.\n\nClick ok to close this " - "application"); - return -1; - } - - return 0; -} - -/** - * - *****************************************************************************/ - -int MainWindow::deinitWtsChannel() -{ - if (!wtsChannel) - return -1; - - WTSVirtualChannelClose(wtsChannel); - return 0; -} - -/** - * Display a msg on the status bar - * - * @param msg message to display in status bar - *****************************************************************************/ - -void MainWindow::setStatusMsg(QString msg) -{ - statusBar->showMessage(msg, 30000); -} - -/** - * - *****************************************************************************/ - -void MainWindow::closeEvent(QCloseEvent *event) -{ - if (!okToQuit) - { - savedGeometry = this->geometry(); - this->hide(); - event->ignore(); - return; - } - - if (wtsChannel) - deinitWtsChannel(); - - event->accept(); -} - -/****************************************************************************** -** ** -** slots go here ** -** ** -******************************************************************************/ -#if 1 -void MainWindow::onBtnRefreshClicked() -{ - int i; - - /* clear drive list */ - if (itemList.count()) - { - for (i = 0; i < itemList.count(); i++) - ui->listWidget->removeItemWidget(itemList.at(i)); - - itemList.clear(); - } - ui->listWidget->clear(); - - if (Utils::getMountList(wtsChannel, &itemList)) - { - QMessageBox::information(this, "Get device list", "\nError getting " - "device list from client"); - return; - } - - if (itemList.count() == 0) - { - QMessageBox::information(this, "Get device list", - "\nNo devices found!"); - return; - } - - /* add mount point to list widget */ - for (i = 0; i < itemList.count(); i++) - ui->listWidget->insertItem(i, itemList.at(i)); -} -#else -void MainWindow::onBtnRefreshClicked() -{ - QListWidgetItem *item; - int i; - int j; - - /* clear drive list */ - if (itemList.count()) - { - for (i = 0; i < itemList.count(); i++) - ui->listWidget->removeItemWidget(itemList.at(i)); - - itemList.clear(); - } - ui->listWidget->clear(); - - QDir dir(QDir::homePath() + "/xrdp_client"); - QStringList sl = dir.entryList(); - - for (i = 0, j = 0; i < sl.count(); i++) - { - /* skip files starting with . */ - if (sl.at(i).startsWith(".")) - continue; - - /* add mount point to list widget */ - item = new QListWidgetItem; - item->setText(sl.at(i)); - ui->listWidget->insertItem(j++, item); - itemList.append(item); - } -} -#endif - -void MainWindow::onBtnUnmountClicked() -{ - QListWidgetItem *item = ui->listWidget->currentItem(); - - if (!item) - { - QMessageBox::information(this, "Unmount device", "\nNo device selected. " - "You must select a device to unmount"); - return; - } - - if (Utils::unmountDevice(wtsChannel, item->text(), statusBar) == 0) - { - delete ui->listWidget->takeItem(itemList.indexOf(item)); - itemList.removeOne(item); - } -} - -void MainWindow::onActionQuit() -{ - okToQuit = true; - this->close(); -} - -void MainWindow::onActionLaunch() -{ - this->show(); - this->setGeometry(savedGeometry); -} - -void MainWindow::onSystemTrayClicked(QSystemTrayIcon::ActivationReason) -{ - trayMenu->popup(QCursor::pos()); -} diff --git a/tcutils/mainwindow.h b/tcutils/mainwindow.h deleted file mode 100644 index 4b59df15d9..0000000000 --- a/tcutils/mainwindow.h +++ /dev/null @@ -1,58 +0,0 @@ -#ifndef MAINWINDOW_H -#define MAINWINDOW_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -//#include - -#include "utils.h" - -namespace Ui -{ - class MainWindow; -} - -class MainWindow : public QMainWindow -{ - Q_OBJECT - - public: - explicit MainWindow(QWidget *parent = 0); - ~MainWindow(); - - private: - Ui::MainWindow *ui; - void *wtsChannel; - QSystemTrayIcon *trayIcon; - QMenu *trayMenu; - bool okToQuit; - QRect savedGeometry; - QStatusBar *statusBar; - - QList itemList; - - void setupSystemTray(); - int initWtsChannel(); - int deinitWtsChannel(); - void setStatusMsg(QString msg); - void closeEvent(QCloseEvent *event); - - private slots: - void onBtnRefreshClicked(); - void onBtnUnmountClicked(); - void onActionQuit(); - void onActionLaunch(); - void onSystemTrayClicked(QSystemTrayIcon::ActivationReason); -}; - -#endif // MAINWINDOW_H diff --git a/tcutils/mainwindow.ui b/tcutils/mainwindow.ui deleted file mode 100644 index 802d01a361..0000000000 --- a/tcutils/mainwindow.ui +++ /dev/null @@ -1,100 +0,0 @@ - - - MainWindow - - - - 0 - 0 - 541 - 355 - - - - TC Utils - - - - - - 0 - 0 - 511 - 291 - - - - 0 - - - - Tab 1 - - - - - 10 - 10 - 321 - 221 - - - - - - - 350 - 60 - 141 - 27 - - - - Unmount device - - - - - - 350 - 10 - 141 - 27 - - - - Get device list - - - - - - Tab 2 - - - - - - - - 0 - 0 - 541 - 25 - - - - - - TopToolBarArea - - - false - - - - - - - - diff --git a/tcutils/resources.qrc b/tcutils/resources.qrc deleted file mode 100644 index 76a1f852d8..0000000000 --- a/tcutils/resources.qrc +++ /dev/null @@ -1,5 +0,0 @@ - - - resources/images/tools.gif - - diff --git a/tcutils/resources/images/tools.gif b/tcutils/resources/images/tools.gif deleted file mode 100644 index c6596cc441..0000000000 Binary files a/tcutils/resources/images/tools.gif and /dev/null differ diff --git a/tcutils/tcutils.pro.user b/tcutils/tcutils.pro.user deleted file mode 100644 index 50311334f9..0000000000 --- a/tcutils/tcutils.pro.user +++ /dev/null @@ -1,365 +0,0 @@ - - - - - - ProjectExplorer.Project.ActiveTarget - 0 - - - ProjectExplorer.Project.EditorSettings - - true - false - - Cpp - - CppGlobal - - - - QmlJS - - QmlJSGlobal - - - 2 - System - true - 4 - true - 1 - true - 2 - true - 0 - 8 - true - 1 - true - true - true - true - - - - ProjectExplorer.Project.PluginSettings - - - - ProjectExplorer.Project.Target.0 - - Desktop - Desktop - Qt4ProjectManager.Target.DesktopTarget - 0 - 0 - 0 - - ProjectExplorer.ToolChain.Gcc:/usr/bin/g++.x86-linux-generic-elf-32bit./usr/bin/gdb - - - qmake - - QtProjectManager.QMakeBuildStep - false - true - - false - - - Make - - Qt4ProjectManager.MakeStep - false - - - - 2 - Build - - ProjectExplorer.BuildSteps.Build - - - - Make - - Qt4ProjectManager.MakeStep - true - clean - - - 1 - Clean - - ProjectExplorer.BuildSteps.Clean - - 2 - false - - Qt 4.8.1 in PATH (System) Release - - Qt4ProjectManager.Qt4BuildConfiguration - 0 - /home/lk/projects/jtech/nlabs_xrdp_tcutils/tcutils-build-desktop-Qt_4_8_1_in_PATH__System__Release - 1 - true - - - ProjectExplorer.ToolChain.Gcc:/usr/bin/g++.x86-linux-generic-elf-32bit./usr/bin/gdb - - - qmake - - QtProjectManager.QMakeBuildStep - false - true - - false - - - Make - - Qt4ProjectManager.MakeStep - false - - - - 2 - Build - - ProjectExplorer.BuildSteps.Build - - - - Make - - Qt4ProjectManager.MakeStep - true - clean - - - 1 - Clean - - ProjectExplorer.BuildSteps.Clean - - 2 - false - - Qt 4.8.1 in PATH (System) Debug - - Qt4ProjectManager.Qt4BuildConfiguration - 2 - /home/lk/projects/jtech/nlabs_xrdp_tcutils/tcutils-build-desktop-Qt_4_8_1_in_PATH__System__Debug - 1 - true - - - ProjectExplorer.ToolChain.Gcc:/usr/bin/g++.x86-linux-generic-elf-32bit./usr/bin/gdb - - - qmake - - QtProjectManager.QMakeBuildStep - false - true - - false - - - Make - - Qt4ProjectManager.MakeStep - false - - - - 2 - Build - - ProjectExplorer.BuildSteps.Build - - - - Make - - Qt4ProjectManager.MakeStep - true - clean - - - 1 - Clean - - ProjectExplorer.BuildSteps.Clean - - 2 - false - - Qt 4.8.1 (System) Release - - Qt4ProjectManager.Qt4BuildConfiguration - 0 - /home/lk/projects/jtech/nlabs_xrdp_tcutils/tcutils-build-desktop-Qt_4_8_1__System__Release - 2 - true - - - ProjectExplorer.ToolChain.Gcc:/usr/bin/g++.x86-linux-generic-elf-32bit./usr/bin/gdb - - - qmake - - QtProjectManager.QMakeBuildStep - false - true - - false - - - Make - - Qt4ProjectManager.MakeStep - false - - - - 2 - Build - - ProjectExplorer.BuildSteps.Build - - - - Make - - Qt4ProjectManager.MakeStep - true - clean - - - 1 - Clean - - ProjectExplorer.BuildSteps.Clean - - 2 - false - - Qt 4.8.1 (System) Debug - - Qt4ProjectManager.Qt4BuildConfiguration - 2 - /home/lk/projects/jtech/nlabs_xrdp_tcutils/tcutils-build-desktop-Qt_4_8_1__System__Debug - 2 - true - - 4 - - - 0 - Deploy - - ProjectExplorer.BuildSteps.Deploy - - 1 - No deployment - - ProjectExplorer.DefaultDeployConfiguration - - 1 - - true - true - - - false - false - false - false - false - false - false - false - true - true - 0.01 - 0.01 - 10 - 10 - true - true - 25 - 25 - - - true - true - valgrind - valgrind - - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - - - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - - tcutils - - Qt4ProjectManager.Qt4RunConfiguration - 2 - - tcutils.pro - false - false - - - 3768 - true - false - false - - 1 - - - - ProjectExplorer.Project.TargetCount - 1 - - - ProjectExplorer.Project.Updater.EnvironmentId - {9a0d9632-2baf-44e0-864a-a12692180779} - - - ProjectExplorer.Project.Updater.FileVersion - 10 - - diff --git a/tcutils/utils.cpp b/tcutils/utils.cpp deleted file mode 100644 index 34ca5614a9..0000000000 --- a/tcutils/utils.cpp +++ /dev/null @@ -1,217 +0,0 @@ -#include "utils.h" - -Utils::Utils() -{ -} - -int Utils::getMountList(void *wtsChannel, QList *itemList) -{ - QListWidgetItem *item; - - STREAM s; - quint32 bytesToSend; - quint32 bytesWritten; - quint32 bytesRead; - quint32 cmdLen; - quint32 cmd; - int rv; - int i; - int nentries; - char buf[2048]; - - if (!wtsChannel) - return -1; - - qstream_new(s, 1024 * 8); - - /* - * command format: - * 4 bytes cmd_len length of this command - * 1 byte cmd TCU_CMD_GET_MOUNT_LIST - */ - - /* setup command */ - qstream_wr_u32(&s, 1); - qstream_wr_u8(&s, TCU_CMD_GET_MOUNT_LIST); - bytesToSend = 5; - - /* send command */ - rv = WTSVirtualChannelWrite(wtsChannel, s.data, bytesToSend, &bytesWritten); - if (rv == 0) - { - QMessageBox::information(NULL, "Get device list", "\nError sending " - "command to client"); - return -1; - } - - qstream_set_pos(&s, 0); /* reuse stream */ - - /* get response */ - - /* - * response format - * 4 bytes cmd_len length of this command - * 4 bytes cmd TCU_CMD_GET_MOUNT_LIST - * 1 byte nentries number of entries in this pkt - * n bytes entry_list nentries null terminated strings - */ - - rv = WTSVirtualChannelRead(wtsChannel, 1000 * 5, s.data, 1024 * 8, &bytesRead); - if (rv == 0 || bytesRead == 0) - goto error; - - /* did we get the entire cmd? */ - qstream_rd_u32(&s, cmdLen); - if (cmdLen != bytesRead - 4) - goto error; - - /* did we get the right response? */ - qstream_rd_u32(&s, cmd); - if (cmd != TCU_CMD_GET_MOUNT_LIST) - goto error; - - qstream_rd_u8(&s, nentries); - if (nentries == 0) - goto done; - - for (i = 0; i < nentries; i++) - { - strcpy(buf, s.pos); - qstream_inc_pos(&s, strlen(buf) + 1); - item = new QListWidgetItem; - item->setText(QString(buf)); - itemList->append(item); - } - -done: - qstream_free(&s); - return 0; - -error: - qstream_free(&s); - return -1; -} - -int Utils::unmountDevice(void *wtsChannel, QString device, QStatusBar *statusBar) -{ - STREAM s; - quint32 bytesRead; - quint32 cmdLen; - quint32 cmd; - quint32 bytesWritten; - int bytesToSend; - int rv; - int seconds = 0; - char status; - char* buf; - - if (!wtsChannel) - return -1; - - qstream_new(s, 1024); - buf = device.toAscii().data(); - - /* - * command format: - * 4 bytes cmd_len length of this command - * 4 bytes cmd TCU_CMD_UNMOUNT_DEVICE - * n bytes device null terminated device name - */ - - /* setup command */ - bytesToSend = 4 + 4 + device.count() + 1; - qstream_wr_u32(&s, bytesToSend - 4); - qstream_wr_u32(&s, TCU_CMD_UNMOUNT_DEVICE); - strcpy(s.pos, buf); - - /* send command */ - rv = WTSVirtualChannelWrite(wtsChannel, s.data, bytesToSend, &bytesWritten); - if (rv == 0) - { - QMessageBox::information(NULL, "Unmount device", "\nError sending " - "command to client"); - return -1; - } - - qstream_set_pos(&s, 0); /* reuse stream */ - - /* get response */ - - /* - * command format - * 4 bytes cmd_len number of bytes in this pkt - * 4 bytes cmd TCU_CMD_UNMOUNT_DEVICE - * 1 byte status operation status code - */ - - while (1) - { - rv = WTSVirtualChannelRead(wtsChannel, 1000 * 1, s.data, 1024, &bytesRead); - if (rv == 0) - goto error; - - if (bytesRead) - break; - - statusBar->showMessage("Waiting for client to unmount device: " + - QString::number(++seconds) + " seconds", 30000); - } - - statusBar->showMessage(""); - - /* did we get the entire pkt? */ - qstream_rd_u32(&s, cmdLen); - if (cmdLen != bytesRead - 4) - goto error; - - /* did we get the right response? */ - qstream_rd_u32(&s, cmd); - if (cmd != TCU_CMD_UNMOUNT_DEVICE) - goto error; - - /* get status */ - qstream_rd_u8(&s, status); - switch(status) - { - case UMOUNT_SUCCESS: - goto done; - break; - - case UMOUNT_BUSY: - QMessageBox::information(NULL, "Unmount error", "\nCannot unmount device " - "because it is in use"); - break; - - case UMOUNT_NOT_MOUNTED: - QMessageBox::information(NULL, "Unmount error", "\nCannot unmount device " - "because it is not mounted"); - break; - - case UMOUNT_OP_NOT_PERMITTED: - QMessageBox::information(NULL, "Unmount error", "\nOperation not " - "permitted. The device may be in use"); - break; - - case UMOUNT_PERMISSION_DENIED: - QMessageBox::information(NULL, "Unmount error", "\nYou don't have " - "permission to unmount this device"); - break; - - case UMOUNT_UNKNOWN: - QMessageBox::information(NULL, "Unmount error", "Cannot unmount " - "device, an unknown error has occurred. The " - "drive may be in use or you do not have " - "permission to unmount it"); - break; - } - - goto error; - -done: - qstream_free(&s); - return 0; - -error: - qstream_free(&s); - return -1; -} diff --git a/tcutils/utils.h b/tcutils/utils.h deleted file mode 100644 index c94af7801b..0000000000 --- a/tcutils/utils.h +++ /dev/null @@ -1,152 +0,0 @@ -#ifndef UTILS_H -#define UTILS_H - -#include -#include -#include -#include -#include - -/* - * stream definition and macros to access them; - * all definitions default to little endian - */ - -typedef struct stream -{ - char *data; /* holds stream data */ - char *pos; /* current read/write position */ - int size; /* number of bytes in data */ - - stream() : data(0), pos(0), size(0) {} -} STREAM; - -#define qstream_new(_s, _size) \ - do \ - { \ - (_s).data = (char *) malloc(_size); \ - (_s).pos = (_s).data; \ - (_s).size = (_size); \ - } \ - while (0) - -#define qstream_new_zero(_s, _size) \ - do \ - { \ - (_s).data = (char *) calloc((_size), 1); \ - (_s).pos = (_s).data; \ - (_s).size = (_size); \ - } \ - while (0) - -#define qstream_free(_s) \ - do \ - { \ - if ((_s)->data) \ - free((_s)->data); \ - } \ - while (0) - -#define qstream_set_pos(_s, _p) \ - do \ - { \ - (_s)->pos = (_s)->data + (_p); \ - } \ - while (0) - -#define qstream_inc_pos(_s, _v) \ - do \ - { \ - (_s)->pos += (_v); \ - } \ - while (0) - -#define qstream_rd_u8(_s, _v) \ - do \ - { \ - (_v) = *((unsigned char *) ((_s)->pos)); \ - (_s)->pos++; \ - } \ - while (0) - -#define qstream_rd_u16(_s, _v) \ - do \ - { \ - (_v) = (unsigned short) \ - ( \ - (*((unsigned char *) ((_s)->pos + 0)) << 0) | \ - (*((unsigned char *) ((_s)->pos + 1)) << 8) \ - ); \ - (_s)->pos += 2; \ - } while (0) - -#define qstream_rd_u32(_s, _v) \ - do \ - { \ - (_v) = (unsigned int) \ - ( \ - (*((unsigned char *) ((_s)->pos + 0)) << 0) | \ - (*((unsigned char *) ((_s)->pos + 1)) << 8) | \ - (*((unsigned char *) ((_s)->pos + 2)) << 16) | \ - (*((unsigned char *) ((_s)->pos + 3)) << 24) \ - ); \ - (_s)->pos += 4; \ - } while (0) - -#define qstream_wr_u8(_s, _v) \ - do \ - { \ - *((_s)->pos) = (unsigned char) (_v); \ - (_s)->pos++; \ - } while (0) - -#define qstream_wr_u16(_s, _v) \ - do \ - { \ - *((_s)->pos) = (unsigned char) ((_v) >> 0); \ - (_s)->pos++; \ - *((_s)->pos) = (unsigned char) ((_v) >> 8); \ - (_s)->pos++; \ - } while (0) - -#define qstream_wr_u32(_s, _v) \ - do \ - { \ - *((_s)->pos) = (unsigned char) ((_v) >> 0); \ - (_s)->pos++; \ - *((_s)->pos) = (unsigned char) ((_v) >> 8); \ - (_s)->pos++; \ - *((_s)->pos) = (unsigned char) ((_v) >> 16); \ - (_s)->pos++; \ - *((_s)->pos) = (unsigned char) ((_v) >> 24); \ - (_s)->pos++; \ - } while (0) - -/* list of commands we support; this list should match the one in */ -/* NeutrinoRDP channels/tcutils/tcutils_main.h */ -enum TCU_COMMANDS -{ - TCU_CMD_GET_MOUNT_LIST = 1, - TCU_CMD_UNMOUNT_DEVICE -}; - -/* umount error codes */ -enum TCU_UMOUNT_ERROR -{ - UMOUNT_SUCCESS = 0, - UMOUNT_BUSY, - UMOUNT_NOT_MOUNTED, - UMOUNT_OP_NOT_PERMITTED, - UMOUNT_PERMISSION_DENIED, - UMOUNT_UNKNOWN -}; - -class Utils -{ - public: - Utils(); - static int getMountList(void *wtsChannel, QList *itemList); - static int unmountDevice(void *wtsChannel, QString device, QStatusBar *statusBar); -}; - -#endif // UTILS_H