Merge branch 'master' of github.com:highfidelity/hifi into fix-polyvox-memory-leak

This commit is contained in:
Seth Alves 2016-11-17 08:44:52 -08:00
commit 1f9598f295
8 changed files with 60 additions and 24 deletions

View file

@ -139,7 +139,8 @@ macro(SET_PACKAGING_PARAMETERS)
set(CLIENT_DESKTOP_SHORTCUT_REG_KEY "ClientDesktopShortcut") set(CLIENT_DESKTOP_SHORTCUT_REG_KEY "ClientDesktopShortcut")
set(CONSOLE_DESKTOP_SHORTCUT_REG_KEY "ConsoleDesktopShortcut") set(CONSOLE_DESKTOP_SHORTCUT_REG_KEY "ConsoleDesktopShortcut")
set(CONSOLE_STARTUP_REG_KEY "ConsoleStartupShortcut") set(CONSOLE_STARTUP_REG_KEY "ConsoleStartupShortcut")
set(LAUNCH_NOW_REG_KEY "LaunchAfterInstall") set(CLIENT_LAUNCH_NOW_REG_KEY "ClientLaunchAfterInstall")
set(SERVER_LAUNCH_NOW_REG_KEY "ServerLaunchAfterInstall")
endif () endif ()
# setup component categories for installer # setup component categories for installer

View file

@ -38,7 +38,8 @@ set(POST_INSTALL_OPTIONS_REG_GROUP "@POST_INSTALL_OPTIONS_REG_GROUP@")
set(CLIENT_DESKTOP_SHORTCUT_REG_KEY "@CLIENT_DESKTOP_SHORTCUT_REG_KEY@") set(CLIENT_DESKTOP_SHORTCUT_REG_KEY "@CLIENT_DESKTOP_SHORTCUT_REG_KEY@")
set(CONSOLE_DESKTOP_SHORTCUT_REG_KEY "@CONSOLE_DESKTOP_SHORTCUT_REG_KEY@") set(CONSOLE_DESKTOP_SHORTCUT_REG_KEY "@CONSOLE_DESKTOP_SHORTCUT_REG_KEY@")
set(CONSOLE_STARTUP_REG_KEY "@CONSOLE_STARTUP_REG_KEY@") set(CONSOLE_STARTUP_REG_KEY "@CONSOLE_STARTUP_REG_KEY@")
set(LAUNCH_NOW_REG_KEY "@LAUNCH_NOW_REG_KEY@") set(SERVER_LAUNCH_NOW_REG_KEY "@SERVER_LAUNCH_NOW_REG_KEY@")
set(CLIENT_LAUNCH_NOW_REG_KEY "@CLIENT_LAUNCH_NOW_REG_KEY@")
set(INSTALLER_HEADER_IMAGE "@INSTALLER_HEADER_IMAGE@") set(INSTALLER_HEADER_IMAGE "@INSTALLER_HEADER_IMAGE@")
set(UNINSTALLER_HEADER_IMAGE "@UNINSTALLER_HEADER_IMAGE@") set(UNINSTALLER_HEADER_IMAGE "@UNINSTALLER_HEADER_IMAGE@")
set(ADD_REMOVE_ICON_PATH "@ADD_REMOVE_ICON_PATH@") set(ADD_REMOVE_ICON_PATH "@ADD_REMOVE_ICON_PATH@")

View file

@ -135,10 +135,6 @@ Var AR_RegFlags
SectionSetFlags ${${SecName}} $AR_SecFlags SectionSetFlags ${${SecName}} $AR_SecFlags
"default_${SecName}:" "default_${SecName}:"
; The client is always selected by default
${If} ${SecName} == @CLIENT_COMPONENT_NAME@
SectionSetFlags ${${SecName}} 17
${EndIf}
!insertmacro LoadSectionSelectedIntoVar ${SecName} ${SecName}_selected !insertmacro LoadSectionSelectedIntoVar ${SecName} ${SecName}_selected
!macroend !macroend
@ -368,7 +364,8 @@ Var PostInstallDialog
Var DesktopClientCheckbox Var DesktopClientCheckbox
Var DesktopServerCheckbox Var DesktopServerCheckbox
Var ServerStartupCheckbox Var ServerStartupCheckbox
Var LaunchNowCheckbox Var LaunchServerNowCheckbox
Var LaunchClientNowCheckbox
Var CurrentOffset Var CurrentOffset
Var OffsetUnits Var OffsetUnits
Var CopyFromProductionCheckbox Var CopyFromProductionCheckbox
@ -431,17 +428,24 @@ Function PostInstallOptionsPage
${If} ${SectionIsSelected} ${@SERVER_COMPONENT_NAME@} ${If} ${SectionIsSelected} ${@SERVER_COMPONENT_NAME@}
${NSD_CreateCheckbox} 0 $CurrentOffset$OffsetUnits 100% 10u "&Launch @CONSOLE_HF_SHORTCUT_NAME@ after install" ${NSD_CreateCheckbox} 0 $CurrentOffset$OffsetUnits 100% 10u "&Launch @CONSOLE_HF_SHORTCUT_NAME@ after install"
${Else} Pop $LaunchServerNowCheckbox
${NSD_CreateCheckbox} 0 $CurrentOffset$OffsetUnits 100% 10u "&Launch @INTERFACE_HF_SHORTCUT_NAME@ after install"
; set the checkbox state depending on what is present in the registry
!insertmacro SetPostInstallOption $LaunchServerNowCheckbox @SERVER_LAUNCH_NOW_REG_KEY@ ${BST_CHECKED}
IntOp $CurrentOffset $CurrentOffset + 15
${EndIf} ${EndIf}
Pop $LaunchNowCheckbox ${If} ${SectionIsSelected} ${@CLIENT_COMPONENT_NAME@}
${NSD_CreateCheckbox} 0 $CurrentOffset$OffsetUnits 100% 10u "&Launch @INTERFACE_HF_SHORTCUT_NAME@ after install"
Pop $LaunchClientNowCheckbox
; set the checkbox state depending on what is present in the registry ; set the checkbox state depending on what is present in the registry
!insertmacro SetPostInstallOption $LaunchNowCheckbox @LAUNCH_NOW_REG_KEY@ ${BST_CHECKED} !insertmacro SetPostInstallOption $LaunchClientNowCheckbox @CLIENT_LAUNCH_NOW_REG_KEY@ ${BST_CHECKED}
${EndIf}
${If} @PR_BUILD@ == 1 ${If} @PR_BUILD@ == 1
; a PR build defaults all install options expect LaunchNowCheckbox and the settings copy to unchecked ; a PR build defaults all install options expect LaunchServerNowCheckbox, LaunchClientNowCheckbox and the settings copy to unchecked
${If} ${SectionIsSelected} ${@CLIENT_COMPONENT_NAME@} ${If} ${SectionIsSelected} ${@CLIENT_COMPONENT_NAME@}
${NSD_SetState} $DesktopClientCheckbox ${BST_UNCHECKED} ${NSD_SetState} $DesktopClientCheckbox ${BST_UNCHECKED}
${EndIf} ${EndIf}
@ -471,7 +475,8 @@ FunctionEnd
Var DesktopClientState Var DesktopClientState
Var DesktopServerState Var DesktopServerState
Var ServerStartupState Var ServerStartupState
Var LaunchNowState Var LaunchServerNowState
Var LaunchClientNowState
Var CopyFromProductionState Var CopyFromProductionState
Function ReadPostInstallOptions Function ReadPostInstallOptions
@ -493,8 +498,15 @@ Function ReadPostInstallOptions
${NSD_GetState} $CopyFromProductionCheckbox $CopyFromProductionState ${NSD_GetState} $CopyFromProductionCheckbox $CopyFromProductionState
${EndIf} ${EndIf}
; check if we need to launch an application post-install ${If} ${SectionIsSelected} ${@SERVER_COMPONENT_NAME@}
${NSD_GetState} $LaunchNowCheckbox $LaunchNowState ; check if we need to launch the server post-install
${NSD_GetState} $LaunchServerNowCheckbox $LaunchServerNowState
${EndIf}
${If} ${SectionIsSelected} ${@CLIENT_COMPONENT_NAME@}
; check if we need to launch the client post-install
${NSD_GetState} $LaunchClientNowCheckbox $LaunchClientNowState
${EndIf}
FunctionEnd FunctionEnd
Function HandlePostInstallOptions Function HandlePostInstallOptions
@ -565,20 +577,31 @@ Function HandlePostInstallOptions
${EndIf} ${EndIf}
${EndIf} ${EndIf}
${If} $LaunchNowState == ${BST_CHECKED} ${If} $LaunchServerNowState == ${BST_CHECKED}
!insertmacro WritePostInstallOption @LAUNCH_NOW_REG_KEY@ YES !insertmacro WritePostInstallOption @SERVER_LAUNCH_NOW_REG_KEY@ YES
; both launches use the explorer trick in case the user has elevated permissions for the installer ; both launches use the explorer trick in case the user has elevated permissions for the installer
; it won't be possible to use this approach if either application should be launched with a command line param ${If} $LaunchClientNowState == ${BST_CHECKED}
${If} ${SectionIsSelected} ${@SERVER_COMPONENT_NAME@} !insertmacro WritePostInstallOption @CLIENT_LAUNCH_NOW_REG_KEY@ YES
; create shortcut with ARGUMENTS ; create shortcut with ARGUMENTS
CreateShortCut "$TEMP\SandboxShortcut.lnk" "$INSTDIR\@CONSOLE_INSTALL_SUBDIR@\@CONSOLE_WIN_EXEC_NAME@" "-- --launchInterface" CreateShortCut "$TEMP\SandboxShortcut.lnk" "$INSTDIR\@CONSOLE_INSTALL_SUBDIR@\@CONSOLE_WIN_EXEC_NAME@" "-- --launchInterface"
Exec '"$WINDIR\explorer.exe" "$TEMP\SandboxShortcut.lnk"' Exec '"$WINDIR\explorer.exe" "$TEMP\SandboxShortcut.lnk"'
${Else} ${Else}
Exec '"$WINDIR\explorer.exe" "$INSTDIR\@INTERFACE_WIN_EXEC_NAME@"' !insertmacro WritePostInstallOption @CLIENT_LAUNCH_NOW_REG_KEY@ NO
Exec '"$WINDIR\explorer.exe" "$INSTDIR\@CONSOLE_INSTALL_SUBDIR@\@CONSOLE_WIN_EXEC_NAME@"'
${EndIf} ${EndIf}
${Else} ${Else}
!insertmacro WritePostInstallOption @LAUNCH_NOW_REG_KEY@ NO !insertmacro WritePostInstallOption @SERVER_LAUNCH_NOW_REG_KEY@ NO
; launch uses the explorer trick in case the user has elevated permissions for the installer
${If} $LaunchClientNowState == ${BST_CHECKED}
!insertmacro WritePostInstallOption @CLIENT_LAUNCH_NOW_REG_KEY@ YES
Exec '"$WINDIR\explorer.exe" "$INSTDIR\@INTERFACE_WIN_EXEC_NAME@"'
${Else}
!insertmacro WritePostInstallOption @CLIENT_LAUNCH_NOW_REG_KEY@ NO
${EndIf}
${EndIf} ${EndIf}
FunctionEnd FunctionEnd

