Changeset 23

Show
Ignore:
Timestamp:
02/18/08 18:21:35 (7 months ago)
Author:
Chris Miller
Message:

Better Tangobos support.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/win32/dfl/application.d

    r7 r23  
    128128    MENU_092 = 0x1, // Adding to menus is the old way. 
    129129    CONTROL_RECREATE_095 = 0x2, // Controls don't recreate automatically when necessary. 
    130     CONTROL_KEYEVENT_096 = 0x4, // Key events don't propagate up the control hierarchy when they are not handled
     130    CONTROL_KEYEVENT_096 = 0x4, // Nothing
    131131    FORM_DIALOGRESULT_096 = 0x8, // When a Form is in showDialog, changing the dialogResult from NONE doesn't close the form. 
    132132} 
  • trunk/win32/dfl/internal/_stdcwindows.d

    r5 r23  
    138138} 
    139139 
    140 WORD HIWORD(int l) { return cast(WORD)((l >> 16) & 0xFFFF); } 
    141 WORD LOWORD(int l) { return cast(WORD)l; } 
    142 int FAILED(int status) { return status < 0; } 
    143 int SUCCEEDED(int Status) { return Status >= 0; } 
     140extern(D) // These are macros anyway. 
     141
     142    WORD HIWORD(int l) { return cast(WORD)((l >> 16) & 0xFFFF); } 
     143    WORD LOWORD(int l) { return cast(WORD)l; } 
     144    int FAILED(int status) { return status < 0; } 
     145    int SUCCEEDED(int Status) { return Status >= 0; } 
     146
    144147 
    145148enum : int 
     
    242245} 
    243246 
    244 const DWORD MAILSLOT_NO_MESSAGE = cast(DWORD)-1; 
    245 const DWORD MAILSLOT_WAIT_FOREVER = cast(DWORD)-1;  
     247extern(D) 
     248
     249    const DWORD MAILSLOT_NO_MESSAGE = cast(DWORD)-1; 
     250    const DWORD MAILSLOT_WAIT_FOREVER = cast(DWORD)-1;  
     251
    246252 
    247253enum : uint 
     
    266272} 
    267273 
    268 const HANDLE INVALID_HANDLE_VALUE = cast(HANDLE)-1; 
    269 const DWORD INVALID_SET_FILE_POINTER = cast(DWORD)-1; 
    270 const DWORD INVALID_FILE_SIZE = cast(DWORD)0xFFFFFFFF; 
     274extern(D) 
     275
     276    const HANDLE INVALID_HANDLE_VALUE = cast(HANDLE)-1; 
     277    const DWORD INVALID_SET_FILE_POINTER = cast(DWORD)-1; 
     278    const DWORD INVALID_FILE_SIZE = cast(DWORD)0xFFFFFFFF; 
     279
    271280 
    272281struct OVERLAPPED { 
     
    420429// 
    421430 
    422 const int REG_CREATED_NEW_KEY =         0x00000001;   // New Registry Key created 
    423 const int REG_OPENED_EXISTING_KEY =     0x00000002;   // Existing Key opened 
     431extern(D) 
     432
     433    const int REG_CREATED_NEW_KEY =         0x00000001;   // New Registry Key created 
     434    const int REG_OPENED_EXISTING_KEY =     0x00000002;   // Existing Key opened 
     435
    424436 
    425437 
     
    509521int MessageBoxExA(HWND hWnd, LPCSTR lpText, LPCSTR lpCaption, UINT uType, WORD wLanguageId); 
    510522 
    511 const HKEY HKEY_CLASSES_ROOT =           cast(HKEY)(0x80000000); 
    512 const HKEY HKEY_CURRENT_USER =           cast(HKEY)(0x80000001); 
    513 const HKEY HKEY_LOCAL_MACHINE =          cast(HKEY)(0x80000002); 
    514 const HKEY HKEY_USERS =                  cast(HKEY)(0x80000003); 
    515 const HKEY HKEY_PERFORMANCE_DATA =       cast(HKEY)(0x80000004); 
    516  
    517 const HKEY HKEY_CURRENT_CONFIG =         cast(HKEY)(0x80000005); 
    518 const HKEY HKEY_DYN_DATA =               cast(HKEY)(0x80000006); 
     523extern(D) 
     524
     525    const HKEY HKEY_CLASSES_ROOT =           cast(HKEY)(0x80000000); 
     526    const HKEY HKEY_CURRENT_USER =           cast(HKEY)(0x80000001); 
     527    const HKEY HKEY_LOCAL_MACHINE =          cast(HKEY)(0x80000002); 
     528    const HKEY HKEY_USERS =                  cast(HKEY)(0x80000003); 
     529    const HKEY HKEY_PERFORMANCE_DATA =       cast(HKEY)(0x80000004); 
     530 
     531    const HKEY HKEY_CURRENT_CONFIG =         cast(HKEY)(0x80000005); 
     532    const HKEY HKEY_DYN_DATA =               cast(HKEY)(0x80000006); 
     533
    519534 
    520535enum 
     
    20222037} 
    20232038 
    2024 const LPSTR IDI_APPLICATION =     cast(LPSTR)(32512); 
    2025  
    2026 const LPSTR IDC_ARROW =           cast(LPSTR)(32512); 
    2027 const LPSTR IDC_CROSS =           cast(LPSTR)(32515); 
     2039extern(D) 
     2040
     2041    const LPSTR IDI_APPLICATION =     cast(LPSTR)(32512); 
     2042 
     2043    const LPSTR IDC_ARROW =           cast(LPSTR)(32512); 
     2044    const LPSTR IDC_CROSS =           cast(LPSTR)(32515); 
     2045
    20282046 
    20292047/* 
     
    20772095} 
    20782096 
    2079 const int CW_USEDEFAULT = cast(int)0x80000000; 
    2080 /* 
    2081  * Special value for CreateWindow, et al. 
    2082  */ 
    2083 const HWND HWND_DESKTOP = (cast(HWND)0); 
     2097extern(D) 
     2098
     2099    const int CW_USEDEFAULT = cast(int)0x80000000; 
     2100    /* 
     2101     * Special value for CreateWindow, et al. 
     2102     */ 
     2103    const HWND HWND_DESKTOP = (cast(HWND)0); 
     2104
    20842105 
    20852106 
     
    21012122 
    21022123 
     2124/+ 
    21032125HWND CreateWindowA( 
    21042126     LPCSTR lpClassName, 
     
    21162138     return CreateWindowExA(0, lpClassName, lpWindowName, dwStyle, X, Y, nWidth, nHeight, hWndParent, hMenu, hInstance, lpParam); 
    21172139} 
     2140+/ 
     2141HWND CreateWindowA( 
     2142     LPCSTR lpClassName, 
     2143     LPCSTR lpWindowName, 
     2144     DWORD dwStyle, 
     2145     int X, 
     2146     int Y, 
     2147     int nWidth, 
     2148     int nHeight, 
     2149     HWND hWndParent , 
     2150     HMENU hMenu, 
     2151     HINSTANCE hInstance, 
     2152     LPVOID lpParam); 
     2153 
    21182154 
    21192155/* 
     
    25162552export HBITMAP LoadBitmapW(HINSTANCE hInstance, LPCWSTR lpBitmapName); 
    25172553 
    2518 LPSTR MAKEINTRESOURCEA(int i) { return cast(LPSTR)(cast(DWORD)(cast(WORD)(i))); } 
     2554extern(D) // This is a macro anyway 
     2555    LPSTR MAKEINTRESOURCEA(int i) { return cast(LPSTR)(cast(DWORD)(cast(WORD)(i))); } 
    25192556 
    25202557export  HFONT     CreateFontIndirectA(LOGFONTA *); 
     
    26722709export  BOOL      CreateScalableFontResourceW(DWORD, LPCWSTR, LPCWSTR, LPCWSTR); 
    26732710 
     2711extern(D) // This is a macro anyway. 
    26742712COLORREF RGB(int r, int g, int b) 
    26752713{ 
     
    27072745export int wsprintfW(LPWSTR, LPCWSTR, ...); 
    27082746 
    2709 const uint INFINITE = uint.max; 
    2710 const uint WAIT_OBJECT_0 = 0; 
     2747extern(D) 
     2748
     2749    const uint INFINITE = uint.max; 
     2750    const uint WAIT_OBJECT_0 = 0; 
     2751
    27112752 
    27122753export HANDLE CreateSemaphoreA(LPSECURITY_ATTRIBUTES lpSemaphoreAttributes, LONG lInitialCount, LONG lMaximumCount, LPCTSTR lpName);