1
mirror of https://invent.kde.org/network/falkon.git synced 2024-09-21 17:52:10 +02:00

Coding style: Uninline public functions

This commit is contained in:
nowrep 2013-06-30 12:41:01 +02:00
parent 8414f4fa48
commit 2554ad9870
9 changed files with 43 additions and 8 deletions

View File

@ -245,6 +245,11 @@ QString DatabaseEncryptedPasswordBackend::name() const
return AutoFill::tr("Database (encrypted)");
}
bool DatabaseEncryptedPasswordBackend::hasSettings() const
{
return true;
}
void DatabaseEncryptedPasswordBackend::showSettings(QWidget* parent)
{
MasterPasswordDialog* masterPasswordDialog = new MasterPasswordDialog(this, parent);
@ -383,6 +388,11 @@ void DatabaseEncryptedPasswordBackend::removeMasterPassword()
}
}
void DatabaseEncryptedPasswordBackend::setAskMasterPasswordState(bool ask)
{
m_askMasterPassword = ask;
}
void DatabaseEncryptedPasswordBackend::encryptDataBaseTableOnFly(const QByteArray &decryptorPassword, const QByteArray &encryptorPassword)
{
if (encryptorPassword == decryptorPassword) {

View File

@ -54,7 +54,7 @@ public:
QString name() const;
inline bool hasSettings() const { return true; }
bool hasSettings() const;
void showSettings(QWidget* parent);
bool isMasterPasswordSetted();
@ -70,7 +70,7 @@ public:
void tryToChangeMasterPassword(const QByteArray &newPassword);
void removeMasterPassword();
inline void setAskMasterPasswordState(bool ask) { m_askMasterPassword = ask; }
void setAskMasterPasswordState(bool ask);
void encryptDataBaseTableOnFly(const QByteArray &decryptorPassword,
const QByteArray &encryptorPassword);

View File

@ -166,7 +166,7 @@ void NetworkManager::setSSLConfiguration(QNetworkReply* reply)
}
}
inline uint qHash(const QSslCertificate &cert)
static inline uint qHash(const QSslCertificate &cert)
{
return qHash(cert.toPem());
}

View File

@ -442,6 +442,21 @@ void FtpDownloader::download(const QUrl &url, QIODevice* dev)
connectToHost(server, port);
}
bool FtpDownloader::isFinished()
{
return m_isFinished;
}
QUrl FtpDownloader::url() const
{
return m_url;
}
QIODevice* FtpDownloader::device() const
{
return m_dev;
}
void FtpDownloader::setError(QFtp::Error err, const QString &errStr)
{
m_lastError = err;

View File

@ -99,9 +99,9 @@ public:
FtpDownloader(QObject* parent = 0);
void download(const QUrl &url, QIODevice* dev);
inline bool isFinished() {return m_isFinished;}
inline QUrl url() const {return m_url;}
inline QIODevice* device() const {return m_dev;}
bool isFinished();
QUrl url() const;
QIODevice* device() const;
void setError(QFtp::Error err, const QString &errStr);
void abort();
QFtp::Error error();

View File

@ -50,6 +50,11 @@ AesInterface::~AesInterface()
EVP_CIPHER_CTX_cleanup(&m_decodeCTX);
}
bool AesInterface::isOk()
{
return m_ok;
}
// Create an 256 bit 'key' using the supplied password, and creates a random 'iv'.
// saltArray is an array of 8 bytes can be added for taste.
// Fills in the encryption and decryption ctx objects and returns true on success

View File

@ -38,7 +38,7 @@ public:
explicit AesInterface(QObject* parent = 0);
~AesInterface();
inline bool isOk() { return m_ok; }
bool isOk();
QByteArray encrypt(const QByteArray &plainData, const QByteArray &password);
QByteArray decrypt(const QByteArray &cipherData, const QByteArray &password);

View File

@ -713,6 +713,11 @@ QSize CloseButton::sizeHint() const
return QSize(width, height);
}
QSize CloseButton::minimumSizeHint() const
{
return sizeHint();
}
void CloseButton::enterEvent(QEvent* event)
{
if (isEnabled()) {

View File

@ -137,7 +137,7 @@ public:
CloseButton(QWidget* parent = 0);
QSize sizeHint() const;
inline QSize minimumSizeHint() const { return sizeHint(); }
QSize minimumSizeHint() const;
void enterEvent(QEvent* event);
void leaveEvent(QEvent* event);