|
Wireshark 4.7.0
The Wireshark network protocol analyzer
|
C++ wrapper for the Sparkle update framework. More...
#include <sparkle_bridge.h>
Static Public Member Functions | |
| static void | updateInit (const char *url, bool enabled, int interval) |
| static void | updateCheck () |
| static void | setUpdateCallbacks (sparkle_update_attention_callback_t attention_cb, sparkle_postpone_relaunch_callback_t postpone_relaunch_cb, sparkle_will_relaunch_callback_t will_relaunch_cb) |
C++ wrapper for the Sparkle update framework.
|
static |
Register callbacks for Sparkle
All callbacks are invoked on the main thread. Any of them may be NULL to ignore that particular event.
| attention_cb | Called when the user has engaged with the update. |
| postpone_relaunch_cb | Called when the update is ready for the app to handle any pre-relaunch tasks (e.g. saving documents). The app should perform the tasks, then call the provided proceed() function pointer to allow Sparkle to continue with the relaunch. |
| will_relaunch_cb | Called when the app is about to be relaunched. |
|
static |
Trigger an immediate, user-initiated update check.
Called when the user selects "Check for Updates…" from the Help menu. Sparkle shows its own native macOS UI (progress sheet, release notes, install prompt) — no additional Qt UI is needed.
|
static |
Initialize the Sparkle update subsystem.
Must be called once at application startup (from software_update_init()). Sets the appcast feed URL, whether automatic background checks are enabled, and the interval between automatic checks.
Internally this creates a singleton SPUStandardUpdaterController — the Sparkle 2 equivalent of the deprecated SUUpdater sharedUpdater from Sparkle 1. The singleton ensures that only one updater instance exists for the lifetime of the application.
| url | Appcast feed URL (an XML file describing available updates). Built by get_appcast_update_url() in software_update.c. |
| enabled | Whether to check for updates automatically in the background. Maps to the Wireshark preference "gui.update.enabled". |
| interval | Seconds between automatic update checks. Maps to the Wireshark preference "gui.update.interval". |