Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/hpc/stand/hpcboot/menu Make the progress bar use th...



details:   https://anonhg.NetBSD.org/src/rev/dae6662755a6
branches:  trunk
changeset: 556699:dae6662755a6
user:      uwe <uwe%NetBSD.org@localhost>
date:      Tue Dec 23 17:18:25 2003 +0000

description:
Make the progress bar use the whole width between the Boot and Cancel
buttons.  Since there are 11 calls to menu.progress() in hpcboot, set
the progress bar range to 0..11, not 0..12.

In RootWindow::WMCreate - when we mean to adjust the top of the client
are by the button height, use _button_height, instead of cmdbar_height
(they now happen to be equal).

diffstat:

 sys/arch/hpc/stand/hpcboot/menu/rootwindow.cpp |  9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diffs (37 lines):

diff -r 325b55897de9 -r dae6662755a6 sys/arch/hpc/stand/hpcboot/menu/rootwindow.cpp
--- a/sys/arch/hpc/stand/hpcboot/menu/rootwindow.cpp    Tue Dec 23 17:12:26 2003 +0000
+++ b/sys/arch/hpc/stand/hpcboot/menu/rootwindow.cpp    Tue Dec 23 17:18:25 2003 +0000
@@ -1,4 +1,4 @@
-/* -*-C++-*-   $NetBSD: rootwindow.cpp,v 1.8 2003/12/23 04:41:13 uwe Exp $     */
+/* -*-C++-*-   $NetBSD: rootwindow.cpp,v 1.9 2003/12/23 17:18:25 uwe Exp $     */
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -218,7 +218,7 @@
        // regsiter myself to menu
        HpcMenuInterface::Instance()._root = this;
 
-       rect.top += cmdbar_height;
+       rect.top += _button_height;
        // Tab control.
        _base =  new TabWindowBase(_app, w, rect, IDC_BASE);
        _base->create(aux);
@@ -308,8 +308,7 @@
 BOOL
 ProgressBar::create(LPCREATESTRUCT aux)
 {
-       int cx = _rect.right - _rect.left
-           - TABCTRL_TAB_WIDTH - BOOT_BUTTON_WIDTH * 2;
+       int cx = _rect.right - _rect.left - BOOT_BUTTON_WIDTH * 2;
        int cy = _root._button_height;
        int x = _rect.left + BOOT_BUTTON_WIDTH;
        _window = CreateWindow(PROGRESS_CLASS, TEXT(""),
@@ -317,7 +316,7 @@
            x, _rect.top, cx, cy, _parent_window,
            reinterpret_cast <HMENU>(IDC_PROGRESSBAR),
            aux->hInstance, NULL);
-       SendMessage(_window, PBM_SETRANGE, 0, MAKELPARAM(0, 12));
+       SendMessage(_window, PBM_SETRANGE, 0, MAKELPARAM(0, 11));
 
        return IsWindow(_window) ? TRUE : FALSE;
 }



Home | Main Index | Thread Index | Old Index