mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-30 00:14:57 +00:00
- Style is now applied instantly, no need to restart qBT
- Fixed a typo in WIndowsXP Style
This commit is contained in:
parent
5ddc3467f8
commit
81eee7bba2
2
TODO
2
TODO
@ -36,7 +36,7 @@
|
||||
- Use a QListWidget to allow multiple input paths
|
||||
- Possibility to add url seeds
|
||||
- Add IPv6 support (at least start working on it, libtorrent seems to support it, we should limit our code to IPv4 anymore)
|
||||
- UPnP support (debug, sync with next aMule release (or CVS)) : seems to be working!
|
||||
- UPnP support (debug, sync with next aMule release) : seems to be working!
|
||||
- Update v0.9.0 changelog after its release
|
||||
- Display Url seeds in torrent properties and allow to edit them
|
||||
- Improve Ipfilter.dat parser (move to a thread ? - too slow to load qBT and more importantly options)
|
||||
|
@ -35,7 +35,6 @@
|
||||
#ifdef Q_WS_WIN
|
||||
#include <QWindowsXPStyle>
|
||||
#endif
|
||||
|
||||
#ifdef Q_WS_MAC
|
||||
#include <QMacStyle>
|
||||
#endif
|
||||
|
@ -1600,7 +1600,7 @@
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text" >
|
||||
<string>WindowsXP style (WIndows XP only)</string>
|
||||
<string>WindowsXP style (Windows XP only)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
|
@ -23,7 +23,19 @@
|
||||
#include <QMessageBox>
|
||||
#include <QInputDialog>
|
||||
#include <QSystemTrayIcon>
|
||||
#include <QApplication>
|
||||
#include <QSettings>
|
||||
#include <QPlastiqueStyle>
|
||||
#include <QCleanlooksStyle>
|
||||
#include <QMotifStyle>
|
||||
#include <QCDEStyle>
|
||||
#ifdef Q_WS_WIN
|
||||
#include <QWindowsXPStyle>
|
||||
#endif
|
||||
|
||||
#ifdef Q_WS_MAC
|
||||
#include <QMacStyle>
|
||||
#endif
|
||||
|
||||
#include "options_imp.h"
|
||||
#include "misc.h"
|
||||
@ -193,8 +205,39 @@ options_imp::~options_imp(){
|
||||
qDebug("-> destructing Options");
|
||||
}
|
||||
|
||||
void options_imp::useStyle(){
|
||||
QString style = getStyle();
|
||||
if(style == "Cleanlooks"){
|
||||
QApplication::setStyle(new QCleanlooksStyle());
|
||||
return;
|
||||
}
|
||||
if(style == "Motif"){
|
||||
QApplication::setStyle(new QMotifStyle());
|
||||
return;
|
||||
}
|
||||
if(style == "CDE"){
|
||||
QApplication::setStyle(new QCDEStyle());
|
||||
return;
|
||||
}
|
||||
#ifdef Q_WS_MAC
|
||||
if(style == "MacOS"){
|
||||
QApplication::setStyle(new QMacStyle());
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
#ifdef Q_WS_WIN
|
||||
if(style == "WinXP"){
|
||||
QApplication::setStyle(new QWindowsXPStyle());
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
QApplication::setStyle(new QPlastiqueStyle());
|
||||
}
|
||||
|
||||
void options_imp::saveOptions(){
|
||||
QSettings settings("qBittorrent", "qBittorrent");
|
||||
// Apply style
|
||||
useStyle();
|
||||
// Check if min port < max port
|
||||
checkPortsLogic();
|
||||
settings.beginGroup("Options");
|
||||
|
@ -112,6 +112,7 @@ class options_imp : public QDialog, private Ui::Dialog{
|
||||
|
||||
public slots:
|
||||
void setLocale(QString locale);
|
||||
void useStyle();
|
||||
|
||||
signals:
|
||||
void status_changed(const QString&, bool) const;
|
||||
|
Loading…
x
Reference in New Issue
Block a user