diff options
author | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-05-17 22:42:31 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-05-17 22:42:31 -0400 |
commit | d3289425003bf1a8d074dc82d80f50dbdd084658 (patch) | |
tree | 554f55646ca82dcf56cea58fe13b0e25dc36cc72 | |
parent | 2a755c0cd61b619ed14e023ad34fc7596eafdf34 (diff) |
Make the window taller as appropriate.
Change-Id: I99688bdfd91d2591def46829b7579f2fada86f53
-rw-r--r-- | sc/source/ui/cctrl/checklistmenu.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx index 4e524d527d9f..f1f8acd9de42 100644 --- a/sc/source/ui/cctrl/checklistmenu.cxx +++ b/sc/source/ui/cctrl/checklistmenu.cxx @@ -1035,6 +1035,13 @@ void ScCheckListMenuWindow::packWindow() // Widen the window to fit the menu items. maWndSize.Width() = maMenuSize.Width(); + // Set proper window height based on the number of menu items. + if (maWndSize.Height() < maMenuSize.Height()*2.8) + maWndSize.Height() = maMenuSize.Height()*2.8; + + // TODO: Make sure the window height never exceeds the height of the + // screen. Also do adjustment based on the number of check box items. + SetOutputSizePixel(maWndSize); const StyleSettings& rStyle = GetSettings().GetStyleSettings(); |