Cockatrice 2025-11-30-Development-2.11.0-beta.38
A cross-platform virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
ClientUpdateChecker Class Reference

#include <client_update_checker.h>

Inheritance diagram for ClientUpdateChecker:
[legend]
Collaboration diagram for ClientUpdateChecker:
[legend]

Signals

void finishedCheck (bool needToUpdate, bool isCompatible, Release *release)
void error (const QString &errorString)

Public Member Functions

 ClientUpdateChecker (QObject *parent=nullptr)
void check ()

Private Member Functions

void actFinishedCheck (bool needToUpdate, bool isCompatible, Release *release)
void actError (const QString &errorString)

Private Attributes

QMetaObject::Connection finishedCheckConnection
QMetaObject::Connection errorConnection

Detailed Description

We use a singleton instance of UpdateChannel, which can cause interference and feedback loops when multiple objects connect to it.

This class encapsulates the usage of that UpdateChannel to ensure that the check only happens once per connection and the connection is destroyed after it's been used.

Constructor & Destructor Documentation

◆ ClientUpdateChecker()

ClientUpdateChecker::ClientUpdateChecker ( QObject * parent = nullptr)
explicit

Member Function Documentation

◆ actError()

void ClientUpdateChecker::actError ( const QString & errorString)
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ actFinishedCheck()

void ClientUpdateChecker::actFinishedCheck ( bool needToUpdate,
bool isCompatible,
Release * release )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ check()

void ClientUpdateChecker::check ( )

Actually performs the check, using the currently selected update channel in the settings. Any resulting signals will only be sent once. This method should only be called ONCE per instance.

Here is the call graph for this function:

◆ error

void ClientUpdateChecker::error ( const QString & errorString)
signal

Forwarded from UpdateChannel::error

Here is the caller graph for this function:

◆ finishedCheck

void ClientUpdateChecker::finishedCheck ( bool needToUpdate,
bool isCompatible,
Release * release )
signal

Forwarded from UpdateChannel::finishedCheck

Here is the caller graph for this function:

Member Data Documentation

◆ errorConnection

QMetaObject::Connection ClientUpdateChecker::errorConnection
private

◆ finishedCheckConnection

QMetaObject::Connection ClientUpdateChecker::finishedCheckConnection
private

The documentation for this class was generated from the following files: