Make resizing of gui window only affect the browser ratio, not the scale

This commit is contained in:
Ylva Selling
2022-05-04 12:40:21 -04:00
parent d3a955e6be
commit 323fea8ec6
6 changed files with 21 additions and 37 deletions
+3 -7
View File
@@ -165,10 +165,6 @@ std::string TargetBrowserPair::targetNodeId() const {
return _targetNode->identifier();
}
glm::vec2 TargetBrowserPair::size() const {
return _browser->size();
}
float TargetBrowserPair::browserRatio() const {
return _browser->browserRatio();
}
@@ -282,9 +278,9 @@ void TargetBrowserPair::setBorderColor(const glm::ivec3& color) {
_browser->setBorderColor(color);
}
void TargetBrowserPair::setScreenSpaceSize(const glm::vec2& dimensions) {
_browser->setScreenSpaceSize(dimensions);
_targetRenderable->setRatio(dimensions.x / dimensions.y);
void TargetBrowserPair::setBrowserRatio(float ratio) {
_browser->setRatio(ratio);
_targetRenderable->setRatio(ratio);
}
void TargetBrowserPair::setVerticalFovWithScroll(float scroll) {