Skip to content

Commit

Permalink
fmk - updating main for analytics and GA4.html
Browse files Browse the repository at this point in the history
  • Loading branch information
fmckenna committed Sep 30, 2023
1 parent dd0f955 commit 6b7d95b
Showing 1 changed file with 18 additions and 6 deletions.
24 changes: 18 additions & 6 deletions main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
#include <QStandardPaths>
#include <QDir>
#include <QStatusBar>
#include <QWebEngineView>

static QString logFilePath;
static bool logToFile = false;
Expand Down Expand Up @@ -122,12 +123,6 @@ int main(int argc, char *argv[])

QApplication a(argc, argv);

//Setting Google Analytics Tracking Information
GoogleAnalytics::SetMeasurementId("G-CPFD5EFJ4Y");
GoogleAnalytics::SetAPISecret("vxNbZfRdRUyVx3fBpdUXxg");
GoogleAnalytics::CreateSessionId();
GoogleAnalytics::StartSession();

//
// create a remote interface
//
Expand Down Expand Up @@ -175,6 +170,7 @@ int main(int argc, char *argv[])

thread->start();


//
// show the main window, set styles & start the event loop
//
Expand Down Expand Up @@ -202,6 +198,22 @@ int main(int argc, char *argv[])
qDebug() << "could not open stylesheet";
}

//Setting Google Analytics Tracking Information
GoogleAnalytics::SetMeasurementId("G-CPFD5EFJ4Y");
GoogleAnalytics::SetAPISecret("vxNbZfRdRUyVx3fBpdUXxg");
GoogleAnalytics::CreateSessionId();
GoogleAnalytics::StartSession();

// Opening a QWebEngineView and using github to get app geographic usage
QWebEngineView view;
view.setUrl(QUrl("https://nheri-simcenter.github.io/E-UQ/GA4.html"));
view.resize(1024, 750);
view.show();
view.hide();

//
// exe application event-loop
//

int res = a.exec();

Expand Down

0 comments on commit 6b7d95b

Please sign in to comment.