diff options
Diffstat (limited to 'src/MessageBoard.cpp')
-rw-r--r-- | src/MessageBoard.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/MessageBoard.cpp b/src/MessageBoard.cpp index 2c89be3..4366d9b 100644 --- a/src/MessageBoard.cpp +++ b/src/MessageBoard.cpp @@ -385,8 +385,8 @@ namespace dchat void MessageBoard::draw(sf::RenderWindow &window, Cache &cache) { auto windowSize = window.getSize(); - backgroundSizeWithoutPadding = sf::Vector2f(floor(windowSize.x - ChannelSidePanel::getWidth() - UsersSidePanel::getWidth()), floor(windowSize.y - ChannelTopPanel::getHeight() - Chatbar::getHeight())); - backgroundSize = sf::Vector2f(floor(windowSize.x - ChannelSidePanel::getWidth() - UsersSidePanel::getWidth() - PADDING_SIDE * Settings::getScaling() * 2.0f), floor(windowSize.y - ChannelTopPanel::getHeight() - Chatbar::getHeight() - PADDING_TOP)); + backgroundSizeWithoutPadding = sf::Vector2f(floor(windowSize.x - ChannelSidePanel::getWidth()), floor(windowSize.y - ChannelTopPanel::getHeight() - Chatbar::getHeight())); + backgroundSize = sf::Vector2f(floor(windowSize.x - ChannelSidePanel::getWidth() - PADDING_SIDE * Settings::getScaling() * 2.0f), floor(windowSize.y - ChannelTopPanel::getHeight() - Chatbar::getHeight() - PADDING_TOP)); backgroundPos = sf::Vector2f(ChannelSidePanel::getWidth(), ChannelTopPanel::getHeight()); //if(backgroundSize != staticContentTexture.getSize()) @@ -459,7 +459,7 @@ namespace dchat scrollbar.maxScroll = totalHeight; scrollbar.width = 10.0f * Settings::getScaling(); scrollbar.maxHeight = (float)backgroundSize.y; - scrollbar.position.x = windowSize.x - UsersSidePanel::getWidth() - scrollbar.width; + scrollbar.position.x = windowSize.x - scrollbar.width; scrollbar.position.y = backgroundPos.y; scrollbar.draw(window); scroll = scrollbar.getScrollingForContent(); |