MuseScore  3.4
Music composition and notation
winSparkleAutoUpdater.h
Go to the documentation of this file.
1 //=============================================================================
2 // MuseScore
3 // Music Composition & Notation
4 //
5 // Copyright (C) 2018 Werner Schweer
6 //
7 // This program is free software; you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License version 2
9 // as published by the Free Software Foundation and appearing in
10 // the file LICENCE.GPL
11 //=============================================================================
12 
13 #ifndef __WIN_SPARKLE_AUTO_UPDATER_H__
14 #define __WIN_SPARKLE_AUTO_UPDATER_H__
15 
16 #include "winsparkle/winsparkle.h"
17 #include "sparkle/autoUpdater.h"
18 
19 namespace Ms
20 {
21  static const wchar_t* vendorName = L"musescore.org";
22  static const wchar_t* productName = L"MuseScore";
24  {
25  public:
26  virtual void checkUpdates()
27  {
28  // Initialize WinSparkle as soon as the app itself is initialized, right
29  // before entering the event loop:
30  win_sparkle_set_appcast_url(WIN_SPARKLE_APPCAST_URL);
31  auto msVersion = QString(VERSION) + QString(".") + QString(BUILD_NUMBER);
32  win_sparkle_set_app_details(vendorName, productName, msVersion.toStdWString().c_str());
33  win_sparkle_init();
34  }
35 
36  virtual void checkForUpdatesNow()
37  {
38  win_sparkle_check_update_with_ui();
39  }
40 
41  virtual void cleanup()
42  {
43  win_sparkle_cleanup();
44  }
45  };
46 
47 } //Ms
48 
49 #endif //__WIN_SPARKLE_AUTO_UPDATER_H__
Definition: autoUpdater.h:17
#define VERSION
Definition: model.cpp:25
virtual void checkForUpdatesNow()
Definition: winSparkleAutoUpdater.h:36
Definition: aeolus.cpp:26
Definition: winSparkleAutoUpdater.h:23
virtual void checkUpdates()
Definition: winSparkleAutoUpdater.h:26
virtual void cleanup()
Definition: winSparkleAutoUpdater.h:41