2013-03-19 04:12:51 +04:00
|
|
|
/**
|
|
|
|
* FreeRDP: A Remote Desktop Protocol Implementation
|
|
|
|
* Windows Client
|
|
|
|
*
|
|
|
|
* Copyright 2009-2011 Jay Sorg
|
|
|
|
* Copyright 2010-2011 Vic Lee
|
|
|
|
* Copyright 2010-2011 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
|
|
|
*
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
* See the License for the specific language governing permissions and
|
|
|
|
* limitations under the License.
|
|
|
|
*/
|
|
|
|
|
2017-06-06 15:01:41 +03:00
|
|
|
#ifndef FREERDP_CLIENT_WIN_INTERFACE_H
|
|
|
|
#define FREERDP_CLIENT_WIN_INTERFACE_H
|
2013-03-19 04:12:51 +04:00
|
|
|
|
|
|
|
#include <winpr/windows.h>
|
|
|
|
|
2014-10-25 02:30:04 +04:00
|
|
|
#include <winpr/collections.h>
|
|
|
|
|
2013-03-19 05:54:50 +04:00
|
|
|
#include <freerdp/api.h>
|
2013-03-19 04:12:51 +04:00
|
|
|
#include <freerdp/freerdp.h>
|
|
|
|
#include <freerdp/gdi/gdi.h>
|
|
|
|
#include <freerdp/gdi/dc.h>
|
|
|
|
#include <freerdp/gdi/region.h>
|
|
|
|
#include <freerdp/cache/cache.h>
|
|
|
|
#include <freerdp/codec/color.h>
|
2014-09-12 19:13:01 +04:00
|
|
|
|
2014-10-24 19:30:04 +04:00
|
|
|
#include <freerdp/client/rail.h>
|
2013-03-19 04:12:51 +04:00
|
|
|
#include <freerdp/channels/channels.h>
|
|
|
|
#include <freerdp/codec/rfx.h>
|
|
|
|
#include <freerdp/codec/nsc.h>
|
2013-04-23 00:08:47 +04:00
|
|
|
#include <freerdp/client/file.h>
|
2013-03-19 04:12:51 +04:00
|
|
|
|
2014-10-25 02:30:04 +04:00
|
|
|
typedef struct wf_context wfContext;
|
|
|
|
|
2014-10-23 23:38:19 +04:00
|
|
|
#include "wf_channels.h"
|
2014-02-27 07:43:52 +04:00
|
|
|
#include "wf_floatbar.h"
|
2013-03-19 04:12:51 +04:00
|
|
|
#include "wf_event.h"
|
2014-10-25 02:30:04 +04:00
|
|
|
#include "wf_cliprdr.h"
|
2013-03-19 04:12:51 +04:00
|
|
|
|
2013-04-09 02:27:59 +04:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2013-04-26 23:46:36 +04:00
|
|
|
// System menu constants
|
2013-04-30 19:15:04 +04:00
|
|
|
#define SYSCOMMAND_ID_SMARTSIZING 1000
|
2013-04-26 23:46:36 +04:00
|
|
|
|
2013-03-19 04:12:51 +04:00
|
|
|
struct wf_bitmap
|
|
|
|
{
|
|
|
|
rdpBitmap _bitmap;
|
|
|
|
HDC hdc;
|
|
|
|
HBITMAP bitmap;
|
|
|
|
HBITMAP org_bitmap;
|
|
|
|
BYTE* pdata;
|
|
|
|
};
|
|
|
|
typedef struct wf_bitmap wfBitmap;
|
|
|
|
|
|
|
|
struct wf_pointer
|
|
|
|
{
|
|
|
|
rdpPointer pointer;
|
|
|
|
HCURSOR cursor;
|
|
|
|
};
|
|
|
|
typedef struct wf_pointer wfPointer;
|
|
|
|
|
|
|
|
struct wf_context
|
|
|
|
{
|
2013-06-16 06:57:21 +04:00
|
|
|
rdpContext context;
|
|
|
|
DEFINE_RDP_CLIENT_COMMON();
|
2013-04-09 06:10:59 +04:00
|
|
|
|
2013-03-19 04:12:51 +04:00
|
|
|
int offset_x;
|
|
|
|
int offset_y;
|
2016-06-22 21:58:39 +03:00
|
|
|
int fullscreen_toggle;
|
2013-03-19 04:12:51 +04:00
|
|
|
int fullscreen;
|
|
|
|
int percentscreen;
|
2018-11-21 11:54:09 +03:00
|
|
|
WCHAR* window_title;
|
2013-04-25 23:42:40 +04:00
|
|
|
int client_x;
|
|
|
|
int client_y;
|
2013-04-11 00:58:14 +04:00
|
|
|
int client_width;
|
2016-08-03 13:09:24 +03:00
|
|
|
int client_height;
|
2013-03-19 04:12:51 +04:00
|
|
|
|
2013-03-19 05:54:50 +04:00
|
|
|
HANDLE keyboardThread;
|
|
|
|
|
|
|
|
HICON icon;
|
2013-03-19 21:17:30 +04:00
|
|
|
HWND hWndParent;
|
2013-03-19 05:54:50 +04:00
|
|
|
HINSTANCE hInstance;
|
|
|
|
WNDCLASSEX wndClass;
|
|
|
|
LPCTSTR wndClassName;
|
|
|
|
HCURSOR hDefaultCursor;
|
|
|
|
|
2013-03-19 04:12:51 +04:00
|
|
|
HWND hwnd;
|
2016-08-03 13:09:24 +03:00
|
|
|
POINT diff;
|
2016-07-21 16:36:15 +03:00
|
|
|
|
2013-03-19 04:12:51 +04:00
|
|
|
wfBitmap* primary;
|
2016-08-03 13:09:24 +03:00
|
|
|
wfBitmap* drawing;
|
2013-03-19 04:12:51 +04:00
|
|
|
HCURSOR cursor;
|
|
|
|
HBRUSH brush;
|
|
|
|
HBRUSH org_brush;
|
|
|
|
RECT update_rect;
|
2013-04-11 00:58:14 +04:00
|
|
|
RECT scale_update_rect;
|
2013-03-19 04:12:51 +04:00
|
|
|
|
2013-04-11 00:58:14 +04:00
|
|
|
DWORD mainThreadId;
|
2013-04-12 00:19:58 +04:00
|
|
|
DWORD keyboardThreadId;
|
2013-03-19 04:12:51 +04:00
|
|
|
|
2013-04-23 00:08:47 +04:00
|
|
|
rdpFile* connectionRdpFile;
|
2013-04-26 01:18:14 +04:00
|
|
|
|
2013-06-16 06:57:21 +04:00
|
|
|
BOOL disablewindowtracking;
|
2013-04-26 23:46:36 +04:00
|
|
|
|
|
|
|
BOOL updating_scrollbars;
|
|
|
|
BOOL xScrollVisible;
|
2014-10-23 23:38:19 +04:00
|
|
|
int xMinScroll;
|
|
|
|
int xCurrentScroll;
|
|
|
|
int xMaxScroll;
|
2013-06-16 06:57:21 +04:00
|
|
|
|
2013-04-26 23:46:36 +04:00
|
|
|
BOOL yScrollVisible;
|
2014-10-23 23:38:19 +04:00
|
|
|
int yMinScroll;
|
|
|
|
int yCurrentScroll;
|
|
|
|
int yMaxScroll;
|
|
|
|
|
2015-10-22 10:31:47 +03:00
|
|
|
void* clipboard;
|
2014-10-23 23:38:19 +04:00
|
|
|
CliprdrClientContext* cliprdr;
|
|
|
|
|
2018-11-16 12:33:29 +03:00
|
|
|
wfFloatBar* floatbar;
|
2014-10-24 19:30:04 +04:00
|
|
|
|
|
|
|
RailClientContext* rail;
|
2014-10-25 02:30:04 +04:00
|
|
|
wHashTable* railWindows;
|
2013-03-19 04:12:51 +04:00
|
|
|
};
|
|
|
|
|
2013-04-09 02:27:59 +04:00
|
|
|
/**
|
|
|
|
* Client Interface
|
|
|
|
*/
|
|
|
|
|
2013-06-16 06:57:21 +04:00
|
|
|
FREERDP_API int RdpClientEntry(RDP_CLIENT_ENTRY_POINTS* pEntryPoints);
|
2016-08-03 13:09:24 +03:00
|
|
|
FREERDP_API int freerdp_client_set_window_size(wfContext* wfc, int width,
|
|
|
|
int height);
|
|
|
|
FREERDP_API void wf_size_scrollbars(wfContext* wfc, UINT32 client_width,
|
|
|
|
UINT32 client_height);
|
2013-04-15 23:58:56 +04:00
|
|
|
|
2013-04-09 02:27:59 +04:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2017-06-06 15:01:41 +03:00
|
|
|
#endif /* FREERDP_CLIENT_WIN_INTERFACE_H */
|