Changeset View
Changeset View
Standalone View
Standalone View
src/core/slavebase.h
Show First 20 Lines • Show All 251 Lines • ▼ Show 20 Line(s) | 63 | public: | |||
---|---|---|---|---|---|
252 | 252 | | |||
253 | /** | 253 | /** | ||
254 | * Call to signal a message, to be displayed if the application wants to, | 254 | * Call to signal a message, to be displayed if the application wants to, | ||
255 | * for instance in a status bar. Usual examples are "connecting to host xyz", etc. | 255 | * for instance in a status bar. Usual examples are "connecting to host xyz", etc. | ||
256 | */ | 256 | */ | ||
257 | void infoMessage(const QString &msg); | 257 | void infoMessage(const QString &msg); | ||
258 | 258 | | |||
259 | /** | 259 | /** | ||
260 | * Type of message box. Should be kept in sync with KMessageBox::ButtonCode. | 260 | * Type of message box. Should be kept in sync with KMessageBox::DialogType. | ||
261 | */ | 261 | */ | ||
262 | enum MessageBoxType { QuestionYesNo = 1, WarningYesNo = 2, WarningContinueCancel = 3, WarningYesNoCancel = 4, Information = 5, SSLMessageBox = 6 }; | 262 | //In KMessageBox::DialogType; Sorry = 7, Error = 8, QuestionYesNoCancel = 9 | ||
dfaure: Does this break API docs generation? Suddenly the /** ... */ comment is separated from the enum. | |||||
The comment didn't affect the doc generation. But the placement was awkward so I changed it. chinmoyr: The comment didn't affect the doc generation. But the placement was awkward so I changed it. | |||||
263 | enum MessageBoxType { QuestionYesNo = 1, WarningYesNo = 2, WarningContinueCancel = 3, WarningYesNoCancel = 4, Information = 5, SSLMessageBox = 6, WarningContinueCancelDetailed = 10, }; | ||||
263 | 264 | | |||
264 | /** | 265 | /** | ||
265 | * Button codes. Should be kept in sync with KMessageBox::ButtonCode | 266 | * Button codes. Should be kept in sync with KMessageBox::ButtonCode | ||
266 | */ | 267 | */ | ||
267 | enum ButtonCode { | 268 | enum ButtonCode { | ||
268 | Ok = 1, | 269 | Ok = 1, | ||
269 | Cancel = 2, | 270 | Cancel = 2, | ||
270 | Yes = 3, | 271 | Yes = 3, | ||
▲ Show 20 Lines • Show All 724 Lines • ▼ Show 20 Line(s) | 995 | /** Internally used | |||
995 | * @internal | 996 | * @internal | ||
996 | */ | 997 | */ | ||
997 | int waitForHostInfo(QHostInfo &info); | 998 | int waitForHostInfo(QHostInfo &info); | ||
998 | 999 | | |||
999 | /** | 1000 | /** | ||
1000 | * Checks with job if privilege operation is allowed. | 1001 | * Checks with job if privilege operation is allowed. | ||
1001 | * @return privilege operation status. | 1002 | * @return privilege operation status. | ||
1002 | * @see PrivilegeOperationStatus | 1003 | * @see PrivilegeOperationStatus | ||
1003 | * @since 5.43 | 1004 | * @since 5.65 | ||
I was too slow, it's 5.66 now. Please change it everywhere. Well by waiting we didn't break the message freeze with all these new i18n calls. dfaure: I was too slow, it's 5.66 now. Please change it everywhere.
Well by waiting we didn't break… | |||||
1004 | */ | 1005 | */ | ||
1005 | PrivilegeOperationStatus requestPrivilegeOperation(); | 1006 | PrivilegeOperationStatus requestPrivilegeOperation(const QString &operationDetails); | ||
1006 | 1007 | | |||
1007 | /** | 1008 | /** | ||
1008 | * Adds @p action to the list of PolicyKit actions which the | 1009 | * Adds @p action to the list of PolicyKit actions which the | ||
1009 | * slave is authorized to perform. | 1010 | * slave is authorized to perform. | ||
1010 | * | 1011 | * | ||
1011 | * @param action the PolicyKit action | 1012 | * @param action the PolicyKit action | ||
1012 | * @since 5.45 | 1013 | * @since 5.45 | ||
1013 | */ | 1014 | */ | ||
1014 | void addTemporaryAuthorization(const QString &action); | 1015 | void addTemporaryAuthorization(const QString &action); | ||
1015 | 1016 | | |||
1017 | /** | ||||
1018 | * @deprecated since 5.65, use requestPrivilegeOperation(QString) | ||||
dfaure: `, use requestPrivilegeOperation(QString)` | |||||
1019 | */ | ||||
1020 | | ||||
1021 | #if KIOCORE_ENABLE_DEPRECATED_SINCE(5, 65) | ||||
dfaure: The modern way is `#if KIOCORE_ENABLE_DEPRECATED_SINCE(5, 65)` | |||||
1022 | KIOCORE_DEPRECATED_VERSION(5, 65, "Pass QString action to requestPrivilegeOperation") PrivilegeOperationStatus requestPrivilegeOperation(); | ||||
KIOCORE_DEPRECATED_VERSION(5, 65, "Pass QString action to requestPrivilegeOperation") dfaure: `KIOCORE_DEPRECATED_VERSION(5, 65, "Pass QString action to requestPrivilegeOperation")` | |||||
1023 | #endif | ||||
1024 | | ||||
1016 | protected: | 1025 | protected: | ||
1017 | /** | 1026 | /** | ||
1018 | * Name of the protocol supported by this slave | 1027 | * Name of the protocol supported by this slave | ||
1019 | */ | 1028 | */ | ||
1020 | QByteArray mProtocol; | 1029 | QByteArray mProtocol; | ||
1021 | //Often used by TcpSlaveBase and unlikely to change | 1030 | //Often used by TcpSlaveBase and unlikely to change | ||
1022 | MetaData mOutgoingMetaData; | 1031 | MetaData mOutgoingMetaData; | ||
1023 | MetaData mIncomingMetaData; | 1032 | MetaData mIncomingMetaData; | ||
1024 | 1033 | | |||
1025 | enum VirtualFunctionId { | 1034 | enum VirtualFunctionId { | ||
Missing "m" prefix like the other members, but wait.... isn't this BIC? Adding a new member to an exported class certainly is. This needs to go into the SlaveBasePrivate class instead. dfaure: Missing "m" prefix like the other members, but wait.... isn't this BIC? Adding a new member to… | |||||
Since we need details from the ioslave somehow, I deprecated requestPrivilegeOperation() in favor of an overload that accepts details as argument. chinmoyr: Since we need details from the ioslave somehow, I deprecated requestPrivilegeOperation() in… | |||||
1026 | AppConnectionMade = 0, | 1035 | AppConnectionMade = 0, | ||
1027 | GetFileSystemFreeSpace = 1 // KF6 TODO: Turn into a virtual method | 1036 | GetFileSystemFreeSpace = 1 // KF6 TODO: Turn into a virtual method | ||
1028 | }; | 1037 | }; | ||
1029 | virtual void virtual_hook(int id, void *data); | 1038 | virtual void virtual_hook(int id, void *data); | ||
1030 | 1039 | | |||
1031 | private: | 1040 | private: | ||
1032 | // Convenience function converting mProtocol to QString as unsupportedActionErrorString(), which | 1041 | // Convenience function converting mProtocol to QString as unsupportedActionErrorString(), which | ||
1033 | // is used in many places in the code, takes a QString parameter | 1042 | // is used in many places in the code, takes a QString parameter | ||
Show All 22 Lines |
Does this break API docs generation? Suddenly the /** ... */ comment is separated from the enum.