]> git.saurik.com Git - wxWidgets.git/blobdiff - src/html/htmlwin.cpp
More samples makefiles
[wxWidgets.git] / src / html / htmlwin.cpp
index a149ca56cbf83c359d7855d57760d3a05d551989..7c08bbbd3f6b54a104974b871013e7c7788ee93b 100644 (file)
@@ -256,20 +256,23 @@ void wxHtmlWindow::CreateLayout()
 
     else {
         GetClientSize(&ClientWidth, &ClientHeight);
+#ifndef __WXMSW__
+        // VS : this looks extremely ugly under windoze, better fix needed!
         SetScrollbars(1, 1, 0, ClientHeight * 2); // always on          
+#endif
         GetClientSize(&ClientWidth, &ClientHeight);
         m_Cell -> Layout(ClientWidth);
-        GetClientSize(&ClientWidth, &ClientHeight);
-       if (ClientHeight < m_Cell -> GetHeight()) {
+       if (ClientHeight < m_Cell -> GetHeight()) {
             SetScrollbars(HTML_SCROLL_STEP, HTML_SCROLL_STEP,
                           m_Cell -> GetWidth() / HTML_SCROLL_STEP,
                           m_Cell -> GetHeight() / HTML_SCROLL_STEP
                           /*cheat: top-level frag is always container*/);
         }
-       else { /* we fit into window, no need for scrollbars */
-           SetScrollbars(1, 1, 0, 0); // disable...
-           m_Cell -> Layout(ClientWidth); // ...and relayout
-       }
+           else { /* we fit into window, no need for scrollbars */
+               SetScrollbars(1, 1, 0, 0); // disable...
+                GetClientSize(&ClientWidth, &ClientHeight);
+               m_Cell -> Layout(ClientWidth); // ...and relayout
+           }
     }
 }