summaryrefslogtreecommitdiffstats
path: root/src/openglwidgets/qopenglwidget.cpp
diff options
context:
space:
mode:
authorIvan Solovev <ivan.solovev@qt.io>2023-08-29 16:50:56 +0200
committerIvan Solovev <ivan.solovev@qt.io>2023-09-03 18:21:18 +0200
commitd85663ced8762b3096dbcbcfbc3894895a6e11c7 (patch)
tree7522c417741e0a9e69c86d843f1ffd765f74e428 /src/openglwidgets/qopenglwidget.cpp
parent1ad424aed502386c97359b65f37edf2966c0dfa6 (diff)
QDBusServiceWatcher: fix binding loops
This class has two bindable properties - watchedServices and watchMode. What makes this class non-trivial is the fact that these properties depend on each other - setWatchedServices() need an up-to-date watchMode to set up the services, and setWatchMode() needs an up-to-date list of services in order to update the mode on them. Update the setters in such way that they remove the bindings from the updated property, and at the same time trigger the re-evaluation of the property they depend on. This includes refactoring of the helper setConnection() method in such way that it does not cause property re-evaluation, and also update of the {add,remove}Service() helper functions to take the watchMode as an input parameter. The public {add,remove}WatchedService() methods were updated similarly. The logic of the removeWatchedService() method was additionally updated to do some changes to the properties only if the service-to-be-removed actually existed in the list. Task-number: QTBUG-116346 Pick-to: 6.6 6.5 Change-Id: If46cf926c7ace9dc4893d8daaef088f61e41c21a Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/openglwidgets/qopenglwidget.cpp')
0 files changed, 0 insertions, 0 deletions