mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
refactor(files): clang-format generated whitespace changes
This commit is contained in:
parent
f7df1191bc
commit
939f2c865a
|
@ -43,8 +43,11 @@ namespace Db {
|
|||
enum class syncType;
|
||||
}
|
||||
|
||||
class Settings : public QObject, public ICoreSettings, public IFriendSettings,
|
||||
public IAudioSettings, public IVideoSettings
|
||||
class Settings : public QObject,
|
||||
public ICoreSettings,
|
||||
public IFriendSettings,
|
||||
public IAudioSettings,
|
||||
public IVideoSettings
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
@ -91,8 +94,8 @@ class Settings : public QObject, public ICoreSettings, public IFriendSettings,
|
|||
Q_PROPERTY(QString dateFormat READ getDateFormat WRITE setDateFormat NOTIFY dateFormatChanged FINAL)
|
||||
Q_PROPERTY(bool statusChangeNotificationEnabled READ getStatusChangeNotificationEnabled WRITE
|
||||
setStatusChangeNotificationEnabled NOTIFY statusChangeNotificationEnabledChanged FINAL)
|
||||
Q_PROPERTY(bool spellCheckingEnabled READ getSpellCheckingEnabled WRITE
|
||||
setSpellCheckingEnabled NOTIFY spellCheckingEnabledChanged FINAL)
|
||||
Q_PROPERTY(bool spellCheckingEnabled READ getSpellCheckingEnabled WRITE setSpellCheckingEnabled
|
||||
NOTIFY spellCheckingEnabledChanged FINAL)
|
||||
|
||||
// Privacy
|
||||
Q_PROPERTY(bool typingNotification READ getTypingNotification WRITE setTypingNotification NOTIFY
|
||||
|
@ -105,8 +108,8 @@ class Settings : public QObject, public ICoreSettings, public IFriendSettings,
|
|||
audioInDevEnabledChanged FINAL)
|
||||
Q_PROPERTY(qreal audioInGainDecibel READ getAudioInGainDecibel WRITE setAudioInGainDecibel
|
||||
NOTIFY audioInGainDecibelChanged FINAL)
|
||||
Q_PROPERTY(qreal audioThreshold READ getAudioThreshold WRITE setAudioThreshold
|
||||
NOTIFY audioThresholdChanged FINAL)
|
||||
Q_PROPERTY(qreal audioThreshold READ getAudioThreshold WRITE setAudioThreshold NOTIFY
|
||||
audioThresholdChanged FINAL)
|
||||
Q_PROPERTY(QString outDev READ getOutDev WRITE setOutDev NOTIFY outDevChanged FINAL)
|
||||
Q_PROPERTY(bool audioOutDevEnabled READ getAudioOutDevEnabled WRITE setAudioOutDevEnabled NOTIFY
|
||||
audioOutDevEnabledChanged FINAL)
|
||||
|
@ -352,8 +355,14 @@ public:
|
|||
void setAudioThreshold(qreal percent) override;
|
||||
|
||||
int getOutVolume() const override;
|
||||
int getOutVolumeMin() const override { return 0; }
|
||||
int getOutVolumeMax() const override { return 100; }
|
||||
int getOutVolumeMin() const override
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
int getOutVolumeMax() const override
|
||||
{
|
||||
return 100;
|
||||
}
|
||||
void setOutVolume(int volume) override;
|
||||
|
||||
int getAudioBitrate() const override;
|
||||
|
@ -491,8 +500,8 @@ public:
|
|||
void saveFriendSettings(const ToxPk& id) override;
|
||||
void removeFriendSettings(const ToxPk& id) override;
|
||||
|
||||
SIGNAL_IMPL(Settings, autoAcceptCallChanged,
|
||||
const ToxPk& id, IFriendSettings::AutoAcceptCallFlags accept)
|
||||
SIGNAL_IMPL(Settings, autoAcceptCallChanged, const ToxPk& id,
|
||||
IFriendSettings::AutoAcceptCallFlags accept)
|
||||
SIGNAL_IMPL(Settings, autoGroupInviteChanged, const ToxPk& id, bool accept)
|
||||
SIGNAL_IMPL(Settings, autoAcceptDirChanged, const ToxPk& id, const QString& dir)
|
||||
SIGNAL_IMPL(Settings, contactNoteChanged, const ToxPk& id, const QString& note)
|
||||
|
|
|
@ -266,8 +266,8 @@ void ChatForm::onTextEditChanged()
|
|||
|
||||
void ChatForm::onAttachClicked()
|
||||
{
|
||||
QStringList paths =
|
||||
QFileDialog::getOpenFileNames(Q_NULLPTR, tr("Send a file"), QDir::homePath(), nullptr, nullptr);
|
||||
QStringList paths = QFileDialog::getOpenFileNames(Q_NULLPTR, tr("Send a file"),
|
||||
QDir::homePath(), nullptr, nullptr);
|
||||
|
||||
if (paths.isEmpty()) {
|
||||
return;
|
||||
|
@ -512,8 +512,8 @@ void ChatForm::searchInBegin(const QString& phrase, const ParameterSearch& param
|
|||
if (isFirst || isAfter) {
|
||||
if (isFirst || (isAfter && parameter.date < getFirstDate())) {
|
||||
const QString pk = f->getPublicKey().toString();
|
||||
if ((isFirst || parameter.date >= history->getStartDateChatHistory(pk).date()) &&
|
||||
loadHistory(phrase, parameter)) {
|
||||
if ((isFirst || parameter.date >= history->getStartDateChatHistory(pk).date())
|
||||
&& loadHistory(phrase, parameter)) {
|
||||
|
||||
return;
|
||||
}
|
||||
|
@ -523,7 +523,8 @@ void ChatForm::searchInBegin(const QString& phrase, const ParameterSearch& param
|
|||
} else {
|
||||
if (parameter.period == PeriodSearch::BeforeDate && parameter.date < getFirstDate()) {
|
||||
const QString pk = f->getPublicKey().toString();
|
||||
if (parameter.date >= history->getStartDateChatHistory(pk).date() && loadHistory(phrase, parameter)) {
|
||||
if (parameter.date >= history->getStartDateChatHistory(pk).date()
|
||||
&& loadHistory(phrase, parameter)) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -558,7 +559,8 @@ void ChatForm::onSearchUp(const QString& phrase, const ParameterSearch& paramete
|
|||
|
||||
if (!isSearch) {
|
||||
const QString pk = f->getPublicKey().toString();
|
||||
const QDateTime newBaseDate = history->getDateWhereFindPhrase(pk, earliestMessage, phrase, parameter);
|
||||
const QDateTime newBaseDate =
|
||||
history->getDateWhereFindPhrase(pk, earliestMessage, phrase, parameter);
|
||||
|
||||
if (!newBaseDate.isValid()) {
|
||||
emit messageNotFoundShow(SearchDirection::Up);
|
||||
|
@ -1086,7 +1088,8 @@ void ChatForm::SendMessageStr(QString msg)
|
|||
bool ChatForm::loadHistory(const QString& phrase, const ParameterSearch& parameter)
|
||||
{
|
||||
const QString pk = f->getPublicKey().toString();
|
||||
const QDateTime newBaseDate = history->getDateWhereFindPhrase(pk, earliestMessage, phrase, parameter);
|
||||
const QDateTime newBaseDate =
|
||||
history->getDateWhereFindPhrase(pk, earliestMessage, phrase, parameter);
|
||||
|
||||
if (newBaseDate.isValid() && getFirstDate().isValid() && newBaseDate.date() < getFirstDate()) {
|
||||
searchAfterLoadHistory = true;
|
||||
|
@ -1136,7 +1139,8 @@ void ChatForm::onExportChat()
|
|||
ToxPk authorPk(ToxId(it.sender).getPublicKey());
|
||||
QString author = getMsgAuthorDispName(authorPk, it.dispName);
|
||||
|
||||
buffer = buffer % QString{datestamp % '\t' % timestamp % '\t' % author % '\t' % it.message % '\n'};
|
||||
buffer = buffer
|
||||
% QString{datestamp % '\t' % timestamp % '\t' % author % '\t' % it.message % '\n'};
|
||||
}
|
||||
file.write(buffer.toUtf8());
|
||||
file.close();
|
||||
|
|
|
@ -151,8 +151,7 @@ GeneralForm::GeneralForm(SettingsWidget* myParent)
|
|||
bodyUI->autoacceptFiles->setChecked(s.getAutoSaveEnabled());
|
||||
|
||||
#ifndef QTOX_PLATFORM_EXT
|
||||
bodyUI->autoAwayLabel->setEnabled(
|
||||
false); // these don't seem to change the appearance of the widgets,
|
||||
bodyUI->autoAwayLabel->setEnabled(false); // these don't seem to change the appearance of the widgets,
|
||||
bodyUI->autoAwaySpinBox->setEnabled(false); // though they are unusable
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user