1 /*---------------------------------------------------------------------\
3 | __ __ ____ _____ ____ |
4 | \ \ / /_ _/ ___|_ _|___ \ |
5 | \ V / _` \___ \ | | __) | |
6 | | | (_| |___) || | / __/ |
7 | |_|\__,_|____/ |_| |_____| |
11 \----------------------------------------------------------------------/
13 File: YQPkgDiskUsageWarningDialog.h
15 Author: Stefan Hundhammer <sh@suse.de>
20 #ifndef YQPkgDiskUsageWarningDialog_h
21 #define YQPkgDiskUsageWarningDialog_h
26 class YQPkgDiskUsageList;
30 * Warning dialog about partitions that are getting full or overflowing.
32 class YQPkgDiskUsageWarningDialog : public QDialog
38 * Static convenience method: Post a disk usage warning with text
39 * 'message', a list of partitions that are at least 'thresholdPercent'
40 * full and one ( default ) or two buttons.
42 * Returns 'true' if the user accepted ( i.e. clicked the 'accept' button )
43 * and 'false' if the user rejected ( i.e. clicked the 'reject' button or
44 * the window manager close button ).
46 static bool diskUsageWarning( const QString & message,
48 const QString & acceptButtonLabel,
49 const QString & rejectButtonLabel = QString::null );
53 * Constructor: Creates a disk usage warning dialog with text 'message' on
54 * top, a list of partitions that are at least 'thresholdPercent' full and
55 * one ( default ) or two buttons.
57 * Not meant for public use. Applications should use the static
58 * 'diskUsageWarning' method instead.
60 YQPkgDiskUsageWarningDialog( QWidget * parent,
61 const QString & message,
63 const QString & acceptButtonLabel,
64 const QString & rejectButtonLabel = QString::null );
68 #endif // ifndef YQPkgDiskUsageWarningDialog_h