From 0318e3616702b19c088f4cd6138b768d45b7ef11 Mon Sep 17 00:00:00 2001 From: AndreyL ProductEngine Date: Tue, 24 May 2016 21:59:58 +0300 Subject: MAINT-6419 Simplified the version check + buildfix --- indra/newview/app_settings/settings.xml | 2 +- indra/newview/llappviewer.cpp | 25 +++---------------------- indra/newview/llappviewer.h | 2 ++ 3 files changed, 6 insertions(+), 23 deletions(-) (limited to 'indra') diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 7bcbf819e4..57a9db9337 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -13285,7 +13285,7 @@ Type Boolean Value - 1 + 1 UploadBakedTexOld diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 29680093f9..acbcb4f8b7 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -5807,29 +5807,10 @@ void LLAppViewer::launchUpdater() */ void LLAppViewer::showReleaseNotesIfRequired() { - if (!gLastRunVersion.empty() && gSavedSettings.getBOOL("UpdaterShowReleaseNotes")) + if (LLVersionInfo::getChannelAndVersion() != gLastRunVersion && gSavedSettings.getBOOL("UpdaterShowReleaseNotes")) { - try - { - boost::regex expr("(?[\\w\\s]+)\\s(?\\d+)\\.(?\\d+)\\.(?\\d+)\\.(?\\d+)", boost::regex::perl | boost::regex::icase); - boost::smatch matches; - if (boost::regex_search(gLastRunVersion, matches, expr)) - { - if (LLVersionInfo::getChannel() == matches["chan"] && // don't show Release Notes when changing a channel - (LLVersionInfo::getBuild() > std::stoi(matches["build"]) - || LLVersionInfo::getPatch() > std::stoi(matches["patch"]) - || LLVersionInfo::getMinor() > std::stoi(matches["min"]) - || LLVersionInfo::getMajor() > std::stoi(matches["maj"]))) - { - LLSD info(getViewerInfo()); - LLWeb::loadURLInternal(info["VIEWER_RELEASE_NOTES_URL"]); - } - } - } - catch (boost::regex_error& e) - { - LL_WARNS() << "Can't parse previous run version, regex errpr: " << e.what() << LL_ENDL; - } + LLSD info(getViewerInfo()); + LLWeb::loadURLInternal(info["VIEWER_RELEASE_NOTES_URL"]); } } diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h index b5e674bd7b..07bef11dbc 100644 --- a/indra/newview/llappviewer.h +++ b/indra/newview/llappviewer.h @@ -254,6 +254,8 @@ private: void sendLogoutRequest(); void disconnectViewer(); + + void showReleaseNotesIfRequired(); // *FIX: the app viewer class should be some sort of singleton, no? // Perhaps its child class is the singleton and this should be an abstract base. -- cgit v1.2.3