View file

@ -24,6 +24,13 @@ EntityItemPointer RenderableLineEntityItem::factory(const EntityItemID& entityID
return entity; return entity;
} }
RenderableLineEntityItem::~RenderableLineEntityItem() {
auto geometryCache = DependencyManager::get<GeometryCache>();
if (geometryCache) {
geometryCache->releaseID(_lineVerticesID);
}
}
void RenderableLineEntityItem::updateGeometry() { void RenderableLineEntityItem::updateGeometry() {
auto geometryCache = DependencyManager::get<GeometryCache>(); auto geometryCache = DependencyManager::get<GeometryCache>();
if (_lineVerticesID == GeometryCache::UNKNOWN_ID) { if (_lineVerticesID == GeometryCache::UNKNOWN_ID) {

View file

@ -23,6 +23,7 @@ public:
LineEntityItem(entityItemID), LineEntityItem(entityItemID),
_lineVerticesID(GeometryCache::UNKNOWN_ID) _lineVerticesID(GeometryCache::UNKNOWN_ID)
{ } { }
~RenderableLineEntityItem();
virtual void render(RenderArgs* args) override; virtual void render(RenderArgs* args) override;

View file

@ -1593,7 +1593,10 @@ void GeometryCache::renderGlowLine(gpu::Batch& batch, const glm::vec3& p1, const
glowIntensity = 0.0f; glowIntensity = 0.0f;
#endif #endif
glowIntensity = 0.0f;
if (glowIntensity <= 0) { if (glowIntensity <= 0) {
bindSimpleProgram(batch, false, false, false, true, false);
renderLine(batch, p1, p2, color, id); renderLine(batch, p1, p2, color, id);
return; return;
} }

View file

@ -1,7 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<title>Server Backup</title> <title>High Fidelity Sandbox</title>
<script src="content-update.js"></script> <script src="content-update.js"></script>
<link rel="stylesheet" type="text/css" href="content-update.css"></link> <link rel="stylesheet" type="text/css" href="content-update.css"></link>
</head> </head>

View file

@ -606,7 +606,7 @@ function checkNewContent() {
buttons: ['Yes', 'No'], buttons: ['Yes', 'No'],
defaultId: 1, defaultId: 1,
cancelId: 1, cancelId: 1,
title: 'New home content', title: 'High Fidelity Sandbox',
message: 'A newer version of the home content set is available.\nDo you wish to update?', message: 'A newer version of the home content set is available.\nDo you wish to update?',
noLink: true, noLink: true,
}, function(idx) { }, function(idx) {