From 7ece217abc9cdb1c81c77393ab4946998b045fb6 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 30 Jun 2015 19:01:47 +0200 Subject: [PATCH] Remove unused file with obsolete PenWindows support. This file was apparently never compiled in, just drop it, as well as the mention of wxUSE_PENWINDOWS in the documentation. --- docs/doxygen/mainpages/const_wxusedef.h | 1 - src/msw/penwin.cpp | 113 ------------------------ 2 files changed, 114 deletions(-) delete mode 100644 src/msw/penwin.cpp diff --git a/docs/doxygen/mainpages/const_wxusedef.h b/docs/doxygen/mainpages/const_wxusedef.h index cbf7c2064a..a0ea2cf251 100644 --- a/docs/doxygen/mainpages/const_wxusedef.h +++ b/docs/doxygen/mainpages/const_wxusedef.h @@ -334,7 +334,6 @@ manifest from wxWidgets RC file. See also wxUSE_RC_MANIFEST.} @itemdef{wxUSE_OLE, Enables OLE helper routines.} @itemdef{wxUSE_OLE_AUTOMATION, Enable OLE automation utilities.} @itemdef{wxUSE_OLE_CLIPBOARD, Use OLE clipboard.} -@itemdef{wxUSE_PENWINDOWS, See src/msw/penwin.cpp file.} @itemdef{wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW, Use PS printing in wxMSW.} @itemdef{wxUSE_PS_PRINTING, See src/msw/dcprint.cpp file.} @itemdef{wxUSE_RC_MANIFEST, Include manifest for common controls library v6 diff --git a/src/msw/penwin.cpp b/src/msw/penwin.cpp deleted file mode 100644 index 399e8c0046..0000000000 --- a/src/msw/penwin.cpp +++ /dev/null @@ -1,113 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: src/msw/penwin.cpp -// Purpose: PenWindows code -// Author: Julian Smart -// Modified by: -// Created: 04/01/98 -// Copyright: (c) Julian Smart -// Licence: wxWindows licence -///////////////////////////////////////////////////////////////////////////// - -// For compilers that support precompilation, includes "wx.h". -#include "wx/wxprec.h" - -#ifdef __BORLANDC__ -#pragma hdrstop -#endif - -#ifndef WX_PRECOMP - #include "wx/window.h" -#endif - -#include "wx/msw/private.h" - -#if wxUSE_PENWINDOWS - -#ifdef __BORLANDC__ -#define RPA_DEFAULT 1 -#else -#include -#endif - -HANDLE g_hPenWin = (HANDLE)NULL; -typedef void (CALLBACK * PENREGPROC)(WORD,BOOL); - -// The routine below allows Windows applications (binaries) to -// support Pen input when running under Microsoft Windows for -// Pen Computing 1.0 without need of the PenPalete. -// -// Should masked edit functions be added to wxWidgets we would -// be a new class of functions to support BEDIT controls. -// -// (The function is a NOOP for native Windows-NT) -#ifndef __WIN32__ -static void (CALLBACK * RegPenApp) (WORD, BOOL) = NULL; -#endif - -// Where is this called?? -void wxEnablePenAppHooks (bool hook) -{ -#ifndef __WIN32__ - if (hook) - { - if (g_hPenWin) - return; - - /////////////////////////////////////////////////////////////////////// - // If running on a Pen Windows system, register this app so all - // EDIT controls in dialogs are replaced by HEDIT controls. - if ((g_hPenWin = (HANDLE)::GetSystemMetrics (SM_PENWINDOWS)) != (HANDLE) NULL) - { - // We do this fancy GetProcAddress simply because we don't - // know if we're running Pen Windows. - if ((RegPenApp = (PENREGPROC)GetProcAddress (g_hPenWin, "RegisterPenApp")) != NULL) - (*RegPenApp) (RPA_DEFAULT, TRUE); - } - } - else - { - /////////////////////////////////////////////////////////////////////// - // If running on a Pen Windows system, unregister - if (g_hPenWin) - { - // Unregister this app - if (RegPenApp != NULL) - (*RegPenApp) (RPA_DEFAULT, FALSE); - g_hPenWin = (HANDLE) NULL; - } - } -#endif /* ! Windows-NT */ -} - -#endif - // End wxUSE_PENWINDOWS - -void wxRegisterPenWin(void) -{ -#if wxUSE_PENWINDOWS -/////////////////////////////////////////////////////////////////////// -// If running on a Pen Windows system, register this app so all -// EDIT controls in dialogs are replaced by HEDIT controls. -// (Notice the CONTROL statement in the RC file is "EDIT", -// RegisterPenApp will automatically change that control to -// an HEDIT. - if ((g_hPenWin = (HANDLE)::GetSystemMetrics(SM_PENWINDOWS)) != (HANDLE)NULL) { - // We do this fancy GetProcAddress simply because we don't - // know if we're running Pen Windows. - if ( (RegPenApp = (void (CALLBACK *)(WORD, BOOL))GetProcAddress(g_hPenWin, "RegisterPenApp"))!= NULL) - (*RegPenApp)(RPA_DEFAULT, TRUE); - } -/////////////////////////////////////////////////////////////////////// -#endif -} - -void wxCleanUpPenWin(void) -{ -#if wxUSE_PENWINDOWS - if (g_hPenWin) { - // Unregister this app - if (RegPenApp != NULL) - (*RegPenApp)(RPA_DEFAULT, FALSE); - } -#endif -}