From c912dd31cfcd1bb4ad5e251d0bc404c31228159b Mon Sep 17 00:00:00 2001 From: george82 Date: Sun, 17 Apr 2005 11:58:47 +0000 Subject: [PATCH] Added ToolBar::getButtonsWidth(), ToolBar::getButtonsHeight(). Modifed ToolBar::autoSize(). If toolbar has CCS_NORESIZE style, then autoSize() resizes toolbar itself else it resizes by TB_AUTOSIZE message. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@292 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- rfbplayer/ToolBar.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rfbplayer/ToolBar.cxx b/rfbplayer/ToolBar.cxx index d92d5849..6551cf80 100644 --- a/rfbplayer/ToolBar.cxx +++ b/rfbplayer/ToolBar.cxx @@ -186,7 +186,7 @@ void ToolBar::autoSize() { RECT r, btnRect; GetClientRect(parentHwnd, &r); getButtonRect(0, &btnRect); - int height = getButtonsHeight() + btnRect.top * 2 + 1; + int height = getButtonsHeight() + btnRect.top * 2 + 2; SetWindowPos(getHandle(), HWND_TOP, 0, 0, r.right - r.left, height, SWP_NOMOVE); } else { -- 2.39.5