LibreOffice Module vcl (master)  1
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at .
18  */
23 #include <sal/config.h>
25 #include <osl/conditn.hxx>
27 #include <salinst.hxx>
29 class SalYieldMutex;
32 {
33 public:
35  HINSTANCE mhInst;
37  HWND mhComWnd;
39  osl::Condition maWaitingYieldCond;
40  unsigned m_nNoYieldLock;
42 public:
44  virtual ~WinSalInstance() override;
46  virtual SalFrame* CreateChildFrame( SystemParentData* pParent, SalFrameStyleFlags nStyle ) override;
47  virtual SalFrame* CreateFrame( SalFrame* pParent, SalFrameStyleFlags nStyle ) override;
48  virtual void DestroyFrame( SalFrame* pFrame ) override;
49  virtual SalObject* CreateObject( SalFrame* pParent, SystemWindowData* pWindowData, bool bShow ) override;
50  virtual void DestroyObject( SalObject* pObject ) override;
51  virtual std::unique_ptr<SalVirtualDevice>
52  CreateVirtualDevice( SalGraphics& rGraphics,
53  tools::Long &nDX, tools::Long &nDY,
54  DeviceFormat eFormat, const SystemGraphicsData *pData = nullptr ) override;
56  ImplJobSetup* pSetupData ) override;
57  virtual void DestroyInfoPrinter( SalInfoPrinter* pPrinter ) override;
58  virtual std::unique_ptr<SalPrinter> CreatePrinter( SalInfoPrinter* pInfoPrinter ) override;
59  virtual void GetPrinterQueueInfo( ImplPrnQueueList* pList ) override;
60  virtual void GetPrinterQueueState( SalPrinterQueueInfo* pInfo ) override;
61  virtual OUString GetDefaultPrinter() override;
62  virtual SalTimer* CreateSalTimer() override;
63  virtual SalSystem* CreateSalSystem() override;
64  virtual std::shared_ptr<SalBitmap> CreateSalBitmap() override;
65  virtual bool IsMainThread() const override;
67  virtual bool DoYield(bool bWait, bool bHandleAllCurrentEvents) override;
68  virtual bool AnyInput( VclInputFlags nType ) override;
69  virtual std::unique_ptr<SalMenu> CreateMenu( bool bMenuBar, Menu* ) override;
70  virtual std::unique_ptr<SalMenuItem> CreateMenuItem( const SalItemParams & rItemData ) override;
71  virtual OpenGLContext* CreateOpenGLContext() override;
72  virtual OUString GetConnectionIdentifier() override;
73  virtual void AddToRecentDocumentList(const OUString& rFileUrl, const OUString& rMimeType, const OUString& rDocumentService) override;
75  virtual OUString getOSVersion() override;
76  virtual void BeforeAbort(const OUString&, bool) override;
78  static int WorkaroundExceptionHandlingInUSER32Lib(int nExcept, LPEXCEPTION_POINTERS pExceptionInfo);
80  virtual css::uno::Reference<css::uno::XInterface> ImplCreateDragSource(const SystemEnvData*) override;
81  virtual css::uno::Reference<css::uno::XInterface> ImplCreateDropTarget(const SystemEnvData*) override;
82 };
84 SalFrame* ImplSalCreateFrame( WinSalInstance* pInst, HWND hWndParent, SalFrameStyleFlags nSalFrameStyle );
86 HWND ImplSalReCreateHWND( HWND hWndParent, HWND oldhWnd, bool bAsChild );
87 bool OSSupportsDarkMode();
91 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual OUString getOSVersion() override
get information about underlying versions
osl::Condition maWaitingYieldCond
Definition: win/salinst.h:39
virtual void DestroyInfoPrinter(SalInfoPrinter *pPrinter) override
virtual std::unique_ptr< SalPrinter > CreatePrinter(SalInfoPrinter *pInfoPrinter) override
long Long
HWND mhComWnd
invisible Window so non-main threads can SendMessage() the main thread
Definition: win/salinst.h:37
SalObject * ImplSalCreateObject(WinSalInstance *pInst, WinSalFrame *pParent)
Definition: inputtypes.hxx:25
virtual SalObject * CreateObject(SalFrame *pParent, SystemWindowData *pWindowData, bool bShow) override
virtual std::shared_ptr< SalBitmap > CreateSalBitmap() override
virtual bool AnyInput(VclInputFlags nType) override
virtual bool IsMainThread() const override
bool OSSupportsDarkMode()
virtual void DestroyFrame(SalFrame *pFrame) override
Instance Handle.
Definition: win/salinst.h:35
virtual OUString GetDefaultPrinter() override
virtual void GetPrinterQueueState(SalPrinterQueueInfo *pInfo) override
virtual void BeforeAbort(const OUString &, bool) override
virtual std::unique_ptr< SalMenuItem > CreateMenuItem(const SalItemParams &rItemData) override
virtual css::uno::Reference< css::uno::XInterface > ImplCreateDropTarget(const SystemEnvData *) override
unsigned m_nNoYieldLock
Definition: win/salinst.h:40
virtual SalTimer * CreateSalTimer() override
virtual OUString GetConnectionIdentifier() override
HWND ImplSalReCreateHWND(HWND hWndParent, HWND oldhWnd, bool bAsChild)
Definition: salgtype.hxx:28
virtual std::unique_ptr< SalMenu > CreateMenu(bool bMenuBar, Menu *) override
A SalFrame is a system window (e.g. an X11 window).
Definition: salframe.hxx:114
virtual OpenGLContext * CreateOpenGLContext() override
Definition: menu.hxx:115
virtual css::uno::Reference< css::uno::XInterface > ImplCreateDragSource(const SystemEnvData *) override
virtual SalFrame * CreateFrame(SalFrame *pParent, SalFrameStyleFlags nStyle) override
Definition: salframe.hxx:64
SalFrame * ImplSalCreateFrame(WinSalInstance *pInst, HWND hWndParent, SalFrameStyleFlags nSalFrameStyle)
virtual SalInfoPrinter * CreateInfoPrinter(SalPrinterQueueInfo *pQueueInfo, ImplJobSetup *pSetupData) override
virtual std::unique_ptr< SalVirtualDevice > CreateVirtualDevice(SalGraphics &rGraphics, tools::Long &nDX, tools::Long &nDY, DeviceFormat eFormat, const SystemGraphicsData *pData=nullptr) override
static int WorkaroundExceptionHandlingInUSER32Lib(int nExcept, LPEXCEPTION_POINTERS pExceptionInfo)
virtual void GetPrinterQueueInfo(ImplPrnQueueList *pList) override
virtual bool DoYield(bool bWait, bool bHandleAllCurrentEvents) override
Wait for the next event (if bWait) and dispatch it, includes posted events, and timers.
virtual SalFrame * CreateChildFrame(SystemParentData *pParent, SalFrameStyleFlags nStyle) override
virtual SalSystem * CreateSalSystem() override
virtual ~WinSalInstance() override
virtual void DestroyObject(SalObject *pObject) override
virtual void AddToRecentDocumentList(const OUString &rFileUrl, const OUString &rMimeType, const OUString &rDocumentService) override