VBoxDownloaderWgt.h revision e1b1ef91aa5c073db2f70f9b03090332841de75d
/** @file
*
* VBox frontends: Qt GUI ("VirtualBox"):
* VBoxDownloaderWgt class declaration
*/
/*
* Copyright (C) 2006-2007 innotek GmbH
*
* This file is part of VirtualBox Open Source Edition (OSE), as
* available from http://www.virtualbox.org. This file is free software;
* General Public License as published by the Free Software Foundation,
* in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
* distribution. VirtualBox OSE is distributed in the hope that it will
* be useful, but WITHOUT ANY WARRANTY of any kind.
*/
#ifndef __VBoxDownloaderWgt_h__
#define __VBoxDownloaderWgt_h__
#include "HappyHttp.h"
#include "qwidget.h"
#include "qurl.h"
#include "qmutex.h"
/** class VBoxDownloaderWgt
*
* The VBoxDownloaderWgt class is an QWidget class for Guest Additions
* http backgroung downloading. This class is also used to display the
* Guest Additions download state through the progress dialog integrated
* into the VM console status bar.
*/
{
void languageChange();
bool isCheckingPresence() { return mIsChecking; }
/* This slot is used to control the connection timeout. */
void processTimeout();
/* This slot is used to process cancel-button clicking signal. */
void processAbort();
/* This slot is used to terminate the downloader, activate the
* Install Guest Additions action and removing the downloader's
* sub-widgets from the VM Console status-bar. */
void suicide();
/* Used to process all the widget events */
/* This function is used to make a request to get a file */
void getFile();
/* This function is used to ask the user about he wants to download the
* founded Guest Additions image or not. It also shows the progress-bar
* and Cancel-button widgets. */
void processFile (int aSize);
/* This wrapper displays an error message box (unless @aReason is
* QString::null) with the cause of the download procedure
* termination. After the message box is dismissed, the downloader signals
* to close itself on the next event loop iteration. */
void abortConnection();
bool mIsChecking;
bool mSuicide;
};
#endif