mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 11:45:36 +02:00
Add API call to retrieve user agent.
This commit is contained in:
parent
647b45323e
commit
f4016bb0d5
2 changed files with 12 additions and 0 deletions
|
@ -29,6 +29,7 @@
|
|||
#include "Menu.h"
|
||||
#include "OffscreenUi.h"
|
||||
#include "commerce/QmlCommerce.h"
|
||||
#include "NetworkingConstants.h"
|
||||
|
||||
static const QString DESKTOP_LOCATION = QStandardPaths::writableLocation(QStandardPaths::DesktopLocation);
|
||||
static const QString LAST_BROWSE_LOCATION_SETTING = "LastBrowseLocation";
|
||||
|
@ -411,6 +412,10 @@ QString WindowScriptingInterface::checkVersion() {
|
|||
return QCoreApplication::applicationVersion();
|
||||
}
|
||||
|
||||
QString WindowScriptingInterface::getUserAgent() {
|
||||
return NetworkingConstants::VIRCADIA_USER_AGENT;
|
||||
}
|
||||
|
||||
QString WindowScriptingInterface::protocolSignature() {
|
||||
return protocolVersionsSignatureBase64();
|
||||
}
|
||||
|
|
|
@ -295,6 +295,13 @@ public slots:
|
|||
*/
|
||||
QString checkVersion();
|
||||
|
||||
/**jsdoc
|
||||
* Gets Interface's user agent.
|
||||
* @function Window.getUserAgent
|
||||
* @returns {string} Interface's user agent.
|
||||
*/
|
||||
QString getUserAgent();
|
||||
|
||||
/**jsdoc
|
||||
* Gets the signature for Interface's protocol version.
|
||||
* @function Window.protocolSignature
|
||||
|
|
Loading…
Reference in a new issue