Changeset View
Changeset View
Standalone View
Standalone View
kded/daemon.h
Show First 20 Lines • Show All 56 Lines • ▼ Show 20 Line(s) | 47 | public Q_SLOTS: | |||
---|---|---|---|---|---|
57 | void displayButton(); | 57 | void displayButton(); | ||
58 | void lidClosedChanged(bool lidIsClosed); | 58 | void lidClosedChanged(bool lidIsClosed); | ||
59 | void lidClosedTimeout(); | 59 | void lidClosedTimeout(); | ||
60 | void setMonitorForChanges(bool enabled); | 60 | void setMonitorForChanges(bool enabled); | ||
61 | void outputConnectedChanged(); | 61 | void outputConnectedChanged(); | ||
62 | void showOutputIdentifier(); | 62 | void showOutputIdentifier(); | ||
63 | void applyOsdAction(KScreen::OsdAction::Action action); | 63 | void applyOsdAction(KScreen::OsdAction::Action action); | ||
64 | 64 | | |||
65 | // DBus | ||||
66 | void applyLayoutPreset(const QString &presetName); | ||||
gladhorn: Could this be unified in some nice way with the above function (applyOsdAction) which does the… | |||||
This thing is called by DBus, so I can only send a string over (or a random int, if you prefer that). I use QMetaEnum to map the string to an enum value to avoid having a duplicated list of strings. I don't think this can be optimized further. broulik: This thing is called by DBus, so I can only send a string over (or a random int, if you prefer… | |||||
65 | Q_SIGNALS: | 67 | Q_SIGNALS: | ||
68 | // DBus | ||||
66 | void outputConnected(const QString &outputName); | 69 | void outputConnected(const QString &outputName); | ||
67 | void unknownOutputConnected(const QString &outputName); | 70 | void unknownOutputConnected(const QString &outputName); | ||
68 | 71 | | |||
69 | protected: | 72 | protected: | ||
70 | virtual void doApplyConfig(const KScreen::ConfigPtr &config); | 73 | virtual void doApplyConfig(const KScreen::ConfigPtr &config); | ||
71 | 74 | | |||
72 | void monitorConnectedChange(); | 75 | void monitorConnectedChange(); | ||
73 | void disableOutput(KScreen::ConfigPtr &config, KScreen::OutputPtr &output); | 76 | void disableOutput(KScreen::ConfigPtr &config, KScreen::OutputPtr &output); | ||
Show All 11 Lines |
Could this be unified in some nice way with the above function (applyOsdAction) which does the same based on the enum...? Maybe just use the enum, or is there a reason for using a string here but not in other places?