Changeset 10376 for trunk/src


Ignore:
Timestamp:
Jan 11, 2004, 12:52:18 PM (22 years ago)
Author:
sandervl
Message:

memory map functions for dib section code

Location:
trunk/src/kernel32
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/mmap.h

    r10357 r10376  
    1 /* $Id: mmap.h,v 1.30 2003-12-12 11:09:37 sandervl Exp $ */
     1/* $Id: mmap.h,v 1.31 2004-01-11 11:52:18 sandervl Exp $ */
    22
    33/*
     
    4646    PAGEVIEW_GUARD
    4747} PAGEVIEW;
     48
     49#ifndef _DEF_PFNEXCEPTIONNOTIFY
     50#define _DEF_PFNEXCEPTIONNOTIFY
     51typedef BOOL (WIN32API * PFNEXCEPTIONNOTIFY)(LPVOID lpBase, ULONG offset, BOOL fWriteAccess, DWORD dwSize, DWORD dwUserData);
     52#endif
    4853
    4954class Win32MemMapView;
     
    247252};
    248253//******************************************************************************
     254//Notification memory mapped file Class
     255//******************************************************************************
     256class Win32MemMapNotify
     257{
     258public:
     259   Win32MemMapNotify(PFNEXCEPTIONNOTIFY pfnNotify, LPVOID lpViewaddr, ULONG size, ULONG dwUserData);
     260  ~Win32MemMapNotify();
     261
     262   LPVOID getViewAddr()                  { return pMapView; };
     263   DWORD  getSize()                      { return mSize;    };
     264   DWORD  getUserData()                  { return dwUserData; };
     265
     266   BOOL   notify(ULONG ulFaultAddr, ULONG offset, BOOL fWriteAccess);
     267
     268static Win32MemMapNotify *findMapByView(ULONG address,
     269                                        ULONG *offset,
     270                                        ULONG accessType);
     271static Win32MemMapNotify *findView(ULONG address);
     272
     273
     274protected:
     275   ULONG  mSize, dwUserData;
     276   LPVOID pMapView;
     277   PFNEXCEPTIONNOTIFY pfnNotify;
     278
     279private:
     280   static Win32MemMapNotify *mapviews;
     281          Win32MemMapNotify *next;
     282};
     283//******************************************************************************
    249284//******************************************************************************
    250285
     
    254289
    255290void InitializeMemMaps();
     291void FinalizeMemMaps();
    256292
    257293#endif //__MMAP_H__
Note: See TracChangeset for help on using the changeset viewer.