Browse Source

- Removed "Resize all columns" action

adaptive-webui-19844
Christophe Dumez 17 years ago
parent
commit
adea644c04
  1. 11
      src/FinishedTorrents.cpp
  2. 1
      src/FinishedTorrents.h
  3. 5
      src/download.ui
  4. 11
      src/downloadingTorrents.cpp
  5. 1
      src/downloadingTorrents.h
  6. 5
      src/seeding.ui

11
src/FinishedTorrents.cpp

@ -82,7 +82,6 @@ FinishedTorrents::FinishedTorrents(QObject *parent, bittorrent *BTSession) : par @@ -82,7 +82,6 @@ FinishedTorrents::FinishedTorrents(QObject *parent, bittorrent *BTSession) : par
connect(actionHOSColUpSpeed, SIGNAL(triggered()), this, SLOT(hideOrShowColumnUpSpeed()));
connect(actionHOSColLeechers, SIGNAL(triggered()), this, SLOT(hideOrShowColumnLeechers()));
connect(actionHOSColRatio, SIGNAL(triggered()), this, SLOT(hideOrShowColumnRatio()));
connect(actionResizeAllColumns, SIGNAL(triggered()), this, SLOT(resetAllColumns()));
}
FinishedTorrents::~FinishedTorrents(){
@ -398,7 +397,6 @@ void FinishedTorrents::displayFinishedHoSMenu(const QPoint& pos){ @@ -398,7 +397,6 @@ void FinishedTorrents::displayFinishedHoSMenu(const QPoint& pos){
for(int i=0; i<=F_RATIO; i++) {
hideshowColumn.addAction(getActionHoSCol(i));
}
hideshowColumn.addAction(actionResizeAllColumns);
// Call menu
hideshowColumn.exec(mapToGlobal(pos)+QPoint(10,55));
}
@ -469,15 +467,6 @@ void FinishedTorrents::hideOrShowColumnRatio() { @@ -469,15 +467,6 @@ void FinishedTorrents::hideOrShowColumnRatio() {
hideOrShowColumn(F_RATIO);
}
void FinishedTorrents::resetAllColumns() {
for(int i=0; i<finishedListModel->columnCount()-1; i++) {
finishedList->setColumnHidden(i, false);
finishedList->resizeColumnToContents(i);
getActionHoSCol(i)->setIcon(QIcon(QString::fromUtf8(":/Icons/button_ok.png")));
}
finishedList->setColumnWidth(F_NAME,270);
}
// load the previous settings, and hide the columns
bool FinishedTorrents::loadHiddenColumns() {
bool loaded = false;

1
src/FinishedTorrents.h

@ -73,7 +73,6 @@ class FinishedTorrents : public QWidget, public Ui::seeding { @@ -73,7 +73,6 @@ class FinishedTorrents : public QWidget, public Ui::seeding {
void hideOrShowColumnUpSpeed();
void hideOrShowColumnLeechers();
void hideOrShowColumnRatio();
void resetAllColumns();
public slots:
void addTorrent(QString hash);

5
src/download.ui

@ -428,11 +428,6 @@ @@ -428,11 +428,6 @@
<string>ETA</string>
</property>
</action>
<action name="actionResizeAllColumns" >
<property name="text" >
<string>Resize all</string>
</property>
</action>
</widget>
<resources>
<include location="icons.qrc" />

11
src/downloadingTorrents.cpp

@ -107,7 +107,6 @@ DownloadingTorrents::DownloadingTorrents(QObject *parent, bittorrent *BTSession) @@ -107,7 +107,6 @@ DownloadingTorrents::DownloadingTorrents(QObject *parent, bittorrent *BTSession)
connect(actionHOSColSeedersLeechers, SIGNAL(triggered()), this, SLOT(hideOrShowColumnSeedersLeechers()));
connect(actionHOSColRatio, SIGNAL(triggered()), this, SLOT(hideOrShowColumnRatio()));
connect(actionHOSColEta, SIGNAL(triggered()), this, SLOT(hideOrShowColumnEta()));
connect(actionResizeAllColumns, SIGNAL(triggered()), this, SLOT(resetAllColumns()));
// Set info Bar infos
setInfoBar(tr("qBittorrent %1 started.", "e.g: qBittorrent v0.x started.").arg(QString::fromUtf8(""VERSION)));
@ -316,7 +315,6 @@ void DownloadingTorrents::displayDLHoSMenu(const QPoint& pos){ @@ -316,7 +315,6 @@ void DownloadingTorrents::displayDLHoSMenu(const QPoint& pos){
for(int i=0; i<=ETA; i++) {
hideshowColumn.addAction(getActionHoSCol(i));
}
hideshowColumn.addAction(actionResizeAllColumns);
// Call menu
hideshowColumn.exec(mapToGlobal(pos)+QPoint(10,55));
}
@ -475,15 +473,6 @@ QAction* DownloadingTorrents::getActionHoSCol(int index) { @@ -475,15 +473,6 @@ QAction* DownloadingTorrents::getActionHoSCol(int index) {
}
}
void DownloadingTorrents::resetAllColumns() {
for(int i=0; i<DLListModel->columnCount()-1; i++) {
downloadList->setColumnHidden(i, false);
downloadList->resizeColumnToContents(i);
getActionHoSCol(i)->setIcon(QIcon(QString::fromUtf8(":/Icons/button_ok.png")));
}
downloadList->setColumnWidth(NAME,270);
}
QStringList DownloadingTorrents::getSelectedTorrents(bool only_one) const{
QStringList res;
QModelIndex index;

1
src/downloadingTorrents.h

@ -92,7 +92,6 @@ class DownloadingTorrents : public QWidget, public Ui::downloading{ @@ -92,7 +92,6 @@ class DownloadingTorrents : public QWidget, public Ui::downloading{
void hideOrShowColumnSeedersLeechers();
void hideOrShowColumnRatio();
void hideOrShowColumnEta();
void resetAllColumns();
public slots:
void updateDlList();

5
src/seeding.ui

@ -131,11 +131,6 @@ @@ -131,11 +131,6 @@
<string>Ratio</string>
</property>
</action>
<action name="actionResizeAllColumns" >
<property name="text" >
<string>Resize All</string>
</property>
</action>
</widget>
<resources>
<include location="icons.qrc" />

Loading…
Cancel
Save