2 Copyright (C) 2000-2004 Kern Sibbald and John Walker
4 This program is free software; you can redistribute it and/or
5 modify it under the terms of the GNU General Public License as
6 published by the Free Software Foundation; either version 2 of
7 the License, or (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 General Public License for more details.
14 You should have received a copy of the GNU General Public
15 License along with this program; if not, write to the Free
16 Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
19 This file is patterned after the VNC Win32 code by ATT
24 #include "winbacula.h"
32 bacAbout::~bacAbout() { };
34 void bacAbout::Show(BOOL show)
36 if (show && !visible) {
37 DialogBoxParam(hAppInstance, MAKEINTRESOURCE(IDD_ABOUT), NULL,
38 (DLGPROC)DialogProc, (LONG)this);
44 bacAbout::DialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam )
46 /* Get the dialog class pointer from USERDATA */
51 /* save the dialog class pointer */
52 SetWindowLong(hwnd, GWL_USERDATA, lParam);
53 _this = (bacAbout *)lParam;
56 SetForegroundWindow(hwnd);
57 _this->visible = true;
61 switch (LOWORD(wParam)) {
64 EndDialog(hwnd, TRUE);
65 _this = (bacAbout *)GetWindowLong(hwnd, GWL_USERDATA);
66 _this->visible = false;
72 EndDialog(hwnd, FALSE);
73 _this = (bacAbout *)GetWindowLong(hwnd, GWL_USERDATA);
74 _this->visible = false;