forked from alex-spataru/QSimpleUpdater
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
aaf10aa
commit 68025d4
Showing
94 changed files
with
8,359 additions
and
0 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# Introduction | ||
|
||
QSimpleUpdater is an implementation of an auto-updating system to be used with Qt projects. It allows you to easily check for updates, download them and install them. Additionally, the QSimpleUpdater allows you to check for updates for different "modules" of your application. Check the WTFs for more information. | ||
|
||
## Integrating QSimpleUpdater with your projects | ||
1. Copy the QSimpleUpdater folder in your "3rd-party" folder. | ||
2. Include the QSimpleUpdater project include (*pri*) file using the include() function. | ||
3. That's all! Check the tutorial project as a reference for your project. | ||
|
||
## WTFs Section | ||
|
||
### 1. How does the QSimpleUpdater check for updates? | ||
|
||
The QSimpleUpdater downloads an update definition file stored in JSON format. This file specifies the latest version, the download links and changelogs for each platform (you can also register your own platform easily if needed). | ||
|
||
After downloading this file, the library analyzes the local version and the remote version. If the remote version is greater than the local version, then the library infers that there is an update available and notifies the user. | ||
|
||
### 2. Can I customize the update notifications shown to the user? | ||
|
||
Yes! You can "toggle" which notifications to show using the library's functions or re-implement by yourself the notifications by "reacting" to the signals emitted by the QSimpleUpdater. | ||
|
||
``` | ||
QString url = "https://MyBadassApplication.com/updates.json"; | ||
QSimpleUpdater::getInstance()->setNotifyOnUpdate (url, true); | ||
QSimpleUpdater::getInstance()->setNotifyOnFinish (url, false); | ||
QSimpleUpdater::getInstance()->checkForUpdates (url); | ||
``` | ||
|
||
### 3. Is the application able to download the updates directly? | ||
|
||
Yes. If there is an update available, the library will prompt the user if he/she wants to download the update. You can enable or disable the integrated downloader with the following code: | ||
|
||
``` | ||
QString url = "https://MyBadassApplication.com/updates.json"; | ||
QSimpleUpdater::getInstance()->setDownloaderEnabled (url, true); | ||
``` | ||
|
||
### 4. Why do I need to specify an URL for each function of the library? | ||
|
||
The QSimpleUpdater allows you to use different updater instances, which can be accessed with the URL of the update definitions. | ||
While it is not obligatory to use multiple updater instances, this can be useful for applications that make use of plugins or different modules. | ||
|
||
Say that you are developing a game, in this case, you could use the following code: | ||
|
||
``` | ||
// Update the game textures | ||
QString textures_url = "https://MyBadassGame.com/textures.json" | ||
QSimpleUpdater::getInstance()->setModuleName (textures_url, "textures"); | ||
QSimpleUpdater::getInstance()->setModuleVersion (textures_url, "0.4"); | ||
QSimpleUpdater::getInstance()->checkForUpdates (textures_url); | ||
// Update the game sounds | ||
QString sounds_url = "https://MyBadassGame.com/sounds.json" | ||
QSimpleUpdater::getInstance()->setModuleName (sounds_url, "sounds"); | ||
QSimpleUpdater::getInstance()->setModuleVersion (sounds_url, "0.6"); | ||
QSimpleUpdater::getInstance()->checkForUpdates (sounds_url); | ||
// Update the client (name & versions are already stored in qApp) | ||
QString client_url = "https://MyBadassGame.com/client.json" | ||
QSimpleUpdater::getInstance()->checkForUpdates (client_url); | ||
``` | ||
|
||
## License | ||
QSimpleUpdater is free and open-source software, it is released under the Don't Be A Dick License. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<html> | ||
<head> | ||
<meta http-equiv="refresh" content="0; url=output/html/index.html"/> | ||
</head> | ||
<body> | ||
<h2>You are being redirected...</h2> | ||
<p>If this piece of crap does not work, please click <a href="output/html/index.html">here</a>.</p> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | ||
<html xmlns="http://www.w3.org/1999/xhtml"> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> | ||
<meta http-equiv="X-UA-Compatible" content="IE=9"/> | ||
<meta name="generator" content="Doxygen 1.8.11"/> | ||
<title>QSimpleUpdater: Class List</title> | ||
<link href="tabs.css" rel="stylesheet" type="text/css"/> | ||
<script type="text/javascript" src="jquery.js"></script> | ||
<script type="text/javascript" src="dynsections.js"></script> | ||
<link href="search/search.css" rel="stylesheet" type="text/css"/> | ||
<script type="text/javascript" src="search/searchdata.js"></script> | ||
<script type="text/javascript" src="search/search.js"></script> | ||
<script type="text/javascript"> | ||
$(document).ready(function() { init_search(); }); | ||
</script> | ||
<link href="doxygen.css" rel="stylesheet" type="text/css" /> | ||
</head> | ||
<body> | ||
<div id="top"><!-- do not remove this div, it is closed by doxygen! --> | ||
<div id="titlearea"> | ||
<table cellspacing="0" cellpadding="0"> | ||
<tbody> | ||
<tr style="height: 56px;"> | ||
<td id="projectlogo"><img alt="Logo" src="icon.png"/></td> | ||
<td id="projectalign" style="padding-left: 0.5em;"> | ||
<div id="projectname">QSimpleUpdater | ||
</div> | ||
<div id="projectbrief">A simple auto-updater system for Qt applications</div> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
<!-- end header part --> | ||
<!-- Generated by Doxygen 1.8.11 --> | ||
<script type="text/javascript"> | ||
var searchBox = new SearchBox("searchBox", "search",false,'Search'); | ||
</script> | ||
<div id="navrow1" class="tabs"> | ||
<ul class="tablist"> | ||
<li><a href="index.html"><span>Main Page</span></a></li> | ||
<li class="current"><a href="annotated.html"><span>Classes</span></a></li> | ||
<li><a href="files.html"><span>Files</span></a></li> | ||
<li> | ||
<div id="MSearchBox" class="MSearchBoxInactive"> | ||
<span class="left"> | ||
<img id="MSearchSelect" src="search/mag_sel.png" | ||
onmouseover="return searchBox.OnSearchSelectShow()" | ||
onmouseout="return searchBox.OnSearchSelectHide()" | ||
alt=""/> | ||
<input type="text" id="MSearchField" value="Search" accesskey="S" | ||
onfocus="searchBox.OnSearchFieldFocus(true)" | ||
onblur="searchBox.OnSearchFieldFocus(false)" | ||
onkeyup="searchBox.OnSearchFieldChange(event)"/> | ||
</span><span class="right"> | ||
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> | ||
</span> | ||
</div> | ||
</li> | ||
</ul> | ||
</div> | ||
<div id="navrow2" class="tabs2"> | ||
<ul class="tablist"> | ||
<li class="current"><a href="annotated.html"><span>Class List</span></a></li> | ||
<li><a href="classes.html"><span>Class Index</span></a></li> | ||
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> | ||
<li><a href="functions.html"><span>Class Members</span></a></li> | ||
</ul> | ||
</div> | ||
</div><!-- top --> | ||
<!-- window showing the filter options --> | ||
<div id="MSearchSelectWindow" | ||
onmouseover="return searchBox.OnSearchSelectShow()" | ||
onmouseout="return searchBox.OnSearchSelectHide()" | ||
onkeydown="return searchBox.OnSearchSelectKey(event)"> | ||
</div> | ||
|
||
<!-- iframe showing the search results (closed by default) --> | ||
<div id="MSearchResultsWindow"> | ||
<iframe src="javascript:void(0)" frameborder="0" | ||
name="MSearchResults" id="MSearchResults"> | ||
</iframe> | ||
</div> | ||
|
||
<div class="header"> | ||
<div class="headertitle"> | ||
<div class="title">Class List</div> </div> | ||
</div><!--header--> | ||
<div class="contents"> | ||
<div class="textblock">Here are the classes, structs, unions and interfaces with brief descriptions:</div><div class="directory"> | ||
<table class="directory"> | ||
<tr id="row_0_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="de/dc0/class_downloader.html" target="_self">Downloader</a></td><td class="desc"></td></tr> | ||
<tr id="row_1_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="d3/d1d/class_updater.html" target="_self">Updater</a></td><td class="desc"></td></tr> | ||
</table> | ||
</div><!-- directory --> | ||
</div><!-- contents --> | ||
<!-- start footer part --> | ||
<hr class="footer"/><address class="footer"><small> | ||
Generated by  <a href="http://www.doxygen.org/index.html"> | ||
<img class="footer" src="doxygen.png" alt="doxygen"/> | ||
</a> 1.8.11 | ||
</small></address> | ||
</body> | ||
</html> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | ||
<html xmlns="http://www.w3.org/1999/xhtml"> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> | ||
<meta http-equiv="X-UA-Compatible" content="IE=9"/> | ||
<meta name="generator" content="Doxygen 1.8.11"/> | ||
<title>QSimpleUpdater: Class Index</title> | ||
<link href="tabs.css" rel="stylesheet" type="text/css"/> | ||
<script type="text/javascript" src="jquery.js"></script> | ||
<script type="text/javascript" src="dynsections.js"></script> | ||
<link href="search/search.css" rel="stylesheet" type="text/css"/> | ||
<script type="text/javascript" src="search/searchdata.js"></script> | ||
<script type="text/javascript" src="search/search.js"></script> | ||
<script type="text/javascript"> | ||
$(document).ready(function() { init_search(); }); | ||
</script> | ||
<link href="doxygen.css" rel="stylesheet" type="text/css" /> | ||
</head> | ||
<body> | ||
<div id="top"><!-- do not remove this div, it is closed by doxygen! --> | ||
<div id="titlearea"> | ||
<table cellspacing="0" cellpadding="0"> | ||
<tbody> | ||
<tr style="height: 56px;"> | ||
<td id="projectlogo"><img alt="Logo" src="icon.png"/></td> | ||
<td id="projectalign" style="padding-left: 0.5em;"> | ||
<div id="projectname">QSimpleUpdater | ||
</div> | ||
<div id="projectbrief">A simple auto-updater system for Qt applications</div> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
<!-- end header part --> | ||
<!-- Generated by Doxygen 1.8.11 --> | ||
<script type="text/javascript"> | ||
var searchBox = new SearchBox("searchBox", "search",false,'Search'); | ||
</script> | ||
<div id="navrow1" class="tabs"> | ||
<ul class="tablist"> | ||
<li><a href="index.html"><span>Main Page</span></a></li> | ||
<li class="current"><a href="annotated.html"><span>Classes</span></a></li> | ||
<li><a href="files.html"><span>Files</span></a></li> | ||
<li> | ||
<div id="MSearchBox" class="MSearchBoxInactive"> | ||
<span class="left"> | ||
<img id="MSearchSelect" src="search/mag_sel.png" | ||
onmouseover="return searchBox.OnSearchSelectShow()" | ||
onmouseout="return searchBox.OnSearchSelectHide()" | ||
alt=""/> | ||
<input type="text" id="MSearchField" value="Search" accesskey="S" | ||
onfocus="searchBox.OnSearchFieldFocus(true)" | ||
onblur="searchBox.OnSearchFieldFocus(false)" | ||
onkeyup="searchBox.OnSearchFieldChange(event)"/> | ||
</span><span class="right"> | ||
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> | ||
</span> | ||
</div> | ||
</li> | ||
</ul> | ||
</div> | ||
<div id="navrow2" class="tabs2"> | ||
<ul class="tablist"> | ||
<li><a href="annotated.html"><span>Class List</span></a></li> | ||
<li class="current"><a href="classes.html"><span>Class Index</span></a></li> | ||
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> | ||
<li><a href="functions.html"><span>Class Members</span></a></li> | ||
</ul> | ||
</div> | ||
</div><!-- top --> | ||
<!-- window showing the filter options --> | ||
<div id="MSearchSelectWindow" | ||
onmouseover="return searchBox.OnSearchSelectShow()" | ||
onmouseout="return searchBox.OnSearchSelectHide()" | ||
onkeydown="return searchBox.OnSearchSelectKey(event)"> | ||
</div> | ||
|
||
<!-- iframe showing the search results (closed by default) --> | ||
<div id="MSearchResultsWindow"> | ||
<iframe src="javascript:void(0)" frameborder="0" | ||
name="MSearchResults" id="MSearchResults"> | ||
</iframe> | ||
</div> | ||
|
||
<div class="header"> | ||
<div class="headertitle"> | ||
<div class="title">Class Index</div> </div> | ||
</div><!--header--> | ||
<div class="contents"> | ||
<div class="qindex"><a class="qindex" href="#letter_D">D</a> | <a class="qindex" href="#letter_U">U</a></div> | ||
<table class="classindex"> | ||
<tr><td rowspan="2" valign="bottom"><a name="letter_D"></a><table border="0" cellspacing="0" cellpadding="0"><tr><td><div class="ah">  D  </div></td></tr></table> | ||
</td><td rowspan="2" valign="bottom"><a name="letter_U"></a><table border="0" cellspacing="0" cellpadding="0"><tr><td><div class="ah">  U  </div></td></tr></table> | ||
</td><td></td></tr> | ||
<tr><td></td></tr> | ||
<tr><td valign="top"><a class="el" href="de/dc0/class_downloader.html">Downloader</a>   </td><td valign="top"><a class="el" href="d3/d1d/class_updater.html">Updater</a>   </td><td></td></tr> | ||
<tr><td></td><td></td><td></td></tr> | ||
</table> | ||
<div class="qindex"><a class="qindex" href="#letter_D">D</a> | <a class="qindex" href="#letter_U">U</a></div> | ||
</div><!-- contents --> | ||
<!-- start footer part --> | ||
<hr class="footer"/><address class="footer"><small> | ||
Generated by  <a href="http://www.doxygen.org/index.html"> | ||
<img class="footer" src="doxygen.png" alt="doxygen"/> | ||
</a> 1.8.11 | ||
</small></address> | ||
</body> | ||
</html> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.