aboutsummaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2018-06-11Connection: InFore/Background -> Fore/BackgroundRequestKitsune Ral
2018-06-09converters.h: drop unneeded template<> lineKitsune Ral
2018-06-09csapi: Now really fix passing query parametersKitsune Ral
Also: GetContentThumbnailJob (again) requires width and height.
2018-06-08csapi: Fix boolean query parameters incorrectly passedKitsune Ral
2018-06-08SyncJob: Support receiving to_device and presence eventsKitsune Ral
2018-06-08csapi: add jobs for keys managementKitsune Ral
This concludes the Great Income of Jobs to libQMatrixClient - all CS API calls are now covered with job classes, yay!
2018-06-08csapi: add jobs for device managementKitsune Ral
Same as for account management jobs, auth objects are modeled as generic QJsonObjects for now.
2018-06-08csapi: Added registration and account management jobsKitsune Ral
Regrettably had to cut corners and use QJsonObject for auth_data.yaml because GTAD 0.6 doesn't properly deal with a combination of properties and additionalProperties in the API description.
2018-06-08csapi: add jobs from rooms.yamlKitsune Ral
Getting a single event (/events), getting the full room state as well as with a specific type/key (/state), getting the list of room members (/members and /joined_members).
2018-06-08gtad.yaml: Update to the released GTAD 0.6Kitsune Ral
variant types now use comma (,) as a delimiter instead of | (because regexes). Also: moved around the `schema` section to be closer to `$ref`.
2018-06-08csapi: added sync filter definitions and jobsKitsune Ral
2018-06-04Make libQMatrixClient buildable outside of QuaternionKitsune Ral
2018-06-04converters.*: FixesKitsune Ral
Qualify functions properly; add converters.* to libqmatrixclient.pri
2018-06-03csapi: jobs to setup push-rulesKitsune Ral
2018-06-03csapi: PeekEventsJob, ReportContentJob, presence jobsKitsune Ral
2018-06-03csapi: No need to explicitly #include <QtCore/QStringList>Kitsune Ral
2018-06-03csapi: GetTurnServerJobKitsune Ral
2018-06-03csapi/content-repo.*: jobs return results in data() instead of content() nowKitsune Ral
Because GTAD has been updated to use a different default name for returned properties.
2018-06-03csapi/notifications.*: Use QVariant instead of QJsonObjectKitsune Ral
Thanks to the latest GTAD. QJsonObject wasn't quite correct there.
2018-06-03csapi + converters: Support variant types (using QVariant)Kitsune Ral
This mandated some rearrangement of toJson() overloads and FromJson<> specializations for QVariant* types - instead of variant_converters.h they are now in converters.cpp.
2018-06-03csapi: Updated to the most recent API definitionsKitsune Ral
2018-06-03gtad.yaml: Fixes around defaultValueKitsune Ral
1. defaultValue now preempts Omittable<> 2. Fixed the problem when defaultValue was provided but initializer was empty (a case for int's, bool's etc.)
2018-06-03gtad.yaml: Fallback to QJsonArray no more neededKitsune Ral
...with the latest GTAD
2018-06-03gtad.yaml: Make sure to pass avoidCopy to ref'ed typesKitsune Ral
2018-06-02BaseJob: fix error handling for M_CONSENT_NOT_GIVENKitsune Ral
2018-06-02Connection::loadedRoomState() signalKitsune Ral
Closes #211.
2018-06-02Room::dropDuplicateEvents(): use a reference instead of a pointerKitsune Ral
There's no case for a nullptr in that function, and I'm fine to use non-const ref parameters.
2018-06-02csapi: Fix adding omittables to a query stringKitsune Ral
2018-06-02GTAD: drop question marks and "true" from attributesKitsune Ral
They lead to an (incorrect) assumption that those attributes are actual binary flags rather than just flags (there's no such thing as avoidCopy=false, avoidCopy should be absent instead).
2018-06-02Typo fixKitsune Ral
2018-06-02csapi: Use Omittable<> container instead of intrusive 'omitted' fieldKitsune Ral
Also: use the latest feature of GTAD, +set/+on, to make gtad.yaml more compact.
2018-06-02addToJson(): Omit unneeded defaulting of ValT to voidKitsune Ral
2018-05-30BaseJob::setStatus: Don't try to remove access token if it's emptyKitsune Ral
Closes #210.
2018-05-29BaseJob: Treat M_CONSENT_NOT_GIVEN separately from other content access errorsKitsune Ral
Closes #207.
2018-05-29BaseJob: "background" switch; more extensive error reportingKitsune Ral
Running a request in background, aside from some tweaks on the network layer (see QNetworkRequest::BackgroundRequestAttribute), allows to distinguish jobs not immediately caused by user interaction (such as fetching thumbnails). This can be used to show or not show certain notifications in UI of clients. Error reporting has been extended with more methods: errorCaption() - a human-readable phrase calculated from the status code; intended to be shown as a dialog caption and in similar situations. errorRawData() - former errorDetails(), returns the raw response from the server. errorUrl() - returns a URL that may be useful with the error (e.g. for the upcoming "consent not given" error, this will have the policy URL). Connection::resultFailed() - a new signal emitted when _any_ BaseJob::failure() is emitted (enables centralised error handling across all network requests in clients). As a part of matching changes in Connection, callApi has an overload that allows to specify the policy; a custom enum instead of bool has been chosen for the parameter type, to avoid clashes with (arbitrary) types of job parameters.
2018-05-28Move out prettyPrint() from Room to util.hKitsune Ral
So that it could be used outside of room context.
2018-05-28BaseJob: support status trackingKitsune Ral
The newly introduced statusChanged() signal allows clients to be notified about the job state transitions.
2018-05-28BaseJob: refresh rotten comments about kill()Kitsune Ral
There is no more BaseJob::kill() for a very long time; we have abandon() instead, with a bit different meaning. Which, by the way, now emits finished() because that's what finished() has been for.
2018-05-26lib/csapi/: regenerate job classes from the most recent templatesKitsune Ral
The second part to close #208.
2018-05-26lib/csapi/: Don't send parameters that were omittedKitsune Ral
This is important because payloads that include omitted parameters may be malformed. Closes #208 (an example of such malformed payload).
2018-05-24Room: Make isFavourite/LowPriority/DirectChat accessible from QMLKitsune Ral
The first two as Q_PROPERTYs, the last one as Q_INVOKABLE.
2018-05-23BaseJob: more careful error handling; unify and extend error signals in ↵Kitsune Ral
Connection (Note: this commit breaks back-compatibility.) BaseJob::gotReply() had a bold assumption that whenever there's no reasonable JSON body in case of error, that meant IncorrectRequestError (which of course was incorrect). This led to syncs dying in Quaternion because it (correctly) considered IncorrectRequestError to be grave enough to not retry. Closes #206. Also: don't dump the whole payload to logs, limit with initial 500 characters (closes #205)
2018-05-06Remove unused job classes.Kitsune Ral
2018-05-06converters.h: Fix CIKitsune Ral
2018-05-06Optimise #includes, eliminate some excess blank lines in lib/csapiKitsune Ral
2018-05-06lib/csapi/*.mustache: Optimise #includes, eliminate some blank linesKitsune Ral
2018-05-06lib/csapi: SearchJobKitsune Ral
2018-05-06Room::calculateDisplayname: fix a misleading room name after leaving a ↵Kitsune Ral
one-on-one
2018-05-04New home for the generated code - lib/csapiKitsune Ral
2018-05-04Fix building on OSXKitsune Ral