Expand enums to multiple lines

Most of our enum declaratons are on multiple lines, but not all of them.

Expand the remaining ones to be consistent
wilder-5.22
Nicolas Fella 5 years ago
parent 8b1ba47dec
commit 7f5d8768c1
  1. 6
      applets/kicker/plugin/abstractentry.h
  2. 5
      applets/kicker/plugin/recentusagemodel.h
  3. 13
      dataengines/filebrowser/filebrowserengine.h
  4. 6
      dataengines/geolocation/geolocationprovider.h
  5. 5
      dataengines/soliddevice/hddtemp.h
  6. 65
      dataengines/weather/ions/ion.h
  7. 5
      kcms/cursortheme/xcursor/thememodel.h
  8. 5
      kioslave/applications/kio_applications.cpp
  9. 5
      klipper/klipper.h
  10. 6
      ksmserver/server.h
  11. 10
      libkworkspace/kdisplaymanager.cpp
  12. 6
      runners/kill/config_keys.h
  13. 7
      runners/sessions/sessionrunner.h

@ -32,7 +32,11 @@ class AbstractEntry
explicit AbstractEntry(AbstractModel *owner);
virtual ~AbstractEntry();
enum EntryType { RunnableType, GroupType, SeparatorType };
enum EntryType {
RunnableType,
GroupType,
SeparatorType,
};
virtual EntryType type() const = 0;

