added wxUSE_REGKEY option
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47617 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
73
configure
vendored
73
configure
vendored
@@ -1,5 +1,5 @@
|
||||
#! /bin/sh
|
||||
# From configure.in Id: configure.in 47611 2007-07-21 07:31:28Z VZ .
|
||||
# From configure.in Id: configure.in 47615 2007-07-21 12:56:22Z VZ .
|
||||
# Guess values for system-dependent variables and create Makefiles.
|
||||
# Generated by GNU Autoconf 2.61 for wxWidgets 2.9.0.
|
||||
#
|
||||
@@ -1847,8 +1847,9 @@ Optional Features:
|
||||
--enable-xpm use xpm images (XPM file format)
|
||||
--enable-icocur use Windows ICO and CUR formats
|
||||
--enable-dccache cache temporary wxDC objects (Win32 only)
|
||||
--enable-regkey use wxRegKey class (Win32 only)
|
||||
--enable-uxtheme enable support for Windows XP themed look (Win32 only)
|
||||
--enable-wxdib compile wxDIB class (Win32 only)
|
||||
--enable-wxdib use wxDIB class (Win32 only)
|
||||
--disable-largefile omit support for large files
|
||||
--disable-gtktest do not try to compile and run a test GTK+ program
|
||||
--disable-gtktest Do not try to compile and run a test GTK program
|
||||
@@ -15293,6 +15294,59 @@ fi
|
||||
echo "${ECHO_T}$result" >&6; }
|
||||
|
||||
|
||||
enablestring=
|
||||
defaultval=$wxUSE_ALL_FEATURES
|
||||
if test -z "$defaultval"; then
|
||||
if test x"$enablestring" = xdisable; then
|
||||
defaultval=yes
|
||||
else
|
||||
defaultval=no
|
||||
fi
|
||||
fi
|
||||
|
||||
{ echo "$as_me:$LINENO: checking for --${enablestring:-enable}-regkey" >&5
|
||||
echo $ECHO_N "checking for --${enablestring:-enable}-regkey... $ECHO_C" >&6; }
|
||||
# Check whether --enable-regkey was given.
|
||||
if test "${enable_regkey+set}" = set; then
|
||||
enableval=$enable_regkey;
|
||||
if test "$enableval" = yes; then
|
||||
wx_cv_use_regkey='wxUSE_REGKEY=yes'
|
||||
else
|
||||
wx_cv_use_regkey='wxUSE_REGKEY=no'
|
||||
fi
|
||||
cache=yes
|
||||
|
||||
else
|
||||
|
||||
LINE=`grep "^wxUSE_REGKEY=" ${wx_arg_cache_file}`
|
||||
if test "x$LINE" != x ; then
|
||||
eval "DEFAULT_$LINE"
|
||||
fi
|
||||
|
||||
wx_cv_use_regkey='wxUSE_REGKEY=${'DEFAULT_wxUSE_REGKEY":-$defaultval}"
|
||||
|
||||
fi
|
||||
|
||||
|
||||
eval "$wx_cv_use_regkey"
|
||||
if test "x$cache" = xyes; then
|
||||
echo "wxUSE_REGKEY=$wxUSE_REGKEY" >> ${wx_arg_cache_file}.tmp
|
||||
fi
|
||||
|
||||
if test x"$enablestring" = xdisable; then
|
||||
if test $wxUSE_REGKEY = yes; then
|
||||
result=no
|
||||
else
|
||||
result=yes
|
||||
fi
|
||||
else
|
||||
result=$wxUSE_REGKEY
|
||||
fi
|
||||
|
||||
{ echo "$as_me:$LINENO: result: $result" >&5
|
||||
echo "${ECHO_T}$result" >&6; }
|
||||
|
||||
|
||||
enablestring=
|
||||
defaultval=$wxUSE_ALL_FEATURES
|
||||
if test -z "$defaultval"; then
|
||||
@@ -48583,16 +48637,23 @@ _ACEOF
|
||||
|
||||
fi
|
||||
|
||||
if test "$wxUSE_UXTHEME" = "yes"; then
|
||||
if test "$wxUSE_DIB" = "yes"; then
|
||||
cat >>confdefs.h <<\_ACEOF
|
||||
#define wxUSE_UXTHEME 1
|
||||
#define wxUSE_WXDIB 1
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
||||
if test "$wxUSE_DIB" = "yes"; then
|
||||
if test "$wxUSE_REGKEY" = "yes"; then
|
||||
cat >>confdefs.h <<\_ACEOF
|
||||
#define wxUSE_WXDIB 1
|
||||
#define wxUSE_REGKEY 1
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
||||
if test "$wxUSE_UXTHEME" = "yes"; then
|
||||
cat >>confdefs.h <<\_ACEOF
|
||||
#define wxUSE_UXTHEME 1
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
15
configure.in
15
configure.in
@@ -896,8 +896,9 @@ dnl wxMSW-only options
|
||||
dnl ---------------------------------------------------------------------------
|
||||
|
||||
WX_ARG_FEATURE(dccache, [ --enable-dccache cache temporary wxDC objects (Win32 only)], wxUSE_DC_CACHEING)
|
||||
WX_ARG_FEATURE(regkey, [ --enable-regkey use wxRegKey class (Win32 only)], wxUSE_REGKEY)
|
||||
WX_ARG_FEATURE(uxtheme, [ --enable-uxtheme enable support for Windows XP themed look (Win32 only)], wxUSE_UXTHEME)
|
||||
WX_ARG_FEATURE(wxdib, [ --enable-wxdib compile wxDIB class (Win32 only)], wxUSE_DIB)
|
||||
WX_ARG_FEATURE(wxdib, [ --enable-wxdib use wxDIB class (Win32 only)], wxUSE_DIB)
|
||||
|
||||
fi
|
||||
dnl for GUI only
|
||||
@@ -7051,14 +7052,18 @@ if test "$wxUSE_DC_CACHEING" = "yes"; then
|
||||
AC_DEFINE(wxUSE_DC_CACHEING)
|
||||
fi
|
||||
|
||||
if test "$wxUSE_UXTHEME" = "yes"; then
|
||||
AC_DEFINE(wxUSE_UXTHEME)
|
||||
fi
|
||||
|
||||
if test "$wxUSE_DIB" = "yes"; then
|
||||
AC_DEFINE(wxUSE_WXDIB)
|
||||
fi
|
||||
|
||||
if test "$wxUSE_REGKEY" = "yes"; then
|
||||
AC_DEFINE(wxUSE_REGKEY)
|
||||
fi
|
||||
|
||||
if test "$wxUSE_UXTHEME" = "yes"; then
|
||||
AC_DEFINE(wxUSE_UXTHEME)
|
||||
fi
|
||||
|
||||
fi
|
||||
dnl wxUSE_MSW = 1
|
||||
|
||||
|
@@ -195,6 +195,7 @@ wxUSE\_LIBPNG.}
|
||||
\twocolitem{wxUSE\_ENH\_METAFILE}{Use wxEnhMetaFile.}
|
||||
\twocolitem{wxUSE\_OLE}{Enables OLE helper routines.}
|
||||
\twocolitem{wxUSE\_OLE\_AUTOMATION}{Enable OLE automation utilities.}
|
||||
\twocolitem{wxUSE\_REGKEY}{Use \helpref{wxRegKey}{wxregkey} class.}
|
||||
\twocolitem{wxUSE\_RICHEDIT2}{Enable use of richtext20.dll in \helpref{wxTextCtrl}{wxtextctrl}}
|
||||
\twocolitem{wxUSE\_UXTHEME}{Enable support for XP themes.}
|
||||
\twocolitem{wxUSE\_XPM\_IN\_MSW}{See also wxUSE\_XPM}
|
||||
|
@@ -12,6 +12,10 @@
|
||||
#ifndef _WX_MSW_REGISTRY_H_
|
||||
#define _WX_MSW_REGISTRY_H_
|
||||
|
||||
#include "wx/defs.h"
|
||||
|
||||
#if wxUSE_REGKEY
|
||||
|
||||
class WXDLLIMPEXP_FWD_BASE wxOutputStream;
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
@@ -242,5 +246,7 @@ private:
|
||||
DECLARE_NO_COPY_CLASS(wxRegKey)
|
||||
};
|
||||
|
||||
#endif // wxUSE_REGKEY
|
||||
|
||||
#endif // _WX_MSW_REGISTRY_H_
|
||||
|
||||
|
@@ -1303,7 +1303,7 @@
|
||||
#define wxUSE_DC_CACHEING 1
|
||||
|
||||
// Set this to 1 to enable wxDIB class used internally for manipulating
|
||||
// wxBitmao data.
|
||||
// wxBitmap data.
|
||||
//
|
||||
// Default is 1, set it to 0 only if you don't use wxImage neither
|
||||
//
|
||||
@@ -1314,6 +1314,13 @@
|
||||
// (just use Windows printing).
|
||||
#define wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW 1
|
||||
|
||||
// Set this to 1 to compile in wxRegKey class.
|
||||
//
|
||||
// Default is 1
|
||||
//
|
||||
// Recommended setting: 1, this is used internally by wx in a few places
|
||||
#define wxUSE_REGKEY 1
|
||||
|
||||
// Set this to 1 to use RICHEDIT controls for wxTextCtrl with style wxTE_RICH
|
||||
// which allows to put more than ~32Kb of text in it even under Win9x (NT
|
||||
// doesn't have such limitation).
|
||||
|
@@ -78,6 +78,13 @@
|
||||
// (just use Windows printing).
|
||||
#define wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW 1
|
||||
|
||||
// Set this to 1 to compile in wxRegKey class.
|
||||
//
|
||||
// Default is 1
|
||||
//
|
||||
// Recommended setting: 1, this is used internally by wx in a few places
|
||||
#define wxUSE_REGKEY 1
|
||||
|
||||
// Set this to 1 to use RICHEDIT controls for wxTextCtrl with style wxTE_RICH
|
||||
// which allows to put more than ~32Kb of text in it even under Win9x (NT
|
||||
// doesn't have such limitation).
|
||||
|
@@ -579,6 +579,8 @@
|
||||
|
||||
#define wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW 0
|
||||
|
||||
#define wxUSE_REGKEY 0
|
||||
|
||||
#define wxUSE_RICHEDIT 0
|
||||
|
||||
#define wxUSE_RICHEDIT2 0
|
||||
|
@@ -19,6 +19,8 @@
|
||||
#pragma hdrstop
|
||||
#endif
|
||||
|
||||
#if wxUSE_REGKEY
|
||||
|
||||
#ifndef WX_PRECOMP
|
||||
#include "wx/msw/wrapwin.h"
|
||||
#include "wx/string.h"
|
||||
@@ -1444,3 +1446,5 @@ inline const wxChar *RegValueStr(const wxString& szValue)
|
||||
{
|
||||
return szValue.empty() ? (const wxChar*)NULL : szValue.wx_str();
|
||||
}
|
||||
|
||||
#endif // wxUSE_REGKEY
|
||||
|
@@ -286,7 +286,7 @@ bool wxGetUserName(wxChar *buf, int maxSize)
|
||||
{
|
||||
wxCHECK_MSG( buf && ( maxSize > 0 ), false,
|
||||
_T("empty buffer in wxGetUserName") );
|
||||
#if defined(__WXWINCE__)
|
||||
#if defined(__WXWINCE__) && wxUSE_REGKEY
|
||||
wxLogNull noLog;
|
||||
wxRegKey key(wxRegKey::HKCU, wxT("ControlPanel\\Owner"));
|
||||
if(!key.Open(wxRegKey::Read))
|
||||
@@ -1483,6 +1483,7 @@ extern long wxCharsetToCodepage(const char *name)
|
||||
|
||||
long CP = -1;
|
||||
|
||||
#if wxUSE_REGKEY
|
||||
wxString path(wxT("MIME\\Database\\Charset\\"));
|
||||
wxString cn(name);
|
||||
|
||||
@@ -1508,6 +1509,7 @@ extern long wxCharsetToCodepage(const char *name)
|
||||
!key.QueryValue(wxT("AliasForCharset"), cn))
|
||||
break;
|
||||
}
|
||||
#endif // wxUSE_REGKEY
|
||||
|
||||
return CP;
|
||||
}
|
||||
|
Reference in New Issue
Block a user