"Fossies" - the Fresh Open Source Software Archive

Member "dlib-19.18/docs/dlib/windows_magic.h.html" (22 Sep 2019, 2917 Bytes) of package /linux/misc/dlib-19.18.tar.bz2:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) HTML source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 <html><!-- Created using the cpp_pretty_printer from the dlib C++ library.  See http://dlib.net for updates. --><head><title>dlib C++ Library - windows_magic.h</title></head><body bgcolor='white'><pre>
    2 <font color='#009900'>// Copyright (C) 2006  Davis E. King (davis@dlib.net)
    3 </font><font color='#009900'>// License: Boost Software License   See LICENSE.txt for the full license.
    4 </font><font color='#0000FF'>#ifndef</font> DLIB_WINDOWS_MAGIc_ 
    5 <font color='#0000FF'>#define</font> DLIB_WINDOWS_MAGIc_ 
    6 
    7 <font color='#0000FF'>#include</font> "<a style='text-decoration:none' href='platform.h.html'>platform.h</a>"
    8 
    9 <font color='#0000FF'>#ifdef</font> WIN32
   10 
   11 <font color='#009900'>// This file contains all the magical #defines you have to setup  before you
   12 </font><font color='#009900'>// include the windows header files.  
   13 </font>
   14 <font color='#0000FF'>#ifndef</font> NOMINMAX
   15 <font color='#0000FF'>#define</font> NOMINMAX <font color='#009900'>// prevent windows from messing with std::min and std::max
   16 </font><font color='#0000FF'>#endif</font>
   17 
   18 <font color='#009900'>// Prevent windows from #defining IN or OUT
   19 </font><font color='#0000FF'>#ifndef</font> _NO_W32_PSEUDO_MODIFIERS
   20 <font color='#0000FF'>#define</font> _NO_W32_PSEUDO_MODIFIERS
   21 <font color='#0000FF'>#endif</font>
   22 
   23 <font color='#009900'>// now just for good measure undefine min and max if they are defined
   24 </font><font color='#0000FF'>#ifdef</font> min
   25 <font color='#0000FF'>#undef</font> min
   26 <font color='#0000FF'>#endif</font>
   27 
   28 <font color='#0000FF'>#ifdef</font> max 
   29 <font color='#0000FF'>#undef</font> max 
   30 <font color='#0000FF'>#endif</font>
   31 
   32 <font color='#0000FF'>#ifdef</font> NO_MAKEFILE
   33 <font color='#009900'>// only define this if all the cpp files are going to be sucked into the headers 
   34 </font><font color='#009900'>// because otherwise we don't need it since everything is isolated in the sockets
   35 </font><font color='#009900'>// cpp file and this declaration for _WINSOCKAPI_ appears there also.
   36 </font><font color='#0000FF'>#ifndef</font> _WINSOCKAPI_
   37 <font color='#0000FF'>#define</font> _WINSOCKAPI_   <font color='#009900'>/* Prevent inclusion of winsock.h in windows.h */</font>
   38 <font color='#0000FF'>#endif</font>
   39 <font color='#0000FF'>#endif</font>
   40 
   41 <font color='#009900'>// This is something stupid you have to do to make visual studio include the right
   42 </font><font color='#009900'>// stuff.  I don't really know what the deal is with this.
   43 </font><font color='#0000FF'>#if</font> _WIN32_WINNT <font color='#5555FF'>&lt;</font> <font color='#979000'>0x0500</font>
   44 <font color='#0000FF'>#undef</font> _WIN32_WINNT
   45 <font color='#0000FF'>#define</font> _WIN32_WINNT <font color='#979000'>0x0500</font>
   46 <font color='#0000FF'>#endif</font>
   47 
   48 <font color='#0000FF'>#endif</font> <font color='#009900'>// WIN32
   49 </font>
   50 <font color='#0000FF'>#endif</font> <font color='#009900'>// DLIB_WINDOWS_MAGIc_
   51 </font>
   52 
   53 </pre></body></html>