@ -76,7 +76,10 @@ class RecentUsageModel : public ForwardingModel, public QQmlParserStatus
};
Q_ENUM(IncludeUsage)
enum Ordering { Recent, Popular };
enum Ordering {
Recent,
Popular,
};
explicit RecentUsageModel(
QObject *parent = nullptr,

@ -45,8 +45,17 @@ protected Q_SLOTS:
void dirDeleted(const QString &path);
private:
enum EventType {INIT, DIRTY, CREATED, DELETED};
enum ObjectType {NOTHING, FILE, DIRECTORY};
enum EventType {
INIT,
DIRTY,
CREATED,
DELETED,
};
enum ObjectType {
NOTHING,
FILE,
DIRECTORY,
};
KDirWatch * m_dirWatch;
void updateData(const QString &path, EventType event);

@ -33,7 +33,11 @@ class GEOLOCATION_EXPORT GeolocationProvider : public QObject
Q_OBJECT
public:
enum UpdateTrigger { ForcedUpdate = 0, SourceEvent = 1, NetworkConnected = 2 };
enum UpdateTrigger {
ForcedUpdate = 0,
SourceEvent = 1,
NetworkConnected = 2,
};
Q_DECLARE_FLAGS(UpdateTriggers, UpdateTrigger)
explicit GeolocationProvider(QObject *parent = nullptr, const QVariantList &args = QVariantList());

@ -33,7 +33,10 @@ class HddTemp : public QObject
Q_OBJECT
public:
enum DataType {Temperature=0, Unit};
enum DataType {
Temperature=0,
Unit,
};
explicit HddTemp(QObject *parent = nullptr);
~HddTemp() override;

@ -119,15 +119,62 @@ class ION_EXPORT IonInterface : public Plasma::DataEngine
public:
enum ConditionIcons { ClearDay = 1, ClearWindyDay, FewCloudsDay, FewCloudsWindyDay, PartlyCloudyDay, PartlyCloudyWindyDay, Overcast, OvercastWindy,
Rain, LightRain, Showers, ChanceShowersDay, Thunderstorm, Hail,
Snow, LightSnow, Flurries, FewCloudsNight, FewCloudsWindyNight, ChanceShowersNight,
PartlyCloudyNight, PartlyCloudyWindyNight, ClearNight, ClearWindyNight, Mist, Haze, FreezingRain,
RainSnow, FreezingDrizzle, ChanceThunderstormDay, ChanceThunderstormNight,
ChanceSnowDay, ChanceSnowNight, NotAvailable
};
enum WindDirections { N, NNE, NE, ENE, E, SSE, SE, ESE, S, NNW, NW, WNW, W, SSW, SW, WSW, VR };
enum ConditionIcons {
ClearDay = 1,
ClearWindyDay,
FewCloudsDay,
FewCloudsWindyDay,
PartlyCloudyDay,
PartlyCloudyWindyDay,
Overcast,
OvercastWindy,
Rain,
LightRain,
Showers,
ChanceShowersDay,
Thunderstorm,
Hail,
Snow,
LightSnow,
Flurries,
FewCloudsNight,
FewCloudsWindyNight,
ChanceShowersNight,
PartlyCloudyNight,
PartlyCloudyWindyNight,
ClearNight,
ClearWindyNight,
Mist,
Haze,
FreezingRain,
RainSnow,
FreezingDrizzle,
ChanceThunderstormDay,
ChanceThunderstormNight,
ChanceSnowDay,
ChanceSnowNight,
NotAvailable,
};
enum WindDirections {
N,
NNE,
NE,
ENE,
E,
SSE,
SE,
ESE,
S,
NNW,
NW,
WNW,
W,
SSW,
SW,
WSW,
VR,
};
/**
* Constructor for the ion

@ -27,7 +27,10 @@ class QDir;
class CursorTheme;
// The two TableView/TreeView columns provided by the model
enum Columns { NameColumn = 0, DescColumn };
enum Columns {
NameColumn = 0,
DescColumn,
};
/**

@ -30,7 +30,10 @@
class ApplicationsProtocol : public KIO::SlaveBase
{
public:
enum RunMode { ProgramsMode, ApplicationsMode };
enum RunMode {
ProgramsMode,
ApplicationsMode,
};
ApplicationsProtocol(const QByteArray &protocol, const QByteArray &pool, const QByteArray &app);
~ApplicationsProtocol() override;
void get( const QUrl& url ) override;

@ -98,7 +98,10 @@ protected:
* Don't use 1, as I use that as a guard against passing
* a boolean true as a mode.
*/
enum SelectionMode { Clipboard = 2, Selection = 4 };
enum SelectionMode {
Clipboard = 2,
Selection = 4,
};
enum class ClipboardUpdateReason {
UpdateClipboard,
PreventEmptyClipboard

@ -64,7 +64,11 @@ class KSMClient;
class OrgKdeKWinSessionInterface;
enum SMType { SM_ERROR, SM_WMCOMMAND, SM_WMSAVEYOURSELF };
enum SMType {
SM_ERROR,
SM_WMCOMMAND,
SM_WMSAVEYOURSELF,
};
struct SMData
{
SMType type;

@ -278,7 +278,15 @@ public:
QDBusConnection::systemBus()) {}
};
static enum { Dunno, NoDM, NewKDM, OldKDM, NewGDM, OldGDM, LightDM } DMType = Dunno;
static enum {
Dunno,
NoDM,
NewKDM,
OldKDM,
NewGDM,
OldGDM,
LightDM,
} DMType = Dunno;
static const char *ctl, *dpy;
class KDisplayManager::Private

@ -27,6 +27,10 @@ static const char CONFIG_TRIGGERWORD[] = "triggerWord";
static const char CONFIG_SORTING[] = "sorting";
/** Possibilities to sort */
enum Sort {NONE = 0, CPU, CPUI};
enum Sort {
NONE = 0,
CPU,
CPUI,
};
#endif

@ -39,7 +39,12 @@ class SessionRunner : public Plasma::AbstractRunner
void match(Plasma::RunnerContext &context) override;
void run(const Plasma::RunnerContext &context, const Plasma::QueryMatch &action) override;
enum { LogoutAction = 1, ShutdownAction, RestartAction, LockAction };
enum {
LogoutAction = 1,
ShutdownAction,
RestartAction,
LockAction,
};
private:
void matchCommands(QList<Plasma::QueryMatch> &matches, const QString& term);

Loading…
Cancel
Save