Skip to content

Commit

Permalink
Run "make format"
Browse files Browse the repository at this point in the history
No semantic changes, just source code formatting.
  • Loading branch information
wolframroesler committed Sep 29, 2019
1 parent 4125894 commit 47e2045
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 24 deletions.
5 changes: 1 addition & 4 deletions src/browser/BrowserAction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -541,10 +541,7 @@ QString BrowserAction::getDatabaseHash()
{
QMutexLocker locker(&m_mutex);
QByteArray hash =
QCryptographicHash::hash(
m_browserService.getDatabaseRootUuid().toUtf8(),
QCryptographicHash::Sha256)
.toHex();
QCryptographicHash::hash(m_browserService.getDatabaseRootUuid().toUtf8(), QCryptographicHash::Sha256).toHex();
return QString(hash);
}

Expand Down
1 change: 0 additions & 1 deletion src/cli/Add.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ const QCommandLineOption Add::GenerateOption = QCommandLineOption(QStringList()
<< "generate",
QObject::tr("Generate a password for the entry."));


Add::Add()
{
name = QString("add");
Expand Down
1 change: 0 additions & 1 deletion src/cli/Export.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ Export::Export()
description = QObject::tr("Exports the content of a database to standard output in the specified format.");
}


int Export::executeWithDatabase(QSharedPointer<Database> database, QSharedPointer<QCommandLineParser> parser)
{
TextStream outputTextStream(Utils::STDOUT, QIODevice::WriteOnly);
Expand Down
2 changes: 1 addition & 1 deletion src/core/Bootstrap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ namespace Bootstrap
nullptr, // do not change owner or group
pACL, // DACL specified
nullptr // do not change SACL
);
);

Cleanup:

Expand Down
12 changes: 6 additions & 6 deletions src/gui/dbsettings/DatabaseSettingsWidgetBrowser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -242,12 +242,12 @@ void DatabaseSettingsWidgetBrowser::convertAttributesToCustomData()
{
if (MessageBox::Yes
!= MessageBox::question(
this,
tr("Move KeePassHTTP attributes to custom data"),
tr("Do you really want to move all legacy browser integration data to the latest standard?\n"
"This is necessary to maintain compatibility with the browser plugin."),
MessageBox::Yes | MessageBox::Cancel,
MessageBox::Cancel)) {
this,
tr("Move KeePassHTTP attributes to custom data"),
tr("Do you really want to move all legacy browser integration data to the latest standard?\n"
"This is necessary to maintain compatibility with the browser plugin."),
MessageBox::Yes | MessageBox::Cancel,
MessageBox::Cancel)) {
return;
}

Expand Down
5 changes: 1 addition & 4 deletions src/keys/YkChallengeResponseKeyCLI.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,7 @@ class YkChallengeResponseKeyCLI : public QObject, public ChallengeResponseKey
public:
static QUuid UUID;

explicit YkChallengeResponseKeyCLI(int slot,
bool blocking,
QString messageInteraction,
FILE* outputDescriptor);
explicit YkChallengeResponseKeyCLI(int slot, bool blocking, QString messageInteraction, FILE* outputDescriptor);

QByteArray rawKey() const override;
bool challenge(const QByteArray& challenge) override;
Expand Down
2 changes: 0 additions & 2 deletions tests/TestMerge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1214,7 +1214,6 @@ void TestMerge::testCustomData()
QCOMPARE(dbDestination->metadata()->customData()->value("key3"),
QString("newValue")); // Old value should be replaced


// Merging again should not do anything if the values are the same.
m_clock->advanceSecond(1);
dbSource->metadata()->customData()->set("key3", "oldValue");
Expand All @@ -1223,7 +1222,6 @@ void TestMerge::testCustomData()
QStringList changes2 = merger2.merge();
QVERIFY(changes2.isEmpty());


Merger merger3(dbSource2.data(), dbDestination2.data());
merger3.merge();

Expand Down
10 changes: 5 additions & 5 deletions tests/gui/TestGuiBrowser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
#include <QDialogButtonBox>
#include <QLineEdit>
#include <QPushButton>
#include <QToolBar>
#include <QTableView>
#include <QToolBar>

#include "config-keepassx-tests.h"
#include "core/Bootstrap.h"
Expand Down Expand Up @@ -144,7 +144,7 @@ void TestGuiBrowser::testEntrySettings()
QTest::mouseClick(entryEditWidget, Qt::LeftButton);
QCOMPARE(m_dbWidget->currentMode(), DatabaseWidget::Mode::EditMode);
auto* editEntryWidget = m_dbWidget->findChild<EditEntryWidget*>("editEntryWidget");

// Switch to Properties page and select all rows from the custom data table
editEntryWidget->setCurrentPage(4);
auto customDataTableView = editEntryWidget->findChild<QTableView*>("customDataTable");
Expand Down Expand Up @@ -181,9 +181,9 @@ void TestGuiBrowser::triggerAction(const QString& name)
}

void TestGuiBrowser::clickIndex(const QModelIndex& index,
QAbstractItemView* view,
Qt::MouseButton button,
Qt::KeyboardModifiers stateKey)
QAbstractItemView* view,
Qt::MouseButton button,
Qt::KeyboardModifiers stateKey)
{
QTest::mouseClick(view->viewport(), button, stateKey, view->visualRect(index).center());
}

0 comments on commit 47e2045

Please sign in to comment.