ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
January 2011
----- 2024 -----
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
20 participants
336 discussions
Start a n
N
ew thread
[tkreuzer] 50314: [CRT] Fix _flsbuf return value
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Fri Jan 7 21:15:35 2011 New Revision: 50314 URL:
http://svn.reactos.org/svn/reactos?rev=50314&view=rev
Log: [CRT] Fix _flsbuf return value Modified: trunk/reactos/lib/sdk/crt/stdio/_flsbuf.c Modified: trunk/reactos/lib/sdk/crt/stdio/_flsbuf.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/stdio/_flsbuf.…
============================================================================== --- trunk/reactos/lib/sdk/crt/stdio/_flsbuf.c [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/stdio/_flsbuf.c [iso-8859-1] Fri Jan 7 21:15:35 2011 @@ -78,5 +78,5 @@ return EOF; } - return (TCHAR)ch; + return ch & (sizeof(TCHAR) > sizeof(char) ? 0xffff : 0xff); }
13 years, 10 months
1
0
0
0
[fireball] 50313: - Move windowing code to window.c. - Add proper code structure for creating client windows too, and fix other places so they would be ready for a newer window manager interface. -...
by fireball@svn.reactos.org
Author: fireball Date: Fri Jan 7 20:50:13 2011 New Revision: 50313 URL:
http://svn.reactos.org/svn/reactos?rev=50313&view=rev
Log: - Move windowing code to window.c. - Add proper code structure for creating client windows too, and fix other places so they would be ready for a newer window manager interface. - Slightly cleanup file headers, and state that some code is based on Wine. - Add some experimental event code, which is #if0ed for now. Added: branches/arwinss/reactos/dll/win32/winent.drv/event.c (with props) Modified: branches/arwinss/reactos/dll/win32/winent.drv/font.c branches/arwinss/reactos/dll/win32/winent.drv/graphics.c branches/arwinss/reactos/dll/win32/winent.drv/userdrv.c branches/arwinss/reactos/dll/win32/winent.drv/window.c branches/arwinss/reactos/dll/win32/winent.drv/winent.h branches/arwinss/reactos/dll/win32/winent.drv/winent.rbuild Added: branches/arwinss/reactos/dll/win32/winent.drv/event.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/event.c (added) +++ branches/arwinss/reactos/dll/win32/winent.drv/event.c [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -1,0 +1,272 @@ +/* + * PROJECT: ReactOS + * LICENSE: GNU LGPL by FSF v2.1 or any later + * FILE: dll/win32/winent.drv/event.c + * PURPOSE: Event handling routines + * PROGRAMMERS: Aleksey Bragin (aleksey(a)reactos.org) + * Some parts inspired by Wine's winex11.drv + */ + +/* INCLUDES ***************************************************************/ + +#include "winent.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(event); +#if 0 +/* GLOBALS ****************************************************************/ + +static void NTDRV_Expose( HWND hwnd, GR_EVENT *event ); + +struct event_handler +{ + GR_EVENT_TYPE type; /* event type */ + ntdrv_event_handler handler; /* corresponding handler function */ +}; + +#define MAX_EVENT_HANDLERS 64 + +static struct event_handler handlers[MAX_EVENT_HANDLERS] = +{ + /* list must be sorted by event type */ + //{ KeyPress, X11DRV_KeyEvent }, + //{ KeyRelease, X11DRV_KeyEvent }, + //{ ButtonPress, X11DRV_ButtonPress }, + //{ ButtonRelease, X11DRV_ButtonRelease }, + //{ MotionNotify, X11DRV_MotionNotify }, + //{ EnterNotify, X11DRV_EnterNotify }, + /* LeaveNotify */ + //{ FocusIn, X11DRV_FocusIn }, + //{ FocusOut, X11DRV_FocusOut }, + //{ KeymapNotify, X11DRV_KeymapNotify }, + { GR_EVENT_TYPE_EXPOSURE, NTDRV_Expose }, + /* GraphicsExpose */ + /* NoExpose */ + /* VisibilityNotify */ + /* CreateNotify */ + //{ DestroyNotify, X11DRV_DestroyNotify }, + /* UnmapNotify */ + //{ MapNotify, X11DRV_MapNotify }, + /* MapRequest */ + //{ ReparentNotify, X11DRV_ReparentNotify }, + //{ ConfigureNotify, X11DRV_ConfigureNotify }, + /* ConfigureRequest */ + //{ GravityNotify, X11DRV_GravityNotify }, + /* ResizeRequest */ + /* CirculateNotify */ + /* CirculateRequest */ + //{ PropertyNotify, X11DRV_PropertyNotify }, + //{ SelectionClear, X11DRV_SelectionClear }, + //{ SelectionRequest, X11DRV_SelectionRequest }, + /* SelectionNotify */ + /* ColormapNotify */ + //{ ClientMessage, X11DRV_ClientMessage }, + //{ MappingNotify, X11DRV_MappingNotify }, +}; + +static int nb_event_handlers = 1; /* change this if you add handlers above */ + +/* FUNCTIONS **************************************************************/ + +/*********************************************************************** + * find_handler + * + * Find the handler for a given event type. Caller must hold the x11 lock. + */ +static inline ntdrv_event_handler find_handler( GR_EVENT_TYPE type ) +{ + int min = 0, max = nb_event_handlers - 1; + + while (min <= max) + { + int pos = (min + max) / 2; + if (handlers[pos].type == type) return handlers[pos].handler; + if (handlers[pos].type > type) max = pos - 1; + else min = pos + 1; + } + return NULL; +} + +enum event_merge_action +{ + MERGE_DISCARD, /* discard the old event */ + MERGE_HANDLE, /* handle the old event */ + MERGE_KEEP /* keep the old event for future merging */ +}; + +/*********************************************************************** + * merge_events + * + * Try to merge 2 consecutive events. + */ +#if 0 +static enum event_merge_action merge_events( GR_EVENT *prev, GR_EVENT *next ) +{ + switch (prev->type) + { + case GR_UPDATE_MOVE: + switch (next->type) + { + case GR_UPDATE_MOVE: + if (prev->wid == next->wid) + { + TRACE( "discarding duplicate ConfigureNotify for window %lx\n", prev->wid ); + return MERGE_DISCARD; + } + break; + case GR_EVENT_MASK_EXPOSURE: + //case PropertyNotify: + return MERGE_KEEP; + } + break; + case GR_EVENT_MASK_MOUSE_MOTION: + if (prev->wid == next->wid && next->type == MotionNotify) + { + TRACE( "discarding duplicate MotionNotify for window %lx\n", prev->wid ); + return MERGE_DISCARD; + }xch + break; + } + + return MERGE_HANDLE; +} +#endif + + +/*********************************************************************** + * call_event_handler + */ +static inline void call_event_handler( GR_EVENT *event ) +{ + HWND hwnd; + ntdrv_event_handler handler; + //GR_EVENT *prev; + //struct ntdrv_thread_data *thread_data; + + if (!(handler = find_handler( event->type ))) + { + TRACE( "%s for win %lx, ignoring\n", "event", -1 ); + return; /* no handler, ignore it */ + } + + hwnd = GrGetHwnd( event->general.wid ); + //if (!hwnd && event->xany.window == root_window) hwnd = GetDesktopWindow(); + + //TRACE( "%lu %s for hwnd/window %p/%lx\n", + // event->xany.serial, dbgstr_event( event->type ), hwnd, event->xany.window ); + //wine_tsx11_unlock(); + //thread_data = ntdrv_thread_data(); + //prev = thread_data->current_event; + //thread_data->current_event = event; + handler( hwnd, event ); + //thread_data->current_event = prev; + //wine_tsx11_lock(); +} + +/*********************************************************************** + * process_events + */ +static int process_events( int mask ) +{ + GR_EVENT event;//, prev_event; + int count = 0; + //enum event_merge_action action = MERGE_DISCARD; + + //prev_event.type = 0; + //wine_tsx11_lock(); + while (GrPeekEvent(&event)) + { + GrGetNextEvent(&event); + ERR("Got event type %d\n", event.type); + count++; +#if 0 + if (prev_event.type) action = merge_events( &prev_event, &event ); + switch( action ) + { + case MERGE_DISCARD: /* discard prev, keep new */ + prev_event = event; + break; + case MERGE_HANDLE: /* handle prev, keep new */ + call_event_handler( display, &prev_event ); + prev_event = event; + break; + case MERGE_KEEP: /* handle new, keep prev for future merging */ + call_event_handler( display, &event ); + break; + } +#else + call_event_handler( &event ); +#endif + } + //if (prev_event.type) call_event_handler( &prev_event ); + //XFlush( gdi_display ); + //wine_tsx11_unlock(); + if (count) TRACE( "processed %d events\n", count ); + return count; +} +#endif + +/*********************************************************************** + * MsgWaitForMultipleObjectsEx (NTDRV.@) + */ +DWORD CDECL RosDrv_MsgWaitForMultipleObjectsEx( DWORD count, const HANDLE *handles, DWORD timeout, + DWORD mask, DWORD flags ) +{ + //TRACE("WaitForMultipleObjectsEx(%d %p %d %x %x %x\n", count, handles, timeout, mask, flags); + + if (!count && !timeout) return WAIT_TIMEOUT; + return WaitForMultipleObjectsEx( count, handles, flags & MWMO_WAITALL, + timeout, flags & MWMO_ALERTABLE ); +} + +#if 0 +/*********************************************************************** + * X11DRV_Expose + */ +static void NTDRV_Expose( HWND hwnd, GR_EVENT *xev ) +{ + GR_EVENT_EXPOSURE *event = &xev->exposure; + RECT rect; + struct ntdrv_win_data *data; + int flags = RDW_INVALIDATE | RDW_ERASE; + + ERR( "win %p (%lx) %d,%d %dx%d\n", + hwnd, event->wid, event->x, event->y, event->width, event->height ); + + if (!(data = NTDRV_get_win_data( hwnd ))) return; + + rect.left = event->x; + rect.top = event->y; + rect.right = event->x + event->width; + rect.bottom = event->y + event->height; + if (event->wid == data->whole_window) + { + OffsetRect( &rect, data->whole_rect.left - data->client_rect.left, + data->whole_rect.top - data->client_rect.top ); + flags |= RDW_FRAME; + } + + //if (event->wid != root_window) + { + if (GetWindowLongW( data->hwnd, GWL_EXSTYLE ) & WS_EX_LAYOUTRTL) + mirror_rect( &data->client_rect, &rect ); + + SERVER_START_REQ( update_window_zorder ) + { + req->window = wine_server_user_handle( hwnd ); + req->rect.left = rect.left; + req->rect.top = rect.top; + req->rect.right = rect.right; + req->rect.bottom = rect.bottom; + wine_server_call( req ); + } + SERVER_END_REQ; + + flags |= RDW_ALLCHILDREN; + } + //else OffsetRect( &rect, virtual_screen_rect.left, virtual_screen_rect.top ); + + RedrawWindow( hwnd, &rect, 0, flags ); +} +#endif +/* EOF */ Propchange: branches/arwinss/reactos/dll/win32/winent.drv/event.c ------------------------------------------------------------------------------ svn:eol-style = native Modified: branches/arwinss/reactos/dll/win32/winent.drv/font.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/font.c [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/winent.drv/font.c [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -4,6 +4,7 @@ * FILE: dll/win32/winent.drv/font.c * PURPOSE: Font Engine support functions * PROGRAMMERS: Aleksey Bragin (aleksey(a)reactos.org) + * Some code is taken from winex11.drv (c) Wine project */ /* INCLUDES ***************************************************************/ Modified: branches/arwinss/reactos/dll/win32/winent.drv/graphics.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/graphics.c [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/winent.drv/graphics.c [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -4,6 +4,7 @@ * FILE: dll/win32/winent.drv/graphics.c * PURPOSE: GDI high-level driver for ReactOS/Windows * PROGRAMMERS: Aleksey Bragin (aleksey(a)reactos.org) + * Some code is taken from winex11.drv (c) Wine project */ /* INCLUDES ***************************************************************/ Modified: branches/arwinss/reactos/dll/win32/winent.drv/userdrv.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/userdrv.c [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/winent.drv/userdrv.c [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -14,61 +14,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(rosuserdrv); /* FUNCTIONS **************************************************************/ - -/*********************************************************************** - * move_window_bits - * - * Move the window bits when a window is moved. - */ -void move_window_bits( struct ntdrv_win_data *data, const RECT *old_rect, const RECT *new_rect, - const RECT *old_client_rect ) -{ - RECT src_rect = *old_rect; - RECT dst_rect = *new_rect; - HDC hdc_src, hdc_dst; - HRGN rgn = 0; - HWND parent = 0; - - if (!data->whole_window) - { - OffsetRect( &dst_rect, -data->window_rect.left, -data->window_rect.top ); - parent = GetAncestor( data->hwnd, GA_PARENT ); - hdc_src = GetDCEx( parent, 0, DCX_CACHE ); - hdc_dst = GetDCEx( data->hwnd, 0, DCX_CACHE | DCX_WINDOW ); - } - else - { - OffsetRect( &dst_rect, -data->client_rect.left, -data->client_rect.top ); - /* make src rect relative to the old position of the window */ - OffsetRect( &src_rect, -old_client_rect->left, -old_client_rect->top ); - if (dst_rect.left == src_rect.left && dst_rect.top == src_rect.top) return; - hdc_src = hdc_dst = GetDCEx( data->hwnd, 0, DCX_CACHE ); - } - - TRACE( "copying bits for win %p (parent %p)/ %s -> %s\n", - data->hwnd, parent, - wine_dbgstr_rect(&src_rect), wine_dbgstr_rect(&dst_rect) ); - BitBlt( hdc_dst, dst_rect.left, dst_rect.top, - dst_rect.right - dst_rect.left, dst_rect.bottom - dst_rect.top, - hdc_src, src_rect.left, src_rect.top, SRCCOPY ); - - ReleaseDC( data->hwnd, hdc_dst ); - if (hdc_src != hdc_dst) ReleaseDC( parent, hdc_src ); - - if (rgn) - { - if (!data->whole_window) - { - /* map region to client rect since we are using DCX_WINDOW */ - OffsetRgn( rgn, data->window_rect.left - data->client_rect.left, - data->window_rect.top - data->client_rect.top ); - RedrawWindow( data->hwnd, NULL, rgn, - RDW_INVALIDATE | RDW_FRAME | RDW_ERASE | RDW_ALLCHILDREN ); - } - else RedrawWindow( data->hwnd, NULL, rgn, RDW_INVALIDATE | RDW_ERASE | RDW_ALLCHILDREN ); - DeleteObject( rgn ); - } -} HKL CDECL RosDrv_ActivateKeyboardLayout( HKL layout, UINT flags ) { @@ -283,180 +228,10 @@ return RosUserGetMonitorInfo(handle, info); } -BOOL CDECL RosDrv_CreateDesktopWindow( HWND hwnd ) -{ - unsigned int width, height; - - /* retrieve the real size of the desktop */ - SERVER_START_REQ( get_window_rectangles ) - { - req->handle = wine_server_user_handle( hwnd ); - wine_server_call( req ); - width = reply->window.right - reply->window.left; - height = reply->window.bottom - reply->window.top; - } - SERVER_END_REQ; - - TRACE("RosDrv_CreateDesktopWindow(%x), w %d h %d\n", hwnd, width, height); - - SwmAddDesktopWindow(hwnd, width, height); - - if (!width && !height) /* not initialized yet */ - { - SERVER_START_REQ( set_window_pos ) - { - req->handle = wine_server_user_handle( hwnd ); - req->previous = 0; - req->flags = SWP_NOZORDER; - req->window.left = 0; - req->window.top = 0; - req->window.right = GetSystemMetrics(SM_CXVIRTUALSCREEN); - req->window.bottom = GetSystemMetrics(SM_CYVIRTUALSCREEN); - req->client = req->window; - wine_server_call( req ); - } - SERVER_END_REQ; - } - - return TRUE; -} - -BOOL CDECL RosDrv_CreateWindow( HWND hwnd ) -{ - WARN("RosDrv_CreateWindow(%x)\n", hwnd); - - if (hwnd == GetDesktopWindow()) - { - /* create desktop win data */ - if (!NTDRV_create_desktop_win_data( hwnd )) return FALSE; - } - - return TRUE; -} - void CDECL RosDrv_DestroyWindow( HWND hwnd ) { /* Destroy its window data */ NTDRV_destroy_win_data( hwnd ); -} - -void CDECL RosDrv_GetDC( HDC hdc, HWND hwnd, HWND top, const RECT *win_rect, - const RECT *top_rect, DWORD flags ) -{ - struct ntdrv_escape_set_drawable escape; - struct ntdrv_win_data *data = NTDRV_get_win_data( hwnd ); - //HWND parent; - - escape.code = NTDRV_SET_DRAWABLE; - escape.clip_children = FALSE; - escape.gl_copy = FALSE; - escape.hwnd = 0; - escape.release = FALSE; - - escape.dc_rect.left = win_rect->left - top_rect->left; - escape.dc_rect.top = win_rect->top - top_rect->top; - escape.dc_rect.right = win_rect->right - top_rect->left; - escape.dc_rect.bottom = win_rect->bottom - top_rect->top; - escape.drawable_rect.left = top_rect->left; - escape.drawable_rect.top = top_rect->top; - escape.drawable_rect.right = top_rect->right; - escape.drawable_rect.bottom = top_rect->bottom; - - if (top == hwnd) - { - //if (flags & DCX_WINDOW) - { - if (data) - { - /* SWM window already exists */ - escape.hwnd = hwnd; - } - else - { - /* There is no SWM window for this hwnd. - If this is desktop, it's fine otherwise reject any drawing operations */ - if (hwnd == GetDesktopWindow()) - escape.hwnd = hwnd; - else - escape.hwnd = 0; - } - } - } - else - { -#if 0 - /* find the first ancestor that has a drawable */ - if (data) escape.hwnd = hwnd; - - for (parent = hwnd; parent && parent != top; parent = GetAncestor( parent, GA_PARENT )) - { - data = NTDRV_get_win_data( parent ); - if (data) - { - escape.hwnd = parent; - break; - } - } -FIXME("Found hwnd %x backed by an SWM window\n", escape.hwnd); - if (escape.hwnd) - { - POINT pt = { 0, 0 }; - MapWindowPoints( top, parent, &pt, 1 ); - //OffsetRect( &escape.dc_rect, pt.x, pt.y ); - //OffsetRect( &escape.drawable_rect, -pt.x, -pt.y ); - - FIXME("Offset by (%d, %d)\n", pt.x, pt.y); - } - else - { - if (NTDRV_get_win_data(top) || (top == GetDesktopWindow())) - { - /* SWM window already exists */ - escape.hwnd = top; - } - } -#else - escape.hwnd = GetAncestor(hwnd, GA_ROOT); -#endif - - if (flags & DCX_CLIPCHILDREN) escape.clip_children = TRUE; - } - - TRACE("hdc %x, hwnd %x, top %x\n win_rect %s, top_rect %s\n", hdc, hwnd, top, - wine_dbgstr_rect(win_rect), wine_dbgstr_rect(top_rect)); - - ExtEscape( hdc, NTDRV_ESCAPE, sizeof(escape), (LPSTR)&escape, 0, NULL ); -} - -DWORD CDECL RosDrv_MsgWaitForMultipleObjectsEx( DWORD count, const HANDLE *handles, DWORD timeout, - DWORD mask, DWORD flags ) -{ - //TRACE("WaitForMultipleObjectsEx(%d %p %d %x %x %x\n", count, handles, timeout, mask, flags); - - if (!count && !timeout) return WAIT_TIMEOUT; - return WaitForMultipleObjectsEx( count, handles, flags & MWMO_WAITALL, - timeout, flags & MWMO_ALERTABLE ); -} - -void CDECL RosDrv_ReleaseDC( HWND hwnd, HDC hdc ) -{ - struct ntdrv_escape_set_drawable escape; - - escape.code = NTDRV_SET_DRAWABLE; - escape.gl_copy = FALSE; - escape.hwnd = hwnd; - escape.release = TRUE; - - escape.dc_rect.left = 0; - escape.dc_rect.top = 0; - escape.dc_rect.right = 0; - escape.dc_rect.bottom = 0; - escape.drawable_rect.left = 0; - escape.drawable_rect.top = 0; - escape.drawable_rect.right = GetSystemMetrics(SM_CXVIRTUALSCREEN); - escape.drawable_rect.bottom = GetSystemMetrics(SM_CYVIRTUALSCREEN); - - ExtEscape( hdc, NTDRV_ESCAPE, sizeof(escape), (LPSTR)&escape, 0, NULL ); } /* @@ -597,21 +372,6 @@ return TRUE; } -void CDECL RosDrv_SetCapture( HWND hwnd, UINT flags ) -{ - if (!(flags & (GUI_INMOVESIZE | GUI_INMENUMODE))) return; - - if (hwnd) - { - /* Capturing */ - TRACE("Capture set for hwnd %x\n", hwnd); - } - else - { - TRACE("Capture released\n"); - } -} - /******************************************************************* * can_activate_window * @@ -628,48 +388,9 @@ return !(style & WS_DISABLED); }*/ -void CDECL RosDrv_SetFocus( HWND hwnd ) -{ - struct ntdrv_win_data *data; - - if (!(hwnd = GetAncestor( hwnd, GA_ROOT ))) return; - if (!(data = NTDRV_get_win_data( hwnd ))) return; - if (!data->whole_window) return; - - TRACE("SetFocus %x, desk %x\n", hwnd, GetDesktopWindow()); - - /* Bring this window to foreground */ - SwmSetForeground(hwnd); -} - void CDECL RosDrv_SetLayeredWindowAttributes( HWND hwnd, COLORREF key, BYTE alpha, DWORD flags ) { UNIMPLEMENTED; -} - -void CDECL RosDrv_SetParent( HWND hwnd, HWND parent, HWND old_parent ) -{ - struct ntdrv_win_data *data = NTDRV_get_win_data( hwnd ); - - if (!data) return; - if (parent == old_parent) return; - - if (parent != GetDesktopWindow()) /* a child window */ - { - if (old_parent == GetDesktopWindow()) - { - /* destroy the old windows */ - //destroy_whole_window( data, FALSE ); - //destroy_icon_window( data ); - FIXME("Should destroy hwnd %x\n", data->hwnd); - } - } - else /* new top level window */ - { - /* FIXME: we ignore errors since we can't really recover anyway */ - //create_whole_window( data ); - FIXME("Should create a new whole window for hwnd %x\n", data->hwnd); - } } int CDECL RosDrv_SetWindowRgn( HWND hwnd, HRGN hrgn, BOOL redraw ) @@ -757,107 +478,4 @@ } } -void CDECL RosDrv_WindowPosChanging( HWND hwnd, HWND insert_after, UINT swp_flags, - const RECT *window_rect, const RECT *client_rect, - RECT *visible_rect ) -{ - DWORD style = GetWindowLongW( hwnd, GWL_STYLE ); - struct ntdrv_win_data *data = NTDRV_get_win_data(hwnd); - - if (!data) - { - /* create the win data if the window is being made visible */ - if (!(style & WS_VISIBLE) && !(swp_flags & SWP_SHOWWINDOW)) return; - if (!(data = NTDRV_create_win_data( hwnd ))) return; - } - - SwmPosChanging(hwnd, window_rect); - - //TRACE( "win %x pos is changing. vis rect %s, win rect %s\n", - // hwnd, wine_dbgstr_rect(visible_rect), wine_dbgstr_rect(window_rect) ); - - *visible_rect = *window_rect; -} - -void CDECL RosDrv_WindowPosChanged( HWND hwnd, HWND insert_after, UINT swp_flags, - const RECT *window_rect, const RECT *rectClient, - const RECT *visible_rect, const RECT *valid_rects ) -{ - RECT old_whole_rect, old_client_rect, old_window_rect; - struct ntdrv_win_data *data = NTDRV_get_win_data(hwnd); - DWORD new_style = GetWindowLongW( hwnd, GWL_STYLE ); - - if (!data) return; - - TRACE( "win %x pos changed. new vis rect %s, old whole rect %s, swp_flags %x insert_after %x\n", - hwnd, wine_dbgstr_rect(visible_rect), wine_dbgstr_rect(&data->whole_rect), swp_flags, insert_after ); - - old_window_rect = data->window_rect; - old_whole_rect = data->whole_rect; - old_client_rect = data->client_rect; - data->window_rect = *window_rect; - data->whole_rect = *visible_rect; - data->client_rect = *rectClient; - - if (!IsRectEmpty( &valid_rects[0] )) - { - int x_offset = old_whole_rect.left - data->whole_rect.left; - int y_offset = old_whole_rect.top - data->whole_rect.top; - - /* if all that happened is that the whole window moved, copy everything */ - if (!(swp_flags & SWP_FRAMECHANGED) && - old_whole_rect.right - data->whole_rect.right == x_offset && - old_whole_rect.bottom - data->whole_rect.bottom == y_offset && - old_client_rect.left - data->client_rect.left == x_offset && - old_client_rect.right - data->client_rect.right == x_offset && - old_client_rect.top - data->client_rect.top == y_offset && - old_client_rect.bottom - data->client_rect.bottom == y_offset && - !memcmp( &valid_rects[0], &data->client_rect, sizeof(RECT) )) - { - /* if we have an SWM window the bits will be moved by the SWM */ - if (!data->whole_window) - move_window_bits( data, &old_whole_rect, &data->whole_rect, &old_client_rect ); - } - else - { - move_window_bits( data, &valid_rects[1], &valid_rects[0], &old_client_rect ); - } - } - - if (!data->whole_window) return; - - /* Sync window position with the SWM */ - sync_window_position( data, swp_flags, - &old_window_rect, &old_whole_rect, &old_client_rect ); - - if (data->mapped) - { - if (((swp_flags & SWP_HIDEWINDOW) && !(new_style & WS_VISIBLE)) || - (!is_window_rect_mapped( window_rect ) && is_window_rect_mapped( &old_window_rect ))) - unmap_window( data ); - } - - /* Pass show/hide information to the window manager */ - if ((new_style & WS_VISIBLE) && - ((new_style & WS_MINIMIZE) || is_window_rect_mapped( window_rect ))) - { - //if (!data->mapped || (swp_flags & (SWP_FRAMECHANGED|SWP_STATECHANGED))) - //set_wm_hints( display, data ); - - if (!data->mapped) - { - map_window( data, new_style ); - } - else if ((swp_flags & SWP_STATECHANGED) && (!data->iconic != !(new_style & WS_MINIMIZE))) - { - data->iconic = (new_style & WS_MINIMIZE) != 0; - FIXME( "changing win %p iconic state to %u\n", data->hwnd, data->iconic ); - //if (data->iconic) - // XIconifyWindow( display, data->whole_window, DefaultScreen(display) ); - //else if (is_window_rect_mapped( rectWindow )) - // XMapWindow( display, data->whole_window ); - } - } -} - /* EOF */ Modified: branches/arwinss/reactos/dll/win32/winent.drv/window.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/window.c [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/winent.drv/window.c [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -4,6 +4,7 @@ * FILE: dll/win32/winent.drv/window.c * PURPOSE: Windows related functions * PROGRAMMERS: Aleksey Bragin (aleksey(a)reactos.org) + * Some code is taken from winex11.drv (c) Wine project */ /* INCLUDES ***************************************************************/ @@ -22,6 +23,11 @@ 0, 0, { (DWORD_PTR)(__FILE__ ": wnd_data_cs") } }; static CRITICAL_SECTION wnd_data_cs = { &critsect_debug, -1, 0, 0, 0, 0 }; + +static const char whole_window_prop[] = "__arwin_nt_whole_window"; +static const char client_window_prop[]= "__arwin_nt_client_window"; + +GR_WINDOW_ID root_window = 2; /* FUNCTIONS **************************************************************/ @@ -89,6 +95,73 @@ return item; } +/********************************************************************** + * CreateDesktopWindow (NTDRV.@) + */ +BOOL CDECL RosDrv_CreateDesktopWindow( HWND hwnd ) +{ + unsigned int width, height; + + /* retrieve the real size of the desktop */ + SERVER_START_REQ( get_window_rectangles ) + { + req->handle = wine_server_user_handle( hwnd ); + wine_server_call( req ); + width = reply->window.right - reply->window.left; + height = reply->window.bottom - reply->window.top; + } + SERVER_END_REQ; + + TRACE("RosDrv_CreateDesktopWindow(%x), w %d h %d\n", hwnd, width, height); + + SwmAddDesktopWindow(hwnd, width, height); + + if (!width && !height) /* not initialized yet */ + { + SERVER_START_REQ( set_window_pos ) + { + req->handle = wine_server_user_handle( hwnd ); + req->previous = 0; + req->flags = SWP_NOZORDER; + req->window.left = 0; + req->window.top = 0; + req->window.right = GetSystemMetrics(SM_CXVIRTUALSCREEN); + req->window.bottom = GetSystemMetrics(SM_CYVIRTUALSCREEN); + req->client = req->window; + wine_server_call( req ); + } + SERVER_END_REQ; + } + else + { + //GR_WINDOW_ID win = (GR_WINDOW_ID)GetPropA( hwnd, whole_window_prop ); + //ERR("win %p, w %d h %d, hwnd %x\n", win, width, height, hwnd); + + //if (win && win != root_window) NTDRV_init_desktop( win, width, height ); + + // create a desktop window + //GrSelectEvents(GR_ROOT_WINDOW_ID, GR_EVENT_MASK_EXPOSURE); + } + + return TRUE; +} + +/********************************************************************** + * CreateWindow (NTDRV.@) + */ +BOOL CDECL RosDrv_CreateWindow( HWND hwnd ) +{ + WARN("RosDrv_CreateWindow(%x)\n", hwnd); + + if (hwnd == GetDesktopWindow() /*&& root_window != GR_ROOT_WINDOW_ID*/) + { + /* create desktop win data */ + if (!NTDRV_create_desktop_win_data( hwnd )) return FALSE; + } + + return TRUE; +} + /*********************************************************************** * NTDRV_get_win_data * @@ -114,7 +187,6 @@ struct ntdrv_win_data *NTDRV_create_win_data( HWND hwnd ) { struct ntdrv_win_data *data; - DWORD style, ex_style; HWND parent; if (!(parent = GetAncestor( hwnd, GA_PARENT ))) return NULL; /* desktop */ @@ -133,16 +205,14 @@ if (parent == GetDesktopWindow()) { - TRACE( "win %p window %s whole %s client %s\n", - hwnd, wine_dbgstr_rect( &data->window_rect ), + if (!create_whole_window( data )) + { + HeapFree( GetProcessHeap(), 0, data ); + return NULL; + } + TRACE( "win %p/%lx/%lx window %s whole %s client %s\n", + hwnd, data->whole_window, data->client_window, wine_dbgstr_rect( &data->window_rect ), wine_dbgstr_rect( &data->whole_rect ), wine_dbgstr_rect( &data->client_rect )); - - style = GetWindowLongW( data->hwnd, GWL_STYLE ); - ex_style = GetWindowLongW( data->hwnd, GWL_EXSTYLE ); - - /* Inform window manager about window rect in screen coords */ - SwmAddWindow(hwnd, &data->window_rect, style, ex_style); - data->whole_window = (PVOID)1; } return data; @@ -157,9 +227,41 @@ if (!data) return NULL; /* Mark it as being a whole window */ - data->whole_window = (PVOID)1; + data->whole_window = data->client_window = root_window; + SetPropA( data->hwnd, whole_window_prop, (HANDLE)root_window ); + SetPropA( data->hwnd, client_window_prop, (HANDLE)root_window ); return data; +} + +/********************************************************************** + * destroy_whole_window + * + * Destroy the whole WM window for a given window. + */ +static void destroy_whole_window( struct ntdrv_win_data *data, BOOL already_destroyed ) +{ + if (!data->whole_window) return; + + TRACE( "win %p xwin %lx/%lx\n", data->hwnd, data->whole_window, data->client_window ); + //if (!already_destroyed) GrDestroyWindow( data->whole_window ); + if (!already_destroyed) SwmRemoveWindow( data->hwnd ); + data->whole_window = data->client_window = 0; + //data->wm_state = WithdrawnState; + //data->net_wm_state = 0; + data->mapped = FALSE; + /*if (data->xic) + { + XUnsetICFocus( data->xic ); + XDestroyIC( data->xic ); + data->xic = 0; + }*/ + /* Outlook stops processing messages after destroying a dialog, so we need an explicit flush */ + //XFlush( display ); + //XFree( data->wm_hints ); + //data->wm_hints = NULL; + RemovePropA( data->hwnd, whole_window_prop ); + RemovePropA( data->hwnd, client_window_prop ); } /*********************************************************************** @@ -175,8 +277,7 @@ /* Remove property and free its data */ associate_destroy( data ); - /* Inform window manager */ - SwmRemoveWindow( hwnd ); + destroy_whole_window( data, FALSE ); } /*********************************************************************** @@ -186,7 +287,9 @@ { TRACE( "win %p/%lx\n", data->hwnd, data->whole_window ); - SwmShowWindow( data->hwnd, TRUE, 0); + //sync_window_style( display, data ); + //GrMapWindow( data->whole_window ); + SwmShowWindow( data->hwnd, TRUE, 0 ); data->mapped = TRUE; data->iconic = (new_style & WS_MINIMIZE) != 0; @@ -200,10 +303,171 @@ { TRACE( "win %p/%lx\n", data->hwnd, data->whole_window ); - SwmShowWindow( data->hwnd, FALSE, 0); + //GrUnmapWindow( data->whole_window ); + SwmShowWindow( data->hwnd, FALSE, 0 ); data->mapped = FALSE; //data->net_wm_state = 0; +} + +/*********************************************************************** + * sync_window_position + * + * Synchronize the SWM window position with the Windows one + */ +void sync_window_position( struct ntdrv_win_data *data, + UINT swp_flags, const RECT *old_window_rect, + const RECT *old_whole_rect, const RECT *old_client_rect ) +{ + //DWORD style = GetWindowLongW( data->hwnd, GWL_STYLE ); + LONG width, height; + LONG x, y; + + if (data->iconic) return; + + SwmPosChanged(data->hwnd, &data->whole_rect, old_whole_rect, NULL, swp_flags); + + width = data->whole_rect.right - data->whole_rect.left; + height = data->whole_rect.bottom - data->whole_rect.top; + /* if window rect is empty force size to 1x1 */ + if (width <= 0 || height <= 0) width = height = 1; + if (width > 65535) width = 65535; + if (height > 65535) height = 65535; + + //GrResizeWindow(data->whole_window, width, height); + + /* only the size is allowed to change for the desktop window */ + if (data->whole_window != root_window) + { + x = data->whole_rect.left; + y = data->whole_rect.top; + //GrMoveWindow(data->whole_window, x, y); + } + + if (!(swp_flags & SWP_NOZORDER) || (swp_flags & SWP_SHOWWINDOW)) + { + /* find window that this one must be after */ + HWND prev = GetWindow( data->hwnd, GW_HWNDPREV ); + while (prev && !(GetWindowLongW( prev, GWL_STYLE ) & WS_VISIBLE)) + prev = GetWindow( prev, GW_HWNDPREV ); + if (!prev) /* top child */ + { + //GR_WINDOW_INFO infoptr; + //GrGetWindowInfo(data->whole_window, &infoptr); + + //GrRaiseWindow(data->whole_window); + //changes.stack_mode = Above; + //mask |= CWStackMode; + SwmSetForeground(data->hwnd); + } + /* should use stack_mode Below but most window managers don't get it right */ + /* and Above with a sibling doesn't work so well either, so we ignore it */ + } + + + TRACE( "win %p/%lx pos %d,%d,%dx%d\n", + data->hwnd, data->whole_window, data->whole_rect.left, data->whole_rect.top, + data->whole_rect.right - data->whole_rect.left, + data->whole_rect.bottom - data->whole_rect.top ); +} + +/*********************************************************************** + * sync_client_position + * + * Synchronize the X client window position with the Windows one + */ +static void sync_client_position( struct ntdrv_win_data *data, + UINT swp_flags, const RECT *old_client_rect, + const RECT *old_whole_rect ) +{ + LONG width, height; + BOOL resize = FALSE; + RECT old = *old_client_rect; + RECT new = data->client_rect; + + OffsetRect( &old, -old_whole_rect->left, -old_whole_rect->top ); + OffsetRect( &new, -data->whole_rect.left, -data->whole_rect.top ); + + width = old.right - old.left; + height = old.bottom - old.top; + if (old.right - old.left != new.right - new.left) + { + if ((width = new.right - new.left) <= 0) width = 1; + else if (width > 65535) width = 65535; + resize = TRUE; + } + if (old.bottom - old.top != new.bottom - new.top) + { + if ((height = new.bottom - new.top) <= 0) height = 1; + else if (height > 65535) height = 65535; + resize = TRUE; + } + + TRACE( "setting client win %lx pos %d,%d,%dx%d\n", + data->client_window, new.left, new.top, + new.right - new.left, new.bottom - new.top ); + + //if (resize) GrResizeWindow( data->client_window, width, height ); + + if ((old.left != new.left) || (old.top != new.top)) + { + //GrMoveWindow(data->client_window, new.left, new.top); + } +} + +/*********************************************************************** + * move_window_bits + * + * Move the window bits when a window is moved. + */ +void move_window_bits( struct ntdrv_win_data *data, const RECT *old_rect, const RECT *new_rect, + const RECT *old_client_rect ) +{ + RECT src_rect = *old_rect; + RECT dst_rect = *new_rect; + HDC hdc_src, hdc_dst; + HRGN rgn = 0; + HWND parent = 0; + + if (!data->whole_window) + { + OffsetRect( &dst_rect, -data->window_rect.left, -data->window_rect.top ); + parent = GetAncestor( data->hwnd, GA_PARENT ); + hdc_src = GetDCEx( parent, 0, DCX_CACHE ); + hdc_dst = GetDCEx( data->hwnd, 0, DCX_CACHE | DCX_WINDOW ); + } + else + { + OffsetRect( &dst_rect, -data->client_rect.left, -data->client_rect.top ); + /* make src rect relative to the old position of the window */ + OffsetRect( &src_rect, -old_client_rect->left, -old_client_rect->top ); + if (dst_rect.left == src_rect.left && dst_rect.top == src_rect.top) return; + hdc_src = hdc_dst = GetDCEx( data->hwnd, 0, DCX_CACHE ); + } + + TRACE( "copying bits for win %p (parent %p)/ %s -> %s\n", + data->hwnd, parent, + wine_dbgstr_rect(&src_rect), wine_dbgstr_rect(&dst_rect) ); + BitBlt( hdc_dst, dst_rect.left, dst_rect.top, + dst_rect.right - dst_rect.left, dst_rect.bottom - dst_rect.top, + hdc_src, src_rect.left, src_rect.top, SRCCOPY ); + + ReleaseDC( data->hwnd, hdc_dst ); + if (hdc_src != hdc_dst) ReleaseDC( parent, hdc_src ); + + if (rgn) + { + if (!data->whole_window) + { + /* map region to client rect since we are using DCX_WINDOW */ + OffsetRgn( rgn, data->window_rect.left - data->client_rect.left, + data->window_rect.top - data->client_rect.top ); + RedrawWindow( data->hwnd, NULL, rgn, + RDW_INVALIDATE | RDW_FRAME | RDW_ERASE | RDW_ALLCHILDREN ); + } + else RedrawWindow( data->hwnd, NULL, rgn, RDW_INVALIDATE | RDW_ERASE | RDW_ALLCHILDREN ); + DeleteObject( rgn ); + } } /*********************************************************************** @@ -224,50 +488,427 @@ } /*********************************************************************** - * sync_window_position - * - * Synchronize the SWM window position with the Windows one - */ -void sync_window_position( struct ntdrv_win_data *data, - UINT swp_flags, const RECT *old_window_rect, - const RECT *old_whole_rect, const RECT *old_client_rect ) -{ - SwmPosChanged(data->hwnd, &data->whole_rect, old_whole_rect, NULL, swp_flags); - - if (!(swp_flags & SWP_NOZORDER) || (swp_flags & SWP_SHOWWINDOW)) - { - /* find window that this one must be after */ - HWND prev = GetWindow( data->hwnd, GW_HWNDPREV ); - while (prev && !(GetWindowLongW( prev, GWL_STYLE ) & WS_VISIBLE)) - prev = GetWindow( prev, GW_HWNDPREV ); - if (!prev) /* top child */ - { - /* Bring this window to foreground */ - SwmSetForeground(data->hwnd); - } - /* should use stack_mode Below but most window managers don't get it right */ - /* and Above with a sibling doesn't work so well either, so we ignore it */ - } - -#ifdef HAVE_LIBXSHAPE - if (IsRectEmpty( old_window_rect ) != IsRectEmpty( &data->window_rect )) - sync_window_region( display, data, (HRGN)1 ); - if (data->shaped) - { - int old_x_offset = old_window_rect->left - old_whole_rect->left; - int old_y_offset = old_window_rect->top - old_whole_rect->top; - int new_x_offset = data->window_rect.left - data->whole_rect.left; - int new_y_offset = data->window_rect.top - data->whole_rect.top; - if (old_x_offset != new_x_offset || old_y_offset != new_y_offset) - XShapeOffsetShape( display, data->whole_window, ShapeBounding, - new_x_offset - old_x_offset, new_y_offset - old_y_offset ); - } + * create_client_window + */ +static GR_WINDOW_ID create_client_window( struct ntdrv_win_data *data ) +{ + int cx, cy; + GR_WINDOW_ID client; + + /*attr.bit_gravity = NorthWestGravity; + attr.win_gravity = NorthWestGravity; + attr.backing_store = NotUseful; + attr.event_mask = (ExposureMask | PointerMotionMask | + ButtonPressMask | ButtonReleaseMask | EnterWindowMask); + mask = CWEventMask | CWBitGravity | CWWinGravity | CWBackingStore;*/ + + if ((cx = data->client_rect.right - data->client_rect.left) <= 0) cx = 1; + else if (cx > 65535) cx = 65535; + if ((cy = data->client_rect.bottom - data->client_rect.top) <= 0) cy = 1; + else if (cy > 65535) cy = 65535; + + client = (GR_WINDOW_ID)1;//GrNewWindow( data->whole_window, + // data->client_rect.left - data->whole_rect.left, + // data->client_rect.top - data->whole_rect.top, + // cx, cy, 0, RGB(255,255,255), 0 ); + + if (!client) + { + return 0; + } + + //GrSelectEvents(client, GR_EVENT_MASK_EXPOSURE); + + if (data->client_window) + { + //GrDestroyWindow( data->client_window ); + } + data->client_window = client; + + //GrMapWindow( data->client_window ); + + SetPropA( data->hwnd, client_window_prop, (HANDLE)data->client_window ); + return data->client_window; +} + +/********************************************************************** + * create_whole_window + * + * Create the whole X window for a given window + */ +GR_WINDOW_ID create_whole_window( struct ntdrv_win_data *data ) +{ + int cx, cy; + //int mask; + //WCHAR text[1024]; + //COLORREF key; + //BYTE alpha; + //DWORD layered_flags; + HRGN win_rgn; + //GR_WM_PROPERTIES props; + DWORD style, ex_style; + + if ((win_rgn = CreateRectRgn( 0, 0, 0, 0 )) && + GetWindowRgn( data->hwnd, win_rgn ) == ERROR) + { + DeleteObject( win_rgn ); + win_rgn = 0; + } + data->shaped = (win_rgn != 0); + + //mask = get_window_attributes( display, data, &attr ); + + data->whole_rect = data->window_rect; + //X11DRV_window_to_X_rect( data, &data->whole_rect ); + if (!(cx = data->whole_rect.right - data->whole_rect.left)) cx = 1; + else if (cx > 65535) cx = 65535; + if (!(cy = data->whole_rect.bottom - data->whole_rect.top)) cy = 1; + else if (cy > 65535) cy = 65535; + + //data->whole_window = GrNewWindow( root_window, + // data->whole_rect.left, + // data->whole_rect.top, + // cx, cy, 0, RGB(255,255,255), 0 ); + data->whole_window = (GR_WINDOW_ID)1; + + /* Inform window manager about window rect in screen coords */ + style = GetWindowLongW( data->hwnd, GWL_STYLE ); + ex_style = GetWindowLongW( data->hwnd, GWL_EXSTYLE ); + SwmAddWindow(data->hwnd, &data->window_rect, style, ex_style); + + //GrSelectEvents(data->whole_window, GR_EVENT_MASK_EXPOSURE); + + //if (data->whole_window) GrSetHwnd( data->whole_window, data->hwnd ); + + if (!data->whole_window) goto done; + + /* Set override_redirect */ + //props.props = GR_WM_PROPS_NODECORATE; + //props.flags = GR_WM_FLAGS_PROPS; + //GrSetWMProperties(data->whole_window, &props); + + if (!create_client_window( data )) + { + //GrDestroyWindow( data->whole_window ); + data->whole_window = 0; + goto done; + } + + //set_initial_wm_hints( display, data ); + //set_wm_hints( display, data ); + + SetPropA( data->hwnd, whole_window_prop, (HANDLE)data->whole_window ); + + /* set the window text */ + //if (!InternalGetWindowText( data->hwnd, text, sizeof(text)/sizeof(WCHAR) )) text[0] = 0; + //sync_window_text( display, data->whole_window, text ); + + /* set the window region */ + //if (win_rgn || IsRectEmpty( &data->window_rect )) sync_window_region( display, data, win_rgn ); + + /* set the window opacity */ + //if (!GetLayeredWindowAttributes( data->hwnd, &key, &alpha, &layered_flags )) layered_flags = 0; + //sync_window_opacity( display, data->whole_window, key, alpha, layered_flags ); + + //sync_window_cursor( data ); +done: + if (win_rgn) DeleteObject( win_rgn ); + return data->whole_window; +} + +/*********************************************************************** + * NTDRV_get_whole_window + * + * Return the X window associated with the full area of a window + */ +GR_WINDOW_ID NTDRV_get_whole_window( HWND hwnd ) +{ + struct ntdrv_win_data *data = NTDRV_get_win_data( hwnd ); + + if (!data) + { + if (hwnd == GetDesktopWindow()) return root_window; + return (GR_WINDOW_ID)GetPropA( hwnd, whole_window_prop ); + } + return data->whole_window; +} + +/*********************************************************************** + * NTDRV_get_client_window + * + * Return the X window associated with the client area of a window + */ +#if 0 +static GR_WINDOW_ID NTDRV_get_client_window( HWND hwnd ) +{ + struct ntdrv_win_data *data = NTDRV_get_win_data( hwnd ); + + if (!data) + { + if (hwnd == GetDesktopWindow()) return root_window; + return (GR_WINDOW_ID)GetPropA( hwnd, client_window_prop ); + } + return data->client_window; +} #endif - - TRACE( "win %p/%lx pos %d,%d,%dx%d\n", - data->hwnd, data->whole_window, data->whole_rect.left, data->whole_rect.top, - data->whole_rect.right - data->whole_rect.left, - data->whole_rect.bottom - data->whole_rect.top ); +/*********************************************************************** + * NTDRV_GetDC (NTDRV.@) + */ +void CDECL RosDrv_GetDC( HDC hdc, HWND hwnd, HWND top, const RECT *win_rect, + const RECT *top_rect, DWORD flags ) +{ + struct ntdrv_escape_set_drawable escape; + //struct ntdrv_win_data *data = NTDRV_get_win_data( hwnd ); + //HWND parent; + + escape.code = NTDRV_SET_DRAWABLE; + escape.clip_children = FALSE; + escape.gl_copy = FALSE; + escape.hwnd = 0; + escape.release = FALSE; + + escape.dc_rect.left = win_rect->left - top_rect->left; + escape.dc_rect.top = win_rect->top - top_rect->top; + escape.dc_rect.right = win_rect->right - top_rect->left; + escape.dc_rect.bottom = win_rect->bottom - top_rect->top; + escape.drawable_rect.left = top_rect->left; + escape.drawable_rect.top = top_rect->top; + escape.drawable_rect.right = top_rect->right; + escape.drawable_rect.bottom = top_rect->bottom; +#if GOOD_VERSION + if (top == hwnd) + { + if (flags & DCX_WINDOW) + { + escape.drawable = data ? data->whole_window : NTDRV_get_whole_window( hwnd ); + } + else + escape.drawable = data ? data->client_window : NTDRV_get_client_window( hwnd ); + } + else + { + for (parent = hwnd; parent && parent != top; parent = GetAncestor( parent, GA_PARENT )) + if ((escape.drawable = NTDRV_get_client_window( parent ))) break; + + if (escape.drawable) + { + POINT pt = { 0, 0 }; + MapWindowPoints( top, parent, &pt, 1 ); + OffsetRect( &escape.dc_rect, pt.x, pt.y ); + OffsetRect( &escape.drawable_rect, -pt.x, -pt.y ); + + FIXME("Offset by (%d, %d)\n", pt.x, pt.y); + } + else escape.drawable = NTDRV_get_client_window( top ); + + if (flags & DCX_CLIPCHILDREN) escape.clip_children = TRUE; + } +#else + escape.hwnd = GetAncestor(hwnd, GA_ROOT); +#endif + + TRACE("hdc %x, hwnd %x, top %x\n win_rect %s, top_rect %s\n", hdc, hwnd, top, + wine_dbgstr_rect(win_rect), wine_dbgstr_rect(top_rect)); + + ExtEscape( hdc, NTDRV_ESCAPE, sizeof(escape), (LPSTR)&escape, 0, NULL ); +} + +void CDECL RosDrv_ReleaseDC( HWND hwnd, HDC hdc ) +{ + struct ntdrv_escape_set_drawable escape; + RECTL virtual_screen_rect; + + escape.code = NTDRV_SET_DRAWABLE; + escape.drawable = root_window; + escape.clip_children = FALSE; + escape.gl_copy = FALSE; + escape.release = TRUE; + escape.hwnd = hwnd; + + virtual_screen_rect.right = GetSystemMetrics(SM_CXVIRTUALSCREEN); + virtual_screen_rect.bottom = GetSystemMetrics(SM_CYVIRTUALSCREEN); + virtual_screen_rect.left = 0; virtual_screen_rect.top = 0; + + SetRect( &escape.dc_rect, 0, 0, virtual_screen_rect.right - virtual_screen_rect.left, + virtual_screen_rect.bottom - virtual_screen_rect.top ); + OffsetRect( &escape.dc_rect, -escape.drawable_rect.left, -escape.drawable_rect.top ); + + ExtEscape( hdc, NTDRV_ESCAPE, sizeof(escape), (LPSTR)&escape, 0, NULL ); +} + +/*********************************************************************** + * SetCapture (NTDRV.@) + */ +void CDECL RosDrv_SetCapture( HWND hwnd, UINT flags ) +{ + if (!(flags & (GUI_INMOVESIZE | GUI_INMENUMODE))) return; + + if (hwnd) + { + /* Capturing */ + TRACE("Capture set for hwnd %x\n", hwnd); + } + else + { + TRACE("Capture released\n"); + } +} + + +/***************************************************************** + * SetParent (NTDRV.@) + */ +void CDECL RosDrv_SetParent( HWND hwnd, HWND parent, HWND old_parent ) +{ + struct ntdrv_win_data *data = NTDRV_get_win_data( hwnd ); + + if (!data) return; + if (parent == old_parent) return; + + if (parent != GetDesktopWindow()) /* a child window */ + { + if (old_parent == GetDesktopWindow()) + { + /* destroy the old windows */ + //destroy_whole_window( data, FALSE ); + //destroy_icon_window( data ); + FIXME("Should destroy hwnd %x\n", data->hwnd); + } + } + else /* new top level window */ + { + /* FIXME: we ignore errors since we can't really recover anyway */ + //create_whole_window( data ); + FIXME("Should create a new whole window for hwnd %x\n", data->hwnd); + } +} + +/***************************************************************** + * SetFocus (NTDRV.@) + * + * Set the Nano focus. + */ +void CDECL RosDrv_SetFocus( HWND hwnd ) +{ + struct ntdrv_win_data *data; + + if (!(hwnd = GetAncestor( hwnd, GA_ROOT ))) return; + if (!(data = NTDRV_get_win_data( hwnd ))) return; + if (!data->whole_window) return; + + TRACE("SetFocus %x, desk %x\n", hwnd, GetDesktopWindow()); + + /* Bring this window to foreground */ + SwmSetForeground(hwnd); + //GrRaiseWindow(data->whole_window); +} + +/*********************************************************************** + * WindowPosChanging (NTDRV.@) + */ +void CDECL RosDrv_WindowPosChanging( HWND hwnd, HWND insert_after, UINT swp_flags, + const RECT *window_rect, const RECT *client_rect, + RECT *visible_rect ) +{ + DWORD style = GetWindowLongW( hwnd, GWL_STYLE ); + struct ntdrv_win_data *data = NTDRV_get_win_data(hwnd); + + if (!data) + { + /* create the win data if the window is being made visible */ + if (!(style & WS_VISIBLE) && !(swp_flags & SWP_SHOWWINDOW)) return; + if (!(data = NTDRV_create_win_data( hwnd ))) return; + } + + //SwmPosChanging(hwnd, window_rect); + + //TRACE( "win %x pos is changing. vis rect %s, win rect %s\n", + // hwnd, wine_dbgstr_rect(visible_rect), wine_dbgstr_rect(window_rect) ); + + *visible_rect = *window_rect; +} + +void CDECL RosDrv_WindowPosChanged( HWND hwnd, HWND insert_after, UINT swp_flags, + const RECT *window_rect, const RECT *rectClient, + const RECT *visible_rect, const RECT *valid_rects ) +{ + RECT old_whole_rect, old_client_rect, old_window_rect; + struct ntdrv_win_data *data = NTDRV_get_win_data(hwnd); + DWORD new_style = GetWindowLongW( hwnd, GWL_STYLE ); + + if (!data) return; + + TRACE( "win %x pos changed. new vis rect %s, old whole rect %s, swp_flags %x insert_after %x\n", + hwnd, wine_dbgstr_rect(visible_rect), wine_dbgstr_rect(&data->whole_rect), swp_flags, insert_after ); + + old_window_rect = data->window_rect; + old_whole_rect = data->whole_rect; + old_client_rect = data->client_rect; + data->window_rect = *window_rect; + data->whole_rect = *visible_rect; + data->client_rect = *rectClient; + + if (!IsRectEmpty( &valid_rects[0] )) + { + int x_offset = old_whole_rect.left - data->whole_rect.left; + int y_offset = old_whole_rect.top - data->whole_rect.top; + + /* if all that happened is that the whole window moved, copy everything */ + if (!(swp_flags & SWP_FRAMECHANGED) && + old_whole_rect.right - data->whole_rect.right == x_offset && + old_whole_rect.bottom - data->whole_rect.bottom == y_offset && + old_client_rect.left - data->client_rect.left == x_offset && + old_client_rect.right - data->client_rect.right == x_offset && + old_client_rect.top - data->client_rect.top == y_offset && + old_client_rect.bottom - data->client_rect.bottom == y_offset && + !memcmp( &valid_rects[0], &data->client_rect, sizeof(RECT) )) + { + /* if we have an SWM window the bits will be moved by the SWM */ + if (!data->whole_window) + move_window_bits( data, &old_whole_rect, &data->whole_rect, &old_client_rect ); + } + else + { + move_window_bits( data, &valid_rects[1], &valid_rects[0], &old_client_rect ); + } + } + + sync_client_position( data, swp_flags, &old_client_rect, &old_whole_rect ); + + if (!data->whole_window) return; + + /* Sync window position with the SWM */ + sync_window_position( data, swp_flags, + &old_window_rect, &old_whole_rect, &old_client_rect ); + + if (data->mapped) + { + if (((swp_flags & SWP_HIDEWINDOW) && !(new_style & WS_VISIBLE)) || + (!is_window_rect_mapped( window_rect ) && is_window_rect_mapped( &old_window_rect ))) + unmap_window( data ); + } + + /* Pass show/hide information to the window manager */ + if ((new_style & WS_VISIBLE) && + ((new_style & WS_MINIMIZE) || is_window_rect_mapped( window_rect ))) + { + //if (!data->mapped || (swp_flags & (SWP_FRAMECHANGED|SWP_STATECHANGED))) + //set_wm_hints( display, data ); + + if (!data->mapped) + { + map_window( data, new_style ); + } + else if ((swp_flags & SWP_STATECHANGED) && (!data->iconic != !(new_style & WS_MINIMIZE))) + { + data->iconic = (new_style & WS_MINIMIZE) != 0; + FIXME( "changing win %p iconic state to %u\n", data->hwnd, data->iconic ); + //if (data->iconic) + // XIconifyWindow( display, data->whole_window, DefaultScreen(display) ); + //else if (is_window_rect_mapped( rectWindow )) + // XMapWindow( display, data->whole_window ); + } + } } /* EOF */ Modified: branches/arwinss/reactos/dll/win32/winent.drv/winent.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/winent.h [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/winent.drv/winent.h [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -58,7 +58,8 @@ struct ntdrv_escape_set_drawable { - enum ntdrv_escape_codes code; /* escape code (X11DRV_SET_DRAWABLE) */ + enum ntdrv_escape_codes code; /* escape code (NTDRV_SET_DRAWABLE) */ + GR_WINDOW_ID drawable; BOOL clip_children;/* ClipByChildren or IncludeInferiors */ RECT dc_rect; /* DC rectangle relative to drawable */ RECT drawable_rect;/* Drawable rectangle relative to screen */ @@ -70,17 +71,30 @@ /* ntdrv private window data */ struct ntdrv_win_data { - struct list entry; /* entry in the linked list of win data */ - HWND hwnd; /* hwnd that this private data belongs to */ - PVOID whole_window; /* SWM window for the complete window */ + struct list entry; /* entry in the linked list of win data */ + HWND hwnd; /* hwnd that this private data belongs to */ + GR_WINDOW_ID whole_window; /* SWM window for the complete window */ + GR_WINDOW_ID client_window; /* SWM window for the client area */ RECT window_rect; /* USER window rectangle relative to parent */ - RECT whole_rect; /* X window rectangle for the whole window relative to parent */ + RECT whole_rect; /* SWM window rectangle for the whole window relative to parent */ RECT client_rect; /* client area relative to parent */ HCURSOR cursor; /* current cursor */ BOOL mapped : 1; /* is window mapped? (in either normal or iconic state) */ BOOL iconic : 1; /* is window in iconic state? */ BOOL shaped : 1; /* is window using a custom region shape? */ }; + +//typedef void (*ntdrv_event_handler)( HWND hwnd, GR_EVENT *event ); + +extern GR_WINDOW_ID root_window; + +static inline void mirror_rect( const RECT *window_rect, RECT *rect ) +{ + int width = window_rect->right - window_rect->left; + int tmp = rect->left; + rect->left = width - rect->right; + rect->right = width - tmp; +} /* clipboard.c */ void NTDRV_InitClipboard(void); @@ -116,7 +130,7 @@ BOOL CDECL RosDrv_GetCursorPos( LPPOINT pt ); -/* wnd.c */ +/* window.c */ struct ntdrv_win_data *NTDRV_get_win_data( HWND hwnd ); struct ntdrv_win_data *NTDRV_create_win_data( HWND hwnd ); struct ntdrv_win_data *NTDRV_create_desktop_win_data( HWND hwnd ); @@ -128,3 +142,4 @@ void sync_window_position( struct ntdrv_win_data *data, UINT swp_flags, const RECT *old_window_rect, const RECT *old_whole_rect, const RECT *old_client_rect ); +GR_WINDOW_ID create_whole_window( struct ntdrv_win_data *data ); Modified: branches/arwinss/reactos/dll/win32/winent.drv/winent.rbuild URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/winen…
============================================================================== --- branches/arwinss/reactos/dll/win32/winent.drv/winent.rbuild [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/winent.drv/winent.rbuild [iso-8859-1] Fri Jan 7 20:50:13 2011 @@ -9,6 +9,7 @@ <file>bitblt.c</file> <file>clipboard.c</file> <file>dib.c</file> + <file>event.c</file> <file>font.c</file> <file>gdidrv.c</file> <file>graphics.c</file>
13 years, 10 months
1
0
0
0
[akhaldi] 50312: [CMAKE] - Add ntdll apitest to build.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Jan 7 20:31:56 2011 New Revision: 50312 URL:
http://svn.reactos.org/svn/reactos?rev=50312&view=rev
Log: [CMAKE] - Add ntdll apitest to build. Modified: trunk/rostests/apitests/CMakeLists.txt trunk/rostests/apitests/ntdll/CMakeLists.txt Modified: trunk/rostests/apitests/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/CMakeLists.txt?r…
============================================================================== --- trunk/rostests/apitests/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/apitests/CMakeLists.txt [iso-8859-1] Fri Jan 7 20:31:56 2011 @@ -3,7 +3,7 @@ add_subdirectory(dciman32) add_subdirectory(gdi32) -#add_subdirectory(ntdll) The asm file needs to be fixed. +add_subdirectory(ntdll) add_subdirectory(user32) if(ARCH MATCHES i386) Modified: trunk/rostests/apitests/ntdll/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/CMakeLists…
============================================================================== --- trunk/rostests/apitests/ntdll/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/CMakeLists.txt [iso-8859-1] Fri Jan 7 20:31:56 2011 @@ -1,5 +1,5 @@ -#add_definitions(-D_DLL -D__USE_CRTIMP) +add_definitions(-D_DLL -D__USE_CRTIMP) list(APPEND SOURCE RtlInitializeBitMap.c @@ -7,13 +7,11 @@ testlist.c) if(ARCH MATCHES i386) -list(APPEND SOURCE i386/ZwContinue.asm) + list(APPEND SOURCE i386/ZwContinue.S) endif() add_executable(ntdll_apitest ${SOURCE}) -target_link_libraries(ntdll_apitest wine - #${PSEH_LIB} - ) +target_link_libraries(ntdll_apitest wine) set_module_type(ntdll_apitest win32cui) -add_importlibs(ntdll_apitest ntdll) +add_importlibs(ntdll_apitest msvcrt kernel32 ntdll) add_cab_target(ntdll_apitest 7)
13 years, 10 months
1
0
0
0
[tkreuzer] 50311: [NTDLL_APITEST] Convert asm to GAS/ML compatible format
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Fri Jan 7 20:11:56 2011 New Revision: 50311 URL:
http://svn.reactos.org/svn/reactos?rev=50311&view=rev
Log: [NTDLL_APITEST] Convert asm to GAS/ML compatible format Added: trunk/rostests/apitests/ntdll/i386/ZwContinue.S - copied, changed from r50248, trunk/rostests/apitests/ntdll/i386/ZwContinue.asm Removed: trunk/rostests/apitests/ntdll/i386/ZwContinue.asm Modified: trunk/rostests/apitests/ntdll/ntdll_apitest.rbuild Copied: trunk/rostests/apitests/ntdll/i386/ZwContinue.S (from r50248, trunk/rostests/apitests/ntdll/i386/ZwContinue.asm) URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/i386/ZwCon…
============================================================================== --- trunk/rostests/apitests/ntdll/i386/ZwContinue.asm [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/i386/ZwContinue.S [iso-8859-1] Fri Jan 7 20:11:56 2011 @@ -1,15 +1,20 @@ -; cpu 486 -segment .text use32 + +#include <asm.inc> +#include <ks386.inc> + + +// cpu 486 +.text extern _check -global _continuePoint +PUBLIC _continuePoint _continuePoint: push ss - push dword 0 + push 0 pushfd push cs - push dword _continuePoint + push offset _continuePoint push ebp push eax @@ -24,25 +29,26 @@ push fs push gs - ; TODO: floating point state - sub esp, 70h + // TODO: floating point state + sub esp, 112 - ; Debug registers - sub esp, 18h + // Debug registers + sub esp, 24 - push dword 00010007h + push HEX(00010007) - ; Fill the Esp field - lea eax, [esp+0CCh] - lea ecx, [esp+0C4h] + // Fill the Esp field + lea eax, [esp + HEX(0CC)] + lea ecx, [esp + HEX(0C4)] mov [ecx], eax - ; Call the function that will compare the current context with the expected one + // Call the function that will compare the current context with the expected one cld push esp call _check - ; check() must not return + // check() must not return int 3 -; EOF +// EOF +END Removed: trunk/rostests/apitests/ntdll/i386/ZwContinue.asm URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/i386/ZwCon…
============================================================================== --- trunk/rostests/apitests/ntdll/i386/ZwContinue.asm [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/i386/ZwContinue.asm (removed) @@ -1,48 +1,0 @@ -; cpu 486 -segment .text use32 - -extern _check - -global _continuePoint -_continuePoint: - push ss - push dword 0 - pushfd - push cs - push dword _continuePoint - push ebp - - push eax - push ecx - push edx - push ebx - push esi - push edi - - push ds - push es - push fs - push gs - - ; TODO: floating point state - sub esp, 70h - - ; Debug registers - sub esp, 18h - - push dword 00010007h - - ; Fill the Esp field - lea eax, [esp+0CCh] - lea ecx, [esp+0C4h] - mov [ecx], eax - - ; Call the function that will compare the current context with the expected one - cld - push esp - call _check - - ; check() must not return - int 3 - -; EOF Modified: trunk/rostests/apitests/ntdll/ntdll_apitest.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/ntdll_apit…
============================================================================== --- trunk/rostests/apitests/ntdll/ntdll_apitest.rbuild [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/ntdll_apitest.rbuild [iso-8859-1] Fri Jan 7 20:11:56 2011 @@ -12,7 +12,7 @@ <file>ZwContinue.c</file> <if property="ARCH" value="i386"> <directory name="i386"> - <file>ZwContinue.asm</file> + <file>ZwContinue.S</file> </directory> </if> </module>
13 years, 10 months
1
0
0
0
[akhaldi] 50310: [CMAKE] - Silence the quotes warning.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Jan 7 20:07:15 2011 New Revision: 50310 URL:
http://svn.reactos.org/svn/reactos?rev=50310&view=rev
Log: [CMAKE] - Silence the quotes warning. Modified: branches/cmake-bringup/base/applications/findstr/lang/bg-BG.rc branches/cmake-bringup/base/applications/findstr/lang/ca-ES.rc branches/cmake-bringup/base/applications/findstr/lang/cs-CZ.rc branches/cmake-bringup/base/applications/findstr/lang/de-DE.rc branches/cmake-bringup/base/applications/findstr/lang/el-GR.rc branches/cmake-bringup/base/applications/findstr/lang/en-US.rc branches/cmake-bringup/base/applications/findstr/lang/es-ES.rc branches/cmake-bringup/base/applications/findstr/lang/fr-FR.rc branches/cmake-bringup/base/applications/findstr/lang/it-IT.rc branches/cmake-bringup/base/applications/findstr/lang/lt-LT.rc branches/cmake-bringup/base/applications/findstr/lang/no-NO.rc branches/cmake-bringup/base/applications/findstr/lang/pl-PL.rc branches/cmake-bringup/base/applications/findstr/lang/pt-BR.rc branches/cmake-bringup/base/applications/findstr/lang/ru-RU.rc branches/cmake-bringup/base/applications/findstr/lang/sk-SK.rc branches/cmake-bringup/base/applications/findstr/lang/sv-SE.rc branches/cmake-bringup/base/applications/findstr/lang/uk-UA.rc Modified: branches/cmake-bringup/base/applications/findstr/lang/bg-BG.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/bg-BG.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/bg-BG.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Èçâåæäà âñè÷êè ðåäîâå âúâ ôàéëà, êîèòî ñúäúðæàò óêàçàíèÿ íèç..\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"íèç\" [ ôàéë... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""íèç"" [ ôàéë... ]\n\ /C Áðîè êîëêî ðåäà ñúäúðæàò íèçà\n\ /I Ïðåíåáðåãâà ÃëÀâÍÎñÒòà\n\ /N Áðîé ïîêàçàíè ðåäîâå, êàòî ñå çàïî÷âà îò 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/ca-ES.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/ca-ES.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/ca-ES.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Mostra totes les linies que continguin una determinada cadena de caràcters.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"Cadena de caràcters\" [ file... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""Cadena de caràcters"" [ file... ]\n\ /C Conta el numero de linies que contenen la cadena de caràcters\n\ /I Ignora majúscules i minúscules\n\ /N Numero de linies mostrades, començant per la primera\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/cs-CZ.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/cs-CZ.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/cs-CZ.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -10,7 +10,7 @@ BEGIN IDS_USAGE, "FIND: Zobrazí vechny øádky souboru obsahující hledaný øetìzec.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"øetìzec\" [ soubor... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""øetìzec"" [ soubor... ]\n\ /C Zobrazí poèet øádkù obsahující øetìzec.\n\ /I Ignoruje velikost písmen.\n\ /N Èísluje zobrazené øádky, zaèíná od 1.\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/de-DE.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/de-DE.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "Sucht in einer Datei nach einer Zeichenfolge.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"string\" [ file... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""string"" [ file... ]\n\ /C Zeigt nur die Anzahl der die Zeichenfolge enthaltenen Zeilen an.\n\ /I Ignoriert Groß-/Kleinbuchstaben bei der Suche.\n\ /N Zeigt die Zeilen mit ihren Zeilennummern an.\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/el-GR.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/el-GR.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/el-GR.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Åêôõðþíåé üëåò ôéò ãñáììÝò åíüò áñ÷åßïõ ðïõ ðåñéÝ÷ïõí Ýíá áëöáñéèìçôéêü.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"áëöáñéèìçôéêü\" [ áñ÷åßï... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""áëöáñéèìçôéêü"" [ áñ÷åßï... ]\n\ /C ÌÝôñçóç ãñáììþí ðïõ ðåñéÝ÷ïõí ôï áëöáñéèìçôéêü\n\ /I Áãíüçóç êåöáëáßùí\n\ /N ÅìöÜíéóç áñéèìþí óôéò åìöáíéæüìåíåò ãñáììÝò, îåêéíþíôáò áðü ôï 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/en-US.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/en-US.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/en-US.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FINDSTR: Prints all lines of a file that contain a string.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"string\" [ file... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""string"" [ file... ]\n\ /C Count the number of lines that contain string\n\ /I Ignore case\n\ /N Number the displayed lines, starting at 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/es-ES.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/es-ES.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/es-ES.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Imprime todas las líneas de un fichero que contiene una cadena.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"cadena\" [ fichero... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""cadena"" [ fichero... ]\n\ /C Cuenta el número de líneas que contienen la cadena de caracteres\n\ /I Ignora mayúsculas y minúsculas\n\ /N Numero de líneas a mostrar en pantalla, a partir de la primera\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/fr-FR.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/fr-FR.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Affiche toutes les lignes d'un fichier qui contiennent un morceau de texte.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"texte\" [ fichier... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""texte"" [ fichier... ]\n\ /C Compte le nombre de lignes qui contiennent le texte\n\ /I Insensible à la casse\n\ /N Numérote les lignes affichées en commençant à 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/it-IT.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/it-IT.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/it-IT.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Visualizza le linee di un file che contengono un stringa.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"stringa\" [ file... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""stringa"" [ file... ]\n\ /C Conta il numero di linee che contengono la stringa\n\ /I Ignora maiuscole/minuscole\n\ /N Numera le linee visualizzate a partire da 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/lt-LT.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/lt-LT.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/lt-LT.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -13,7 +13,7 @@ BEGIN IDS_USAGE, "FIND: Spausdina visas bylos eilutes, kuriose yra ieðkomas tekstas.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"tekstas\" [ byla... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""tekstas"" [ byla... ]\n\ /C Skaièiuoti eilutes, kuriose yra ieðkomas tekstas\n\ /I Ignoruoti raidþiø dydá\n\ /N Numeruoti vaizduojamas eilutes, pradedant nuo 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/no-NO.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/no-NO.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/no-NO.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FINN: Skriv alle linjene for filen som inneholder en streng.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"streng\" [ fil... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""streng"" [ fil... ]\n\ /C Teller nummer av linjer som inneholder strenger\n\ /I Ignorere sak\n\ /N Nummer viste linjer, start med 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/pl-PL.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/pl-PL.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/pl-PL.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -11,7 +11,7 @@ BEGIN IDS_USAGE, "FIND: Wywietla wszystkie linie danego pliku, zawieraj¹ce szukany ci¹g znaków.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"ci¹g znaków\" [ plik... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""ci¹g znaków"" [ plik... ]\n\ /C Oblicza w ilu liniach pojawi³ siê szukany ci¹g znaków\n\ /I Ignoruje wielkoæ liter\n\ /N Numeruje wywietlane linie, zaczynaj¹c od 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/pt-BR.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/pt-BR.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/pt-BR.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Localiza uma seqüência de texto em um ou mais arquivos.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"seqüência\" [ arquivo... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""seqüência"" [ arquivo... ]\n\ /C Exibe apenas o número de linhas que contêm a seqüência.\n\ /I Ignora maiúsculas/minúsculas ao localizar uma seqüência.\n\ /N Exibe o número de cada linha, iniciando no 1.\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/ru-RU.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/ru-RU.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/ru-RU.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Ïîèñê òåêñòîâîé ñòðîêè â îäíîì èëè íåñêîëüêèõ ôàéëàõ.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"ñòðîêà\" [ ôàéë... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""ñòðîêà"" [ ôàéë... ]\n\ /C Âûâîä òîëüêî îáùåãî ÷èñëà ñòðîê, ñîäåðæàùèõ çàäàííóþ ñòðîêó.\n\ /I Ïîèñê áåç ó÷åòà ðåãèñòðà ñèìâîëîâ.\n\ /N Âûâîä íîìåðîâ îòîáðàæàåìûõ ñòðîê (íà÷èíàÿ ñ 1).\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/sk-SK.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/sk-SK.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/sk-SK.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -8,7 +8,7 @@ BEGIN IDS_USAGE, "FIND: Zobraz¡ vçetky riadky s£boru obsahuj£ce hadanì reazec.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"reazec\" [ s£bor... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""reazec"" [ s£bor... ]\n\ /C Zobraz¡ poet riadkov, ktor obsahuj£ reazec.\n\ /I Ignoruje vekos p¡smen.\n\ /N ¬¡sluje zobrazen riadky, za¡na od 1.\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/sv-SE.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/sv-SE.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/sv-SE.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -4,7 +4,7 @@ BEGIN IDS_USAGE, "FIND: Skriver ut alla rader i en fil som innehåller en sträng.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"sträng\" [ fil... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""sträng"" [ fil... ]\n\ /C Räkna nummren av linjer som innehåller en strängen\n\ /I Ignorera skiftläge\n\ /N Antal visade rader, börjar på 1\n\ Modified: branches/cmake-bringup/base/applications/findstr/lang/uk-UA.rc URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/base/applications…
============================================================================== --- branches/cmake-bringup/base/applications/findstr/lang/uk-UA.rc [iso-8859-1] (original) +++ branches/cmake-bringup/base/applications/findstr/lang/uk-UA.rc [iso-8859-1] Fri Jan 7 20:07:15 2011 @@ -12,7 +12,7 @@ BEGIN IDS_USAGE, "FIND: Âèâåäåííÿ âñ³õ ðÿäê³â ôàéëó, ÿê³ ì³ñòÿòü ðÿäîê.\n\n\ - FIND [ /C ] [ /I ] [ /N ] [ /V ] \"ðÿäîê\" [ ôàéë... ]\n\ + FIND [ /C ] [ /I ] [ /N ] [ /V ] ""ðÿäîê"" [ ôàéë... ]\n\ /C Ïîðàõóâàòè ê³ëüê³ñòü ðÿäê³â, ÿê³ ì³ñòÿòü ðÿäîê\n\ /I Íå âðàõîâóâàòè ðåã³ñòð ñèìâîë³â\n\ /N Íóìåðóâàòè ðÿäêè, ÿê³ â³äîáðàæàþòüñÿ (ïî÷èíàþ÷è ç 1)\n\
13 years, 10 months
1
0
0
0
[fireball] 50309: [HEAP] - Fix a typo (assignment) in the ASSERT, spotted by Johannes Anderwald.
by fireball@svn.reactos.org
Author: fireball Date: Fri Jan 7 15:33:46 2011 New Revision: 50309 URL:
http://svn.reactos.org/svn/reactos?rev=50309&view=rev
Log: [HEAP] - Fix a typo (assignment) in the ASSERT, spotted by Johannes Anderwald. Modified: trunk/reactos/lib/rtl/heap.c Modified: trunk/reactos/lib/rtl/heap.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/rtl/heap.c?rev=50309&r…
============================================================================== --- trunk/reactos/lib/rtl/heap.c [iso-8859-1] (original) +++ trunk/reactos/lib/rtl/heap.c [iso-8859-1] Fri Jan 7 15:33:46 2011 @@ -238,7 +238,7 @@ /* Check if PreviousSize of the next entry matches ours */ if (!(FreeEntry->Flags & HEAP_ENTRY_LAST_ENTRY)) { - ASSERT(((PHEAP_ENTRY)FreeEntry + BlockSize)->PreviousSize = BlockSize); + ASSERT(((PHEAP_ENTRY)FreeEntry + BlockSize)->PreviousSize == BlockSize); } /* Insert it either into dedicated or non-dedicated list */ @@ -2344,6 +2344,7 @@ /* Release the heap lock */ if (Locked) RtlLeaveHeapLock(Heap->LockVariable); + DbgBreakPoint(); return FALSE; }
13 years, 10 months
1
0
0
0
[akhaldi] 50308: [CMAKE] - Delete an unneeded lib.mak - Don't build bin2c, we don't seem to need it. - A minor cleanup, no functionality change intended.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Jan 7 12:11:46 2011 New Revision: 50308 URL:
http://svn.reactos.org/svn/reactos?rev=50308&view=rev
Log: [CMAKE] - Delete an unneeded lib.mak - Don't build bin2c, we don't seem to need it. - A minor cleanup, no functionality change intended. Removed: branches/cmake-bringup/lib/lib.mak Modified: branches/cmake-bringup/lib/3rdparty/CMakeLists.txt branches/cmake-bringup/lib/3rdparty/adns/CMakeLists.txt branches/cmake-bringup/lib/3rdparty/mingw/CMakeLists.txt branches/cmake-bringup/lib/3rdparty/zlib/CMakeLists.txt branches/cmake-bringup/lib/atl/CMakeLists.txt branches/cmake-bringup/lib/cmlib/CMakeLists.txt branches/cmake-bringup/lib/drivers/ip/CMakeLists.txt branches/cmake-bringup/lib/inflib/CMakeLists.txt branches/cmake-bringup/lib/newinflib/CMakeLists.txt branches/cmake-bringup/lib/ppcmmu/CMakeLists.txt branches/cmake-bringup/lib/pseh/CMakeLists.txt branches/cmake-bringup/lib/recyclebin/CMakeLists.txt branches/cmake-bringup/lib/rossym/CMakeLists.txt branches/cmake-bringup/lib/rtl/CMakeLists.txt branches/cmake-bringup/lib/sdk/CMakeLists.txt branches/cmake-bringup/lib/sdk/crt/CMakeLists.txt branches/cmake-bringup/lib/smlib/CMakeLists.txt branches/cmake-bringup/subsystems/win32/csrss/CMakeLists.txt branches/cmake-bringup/subsystems/win32/win32k/CMakeLists.txt branches/cmake-bringup/tools/CMakeLists.txt Modified: branches/cmake-bringup/lib/3rdparty/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/3rdparty/CMak…
============================================================================== --- branches/cmake-bringup/lib/3rdparty/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/3rdparty/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -12,4 +12,4 @@ add_subdirectory(libxml2) add_subdirectory(mingw) add_subdirectory(stlport) -add_subdirectory(zlib) +add_subdirectory(zlib) Modified: branches/cmake-bringup/lib/3rdparty/adns/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/3rdparty/adns…
============================================================================== --- branches/cmake-bringup/lib/3rdparty/adns/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/3rdparty/adns/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -21,4 +21,4 @@ src/types.c) add_library(adns ${SOURCE}) -add_dependencies(adns psdk) +add_dependencies(adns psdk) Modified: branches/cmake-bringup/lib/3rdparty/mingw/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/3rdparty/ming…
============================================================================== --- branches/cmake-bringup/lib/3rdparty/mingw/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/3rdparty/mingw/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -4,8 +4,8 @@ add_definitions(-D_CRTBLD) if(NOT MSVC) -add_definitions(-Wno-main) -endif(NOT MSVC) + add_definitions(-Wno-main) +endif() list(APPEND MINGW_COMMON_SOURCE _newmode.c @@ -36,16 +36,16 @@ cxa_pure_virtual.c) if(MSVC) -list(APPEND MINGW_COMMON_SOURCE mscmain.c) + list(APPEND MINGW_COMMON_SOURCE mscmain.c) else() -list(APPEND MINGW_COMMON_SOURCE gccmain.c) + list(APPEND MINGW_COMMON_SOURCE gccmain.c) endif() add_library(mingw_common ${MINGW_COMMON_SOURCE}) if(NOT MSVC) target_link_libraries(mingw_common oldnames) -endif(NOT MSVC) +endif() set_target_properties(mingw_common PROPERTIES COMPILE_DEFINITIONS _M_CEE_PURE) add_dependencies(mingw_common psdk) @@ -62,15 +62,15 @@ add_library(mingw_dllmain crtdll.c dllargv.c) add_dependencies(mingw_dllmain psdk) -if (NOT MSVC) -add_custom_command( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a - COMMAND ${MINGW_PREFIX}dlltool --def ${CMAKE_CURRENT_SOURCE_DIR}/moldname-msvcrt.def --kill-at --output-lib ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a - COMMAND ${MINGW_PREFIX}ar -rc ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a) +if(NOT MSVC) + add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a + COMMAND ${MINGW_PREFIX}dlltool --def ${CMAKE_CURRENT_SOURCE_DIR}/moldname-msvcrt.def --kill-at --output-lib ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a + COMMAND ${MINGW_PREFIX}ar -rc ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a) -set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a PROPERTIES GENERATED TRUE) + set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a PROPERTIES GENERATED TRUE) -add_custom_target(oldnames ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a) + add_custom_target(oldnames ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/liboldnames.a) endif() add_library(getopt getopt.c) Modified: branches/cmake-bringup/lib/3rdparty/zlib/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/3rdparty/zlib…
============================================================================== --- branches/cmake-bringup/lib/3rdparty/zlib/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/3rdparty/zlib/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -19,7 +19,7 @@ zutil.c) if(CMAKE_CROSSCOMPILING) -add_library(zlib ${SOURCE}) + add_library(zlib ${SOURCE}) else() -add_library(zlibhost ${SOURCE}) + add_library(zlibhost ${SOURCE}) endif() Modified: branches/cmake-bringup/lib/atl/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/atl/CMakeList…
============================================================================== --- branches/cmake-bringup/lib/atl/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/atl/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,5 +1,6 @@ -add_definitions(-DUNICODE -D_UNICODE) -add_definitions(-DROS_Headers) +add_definitions( + -DUNICODE -D_UNICODE + -DROS_Headers) -add_library(atlnew atlbase.cpp atlcore.cpp) +add_library(atlnew atlbase.cpp atlcore.cpp) Modified: branches/cmake-bringup/lib/cmlib/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/cmlib/CMakeLi…
============================================================================== --- branches/cmake-bringup/lib/cmlib/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/cmlib/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -13,13 +13,13 @@ hivewrt.c) if(CMAKE_CROSSCOMPILING) -add_library(cmlib ${SOURCE}) -add_dependencies(cmlib bugcodes) + add_library(cmlib ${SOURCE}) + add_dependencies(cmlib bugcodes) else() -add_definitions( - -DWINE_UNICODE_API= - -D__NO_CTYPE_INLINES - -DCMLIB_HOST) -add_library(cmlibhost ${SOURCE}) -target_link_libraries(cmlibhost unicode) + add_definitions( + -DWINE_UNICODE_API= + -D__NO_CTYPE_INLINES + -DCMLIB_HOST) + add_library(cmlibhost ${SOURCE}) + target_link_libraries(cmlibhost unicode) endif() Modified: branches/cmake-bringup/lib/drivers/ip/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/drivers/ip/CM…
============================================================================== --- branches/cmake-bringup/lib/drivers/ip/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/drivers/ip/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -6,7 +6,7 @@ ${REACTOS_SOURCE_DIR}/lib/drivers/oskittcp/include) if(ARCH MATCHES i386) -list(APPEND SOURCE network/i386/checksum.S) + list(APPEND SOURCE network/i386/checksum.S) endif() list(APPEND SOURCE Modified: branches/cmake-bringup/lib/inflib/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/inflib/CMakeL…
============================================================================== --- branches/cmake-bringup/lib/inflib/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/inflib/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,20 +1,15 @@ -SET(GLOBAL_FILES infcore.c infget.c infput.c) +set(GLOBAL_FILES infcore.c infget.c infput.c) if(CMAKE_CROSSCOMPILING) - -file(GLOB_RECURSE SOURCE "infros*.c") -add_library(inflib ${GLOBAL_FILES} ${SOURCE}) -add_dependencies(inflib psdk) - + file(GLOB_RECURSE SOURCE "infros*.c") + add_library(inflib ${GLOBAL_FILES} ${SOURCE}) + add_dependencies(inflib psdk) else() - -file(GLOB_RECURSE SOURCE "infhost*.c") - -add_definitions(-D__NO_CTYPE_INLINES -DINFLIB_HOST) -if(NOT MSVC) -add_definitions(-Wpointer-arith -Wconversion -Wstrict-prototypes -Wmissing-prototypes) + file(GLOB_RECURSE SOURCE "infhost*.c") + add_definitions(-D__NO_CTYPE_INLINES -DINFLIB_HOST) + if(NOT MSVC) + add_definitions(-Wpointer-arith -Wconversion -Wstrict-prototypes -Wmissing-prototypes) + endif() + add_library(inflibhost ${GLOBAL_FILES} ${SOURCE}) endif() -add_library(inflibhost ${GLOBAL_FILES} ${SOURCE}) - -endif() Removed: branches/cmake-bringup/lib/lib.mak URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/lib.mak?rev=5…
============================================================================== --- branches/cmake-bringup/lib/lib.mak [iso-8859-1] (original) +++ branches/cmake-bringup/lib/lib.mak (removed) @@ -1,7 +1,0 @@ -LIB_BASE = lib -LIB_BASE_ = $(LIB_BASE)$(SEP) - -include lib/inflib/inflib.mak -ifeq ($(ARCH),powerpc) -include lib/ppcmmu/ppcmmu.mak -endif Modified: branches/cmake-bringup/lib/newinflib/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/newinflib/CMa…
============================================================================== --- branches/cmake-bringup/lib/newinflib/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/newinflib/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,22 +1,16 @@ -SET(GLOBAL_FILES infcore.c infget.c infput.c) +set(GLOBAL_FILES infcore.c infget.c infput.c) if(CMAKE_CROSSCOMPILING) - -file(GLOB_RECURSE SOURCE "infros*.c") -add_library(newinflib ${GLOBAL_FILES} ${SOURCE}) -add_dependencies(newinflib psdk) - + file(GLOB_RECURSE SOURCE "infros*.c") + add_library(newinflib ${GLOBAL_FILES} ${SOURCE}) + add_dependencies(newinflib psdk) else() - -file(GLOB_RECURSE SOURCE "infhost*.c") - -add_definitions(-DWINE_UNICODE_API= -D__NO_CTYPE_INLINES -DINFLIB_HOST -DUSE_HOST_WCSFUNCS) -if(NOT MSVC) -add_definitions(-Wpointer-arith -Wwrite-strings) + file(GLOB_RECURSE SOURCE "infhost*.c") + add_definitions(-DWINE_UNICODE_API= -D__NO_CTYPE_INLINES -DINFLIB_HOST -DUSE_HOST_WCSFUNCS) + if(NOT MSVC) + add_definitions(-Wpointer-arith -Wwrite-strings) + endif() + add_library(newinflibhost ${GLOBAL_FILES} ${SOURCE}) + target_link_libraries(newinflibhost unicode) endif() -add_library(newinflibhost ${GLOBAL_FILES} ${SOURCE}) -target_link_libraries(newinflibhost unicode) - -endif() - Modified: branches/cmake-bringup/lib/ppcmmu/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/ppcmmu/CMakeL…
============================================================================== --- branches/cmake-bringup/lib/ppcmmu/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/ppcmmu/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -2,8 +2,7 @@ list(APPEND SOURCE dummy.c) if(ARCH MATCHES powerpc) -list(APPEND SOURCE - mmuutil.c) -endif(ARCH MATCHES powerpc) + list(APPEND SOURCE mmuutil.c) +endif() add_library(ppcmmu ${SOURCE}) Modified: branches/cmake-bringup/lib/pseh/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/pseh/CMakeLis…
============================================================================== --- branches/cmake-bringup/lib/pseh/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/pseh/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,20 +1,19 @@ if(NOT MSVC) -list(APPEND SOURCE framebased.c) + list(APPEND SOURCE framebased.c) + if(ARCH MATCHES i386) + list(APPEND SOURCE + i386/framebased.S + i386/framebased-gcchack.c + i386/framebased-gcchack-asm.S) + elseif(ARCH MATCHES amd64) + list(APPEND SOURCE amd64/framebased.S) + elseif(ARCH MATCHES powerpc) + list(APPEND SOURCE powerpc/framebased.S) + endif() -if(ARCH MATCHES i386) -list(APPEND SOURCE - i386/framebased.S - i386/framebased-gcchack.c - i386/framebased-gcchack-asm.S) -elseif(ARCH MATCHES amd64) -list(APPEND SOURCE amd64/framebased.S) -elseif(ARCH MATCHES powerpc) -list(APPEND SOURCE powerpc/framebased.S) -endif(ARCH MATCHES i386) - -add_library(pseh ${SOURCE}) -add_dependencies(pseh psdk) + add_library(pseh ${SOURCE}) + add_dependencies(pseh psdk) endif() Modified: branches/cmake-bringup/lib/recyclebin/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/recyclebin/CM…
============================================================================== --- branches/cmake-bringup/lib/recyclebin/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/recyclebin/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -7,4 +7,4 @@ recyclebin_v5.c recyclebin_v5_enumerator.c) -add_library(recyclebin ${SOURCE}) +add_library(recyclebin ${SOURCE}) Modified: branches/cmake-bringup/lib/rossym/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/rossym/CMakeL…
============================================================================== --- branches/cmake-bringup/lib/rossym/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/rossym/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -19,4 +19,4 @@ pe.c zwfile.c) add_library(rossym ${SOURCE}) -add_dependencies(rossym psdk) +add_dependencies(rossym psdk) Modified: branches/cmake-bringup/lib/rtl/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/rtl/CMakeList…
============================================================================== --- branches/cmake-bringup/lib/rtl/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/rtl/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -66,39 +66,38 @@ workitem.c) if(ARCH MATCHES i386) -list(APPEND SOURCE - i386/debug_asm.S - i386/except_asm.s - i386/except.c - i386/interlck.S - i386/rtlmem.s - i386/res_asm.s - i386/thread.c) + list(APPEND SOURCE + i386/debug_asm.S + i386/except_asm.s + i386/except.c + i386/interlck.S + i386/rtlmem.s + i386/res_asm.s + i386/thread.c) elseif(ARCH MATCHES amd64) -list(APPEND SOURCE - amd64/debug_asm.S - amd64/except_asm.S - amd64/slist.S - amd64/unwind.c - amd64/stubs.c - mem.c - memgen.c) + list(APPEND SOURCE + amd64/debug_asm.S + amd64/except_asm.S + amd64/slist.S + amd64/unwind.c + amd64/stubs.c + mem.c + memgen.c) elseif(ARCH MATCHES arm) -list(APPEND SOURCE - arm/debug_asm.S - mem.c - memgen.c) + list(APPEND SOURCE + arm/debug_asm.S + mem.c + memgen.c) elseif(ARCH MATCHES powerpc) -list(APPEND SOURCE - powerpc/debug.c - powerpc/except.c - powerpc/interlocked.c - powerpc/rtlmem.s - powerpc/rtlswap.s - powerpc/thread.c) -endif(ARCH MATCHES i386) + list(APPEND SOURCE + powerpc/debug.c + powerpc/except.c + powerpc/interlocked.c + powerpc/rtlmem.s + powerpc/rtlswap.s + powerpc/thread.c) +endif() add_library(rtl ${CMAKE_CURRENT_BINARY_DIR}/rtl_rtl.h.gch ${SOURCE}) add_pch(rtl ${CMAKE_CURRENT_SOURCE_DIR}/rtl.h ${SOURCE}) add_dependencies(rtl psdk asm) - Modified: branches/cmake-bringup/lib/sdk/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/sdk/CMakeList…
============================================================================== --- branches/cmake-bringup/lib/sdk/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/sdk/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -7,4 +7,4 @@ add_subdirectory(scrnsave) add_subdirectory(strmiids) add_subdirectory(uuid) -add_subdirectory(wdmguid) +add_subdirectory(wdmguid) Modified: branches/cmake-bringup/lib/sdk/crt/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/sdk/crt/CMake…
============================================================================== --- branches/cmake-bringup/lib/sdk/crt/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/sdk/crt/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -280,139 +280,139 @@ wine/undname.c) if(NOT ARCH MATCHES arm) -list(APPEND CRT_SOURCE - except/${ARCH}/seh.s) + list(APPEND CRT_SOURCE + except/${ARCH}/seh.s) endif() if(ARCH MATCHES i386) -list(APPEND CRT_SOURCE - except/i386/chkstk_asm.s - except/i386/prolog.s - except/i386/unwind.c - float/i386/clearfp.c - float/i386/cntrlfp.c - float/i386/fpreset.c - float/i386/logb.c - float/i386/statfp.c - setjmp/i386/setjmp.s) + list(APPEND CRT_SOURCE + except/i386/chkstk_asm.s + except/i386/prolog.s + except/i386/unwind.c + float/i386/clearfp.c + float/i386/cntrlfp.c + float/i386/fpreset.c + float/i386/logb.c + float/i386/statfp.c + setjmp/i386/setjmp.s) elseif(ARCH MATCHES amd64) -list(APPEND CRT_SOURCE - except/amd64/chkstk_asm.s - float/i386/clearfp.c - float/i386/cntrlfp.c - float/i386/fpreset.c - float/i386/logb.c - float/i386/statfp.c - setjmp/amd64/setjmp.s) + list(APPEND CRT_SOURCE + except/amd64/chkstk_asm.s + float/i386/clearfp.c + float/i386/cntrlfp.c + float/i386/fpreset.c + float/i386/logb.c + float/i386/statfp.c + setjmp/amd64/setjmp.s) endif() if(ARCH MATCHES i386) -list(APPEND CRT_SOURCE - math/i386/alldiv_asm.s - math/i386/alldvrm_asm.s - math/i386/allmul_asm.s - math/i386/allrem_asm.s - math/i386/allshl_asm.s - math/i386/allshr_asm.s - math/i386/atan_asm.s - math/i386/aulldiv_asm.s - math/i386/aulldvrm_asm.s - math/i386/aullrem_asm.s - math/i386/aullshr_asm.s - math/i386/ceil_asm.s - math/i386/ceilf.S - math/i386/cos_asm.s - math/i386/fabs_asm.s - math/i386/floor_asm.s - math/i386/floorf.S - math/i386/ftol_asm.s - math/i386/log_asm.s - math/i386/log10_asm.s - math/i386/pow_asm.s - math/i386/sin_asm.s - math/i386/sqrt_asm.s - math/i386/tan_asm.s - math/i386/atan2_asm.s - math/i386/ci.c - math/i386/exp_asm.s - math/i386/fmod_asm.s - math/i386/fmodf_asm.s - math/i386/ldexp.c - mem/i386/memchr_asm.s - mem/i386/memmove_asm.s - mem/i386/memset_asm.s - misc/i386/readcr4.S - string/i386/strcat_asm.s - string/i386/strchr_asm.s - string/i386/strcmp_asm.s - string/i386/strcpy_asm.s - string/i386/strlen_asm.s - string/i386/strncat_asm.s - string/i386/strncmp_asm.s - string/i386/strncpy_asm.s - string/i386/strnlen_asm.s - string/i386/strrchr_asm.s - string/i386/wcscat_asm.s - string/i386/wcschr_asm.s - string/i386/wcscmp_asm.s - string/i386/wcscpy_asm.s - string/i386/wcslen_asm.s - string/i386/wcsncat_asm.s - string/i386/wcsncmp_asm.s - string/i386/wcsncpy_asm.s - string/i386/wcsnlen_asm.s - string/i386/wcsrchr_asm.s) + list(APPEND CRT_SOURCE + math/i386/alldiv_asm.s + math/i386/alldvrm_asm.s + math/i386/allmul_asm.s + math/i386/allrem_asm.s + math/i386/allshl_asm.s + math/i386/allshr_asm.s + math/i386/atan_asm.s + math/i386/aulldiv_asm.s + math/i386/aulldvrm_asm.s + math/i386/aullrem_asm.s + math/i386/aullshr_asm.s + math/i386/ceil_asm.s + math/i386/ceilf.S + math/i386/cos_asm.s + math/i386/fabs_asm.s + math/i386/floor_asm.s + math/i386/floorf.S + math/i386/ftol_asm.s + math/i386/log_asm.s + math/i386/log10_asm.s + math/i386/pow_asm.s + math/i386/sin_asm.s + math/i386/sqrt_asm.s + math/i386/tan_asm.s + math/i386/atan2_asm.s + math/i386/ci.c + math/i386/exp_asm.s + math/i386/fmod_asm.s + math/i386/fmodf_asm.s + math/i386/ldexp.c + mem/i386/memchr_asm.s + mem/i386/memmove_asm.s + mem/i386/memset_asm.s + misc/i386/readcr4.S + string/i386/strcat_asm.s + string/i386/strchr_asm.s + string/i386/strcmp_asm.s + string/i386/strcpy_asm.s + string/i386/strlen_asm.s + string/i386/strncat_asm.s + string/i386/strncmp_asm.s + string/i386/strncpy_asm.s + string/i386/strnlen_asm.s + string/i386/strrchr_asm.s + string/i386/wcscat_asm.s + string/i386/wcschr_asm.s + string/i386/wcscmp_asm.s + string/i386/wcscpy_asm.s + string/i386/wcslen_asm.s + string/i386/wcsncat_asm.s + string/i386/wcsncmp_asm.s + string/i386/wcsncpy_asm.s + string/i386/wcsnlen_asm.s + string/i386/wcsrchr_asm.s) else() -list(APPEND CRT_SOURCE - math/stubs.c - mem/memchr.c - mem/memcpy.c - mem/memmove.c - mem/memset.c - string/strcat.c - string/strchr.c - string/strcmp.c - string/strcpy.c - string/strlen.c - string/strncat.c - string/strncmp.c - string/strncpy.c - string/strnlen.c - string/strrchr.c - string/wcscat.c - string/wcschr.c - string/wcscmp.c - string/wcscpy.c - string/wcslen.c - string/wcsncat.c - string/wcsncmp.c - string/wcsncpy.c - string/wcsnlen.c - string/wcsrchr.c) + list(APPEND CRT_SOURCE + math/stubs.c + mem/memchr.c + mem/memcpy.c + mem/memmove.c + mem/memset.c + string/strcat.c + string/strchr.c + string/strcmp.c + string/strcpy.c + string/strlen.c + string/strncat.c + string/strncmp.c + string/strncpy.c + string/strnlen.c + string/strrchr.c + string/wcscat.c + string/wcschr.c + string/wcscmp.c + string/wcscpy.c + string/wcslen.c + string/wcsncat.c + string/wcsncmp.c + string/wcsncpy.c + string/wcsnlen.c + string/wcsrchr.c) endif() if(ARCH MATCHES amd64) -list(APPEND CRT_SOURCE - math/cos.c - math/sin.c - math/amd64/alldiv.S - math/amd64/atan.S - math/amd64/atan2.S - math/amd64/ceil.S - math/amd64/ceilf.S - math/amd64/exp.S - math/amd64/fabs.S - math/amd64/floor.S - math/amd64/floorf.S - math/amd64/fmod.S - math/amd64/fmodf.S - math/amd64/ldexp.S - math/amd64/log.S - math/amd64/log10.S - math/amd64/pow.S - math/amd64/sqrt.S - math/amd64/sqrtf.S - math/amd64/tan.S) + list(APPEND CRT_SOURCE + math/cos.c + math/sin.c + math/amd64/alldiv.S + math/amd64/atan.S + math/amd64/atan2.S + math/amd64/ceil.S + math/amd64/ceilf.S + math/amd64/exp.S + math/amd64/fabs.S + math/amd64/floor.S + math/amd64/floorf.S + math/amd64/fmod.S + math/amd64/fmodf.S + math/amd64/ldexp.S + math/amd64/log.S + math/amd64/log10.S + math/amd64/pow.S + math/amd64/sqrt.S + math/amd64/sqrtf.S + math/amd64/tan.S) endif() add_library(crt ${CMAKE_CURRENT_BINARY_DIR}/crt_precomp.h.gch ${CRT_SOURCE}) @@ -471,109 +471,109 @@ wstring/wcsstr.c) if(NOT ARCH MATCHES arm) -list(APPEND LIBCNTPR_SOURCE - except/${ARCH}/chkstk_asm.s - except/${ARCH}/seh.s - setjmp/${ARCH}/setjmp.s) + list(APPEND LIBCNTPR_SOURCE + except/${ARCH}/chkstk_asm.s + except/${ARCH}/seh.s + setjmp/${ARCH}/setjmp.s) endif() if(ARCH MATCHES i386) -list(APPEND LIBCNTPR_SOURCE - math/i386/alldiv_asm.s - math/i386/alldvrm_asm.s - math/i386/allmul_asm.s - math/i386/allrem_asm.s - math/i386/allshl_asm.s - math/i386/allshr_asm.s - math/i386/atan_asm.s - math/i386/aulldiv_asm.s - math/i386/aulldvrm_asm.s - math/i386/aullrem_asm.s - math/i386/aullshr_asm.s - math/i386/ceil_asm.s - math/i386/cos_asm.s - math/i386/fabs_asm.s - math/i386/floor_asm.s - math/i386/ftol_asm.s - math/i386/ftol2_asm.s - math/i386/log_asm.s - math/i386/pow_asm.s - math/i386/sin_asm.s - math/i386/sqrt_asm.s - math/i386/tan_asm.s - math/i386/ci.c - misc/i386/readcr4.S) + list(APPEND LIBCNTPR_SOURCE + math/i386/alldiv_asm.s + math/i386/alldvrm_asm.s + math/i386/allmul_asm.s + math/i386/allrem_asm.s + math/i386/allshl_asm.s + math/i386/allshr_asm.s + math/i386/atan_asm.s + math/i386/aulldiv_asm.s + math/i386/aulldvrm_asm.s + math/i386/aullrem_asm.s + math/i386/aullshr_asm.s + math/i386/ceil_asm.s + math/i386/cos_asm.s + math/i386/fabs_asm.s + math/i386/floor_asm.s + math/i386/ftol_asm.s + math/i386/ftol2_asm.s + math/i386/log_asm.s + math/i386/pow_asm.s + math/i386/sin_asm.s + math/i386/sqrt_asm.s + math/i386/tan_asm.s + math/i386/ci.c + misc/i386/readcr4.S) elseif(ARCH MATCHES amd64) -list(APPEND LIBCNTPR_SOURCE - math/cos.c - math/sin.c - math/amd64/alldiv.S - math/amd64/atan.S - math/amd64/atan2.S - math/amd64/ceil.S - math/amd64/exp.S - math/amd64/fabs.S - math/amd64/floor.S - math/amd64/fmod.S - math/amd64/ldexp.S - math/amd64/log.S - math/amd64/log10.S - math/amd64/pow.S - math/amd64/sqrt.S - math/amd64/tan.S) + list(APPEND LIBCNTPR_SOURCE + math/cos.c + math/sin.c + math/amd64/alldiv.S + math/amd64/atan.S + math/amd64/atan2.S + math/amd64/ceil.S + math/amd64/exp.S + math/amd64/fabs.S + math/amd64/floor.S + math/amd64/fmod.S + math/amd64/ldexp.S + math/amd64/log.S + math/amd64/log10.S + math/amd64/pow.S + math/amd64/sqrt.S + math/amd64/tan.S) endif() if(ARCH MATCHES i386) -list(APPEND LIBCNTPR_SOURCE - mem/i386/memchr_asm.s - mem/i386/memmove_asm.s - mem/i386/memset_asm.s - string/i386/strcat_asm.s - string/i386/strchr_asm.s - string/i386/strcmp_asm.s - string/i386/strcpy_asm.s - string/i386/strlen_asm.s - string/i386/strncat_asm.s - string/i386/strncmp_asm.s - string/i386/strncpy_asm.s - string/i386/strnlen_asm.s - string/i386/strrchr_asm.s - string/i386/wcscat_asm.s - string/i386/wcschr_asm.s - string/i386/wcscmp_asm.s - string/i386/wcscpy_asm.s - string/i386/wcslen_asm.s - string/i386/wcsncat_asm.s - string/i386/wcsncmp_asm.s - string/i386/wcsncpy_asm.s - string/i386/wcsnlen_asm.s - string/i386/wcsrchr_asm.s) + list(APPEND LIBCNTPR_SOURCE + mem/i386/memchr_asm.s + mem/i386/memmove_asm.s + mem/i386/memset_asm.s + string/i386/strcat_asm.s + string/i386/strchr_asm.s + string/i386/strcmp_asm.s + string/i386/strcpy_asm.s + string/i386/strlen_asm.s + string/i386/strncat_asm.s + string/i386/strncmp_asm.s + string/i386/strncpy_asm.s + string/i386/strnlen_asm.s + string/i386/strrchr_asm.s + string/i386/wcscat_asm.s + string/i386/wcschr_asm.s + string/i386/wcscmp_asm.s + string/i386/wcscpy_asm.s + string/i386/wcslen_asm.s + string/i386/wcsncat_asm.s + string/i386/wcsncmp_asm.s + string/i386/wcsncpy_asm.s + string/i386/wcsnlen_asm.s + string/i386/wcsrchr_asm.s) else() -list(APPEND LIBCNTPR_SOURCE - mem/memchr.c - mem/memcpy.c - mem/memmove.c - mem/memset.c - string/strcat.c - string/strchr.c - string/strcmp.c - string/strcpy.c - string/strlen.c - string/strncat.c - string/strncmp.c - string/strncpy.c - string/strnlen.c - string/strrchr.c - string/wcscat.c - string/wcschr.c - string/wcscmp.c - string/wcscpy.c - string/wcslen.c - string/wcsncat.c - string/wcsncmp.c - string/wcsncpy.c - string/wcsnlen.c - string/wcsrchr.c) + list(APPEND LIBCNTPR_SOURCE + mem/memchr.c + mem/memcpy.c + mem/memmove.c + mem/memset.c + string/strcat.c + string/strchr.c + string/strcmp.c + string/strcpy.c + string/strlen.c + string/strncat.c + string/strncmp.c + string/strncpy.c + string/strnlen.c + string/strrchr.c + string/wcscat.c + string/wcschr.c + string/wcscmp.c + string/wcscpy.c + string/wcslen.c + string/wcsncat.c + string/wcsncmp.c + string/wcsncpy.c + string/wcsnlen.c + string/wcsrchr.c) endif() add_library(libcntpr ${LIBCNTPR_SOURCE}) @@ -582,11 +582,11 @@ if(MSVC) # This is a temporary solution until we have proper crt libs -list(APPEND MSVCSUP_SOURCE - misc/fltused.c - except/i386/chkstk_asm.s - math/i386/ftol2_asm.S) - -add_library(msvcsup ${MSVCSUP_SOURCE}) -add_dependencies(msvcsup psdk buildno_header asm) -endif() + list(APPEND MSVCSUP_SOURCE + misc/fltused.c + except/i386/chkstk_asm.s + math/i386/ftol2_asm.S) + + add_library(msvcsup ${MSVCSUP_SOURCE}) + add_dependencies(msvcsup psdk buildno_header asm) +endif() Modified: branches/cmake-bringup/lib/smlib/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/lib/smlib/CMakeLi…
============================================================================== --- branches/cmake-bringup/lib/smlib/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/lib/smlib/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,3 +1,4 @@ + add_definitions(-D_DLL -D__USE_CRTIMP) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/subsys) Modified: branches/cmake-bringup/subsystems/win32/csrss/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/subsystems/win32/…
============================================================================== --- branches/cmake-bringup/subsystems/win32/csrss/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/subsystems/win32/csrss/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,18 +1,16 @@ -include_directories(include) -include_directories(${REACTOS_SOURCE_DIR}/include/reactos/subsys) -include_directories(${REACTOS_SOURCE_DIR}/include/reactos/drivers) +include_directories( + include + ${REACTOS_SOURCE_DIR}/include/reactos/subsys + ${REACTOS_SOURCE_DIR}/include/reactos/drivers) add_executable(csrss csrss.c csrss.rc) set_module_type(csrss nativecui) - target_link_libraries(csrss nt) - add_importlibs(csrss ntdll csrsrv) - add_dependencies(csrss psdk bugcodes) +add_cab_target(csrss 1) add_subdirectory(csrsrv) add_subdirectory(win32csr) -add_cab_target(csrss 1) Modified: branches/cmake-bringup/subsystems/win32/win32k/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/subsystems/win32/…
============================================================================== --- branches/cmake-bringup/subsystems/win32/win32k/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/subsystems/win32/win32k/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -173,7 +173,7 @@ list(APPEND SOURCE dib/dib24bppc.c dib/dib32bppc.c) -endif(ARCH MATCHES i386) +endif() add_library(win32k SHARED ${CMAKE_CURRENT_BINARY_DIR}/win32k_pch.h.gch @@ -192,4 +192,3 @@ add_dependencies(win32k gendib_generated subsystem_napi) add_cab_target(win32k 1) add_importlib_target(win32k.spec win32k.sys) - Modified: branches/cmake-bringup/tools/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/tools/CMakeLists.…
============================================================================== --- branches/cmake-bringup/tools/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/tools/CMakeLists.txt [iso-8859-1] Fri Jan 7 12:11:46 2011 @@ -1,6 +1,6 @@ + add_library(xml xml.cpp) -add_executable(bin2c bin2c.c) #add_executable(pefixup pefixup.c) add_subdirectory(buildno) @@ -12,12 +12,8 @@ add_subdirectory(nci) add_subdirectory(spec2def) add_subdirectory(unicode) + if(NOT MSVC) -#add_subdirectory(rsym) add_subdirectory(wpp) -#add_subdirectory(wmc) add_subdirectory(widl) -#add_subdirectory(wrc) -#add_subdirectory(log2lines) endif() -
13 years, 10 months
1
0
0
0
[tkreuzer] 50307: [WIN32K] - Use if, instead of switch to handle flags in XFORMOBJ_bXformFixPoints - Define XFORMOBJ to EXFORMOBJ, a stack object that links to the matrix - There is no spoon.
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Thu Jan 6 22:00:26 2011 New Revision: 50307 URL:
http://svn.reactos.org/svn/reactos?rev=50307&view=rev
Log: [WIN32K] - Use if, instead of switch to handle flags in XFORMOBJ_bXformFixPoints - Define XFORMOBJ to EXFORMOBJ, a stack object that links to the matrix - There is no spoon. Modified: trunk/reactos/subsystems/win32/win32k/include/coord.h trunk/reactos/subsystems/win32/win32k/include/gdifloat.h trunk/reactos/subsystems/win32/win32k/include/xformobj.h trunk/reactos/subsystems/win32/win32k/objects/xformobj.c trunk/reactos/subsystems/win32/win32k/stubs/stubs.c trunk/reactos/subsystems/win32/win32k/stubs/umpdstubs.c trunk/reactos/subsystems/win32/win32k/win32k.pspec Modified: trunk/reactos/subsystems/win32/win32k/include/coord.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/coord.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/coord.h [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -1,13 +1,80 @@ #pragma once #include <include/dc.h> +#include <include/xformobj.h> -#define IntDPtoLP(dc, pp, c) XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxDeviceToWorld, XF_LTOL, c, pp, pp); -#define IntLPtoDP(dc, pp, c) XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxWorldToDevice, XF_LTOL, c, pp, pp); -#define CoordDPtoLP(dc, pp) XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxDeviceToWorld, XF_LTOL, 1, pp, pp); -#define CoordLPtoDP(dc, pp) XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxWorldToDevice, XF_LTOL, 1, pp, pp); -#define XForm2MatrixS(m, x) XFORMOBJ_iSetXform((XFORMOBJ*)m, (XFORML*)x) -#define MatrixS2XForm(x, m) XFORMOBJ_iGetXform((XFORMOBJ*)m, (XFORML*)x) +#define IntLPtoDP(pdc, ppt, count) DC_vXformWorldToDevice(pdc, count, (PPOINTL)(ppt), (PPOINTL)(ppt)); +#define CoordLPtoDP(pdc, ppt) DC_vXformWorldToDevice(pdc, 1, (PPOINTL)(ppt), (PPOINTL)(ppt)); +#define IntDPtoLP(pdc, ppt, count) DC_vXformDeviceToWorld(pdc, count, (PPOINTL)(ppt), (PPOINTL)(ppt)); +#define CoordDPtoLP(pdc, ppt) DC_vXformDeviceToWorld(pdc, 1, (PPOINTL)(ppt), (PPOINTL)(ppt)); + +#define XForm2MatrixS(m, x) XFormToMatrix(m, (XFORML*)x) +#define MatrixS2XForm(x, m) MatrixToXForm((XFORML*)x, m) + +FORCEINLINE +void +XFormToMatrix( + MATRIX *pmx, + const XFORML *pxform) +{ + XFORMOBJ xo; + XFORMOBJ_vInit(&xo, pmx); + XFORMOBJ_iSetXform(&xo, pxform); +} + +FORCEINLINE +void +MatrixToXForm( + XFORML *pxform, + const MATRIX *pmx) +{ + XFORMOBJ xo; + XFORMOBJ_vInit(&xo, (MATRIX*)pmx); + XFORMOBJ_iGetXform(&xo, pxform); +} + +FORCEINLINE +void +InvertXform( + XFORML *pxformDest, + const XFORML *pxformSource) +{ + XFORMOBJ xo; + MATRIX mx; + + XFORMOBJ_vInit(&xo, &mx); + XFORMOBJ_iSetXform(&xo, pxformSource); + XFORMOBJ_iInverse(&xo, &xo); + XFORMOBJ_iGetXform(&xo, pxformDest); +} + +FORCEINLINE +void +DC_vXformDeviceToWorld( + IN PDC pdc, + IN ULONG cNumPoints, + IN PPOINTL pptlDest, + IN PPOINTL pptlSource) +{ + XFORMOBJ xo; + + XFORMOBJ_vInit(&xo, &pdc->dclevel.mxDeviceToWorld); + XFORMOBJ_bApplyXform(&xo, XF_LTOL, cNumPoints, pptlDest, pptlSource); +} + +FORCEINLINE +void +DC_vXformWorldToDevice( + IN PDC pdc, + IN ULONG cNumPoints, + IN PPOINTL pptlDest, + IN PPOINTL pptlSource) +{ + XFORMOBJ xo; + + XFORMOBJ_vInit(&xo, &pdc->dclevel.mxWorldToDevice); + XFORMOBJ_bApplyXform(&xo, XF_LTOL, cNumPoints, pptlDest, pptlSource); +} int APIENTRY IntGdiSetMapMode(PDC, int); @@ -20,4 +87,4 @@ VOID FASTCALL IntMirrorWindowOrg(PDC); void FASTCALL IntFixIsotropicMapping(PDC); LONG FASTCALL IntCalcFillOrigin(PDC); -PPOINTL FASTCALL IntptlBrushOrigin(PDC pdc,LONG,LONG); +PPOINTL FASTCALL IntptlBrushOrigin(PDC pdc,LONG,LONG); Modified: trunk/reactos/subsystems/win32/win32k/include/gdifloat.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/gdifloat.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/gdifloat.h [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -4,6 +4,7 @@ #include <reactos/win32k/ntgdihdl.h> #include "dc.h" #include "math.h" +#include "xformobj.h" #include <ft2build.h> #include FT_FREETYPE_H Modified: trunk/reactos/subsystems/win32/win32k/include/xformobj.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/xformobj.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/xformobj.h [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -1,28 +1,76 @@ #pragma once + +typedef struct _EXFORMOBJ +{ + MATRIX *pmx; +} EXFORMOBJ; + +#define XFORMOBJ EXFORMOBJ +#define XFORMOBJ_iGetXform EXFORMOBJ_iGetXform +#define XFORMOBJ_iGetFloatObjXform EXFORMOBJ_iGetFloatObjXform +#define XFORMOBJ_bApplyXform EXFORMOBJ_bApplyXform +#define XFORMOBJ_vInit EXFORMOBJ_vInit +#define XFORMOBJ_pmx EXFORMOBJ_pmx +#define XFORMOBJ_iSetXform EXFORMOBJ_iSetXform +#define XFORMOBJ_iCombine EXFORMOBJ_iCombine +#define XFORMOBJ_iCombineXform EXFORMOBJ_iCombineXform +#define XFORMOBJ_iInverse EXFORMOBJ_iInverse + +FORCEINLINE +VOID +XFORMOBJ_vInit( + OUT XFORMOBJ *pxo, + IN MATRIX *pmx) +{ + pxo->pmx = pmx; +} + +FORCEINLINE +MATRIX* +XFORMOBJ_pmx( + IN XFORMOBJ *pxo) +{ + return pxo->pmx; +} ULONG INTERNAL_CALL XFORMOBJ_iSetXform( - OUT XFORMOBJ *pxo, - IN XFORML * pxform); + OUT XFORMOBJ *pxo, + IN const XFORML *pxform); ULONG INTERNAL_CALL XFORMOBJ_iCombine( - IN XFORMOBJ *pxo, - IN XFORMOBJ *pxo1, - IN XFORMOBJ *pxo2); + IN XFORMOBJ *pxo, + IN XFORMOBJ *pxo1, + IN XFORMOBJ *pxo2); ULONG INTERNAL_CALL XFORMOBJ_iCombineXform( - IN XFORMOBJ *pxo, - IN XFORMOBJ *pxo1, - IN XFORML *pxform, - IN BOOL bLeftMultiply); + IN XFORMOBJ *pxo, + IN XFORMOBJ *pxo1, + IN XFORML *pxform, + IN BOOL bLeftMultiply); ULONG INTERNAL_CALL -XFORMOBJ_Inverse( - OUT XFORMOBJ *pxoDst, - IN XFORMOBJ *pxoSrc); +XFORMOBJ_iInverse( + OUT XFORMOBJ *pxoDst, + IN XFORMOBJ *pxoSrc); + +ULONG +APIENTRY +XFORMOBJ_iGetXform( + IN XFORMOBJ *pxo, + OUT XFORML *pxform); + +BOOL +APIENTRY +XFORMOBJ_bApplyXform( + IN XFORMOBJ *pxo, + IN ULONG iMode, + IN ULONG cPoints, + IN PVOID pvIn, + OUT PVOID pvOut); Modified: trunk/reactos/subsystems/win32/win32k/objects/xformobj.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/xformobj.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/xformobj.c [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -97,14 +97,14 @@ { switch (flAccel & (MX_NOTRANSLATE | MX_IDENTITYSCALE | MX_SCALE)) { - case (MX_SCALE | MX_IDENTITYSCALE | MX_NOTRANSLATE): - return GX_IDENTITY; - case (MX_SCALE | MX_IDENTITYSCALE): - return GX_OFFSET; - case MX_SCALE: - return GX_SCALE; - default: - return GX_GENERAL; + case (MX_SCALE | MX_IDENTITYSCALE | MX_NOTRANSLATE): + return GX_IDENTITY; + case (MX_SCALE | MX_IDENTITYSCALE): + return GX_OFFSET; + case MX_SCALE: + return GX_SCALE; + default: + return GX_GENERAL; } } @@ -115,7 +115,7 @@ XFORMOBJ_UpdateAccel( IN XFORMOBJ *pxo) { - PMATRIX pmx = (PMATRIX)pxo; + PMATRIX pmx = XFORMOBJ_pmx(pxo); /* Copy Dx and Dy to FIX format */ pmx->fxDx = FLOATOBJ_GetFix(&pmx->efDx); @@ -124,25 +124,25 @@ pmx->flAccel = 0; if (FLOATOBJ_Equal0(&pmx->efDx) && - FLOATOBJ_Equal0(&pmx->efDy)) + FLOATOBJ_Equal0(&pmx->efDy)) { pmx->flAccel |= MX_NOTRANSLATE; } if (FLOATOBJ_Equal0(&pmx->efM12) && - FLOATOBJ_Equal0(&pmx->efM21)) + FLOATOBJ_Equal0(&pmx->efM21)) { pmx->flAccel |= MX_SCALE; } if (FLOATOBJ_Equal1(&pmx->efM11) && - FLOATOBJ_Equal1(&pmx->efM22)) + FLOATOBJ_Equal1(&pmx->efM22)) { pmx->flAccel |= MX_IDENTITYSCALE; } if (FLOATOBJ_IsLong(&pmx->efM11) && FLOATOBJ_IsLong(&pmx->efM12) && - FLOATOBJ_IsLong(&pmx->efM21) && FLOATOBJ_IsLong(&pmx->efM22)) + FLOATOBJ_IsLong(&pmx->efM21) && FLOATOBJ_IsLong(&pmx->efM22)) { pmx->flAccel |= MX_INTEGER; } @@ -155,9 +155,9 @@ INTERNAL_CALL XFORMOBJ_iSetXform( OUT XFORMOBJ *pxo, - IN XFORML * pxform) -{ - PMATRIX pmx = (PMATRIX)pxo; + IN const XFORML *pxform) +{ + PMATRIX pmx = XFORMOBJ_pmx(pxo); /* Check parameters */ if (!pxo || !pxform) @@ -195,9 +195,9 @@ MATRIX mx; PMATRIX pmx, pmx1, pmx2; - pmx = (PMATRIX)pxo; - pmx1 = (PMATRIX)pxo1; - pmx2 = (PMATRIX)pxo2; + pmx = XFORMOBJ_pmx(pxo); + pmx1 =XFORMOBJ_pmx(pxo1); + pmx2 = XFORMOBJ_pmx(pxo2); /* Do a 3 x 3 matrix multiplication with mx as destinantion */ MulAdd(&mx.efM11, &pmx1->efM11, &pmx2->efM11, &pmx1->efM12, &pmx2->efM21); @@ -226,17 +226,18 @@ IN BOOL bLeftMultiply) { MATRIX mx; - XFORMOBJ *pxo2 = (XFORMOBJ*)&mx; - - XFORMOBJ_iSetXform(pxo2, pxform); + XFORMOBJ xo2; + + XFORMOBJ_vInit(&xo2, &mx); + XFORMOBJ_iSetXform(&xo2, pxform); if (bLeftMultiply) { - return XFORMOBJ_iCombine(pxo, pxo2, pxo1); + return XFORMOBJ_iCombine(pxo, &xo2, pxo1); } else { - return XFORMOBJ_iCombine(pxo, pxo1, pxo2); + return XFORMOBJ_iCombine(pxo, pxo1, &xo2); } } @@ -246,15 +247,15 @@ */ ULONG INTERNAL_CALL -XFORMOBJ_Inverse( +XFORMOBJ_iInverse( OUT XFORMOBJ *pxoDst, IN XFORMOBJ *pxoSrc) { PMATRIX pmxDst, pmxSrc; FLOATOBJ foDet; - pmxDst = (PMATRIX)pxoDst; - pmxSrc = (PMATRIX)pxoSrc; + pmxDst = XFORMOBJ_pmx(pxoDst); + pmxSrc = XFORMOBJ_pmx(pxoSrc); /* det = M11 * M22 - M12 * M21 */ MulSub(&foDet, &pmxSrc->efM11, &pmxSrc->efM22, &pmxSrc->efM12, &pmxSrc->efM21); @@ -296,56 +297,57 @@ FLOATOBJ fo1, fo2; FLONG flAccel; - pmx = (PMATRIX)pxo; - flAccel = pmx->flAccel & (MX_INTEGER|MX_SCALE|MX_IDENTITYSCALE); - - switch (flAccel) - { - case (MX_SCALE | MX_IDENTITYSCALE): - case (MX_SCALE | MX_IDENTITYSCALE | MX_INTEGER): + pmx = XFORMOBJ_pmx(pxo); + flAccel = pmx->flAccel; + + if ((flAccel & (MX_SCALE|MX_IDENTITYSCALE)) == (MX_SCALE|MX_IDENTITYSCALE)) + { /* Identity transformation, nothing todo */ - break; - - case (MX_IDENTITYSCALE | MX_INTEGER): - /* 1-scale integer transform */ - i = cPoints - 1; - do - { - LONG x = pptIn[i].x + pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM21); - LONG y = pptIn[i].y + pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM12); - pptOut[i].y = y; - pptOut[i].x = x; - } - while (--i >= 0); - break; - - case (MX_SCALE | MX_INTEGER): - /* Diagonal integer transform */ - i = cPoints - 1; - do - { - pptOut[i].x = pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM11); - pptOut[i].y = pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM22); - } - while (--i >= 0); - break; - - case (MX_INTEGER): - /* Full integer transform */ - i = cPoints - 1; - do - { - LONG x; - x = pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM11); - x += pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM21); - pptOut[i].y = pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM22); - pptOut[i].y += pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM12); - pptOut[i].x = x; - } - while (--i >= 0); - break; - - case (MX_IDENTITYSCALE): + } + else if (flAccel & MX_INTEGER) + { + if (flAccel & MX_IDENTITYSCALE) + { + /* 1-scale integer transform */ + i = cPoints - 1; + do + { + LONG x = pptIn[i].x + pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM21); + LONG y = pptIn[i].y + pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM12); + pptOut[i].y = y; + pptOut[i].x = x; + } + while (--i >= 0); + } + else if (flAccel & MX_SCALE) + { + /* Diagonal integer transform */ + i = cPoints - 1; + do + { + pptOut[i].x = pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM11); + pptOut[i].y = pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM22); + } + while (--i >= 0); + } + else + { + /* Full integer transform */ + i = cPoints - 1; + do + { + LONG x; + x = pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM11); + x += pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM21); + pptOut[i].y = pptIn[i].y * FLOATOBJ_GetLong(&pmx->efM22); + pptOut[i].y += pptIn[i].x * FLOATOBJ_GetLong(&pmx->efM12); + pptOut[i].x = x; + } + while (--i >= 0); + } + } + else if (flAccel & MX_IDENTITYSCALE) + { /* 1-scale transform */ i = cPoints - 1; do @@ -358,9 +360,9 @@ pptOut[i].y = pptIn[i].y + FLOATOBJ_GetLong(&fo2); } while (--i >= 0); - break; - - case (MX_SCALE): + } + else if (flAccel & MX_SCALE) + { /* Diagonal float transform */ i = cPoints - 1; do @@ -373,9 +375,9 @@ pptOut[i].y = FLOATOBJ_GetLong(&fo2); } while (--i >= 0); - break; - - default: + } + else + { /* Full float transform */ i = cPoints - 1; do @@ -386,7 +388,6 @@ pptOut[i].y = FLOATOBJ_GetLong(&fo2); } while (--i >= 0); - break; } if (!(pmx->flAccel & MX_NOTRANSLATE)) @@ -414,7 +415,7 @@ IN XFORMOBJ *pxo, OUT XFORML *pxform) { - PMATRIX pmx = (PMATRIX)pxo; + PMATRIX pmx = XFORMOBJ_pmx(pxo); /* Check parameters */ if (!pxo || !pxform) @@ -442,7 +443,7 @@ IN XFORMOBJ *pxo, OUT FLOATOBJ_XFORM *pxfo) { - PMATRIX pmx = (PMATRIX)pxo; + PMATRIX pmx = XFORMOBJ_pmx(pxo); /* Check parameters */ if (!pxo || !pxfo) @@ -467,13 +468,14 @@ BOOL APIENTRY XFORMOBJ_bApplyXform( - IN XFORMOBJ *pxo, - IN ULONG iMode, - IN ULONG cPoints, - IN PVOID pvIn, - OUT PVOID pvOut) + IN XFORMOBJ *pxo, + IN ULONG iMode, + IN ULONG cPoints, + IN PVOID pvIn, + OUT PVOID pvOut) { MATRIX mx; + XFORMOBJ xoInv; POINTL *pptl; INT i; @@ -486,13 +488,12 @@ /* Use inverse xform? */ if (iMode == XF_INV_FXTOL || iMode == XF_INV_LTOL) { - ULONG ret; - ret = XFORMOBJ_Inverse((XFORMOBJ*)&mx, pxo); - if (ret == DDI_ERROR) + XFORMOBJ_vInit(&xoInv, &mx); + if (XFORMOBJ_iInverse(&xoInv, pxo) == DDI_ERROR) { return FALSE; } - pxo = (XFORMOBJ*)&mx; + pxo = &xoInv; } /* Convert POINTL to POINTFIX? */ Modified: trunk/reactos/subsystems/win32/win32k/stubs/stubs.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/st…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/stubs/stubs.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/stubs/stubs.c [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -3,6 +3,7 @@ */ #include <win32k.h> +#undef XFORMOBJ #define UNIMPLEMENTED DbgPrint("(%s:%i) WIN32K: %s UNIMPLEMENTED\n", __FILE__, __LINE__, __FUNCTION__ ) Modified: trunk/reactos/subsystems/win32/win32k/stubs/umpdstubs.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/st…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/stubs/umpdstubs.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/stubs/umpdstubs.c [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -1,4 +1,5 @@ #include <win32k.h> +#undef XFORMOBJ #define UNIMPLEMENTED DbgPrint("(%s:%i) WIN32K: %s UNIMPLEMENTED\n", __FILE__, __LINE__, __FUNCTION__ ) Modified: trunk/reactos/subsystems/win32/win32k/win32k.pspec URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/wi…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/win32k.pspec [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/win32k.pspec [iso-8859-1] Thu Jan 6 22:00:26 2011 @@ -214,9 +214,9 @@ @ stdcall WNDOBJ_bEnum(ptr long ptr) @ stdcall WNDOBJ_cEnumStart(ptr long long long) @ stdcall WNDOBJ_vSetConsumer(ptr ptr) -@ stdcall XFORMOBJ_bApplyXform(ptr long long ptr ptr) -@ stdcall XFORMOBJ_iGetFloatObjXform(ptr ptr) -@ stdcall XFORMOBJ_iGetXform(ptr ptr) +@ stdcall XFORMOBJ_bApplyXform(ptr long long ptr ptr) EXFORMOBJ_bApplyXform +@ stdcall XFORMOBJ_iGetFloatObjXform(ptr ptr) EXFORMOBJ_iGetFloatObjXform +@ stdcall XFORMOBJ_iGetXform(ptr ptr) EXFORMOBJ_iGetXform @ stdcall XLATEOBJ_cGetPalette(ptr long long ptr) @ stdcall XLATEOBJ_hGetColorTransform(ptr) @ stdcall XLATEOBJ_iXlate(ptr long)
13 years, 10 months
1
0
0
0
[jgardou] 50306: [APITESTS:GDI32] Add missing \n
by jgardou@svn.reactos.org
Author: jgardou Date: Thu Jan 6 19:03:09 2011 New Revision: 50306 URL:
http://svn.reactos.org/svn/reactos?rev=50306&view=rev
Log: [APITESTS:GDI32] Add missing \n Modified: trunk/rostests/apitests/gdi32/AddFontResourceEx.c Modified: trunk/rostests/apitests/gdi32/AddFontResourceEx.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/gdi32/AddFontRes…
============================================================================== --- trunk/rostests/apitests/gdi32/AddFontResourceEx.c [iso-8859-1] (original) +++ trunk/rostests/apitests/gdi32/AddFontResourceEx.c [iso-8859-1] Thu Jan 6 19:03:09 2011 @@ -29,7 +29,7 @@ SetLastError(_SEH2_GetExceptionCode()); } _SEH2_END - ok(result == -1, "AddFontResourceExW should throw an exception!, result == %d", result); + ok(result == -1, "AddFontResourceExW should throw an exception!, result == %d\n", result); ok(GetLastError() == 0xc0000005, "GetLastError()==%lx\n", GetLastError()); /* Test "" filename */
13 years, 10 months
1
0
0
0
[akhaldi] 50305: [CMAKE] - Restructure hal build.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Thu Jan 6 18:59:49 2011 New Revision: 50305 URL:
http://svn.reactos.org/svn/reactos?rev=50305&view=rev
Log: [CMAKE] - Restructure hal build. Added: branches/cmake-bringup/hal/halx86/CMakeLists.txt (with props) Modified: branches/cmake-bringup/hal/CMakeLists.txt Modified: branches/cmake-bringup/hal/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/hal/CMakeLists.tx…
============================================================================== --- branches/cmake-bringup/hal/CMakeLists.txt [iso-8859-1] (original) +++ branches/cmake-bringup/hal/CMakeLists.txt [iso-8859-1] Thu Jan 6 18:59:49 2011 @@ -1,110 +1,8 @@ -spec2def(hal.dll hal.spec) - -if(ARCH MATCHES i386) - -add_definitions( - -D_NTHALDLL_ - -D_NTHAL_) - -include_directories( - halx86/include - ${REACTOS_SOURCE_DIR}/ntoskrnl/include) - -list(APPEND HAL_GENERIC_SOURCE - halx86/generic/beep.c - halx86/generic/cmos.c - halx86/generic/display.c - halx86/generic/dma.c - halx86/generic/drive.c - halx86/generic/memory.c - halx86/generic/misc.c - halx86/generic/profil.c - halx86/generic/reboot.c - halx86/generic/sysinfo.c - halx86/generic/timer.c - halx86/generic/usage.c) - -list(APPEND HAL_GENERIC_SOURCE - halx86/generic/bios.c - halx86/generic/halinit.c - halx86/generic/i386/portio.c - halx86/generic/i386/systimer.S - halx86/generic/i386/trap.S) - -list(APPEND HAL_GENERIC_PCAT_SOURCE - halx86/generic/legacy/bus/bushndlr.c - halx86/generic/legacy/bus/cmosbus.c - halx86/generic/legacy/bus/isabus.c - halx86/generic/legacy/bus/pcibus.c - halx86/generic/legacy/bus/pcidata.c - halx86/generic/legacy/bus/sysbus.c - halx86/generic/legacy/bussupp.c - halx86/generic/legacy/halpcat.c) - -list(APPEND HAL_GENERIC_UP_SOURCE - halx86/generic/spinlock.c - halx86/up/pic.c - halx86/up/processor.c) - -list(APPEND HAL_SOURCE - ${CMAKE_CURRENT_BINARY_DIR}/hal_hal.h.gch - ${HAL_GENERIC_SOURCE} - ${HAL_GENERIC_PCAT_SOURCE} - ${HAL_GENERIC_UP_SOURCE} - halx86/up/halinit_up.c - halx86/up/halup.rc - ${CMAKE_CURRENT_BINARY_DIR}/hal.def) - -add_library(hal SHARED ${HAL_SOURCE}) -add_pch(hal ${CMAKE_CURRENT_SOURCE_DIR}/halx86/include/hal.h ${HAL_SOURCE}) -add_dependencies(hal psdk bugcodes) - -set_entrypoint(hal HalInitSystem@8) -set_subsystem(hal native) -set_image_base(hal 0x00010000) - -add_importlibs(hal ntoskrnl) - -target_link_libraries(hal libcntpr) - -list(APPEND MINI_HAL_SOURCE - halx86/generic/legacy/bus/bushndlr.c - halx86/generic/legacy/bus/cmosbus.c - halx86/generic/legacy/bus/isabus.c - halx86/generic/legacy/bus/pcibus.c - halx86/generic/legacy/bus/sysbus.c - halx86/generic/legacy/bussupp.c - halx86/generic/beep.c - halx86/generic/bios.c - halx86/generic/cmos.c - halx86/generic/dma.c - halx86/generic/display.c - halx86/generic/drive.c - halx86/generic/misc.c - halx86/generic/profil.c - halx86/generic/reboot.c - halx86/generic/spinlock.c - halx86/generic/sysinfo.c - halx86/generic/timer.c - halx86/generic/usage.c - halx86/up/halinit_up.c - halx86/up/pic.c - halx86/up/processor.c) - -if(ARCH MATCHES i386) -list(APPEND MINI_HAL_SOURCE - halx86/generic/i386/portio.c - halx86/generic/i386/systimer.S) -endif(ARCH MATCHES i386) - -add_library(mini_hal ${MINI_HAL_SOURCE}) -set_property(TARGET mini_hal PROPERTY COMPILE_DEFINITIONS "_BLDR_;_MINIHAL_") -add_dependencies(mini_hal psdk bugcodes asm) -add_minicd_target(hal reactos hal.dll) -add_livecd_target(hal reactos/system32) -else() -#TBD -endif(ARCH MATCHES i386) - -add_importlib_target(hal.spec) +if(ARCH MATCHES i386 OR ARCH MATCHES amd64) + add_subdirectory(halx86) +elseif(ARCH MATCHES arm) +# add_subdirectory(halarm) +elseif(ARCH MATCHES powerpc) +# add_subdirectory(halppc) +endif() Added: branches/cmake-bringup/hal/halx86/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/hal/halx86/CMakeL…
============================================================================== --- branches/cmake-bringup/hal/halx86/CMakeLists.txt (added) +++ branches/cmake-bringup/hal/halx86/CMakeLists.txt [iso-8859-1] Thu Jan 6 18:59:49 2011 @@ -1,0 +1,116 @@ + +add_definitions( + -D_NTHALDLL_ + -D_NTHAL_) + +include_directories( + include + ${REACTOS_SOURCE_DIR}/ntoskrnl/include) + +list(APPEND HAL_GENERIC_SOURCE + generic/beep.c + generic/cmos.c + generic/display.c + generic/dma.c + generic/drive.c + generic/memory.c + generic/misc.c + generic/profil.c + generic/reboot.c + generic/sysinfo.c + generic/timer.c + generic/usage.c) + +if(ARCH MATCHES i386) + list(APPEND HAL_GENERIC_SOURCE + generic/bios.c + generic/halinit.c + generic/i386/portio.c + generic/i386/systimer.S + generic/i386/trap.S) +endif() + +list(APPEND HAL_GENERIC_PCAT_SOURCE + generic/legacy/bus/bushndlr.c + generic/legacy/bus/cmosbus.c + generic/legacy/bus/isabus.c + generic/legacy/bus/pcibus.c + generic/legacy/bus/pcidata.c + generic/legacy/bus/sysbus.c + generic/legacy/bussupp.c + generic/legacy/halpcat.c) + +list(APPEND HAL_GENERIC_ACPI_SOURCE + generic/acpi/halacpi.c + generic/acpi/halpnpdd.c + generic/acpi/busemul.c + generic/legacy/bus/pcibus.c) + +if(ARCH MATCHES i386) + + list(APPEND HAL_GENERIC_UP_SOURCE + generic/spinlock.c + up/pic.c + up/processor.c) + + list(APPEND MINI_HAL_SOURCE + generic/i386/portio.c + generic/i386/systimer.S + generic/legacy/bus/bushndlr.c + generic/legacy/bus/cmosbus.c + generic/legacy/bus/isabus.c + generic/legacy/bus/pcibus.c + generic/legacy/bus/sysbus.c + generic/legacy/bussupp.c + generic/beep.c + generic/bios.c + generic/cmos.c + generic/dma.c + generic/display.c + generic/drive.c + generic/misc.c + generic/profil.c + generic/reboot.c + generic/spinlock.c + generic/sysinfo.c + generic/timer.c + generic/usage.c + up/halinit_up.c + up/pic.c + up/processor.c) + + spec2def(hal.dll ../hal.spec) + + list(APPEND HAL_SOURCE + ${CMAKE_CURRENT_BINARY_DIR}/hal_hal.h.gch + ${HAL_GENERIC_SOURCE} + ${HAL_GENERIC_PCAT_SOURCE} + ${HAL_GENERIC_UP_SOURCE} + up/halinit_up.c + up/halup.rc + ${CMAKE_CURRENT_BINARY_DIR}/hal.def) + + # hal + add_library(hal SHARED ${HAL_SOURCE}) + add_pch(hal ${CMAKE_CURRENT_SOURCE_DIR}/include/hal.h ${HAL_SOURCE}) + add_dependencies(hal psdk bugcodes) + + set_entrypoint(hal HalInitSystem@8) + set_subsystem(hal native) + set_image_base(hal 0x00010000) + add_importlibs(hal ntoskrnl) + target_link_libraries(hal libcntpr) + + add_minicd_target(hal reactos hal.dll) + add_livecd_target(hal reactos/system32) + + # mini_hal + add_library(mini_hal ${MINI_HAL_SOURCE}) + set_property(TARGET mini_hal PROPERTY COMPILE_DEFINITIONS "_BLDR_;_MINIHAL_") + add_dependencies(mini_hal psdk bugcodes asm) + +elseif(ARCH MATCHES amd64) +#TBD +endif() + +add_importlib_target(../hal.spec) Propchange: branches/cmake-bringup/hal/halx86/CMakeLists.txt ------------------------------------------------------------------------------ svn:eol-style = native
13 years, 10 months
1
0
0
0
← Newer
1
...
25
26
27
28
29
30
31
...
34
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
Results per page:
10
25
50
100
200