diff --git a/client/DirectFB/CMakeLists.txt b/client/DirectFB/CMakeLists.txt index e0e06a123..d0ef4b302 100644 --- a/client/DirectFB/CMakeLists.txt +++ b/client/DirectFB/CMakeLists.txt @@ -17,10 +17,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -include_directories(../../libfreerdp-gdi) -include_directories(../../libfreerdp-kbd) -include_directories(../../libfreerdp-core) -include_directories(../../libfreerdp-cache) include_directories(${DIRECTFB_INCLUDE_DIRS}) add_executable(dfreerdp diff --git a/client/DirectFB/df_event.c b/client/DirectFB/df_event.c index bac14eec9..52d8d9fb4 100644 --- a/client/DirectFB/df_event.c +++ b/client/DirectFB/df_event.c @@ -17,8 +17,8 @@ * limitations under the License. */ -#include "keyboard.h" -#include +#include +#include #include "df_event.h" diff --git a/client/DirectFB/dfreerdp.h b/client/DirectFB/dfreerdp.h index f134d4255..78f8cae27 100644 --- a/client/DirectFB/dfreerdp.h +++ b/client/DirectFB/dfreerdp.h @@ -20,13 +20,13 @@ #ifndef __DFREERDP_H #define __DFREERDP_H -#include "gdi.h" #include #include #include #include #include -#include +#include +#include #define SET_DFI(_instance, _dfi) (_instance)->param1 = _dfi #define GET_DFI(_instance) ((dfInfo*) ((_instance)->param1)) diff --git a/client/X11/CMakeLists.txt b/client/X11/CMakeLists.txt index 93e18364d..b8ea2675d 100644 --- a/client/X11/CMakeLists.txt +++ b/client/X11/CMakeLists.txt @@ -17,10 +17,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -include_directories(../../libfreerdp-gdi) -include_directories(../../libfreerdp-kbd) -include_directories(../../libfreerdp-core) -include_directories(../../libfreerdp-cache) include_directories(${X11_INCLUDE_DIRS}) add_executable(xfreerdp diff --git a/client/X11/xf_event.c b/client/X11/xf_event.c index f2fe7ef98..bdba6b733 100644 --- a/client/X11/xf_event.c +++ b/client/X11/xf_event.c @@ -17,8 +17,8 @@ * limitations under the License. */ -#include "keyboard.h" -#include +#include +#include #include "xf_event.h" diff --git a/client/X11/xf_keyboard.c b/client/X11/xf_keyboard.c index fe904be4d..d9e8e5bf5 100644 --- a/client/X11/xf_keyboard.c +++ b/client/X11/xf_keyboard.c @@ -24,8 +24,8 @@ #include #include -#include "keyboard.h" -#include +#include +#include #include "xf_keyboard.h" diff --git a/client/X11/xfreerdp.h b/client/X11/xfreerdp.h index 649eee638..54e9ca353 100644 --- a/client/X11/xfreerdp.h +++ b/client/X11/xfreerdp.h @@ -20,11 +20,11 @@ #ifndef __XFREERDP_H #define __XFREERDP_H -#include "gdi.h" #include #include #include -#include +#include +#include typedef struct xf_info xfInfo; diff --git a/client/test/CMakeLists.txt b/client/test/CMakeLists.txt index ec412b938..09235b4e1 100644 --- a/client/test/CMakeLists.txt +++ b/client/test/CMakeLists.txt @@ -17,10 +17,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -include_directories(../../libfreerdp-gdi) -include_directories(../../libfreerdp-core) -include_directories(../../libfreerdp-cache) - add_executable(freerdp-test freerdp.c) diff --git a/client/test/freerdp.c b/client/test/freerdp.c index 1820b6eae..cbc39021f 100644 --- a/client/test/freerdp.c +++ b/client/test/freerdp.c @@ -17,19 +17,19 @@ * limitations under the License. */ -#include "gdi.h" #include #include #include #include #include #include +#include #include #include #include #include #include -#include +#include #include #define SET_TFI(_instance, _tfi) (_instance)->param1 = _tfi diff --git a/cunit/test_chanman.c b/cunit/test_chanman.c index 3040af6b8..a5cde3427 100644 --- a/cunit/test_chanman.c +++ b/cunit/test_chanman.c @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include #include "test_chanman.h" diff --git a/cunit/test_cliprdr.c b/cunit/test_cliprdr.c index 4174a2706..69ae3aed6 100644 --- a/cunit/test_cliprdr.c +++ b/cunit/test_cliprdr.c @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/cunit/test_color.c b/cunit/test_color.c index 93333817e..16214809e 100644 --- a/cunit/test_color.c +++ b/cunit/test_color.c @@ -20,8 +20,8 @@ #include #include #include -#include "gdi.h" -#include "color.h" +#include +#include #include "test_color.h" int init_color_suite(void) diff --git a/cunit/test_drdynvc.c b/cunit/test_drdynvc.c index 12f7f89f1..a6d003003 100644 --- a/cunit/test_drdynvc.c +++ b/cunit/test_drdynvc.c @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/cunit/test_libgdi.c b/cunit/test_libgdi.c index 96a0e439d..6932f0572 100644 --- a/cunit/test_libgdi.c +++ b/cunit/test_libgdi.c @@ -22,7 +22,8 @@ #include #include -#include "gdi.h" +#include + #include "gdi_dc.h" #include "gdi_pen.h" #include "gdi_line.h" diff --git a/cunit/test_librfx.c b/cunit/test_librfx.c index 4f8299d27..130dbac93 100644 --- a/cunit/test_librfx.c +++ b/cunit/test_librfx.c @@ -28,7 +28,7 @@ #include #include #include -#include +#include #include "rfx_types.h" #include "rfx_bitstream.h" #include "rfx_rlgr.h" diff --git a/libfreerdp-cache/bitmap_v2.h b/include/freerdp/cache/bitmap_v2.h similarity index 100% rename from libfreerdp-cache/bitmap_v2.h rename to include/freerdp/cache/bitmap_v2.h diff --git a/libfreerdp-cache/brush.h b/include/freerdp/cache/brush.h similarity index 100% rename from libfreerdp-cache/brush.h rename to include/freerdp/cache/brush.h diff --git a/libfreerdp-cache/cache.h b/include/freerdp/cache/cache.h similarity index 88% rename from libfreerdp-cache/cache.h rename to include/freerdp/cache/cache.h index 403e9f578..1b7e51fd8 100644 --- a/libfreerdp-cache/cache.h +++ b/include/freerdp/cache/cache.h @@ -20,10 +20,10 @@ #ifndef __CACHE_H #define __CACHE_H -#include "brush.h" -#include "bitmap_v2.h" -#include "offscreen.h" -#include "color_table.h" +#include +#include +#include +#include #include #include diff --git a/libfreerdp-cache/color_table.h b/include/freerdp/cache/color_table.h similarity index 100% rename from libfreerdp-cache/color_table.h rename to include/freerdp/cache/color_table.h diff --git a/libfreerdp-cache/offscreen.h b/include/freerdp/cache/offscreen.h similarity index 100% rename from libfreerdp-cache/offscreen.h rename to include/freerdp/cache/offscreen.h diff --git a/include/freerdp/chanman.h b/include/freerdp/chanman/chanman.h similarity index 100% rename from include/freerdp/chanman.h rename to include/freerdp/chanman/chanman.h diff --git a/libfreerdp-gdi/color.h b/include/freerdp/gdi/color.h similarity index 100% rename from libfreerdp-gdi/color.h rename to include/freerdp/gdi/color.h diff --git a/libfreerdp-gdi/gdi.h b/include/freerdp/gdi/gdi.h similarity index 99% rename from libfreerdp-gdi/gdi.h rename to include/freerdp/gdi/gdi.h index ff044143c..c5e9427d4 100644 --- a/libfreerdp-gdi/gdi.h +++ b/include/freerdp/gdi/gdi.h @@ -20,7 +20,7 @@ #ifndef __GDI_H #define __GDI_H -#include "cache.h" +#include #include "color.h" #include #include diff --git a/include/freerdp/kbd.h b/include/freerdp/kbd/kbd.h similarity index 100% rename from include/freerdp/kbd.h rename to include/freerdp/kbd/kbd.h diff --git a/libfreerdp-kbd/layout_ids.h b/include/freerdp/kbd/layouts.h similarity index 98% rename from libfreerdp-kbd/layout_ids.h rename to include/freerdp/kbd/layouts.h index 8af8cc636..d64952884 100644 --- a/libfreerdp-kbd/layout_ids.h +++ b/include/freerdp/kbd/layouts.h @@ -22,7 +22,7 @@ #ifndef __LAYOUT_IDS_H #define __LAYOUT_IDS_H -#include +#include /* Keyboard layout IDs */ @@ -177,10 +177,7 @@ #define KBD_CHINESE_TRADITIONAL_MICROSOFT_PINYIN_IME_3 0xE00E0804 #define KBD_CHINESE_TRADITIONAL_ALPHANUMERIC 0xE00F0404 -rdpKeyboardLayout * -get_keyboard_layouts(int types); - -char * -get_layout_name(unsigned int keyboardLayoutID); +rdpKeyboardLayout* get_keyboard_layouts(int types); +char* get_layout_name(unsigned int keyboardLayoutID); #endif diff --git a/libfreerdp-kbd/locales.h b/include/freerdp/kbd/locales.h similarity index 100% rename from libfreerdp-kbd/locales.h rename to include/freerdp/kbd/locales.h diff --git a/libfreerdp-kbd/keyboard.h b/include/freerdp/kbd/vkcodes.h similarity index 99% rename from libfreerdp-kbd/keyboard.h rename to include/freerdp/kbd/vkcodes.h index 7fe974e01..40d2e4e3d 100644 --- a/libfreerdp-kbd/keyboard.h +++ b/include/freerdp/kbd/vkcodes.h @@ -19,12 +19,11 @@ /* Microsoft Windows Virtual Key Codes: http://msdn.microsoft.com/en-us/library/ms645540.aspx */ -#ifndef __KEYBOARD_H -#define __KEYBOARD_H +#ifndef __VKCODES_H +#define __VKCODES_H #include - -#include "layout_ids.h" +#include /* Mouse buttons */ @@ -584,4 +583,4 @@ static const virtualKey virtualKeyboard[256 + 2] = { 0x1C, 1, "" , "KPEN" }, }; -#endif /* __KEYBOARD_H */ +#endif /* __VKCODES_H */ diff --git a/include/freerdp/rail.h b/include/freerdp/rail.h index 7eaf8cf80..c7b45432e 100644 --- a/include/freerdp/rail.h +++ b/include/freerdp/rail.h @@ -309,173 +309,19 @@ enum FRDP_EVENT_TYPE_RAIL /* RAIL Common structures */ -// Events from 'rail' vchannel plugin to UI -enum RAIL_VCHANNEL_EVENT -{ - RAIL_VCHANNEL_EVENT_SESSION_ESTABLISHED = 1, - RAIL_VCHANNEL_EVENT_EXEC_RESULT_RETURNED, - RAIL_VCHANNEL_EVENT_SERVER_SYSPARAM_RECEIVED, - RAIL_VCHANNEL_EVENT_MOVESIZE_STARTED, - RAIL_VCHANNEL_EVENT_MOVESIZE_FINISHED, - RAIL_VCHANNEL_EVENT_MINMAX_INFO_UPDATED, - RAIL_VCHANNEL_EVENT_LANGBAR_STATUS_UPDATED, - RAIL_VCHANNEL_EVENT_APP_RESPONSE_RECEIVED -}; - typedef struct _RAIL_VCHANNEL_EVENT { uint32 event_id; - - union - { - struct - { - uint16 flags; - uint16 exec_result; - uint32 raw_result; - const char* exe_or_file; - } exec_result_info; - - struct - { - uint32 param_type; - boolean screen_saver_enabled; - boolean screen_saver_lock_enabled; - } server_param_info; - - struct - { - uint32 window_id; - uint16 move_size_type; - uint16 pos_x; - uint16 pos_y; - } movesize_info; - - struct - { - uint32 window_id; - uint16 max_width; - uint16 max_height; - uint16 max_pos_x; - uint16 max_pos_y; - uint16 min_track_width; - uint16 min_track_height; - uint16 max_track_width; - uint16 max_track_height; - } minmax_info; - - struct - { - uint32 status; - } langbar_info; - - struct - { - uint32 window_id; - const char* application_id; - - } app_response_info; - - }param; + void* param; } RAIL_VCHANNEL_EVENT; -// Events from UI to 'rail' vchannel plugin -enum RAIL_UI_EVENT -{ - RAIL_UI_EVENT_UPDATE_CLIENT_SYSPARAM = 1, - RAIL_UI_EVENT_EXECUTE_REMOTE_APP, - RAIL_UI_EVENT_ACTIVATE, - RAIL_UI_EVENT_SYS_COMMAND, - RAIL_UI_EVENT_NOTIFY, - RAIL_UI_EVENT_WINDOW_MOVE, - RAIL_UI_EVENT_SYSTEM_MENU, - RAIL_UI_EVENT_LANGBAR_INFO, - RAIL_UI_EVENT_GET_APP_ID -}; - typedef struct _RAIL_UI_EVENT { uint32 event_id; - - union - { - struct - { - uint32 param; - - union - { - boolean full_window_drag_enabled; - boolean menu_access_key_always_underlined; - boolean keyboard_for_user_prefered; - boolean left_right_mouse_buttons_swapped; - RECTANGLE_16 work_area; - RECTANGLE_16 display_resolution; - RECTANGLE_16 taskbar_size; - struct - { - uint32 flags; - const char* color_scheme; - } high_contrast_system_info; - } value; - - } sysparam_info; - - struct - { - boolean exec_or_file_is_file_path; - const char* exe_or_file; - const char* working_directory; - const char* arguments; - } execute_info; - - struct - { - uint32 window_id; - boolean enabled; - } activate_info; - - struct - { - uint32 window_id; - uint32 syscommand; - } syscommand_info; - - struct - { - uint32 window_id; - uint32 notify_icon_id; - uint32 message; - } notify_info; - - struct - { - uint32 window_id; - RECTANGLE_16 new_position; - } window_move_info; - - struct - { - uint32 window_id; - uint16 left; - uint16 top; - } system_menu_info; - - struct - { - uint32 status; - } langbar_info; - - - struct - { - uint32 window_id; - } get_app_id_info; - } param; + void* param; } RAIL_UI_EVENT; - #endif /* __RAIL_H */ diff --git a/include/freerdp/rfx.h b/include/freerdp/rfx/rfx.h similarity index 100% rename from include/freerdp/rfx.h rename to include/freerdp/rfx/rfx.h diff --git a/libfreerdp-cache/CMakeLists.txt b/libfreerdp-cache/CMakeLists.txt index fac9e0a78..fa0e6f596 100644 --- a/libfreerdp-cache/CMakeLists.txt +++ b/libfreerdp-cache/CMakeLists.txt @@ -19,15 +19,10 @@ set(FREERDP_CACHE_SRCS brush.c - brush.h bitmap_v2.c - bitmap_v2.h offscreen.c - offscreen.h color_table.c - color_table.h - cache.c - cache.h) + cache.c) add_library(freerdp-cache SHARED ${FREERDP_CACHE_SRCS}) diff --git a/libfreerdp-cache/bitmap_v2.c b/libfreerdp-cache/bitmap_v2.c index f931ef75f..e5297b383 100644 --- a/libfreerdp-cache/bitmap_v2.c +++ b/libfreerdp-cache/bitmap_v2.c @@ -20,7 +20,7 @@ #include #include -#include "bitmap_v2.h" +#include void* bitmap_v2_get(rdpBitmapV2* bitmap_v2, uint8 id, uint16 index) { diff --git a/libfreerdp-cache/brush.c b/libfreerdp-cache/brush.c index 03d8b05e9..483bebb86 100644 --- a/libfreerdp-cache/brush.c +++ b/libfreerdp-cache/brush.c @@ -20,7 +20,7 @@ #include #include -#include "brush.h" +#include void* brush_get(rdpBrush* brush, uint8 index, uint8* bpp) { diff --git a/libfreerdp-cache/cache.c b/libfreerdp-cache/cache.c index ac2baab1d..5b1a3e163 100644 --- a/libfreerdp-cache/cache.c +++ b/libfreerdp-cache/cache.c @@ -20,7 +20,7 @@ #include #include -#include "cache.h" +#include rdpCache* cache_new(rdpSettings* settings) { diff --git a/libfreerdp-cache/color_table.c b/libfreerdp-cache/color_table.c index 32d67483e..a1d474ddb 100644 --- a/libfreerdp-cache/color_table.c +++ b/libfreerdp-cache/color_table.c @@ -20,7 +20,7 @@ #include #include -#include "color_table.h" +#include void* color_table_get(rdpColorTable* color_table, uint8 index) { diff --git a/libfreerdp-cache/offscreen.c b/libfreerdp-cache/offscreen.c index 143b22547..88f9d8a02 100644 --- a/libfreerdp-cache/offscreen.c +++ b/libfreerdp-cache/offscreen.c @@ -20,7 +20,7 @@ #include #include -#include "offscreen.h" +#include void* offscreen_get(rdpOffscreen* offscreen, uint16 index) { diff --git a/libfreerdp-chanman/libchanman.c b/libfreerdp-chanman/libchanman.c index b5f2fef81..d7eeca737 100644 --- a/libfreerdp-chanman/libchanman.c +++ b/libfreerdp-chanman/libchanman.c @@ -38,7 +38,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/libfreerdp-gdi/CMakeLists.txt b/libfreerdp-gdi/CMakeLists.txt index 4132d9194..6b5bcfc1a 100644 --- a/libfreerdp-gdi/CMakeLists.txt +++ b/libfreerdp-gdi/CMakeLists.txt @@ -17,11 +17,8 @@ # See the License for the specific language governing permissions and # limitations under the License. -include_directories(../libfreerdp-cache) - set(FREERDP_GDI_SRCS color.c - color.h gdi_8bpp.c gdi_8bpp.h gdi_16bpp.c @@ -48,8 +45,7 @@ set(FREERDP_GDI_SRCS gdi_region.h gdi_shape.c gdi_shape.h - gdi.c - gdi.h) + gdi.c) add_library(freerdp-gdi SHARED ${FREERDP_GDI_SRCS}) diff --git a/libfreerdp-gdi/color.c b/libfreerdp-gdi/color.c index 310490ed6..76fdff86e 100644 --- a/libfreerdp-gdi/color.c +++ b/libfreerdp-gdi/color.c @@ -21,8 +21,7 @@ #include #include #include - -#include "color.h" +#include uint32 gdi_color_convert_rgb(uint32 srcColor, int srcBpp, int dstBpp, HCLRCONV clrconv) { diff --git a/libfreerdp-gdi/gdi.c b/libfreerdp-gdi/gdi.c index 615ae8745..059f8c44d 100644 --- a/libfreerdp-gdi/gdi.c +++ b/libfreerdp-gdi/gdi.c @@ -22,9 +22,8 @@ #include #include #include -#include - -#include "color.h" +#include +#include #include "gdi_dc.h" #include "gdi_pen.h" @@ -37,7 +36,7 @@ #include "gdi_drawing.h" #include "gdi_clipping.h" -#include "gdi.h" +#include /* Ternary Raster Operation Table */ const uint32 rop3_code_table[] = diff --git a/libfreerdp-gdi/gdi_16bpp.c b/libfreerdp-gdi/gdi_16bpp.c index f4fbc3fbc..a2a44921c 100644 --- a/libfreerdp-gdi/gdi_16bpp.c +++ b/libfreerdp-gdi/gdi_16bpp.c @@ -21,9 +21,9 @@ #include #include #include +#include +#include -#include "gdi.h" -#include "color.h" #include "gdi_pen.h" #include "gdi_bitmap.h" #include "gdi_region.h" diff --git a/libfreerdp-gdi/gdi_16bpp.h b/libfreerdp-gdi/gdi_16bpp.h index 5f51f1c91..8566f0d87 100644 --- a/libfreerdp-gdi/gdi_16bpp.h +++ b/libfreerdp-gdi/gdi_16bpp.h @@ -18,7 +18,7 @@ */ #include -#include "gdi.h" +#include typedef void (*pSetPixel16_ROP2)(uint16 *pixel, uint16 *pen); diff --git a/libfreerdp-gdi/gdi_32bpp.c b/libfreerdp-gdi/gdi_32bpp.c index 36f53f83e..323f332b2 100644 --- a/libfreerdp-gdi/gdi_32bpp.c +++ b/libfreerdp-gdi/gdi_32bpp.c @@ -21,9 +21,9 @@ #include #include #include +#include +#include -#include "gdi.h" -#include "color.h" #include "gdi_pen.h" #include "gdi_bitmap.h" #include "gdi_region.h" diff --git a/libfreerdp-gdi/gdi_32bpp.h b/libfreerdp-gdi/gdi_32bpp.h index c64814567..ee484dac2 100644 --- a/libfreerdp-gdi/gdi_32bpp.h +++ b/libfreerdp-gdi/gdi_32bpp.h @@ -18,7 +18,7 @@ */ #include -#include "gdi.h" +#include typedef void (*pSetPixel32_ROP2)(uint32 *pixel, uint32 *pen); diff --git a/libfreerdp-gdi/gdi_8bpp.c b/libfreerdp-gdi/gdi_8bpp.c index 7c93f62e8..24c01981a 100644 --- a/libfreerdp-gdi/gdi_8bpp.c +++ b/libfreerdp-gdi/gdi_8bpp.c @@ -21,9 +21,9 @@ #include #include #include +#include +#include -#include "gdi.h" -#include "color.h" #include "gdi_pen.h" #include "gdi_bitmap.h" #include "gdi_region.h" diff --git a/libfreerdp-gdi/gdi_8bpp.h b/libfreerdp-gdi/gdi_8bpp.h index 6ee6e4d09..e87750d6f 100644 --- a/libfreerdp-gdi/gdi_8bpp.h +++ b/libfreerdp-gdi/gdi_8bpp.h @@ -18,7 +18,7 @@ */ #include -#include "gdi.h" +#include typedef void (*pSetPixel8_ROP2)(uint8 *pixel, uint8 *pen); diff --git a/libfreerdp-gdi/gdi_bitmap.c b/libfreerdp-gdi/gdi_bitmap.c index 831c9a5f8..11e0f73fa 100644 --- a/libfreerdp-gdi/gdi_bitmap.c +++ b/libfreerdp-gdi/gdi_bitmap.c @@ -20,11 +20,10 @@ #include #include #include - #include -#include "gdi.h" +#include +#include -#include "color.h" #include "gdi_32bpp.h" #include "gdi_16bpp.h" #include "gdi_8bpp.h" diff --git a/libfreerdp-gdi/gdi_bitmap.h b/libfreerdp-gdi/gdi_bitmap.h index ba9272b34..0b9bad9c5 100644 --- a/libfreerdp-gdi/gdi_bitmap.h +++ b/libfreerdp-gdi/gdi_bitmap.h @@ -20,7 +20,7 @@ #ifndef __GDI_BITMAP_H #define __GDI_BITMAP_H -#include "gdi.h" +#include GDI_COLOR gdi_GetPixel(HGDI_DC hdc, int nXPos, int nYPos); GDI_COLOR gdi_SetPixel(HGDI_DC hdc, int X, int Y, GDI_COLOR crColor); diff --git a/libfreerdp-gdi/gdi_brush.c b/libfreerdp-gdi/gdi_brush.c index 23fe99c1f..e01565004 100644 --- a/libfreerdp-gdi/gdi_brush.c +++ b/libfreerdp-gdi/gdi_brush.c @@ -24,7 +24,7 @@ #include #include -#include "gdi.h" +#include #include "gdi_32bpp.h" #include "gdi_16bpp.h" diff --git a/libfreerdp-gdi/gdi_brush.h b/libfreerdp-gdi/gdi_brush.h index 26d8d7df9..e3da8b633 100644 --- a/libfreerdp-gdi/gdi_brush.h +++ b/libfreerdp-gdi/gdi_brush.h @@ -20,7 +20,7 @@ #ifndef __GDI_BRUSH_H #define __GDI_BRUSH_H -#include "gdi.h" +#include HGDI_BRUSH gdi_CreateSolidBrush(GDI_COLOR crColor); HGDI_BRUSH gdi_CreatePatternBrush(HGDI_BITMAP hbmp); diff --git a/libfreerdp-gdi/gdi_clipping.c b/libfreerdp-gdi/gdi_clipping.c index 669168052..f6804cc6d 100644 --- a/libfreerdp-gdi/gdi_clipping.c +++ b/libfreerdp-gdi/gdi_clipping.c @@ -21,8 +21,8 @@ #include #include #include +#include -#include "gdi.h" #include "gdi_region.h" #include "gdi_clipping.h" diff --git a/libfreerdp-gdi/gdi_clipping.h b/libfreerdp-gdi/gdi_clipping.h index fc44771da..931cd77c6 100644 --- a/libfreerdp-gdi/gdi_clipping.h +++ b/libfreerdp-gdi/gdi_clipping.h @@ -20,7 +20,7 @@ #ifndef __GDI_CLIPPING_H #define __GDI_CLIPPING_H -#include "gdi.h" +#include int gdi_SetClipRgn(HGDI_DC hdc, int nXLeft, int nYLeft, int nWidth, int nHeight); HGDI_RGN gdi_GetClipRgn(HGDI_DC hdc); diff --git a/libfreerdp-gdi/gdi_dc.c b/libfreerdp-gdi/gdi_dc.c index 2f33e8b4b..129f50dd8 100644 --- a/libfreerdp-gdi/gdi_dc.c +++ b/libfreerdp-gdi/gdi_dc.c @@ -23,8 +23,8 @@ #include #include #include +#include -#include "gdi.h" #include "gdi_region.h" #include "gdi_dc.h" diff --git a/libfreerdp-gdi/gdi_dc.h b/libfreerdp-gdi/gdi_dc.h index b45730501..14482f3ca 100644 --- a/libfreerdp-gdi/gdi_dc.h +++ b/libfreerdp-gdi/gdi_dc.h @@ -20,7 +20,7 @@ #ifndef __GDI_DC_H #define __GDI_DC_H -#include "gdi.h" +#include HGDI_DC gdi_GetDC(); HGDI_DC gdi_CreateCompatibleDC(HGDI_DC hdc); diff --git a/libfreerdp-gdi/gdi_drawing.c b/libfreerdp-gdi/gdi_drawing.c index 56b71f773..f824c458c 100644 --- a/libfreerdp-gdi/gdi_drawing.c +++ b/libfreerdp-gdi/gdi_drawing.c @@ -24,7 +24,7 @@ #include #include -#include "gdi.h" +#include #include "gdi_dc.h" diff --git a/libfreerdp-gdi/gdi_drawing.h b/libfreerdp-gdi/gdi_drawing.h index cc58ccec9..08fafa9e8 100644 --- a/libfreerdp-gdi/gdi_drawing.h +++ b/libfreerdp-gdi/gdi_drawing.h @@ -20,7 +20,7 @@ #ifndef __GDI_DRAWING_H #define __GDI_DRAWING_H -#include "gdi.h" +#include int gdi_GetROP2(HGDI_DC hdc); int gdi_SetROP2(HGDI_DC hdc, int fnDrawMode); diff --git a/libfreerdp-gdi/gdi_line.c b/libfreerdp-gdi/gdi_line.c index 1eb79eedd..d6f943210 100644 --- a/libfreerdp-gdi/gdi_line.c +++ b/libfreerdp-gdi/gdi_line.c @@ -22,7 +22,7 @@ #include #include -#include "gdi.h" +#include #include "gdi_32bpp.h" #include "gdi_16bpp.h" diff --git a/libfreerdp-gdi/gdi_line.h b/libfreerdp-gdi/gdi_line.h index 51e46910a..f5b9797f9 100644 --- a/libfreerdp-gdi/gdi_line.h +++ b/libfreerdp-gdi/gdi_line.h @@ -20,7 +20,7 @@ #ifndef __GDI_LINE_H #define __GDI_LINE_H -#include "gdi.h" +#include int gdi_LineTo(HGDI_DC hdc, int nXEnd, int nYEnd); int gdi_PolylineTo(HGDI_DC hdc, GDI_POINT *lppt, int cCount); diff --git a/libfreerdp-gdi/gdi_palette.c b/libfreerdp-gdi/gdi_palette.c index 032b2efc9..1ec3cf5f0 100644 --- a/libfreerdp-gdi/gdi_palette.c +++ b/libfreerdp-gdi/gdi_palette.c @@ -24,7 +24,7 @@ #include #include -#include "gdi.h" +#include #include "gdi_palette.h" diff --git a/libfreerdp-gdi/gdi_palette.h b/libfreerdp-gdi/gdi_palette.h index 0bfba4442..ffba58cc9 100644 --- a/libfreerdp-gdi/gdi_palette.h +++ b/libfreerdp-gdi/gdi_palette.h @@ -20,7 +20,7 @@ #ifndef __GDI_PALETTE_H #define __GDI_PALETTE_H -#include "gdi.h" +#include HGDI_PALETTE gdi_CreatePalette(HGDI_PALETTE palette); HGDI_PALETTE gdi_GetSystemPalette(); diff --git a/libfreerdp-gdi/gdi_pen.c b/libfreerdp-gdi/gdi_pen.c index 01a7b732e..65fac678d 100644 --- a/libfreerdp-gdi/gdi_pen.c +++ b/libfreerdp-gdi/gdi_pen.c @@ -24,7 +24,7 @@ #include #include -#include "gdi.h" +#include #include "gdi_pen.h" diff --git a/libfreerdp-gdi/gdi_pen.h b/libfreerdp-gdi/gdi_pen.h index 3978d2bd3..2e6e57b1c 100644 --- a/libfreerdp-gdi/gdi_pen.h +++ b/libfreerdp-gdi/gdi_pen.h @@ -20,7 +20,7 @@ #ifndef __GDI_PEN_H #define __GDI_PEN_H -#include "gdi.h" +#include HGDI_PEN gdi_CreatePen(int fnPenStyle, int nWidth, int crColor); uint8 gdi_GetPenColor_8bpp(HGDI_PEN pen); diff --git a/libfreerdp-gdi/gdi_region.c b/libfreerdp-gdi/gdi_region.c index f81477e36..53eadccae 100644 --- a/libfreerdp-gdi/gdi_region.c +++ b/libfreerdp-gdi/gdi_region.c @@ -22,7 +22,7 @@ #include #include -#include "gdi.h" +#include #include "gdi_region.h" diff --git a/libfreerdp-gdi/gdi_region.h b/libfreerdp-gdi/gdi_region.h index 61f8ed47d..10a9b101a 100644 --- a/libfreerdp-gdi/gdi_region.h +++ b/libfreerdp-gdi/gdi_region.h @@ -20,7 +20,7 @@ #ifndef __GDI_REGION_H #define __GDI_REGION_H -#include "gdi.h" +#include HGDI_RGN gdi_CreateRectRgn(int nLeftRect, int nTopRect, int nRightRect, int nBottomRect); HGDI_RECT gdi_CreateRect(int xLeft, int yTop, int xRight, int yBottom); diff --git a/libfreerdp-gdi/gdi_shape.c b/libfreerdp-gdi/gdi_shape.c index eecf4cfd1..452c1a881 100644 --- a/libfreerdp-gdi/gdi_shape.c +++ b/libfreerdp-gdi/gdi_shape.c @@ -21,8 +21,8 @@ #include #include #include +#include -#include "gdi.h" #include "gdi_8bpp.h" #include "gdi_16bpp.h" #include "gdi_32bpp.h" diff --git a/libfreerdp-gdi/gdi_shape.h b/libfreerdp-gdi/gdi_shape.h index 732973448..1b80f8e59 100644 --- a/libfreerdp-gdi/gdi_shape.h +++ b/libfreerdp-gdi/gdi_shape.h @@ -20,7 +20,7 @@ #ifndef __GDI_SHAPE_H #define __GDI_SHAPE_H -#include "gdi.h" +#include int gdi_Ellipse(HGDI_DC hdc, int nLeftRect, int nTopRect, int nRightRect, int nBottomRect); int gdi_FillRect(HGDI_DC hdc, HGDI_RECT rect, HGDI_BRUSH hbr); diff --git a/libfreerdp-kbd/CMakeLists.txt b/libfreerdp-kbd/CMakeLists.txt index a31abe4fa..9fee2be5f 100644 --- a/libfreerdp-kbd/CMakeLists.txt +++ b/libfreerdp-kbd/CMakeLists.txt @@ -18,11 +18,8 @@ # limitations under the License. set(FREERDP_KBD_SRCS - keyboard.h locales.c - locales.h - layout_ids.c - layout_ids.h + layouts.c layouts_xkb.c layouts_xkb.h x_layout_id_table.c diff --git a/libfreerdp-kbd/layout_ids.c b/libfreerdp-kbd/layouts.c similarity index 98% rename from libfreerdp-kbd/layout_ids.c rename to libfreerdp-kbd/layouts.c index 6fcecc221..e77f06836 100644 --- a/libfreerdp-kbd/layout_ids.c +++ b/libfreerdp-kbd/layouts.c @@ -22,7 +22,7 @@ #include #include "libkbd.h" -#include "layout_ids.h" +#include typedef struct { @@ -229,8 +229,7 @@ keyboardIME keyboardIMEs[] = }; -rdpKeyboardLayout * -get_keyboard_layouts(int types) +rdpKeyboardLayout* get_keyboard_layouts(int types) { rdpKeyboardLayout * layouts; int num; @@ -276,8 +275,7 @@ get_keyboard_layouts(int types) return layouts; } -char * -get_layout_name(unsigned int keyboardLayoutID) +char* get_layout_name(unsigned int keyboardLayoutID) { int i; for(i = 0; i < sizeof(keyboardLayouts) / sizeof(keyboardLayout); i++) diff --git a/libfreerdp-kbd/layouts_xkb.c b/libfreerdp-kbd/layouts_xkb.c index f627ff62f..a8bff5f09 100644 --- a/libfreerdp-kbd/layouts_xkb.c +++ b/libfreerdp-kbd/layouts_xkb.c @@ -22,26 +22,28 @@ #include #include "libkbd.h" -#include "keyboard.h" +#include #include "x_layout_id_table.h" #include "layouts_xkb.h" +#ifndef KEYMAP_PATH +#define KEYMAP_PATH "/usr/local/freerdp/keymaps" +#endif + #ifdef WITH_XKBFILE #include #include #include -int -init_xkb(void *dpy) +int init_xkb(void *dpy) { return XkbQueryExtension(dpy, NULL, NULL, NULL, NULL, NULL); } /* return substring starting after nth comma, ending at following comma */ -static char * -comma_substring(char *s, int n) +static char* comma_substring(char *s, int n) { char *p; if (!s) @@ -56,8 +58,7 @@ comma_substring(char *s, int n) return s; } -unsigned int -detect_keyboard_layout_from_xkb(void *dpy) +unsigned int detect_keyboard_layout_from_xkb(void *dpy) { char *layout, *variant; unsigned int keyboard_layout = 0, group = 0; @@ -93,8 +94,7 @@ detect_keyboard_layout_from_xkb(void *dpy) return keyboard_layout; } -int -init_keycodes_from_xkb(void *dpy, RdpKeycodes x_keycode_to_rdp_keycode) +int init_keycodes_from_xkb(void *dpy, RdpKeycodes x_keycode_to_rdp_keycode) { int ret = 0; XkbDescPtr xkb; @@ -163,8 +163,7 @@ static const KeycodeToVkcode defaultKeycodeToVkcode = 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; -static int -load_xkb_keyboard(KeycodeToVkcode map, char* kbd) +static int load_xkb_keyboard(KeycodeToVkcode map, char* kbd) { char* pch; char *beg, *end; @@ -357,8 +356,7 @@ load_xkb_keyboard(KeycodeToVkcode map, char* kbd) return 1; } -void -load_keyboard_map(KeycodeToVkcode keycodeToVkcode, char *xkbfile) +void load_keyboard_map(KeycodeToVkcode keycodeToVkcode, char *xkbfile) { char* kbd; char* xkbfileEnd; diff --git a/libfreerdp-kbd/libkbd.c b/libfreerdp-kbd/libkbd.c index 679700832..34a93f95a 100644 --- a/libfreerdp-kbd/libkbd.c +++ b/libfreerdp-kbd/libkbd.c @@ -20,16 +20,15 @@ #include #include #include - -#include #include +#include #include "libkbd.h" -#include "locales.h" -#include "layout_ids.h" +#include +#include +#include #include "layouts_xkb.h" -#include "keyboard.h" /* * The actual mapping from X keycodes to RDP keycodes, initialized from xkb keycodes or similar. diff --git a/libfreerdp-kbd/locales.c b/libfreerdp-kbd/locales.c index 32b0f3a89..7d02eed5c 100644 --- a/libfreerdp-kbd/locales.c +++ b/libfreerdp-kbd/locales.c @@ -22,7 +22,7 @@ #include #include "libkbd.h" -#include "locales.h" +#include typedef struct { diff --git a/libfreerdp-kbd/x_layout_id_table.c b/libfreerdp-kbd/x_layout_id_table.c index 59e6a3625..2e447ee1b 100644 --- a/libfreerdp-kbd/x_layout_id_table.c +++ b/libfreerdp-kbd/x_layout_id_table.c @@ -22,7 +22,7 @@ #include #include "libkbd.h" -#include "layout_ids.h" +#include #include "x_layout_id_table.h" diff --git a/libfreerdp-kbd/x_layout_id_table.h b/libfreerdp-kbd/x_layout_id_table.h index 440a9e86e..11db11a12 100644 --- a/libfreerdp-kbd/x_layout_id_table.h +++ b/libfreerdp-kbd/x_layout_id_table.h @@ -22,12 +22,10 @@ #ifndef __LAYOUTS_X_H #define __LAYOUTS_X_H -unsigned int -find_keyboard_layout_in_xorg_rules(char* layout, char* variant); +unsigned int find_keyboard_layout_in_xorg_rules(char* layout, char* variant); #if defined(sun) -unsigned int -detect_keyboard_type_and_layout_sunos(char* xkbfile, int length); +unsigned int detect_keyboard_type_and_layout_sunos(char* xkbfile, int length); #endif #endif diff --git a/libfreerdp-rfx/librfx.c b/libfreerdp-rfx/librfx.c index eff6aa393..910c7d887 100644 --- a/libfreerdp-rfx/librfx.c +++ b/libfreerdp-rfx/librfx.c @@ -21,7 +21,7 @@ #include #include #include -#include +#include #include #include "rfx_constants.h" diff --git a/libfreerdp-rfx/rfx_bitstream.h b/libfreerdp-rfx/rfx_bitstream.h index 23dd54f2a..0766543f7 100644 --- a/libfreerdp-rfx/rfx_bitstream.h +++ b/libfreerdp-rfx/rfx_bitstream.h @@ -20,7 +20,7 @@ #ifndef __RFX_BITSTREAM_H #define __RFX_BITSTREAM_H -#include +#include struct _RFX_BITSTREAM { diff --git a/libfreerdp-rfx/rfx_decode.h b/libfreerdp-rfx/rfx_decode.h index 617acdb13..f7f7f29cf 100644 --- a/libfreerdp-rfx/rfx_decode.h +++ b/libfreerdp-rfx/rfx_decode.h @@ -20,7 +20,7 @@ #ifndef __RFX_DECODE_H #define __RFX_DECODE_H -#include +#include void rfx_decode_ycbcr_to_rgb(sint16* y_r_buf, sint16* cb_g_buf, sint16* cr_b_buf); diff --git a/libfreerdp-rfx/rfx_differential.h b/libfreerdp-rfx/rfx_differential.h index 9591858b4..12619aa40 100644 --- a/libfreerdp-rfx/rfx_differential.h +++ b/libfreerdp-rfx/rfx_differential.h @@ -20,7 +20,7 @@ #ifndef __RFX_DIFFERENTIAL_H #define __RFX_DIFFERENTIAL_H -#include +#include void rfx_differential_decode(sint16* buffer, int buffer_size); void rfx_differential_encode(sint16* buffer, int buffer_size); diff --git a/libfreerdp-rfx/rfx_dwt.h b/libfreerdp-rfx/rfx_dwt.h index 902ad0a2c..ab07fd8b7 100644 --- a/libfreerdp-rfx/rfx_dwt.h +++ b/libfreerdp-rfx/rfx_dwt.h @@ -20,7 +20,7 @@ #ifndef __RFX_DWT_H #define __RFX_DWT_H -#include +#include void rfx_dwt_2d_decode(sint16* buffer, sint16* dwt_buffer); void rfx_dwt_2d_encode(sint16* buffer, sint16* dwt_buffer); diff --git a/libfreerdp-rfx/rfx_encode.h b/libfreerdp-rfx/rfx_encode.h index ef7e24ea9..465e2fc90 100644 --- a/libfreerdp-rfx/rfx_encode.h +++ b/libfreerdp-rfx/rfx_encode.h @@ -20,7 +20,7 @@ #ifndef __RFX_ENCODE_H #define __RFX_ENCODE_H -#include +#include void rfx_encode_rgb_to_ycbcr(sint16* y_r_buf, sint16* cb_g_buf, sint16* cr_b_buf); diff --git a/libfreerdp-rfx/rfx_pool.h b/libfreerdp-rfx/rfx_pool.h index 68132656a..2843daf11 100644 --- a/libfreerdp-rfx/rfx_pool.h +++ b/libfreerdp-rfx/rfx_pool.h @@ -20,7 +20,7 @@ #ifndef __RFX_POOL_H #define __RFX_POOL_H -#include +#include struct _RFX_POOL { diff --git a/libfreerdp-rfx/rfx_quantization.h b/libfreerdp-rfx/rfx_quantization.h index 9b1f289d7..41cf842df 100644 --- a/libfreerdp-rfx/rfx_quantization.h +++ b/libfreerdp-rfx/rfx_quantization.h @@ -20,7 +20,7 @@ #ifndef __RFX_QUANTIZATION_H #define __RFX_QUANTIZATION_H -#include +#include void rfx_quantization_decode(sint16* buffer, const uint32* quantization_values); void rfx_quantization_encode(sint16* buffer, const uint32* quantization_values); diff --git a/libfreerdp-rfx/rfx_rlgr.h b/libfreerdp-rfx/rfx_rlgr.h index 05604766e..5b680afeb 100644 --- a/libfreerdp-rfx/rfx_rlgr.h +++ b/libfreerdp-rfx/rfx_rlgr.h @@ -20,7 +20,7 @@ #ifndef __RFX_RLGR_H #define __RFX_RLGR_H -#include +#include int rfx_rlgr_decode(RLGR_MODE mode, const uint8* data, int data_size, sint16* buffer, int buffer_size); int rfx_rlgr_encode(RLGR_MODE mode, const sint16* data, int data_size, uint8* buffer, int buffer_size);