Mercurial > hg > easyhg
diff filestatuswidget.h @ 283:bc39f2e28da8 status_outside_tabs
Separate out work-status code from the file status widget
author | Chris Cannam |
---|---|
date | Mon, 21 Feb 2011 08:48:31 +0000 |
parents | 8fd71f570884 |
children | 3fbafca196e4 |
line wrap: on
line diff
--- a/filestatuswidget.h Fri Feb 18 13:39:16 2011 +0000 +++ b/filestatuswidget.h Mon Feb 21 08:48:31 2011 +0000 @@ -27,9 +27,10 @@ class QListWidget; class QPushButton; class QFileInfo; -class ClickableLabel; class QCheckBox; +class WorkStatusWidget; + class FileStatusWidget : public QWidget { Q_OBJECT @@ -38,16 +39,16 @@ FileStatusWidget(QWidget *parent = 0); ~FileStatusWidget(); - QString localPath() const { return m_localPath; } + QString localPath() const; void setLocalPath(QString p); - QString remoteURL() const { return m_remoteURL; } + QString remoteURL() const; void setRemoteURL(QString u); - QString state() const { return m_state; } + QString state() const; void setState(QString b); - FileStates fileStates() const { return m_fileStates; } + FileStates fileStates() const; void setFileStates(FileStates sp); bool haveChangesToCommit() const; @@ -80,17 +81,9 @@ private slots: void itemSelectionChanged(); - void openButtonClicked(); private: - QString m_localPath; - ClickableLabel *m_openButton; - - QString m_remoteURL; - QLabel *m_remoteURLLabel; - - QString m_state; - QLabel *m_stateLabel; + WorkStatusWidget *m_workStatus; QLabel *m_noModificationsLabel; @@ -112,7 +105,6 @@ void layoutBoxesGridly(int count); void layoutBoxesLinearly(); - void updateStateLabel(); void setNoModificationsLabelText(); QString labelFor(FileStates::State, bool addHighlightExplanation = false); void setLabelFor(QWidget *w, FileStates::State, bool addHighlightExplanation);