TexturedButton::TexturedButton(Widget *parent, const Point &pos, const Size &size, int id, const char *resourceGroup, int normalTxIndex, int hovTxIndex, int prsTxIndex, int dsbTxIndex) : PushButton( parent, Rect( pos, size ), "", id, false, noBackground ) { setPicture( resourceGroup, normalTxIndex , stNormal ); setPicture( resourceGroup, (hovTxIndex == -1) ? normalTxIndex+1 : hovTxIndex, stHovered ); setPicture( resourceGroup, (prsTxIndex == -1) ? normalTxIndex+2 : prsTxIndex, stPressed ); setPicture( resourceGroup, (dsbTxIndex == -1) ? normalTxIndex+3 : dsbTxIndex, stDisabled ); setTextVisible( false ); }
IntervalChunksDisplay::IntervalChunksDisplay(QWidget *parent) : QProgressBar(parent), downloadedChunks(0), totalChunks(0) { setSizePolicy(QSizePolicy(QSizePolicy::Expanding, QSizePolicy::Maximum)); setToolTip("Downloaded intervals"); setAccessibleDescription(toolTip()); setValue(totalChunks); setTextVisible(false); }
// XXX - Add a "stop what you're doing this instant" button. // XXX - We need to show the task and item titles. Maybe as a tooltip or popped // into our sibling status message? ProgressBar::ProgressBar(QWidget *parent) : QProgressBar(parent), terminate_is_stop_(false), stop_flag_(NULL) { progress_dialog_.progress_bar = this; progress_dialog_.top_level_window = window(); //#ifdef Q_OS_MAC // // https://bugreports.qt-project.org/browse/QTBUG-11569 // setAttribute(Qt::WA_MacSmallSize, true); //#endif setTextVisible(false); setStyleSheet(QString( "ProgressBar {" " max-width: 20em;" " min-height: 0.8em;" " max-height: 1em;" " border-bottom: 0;" " background: transparent;" "}")); hide(); }
gui::TexturedButton::TexturedButton(gui::Widget *parent) : PushButton( parent ) { setTextVisible( false ); }