LibreOffice Module vcl (master)  1
gtkinst.hxx
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 http://mozilla.org/MPL/2.0/.
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 http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 
20 #ifndef INCLUDED_VCL_INC_UNX_GTK_GTKINST_HXX
21 #define INCLUDED_VCL_INC_UNX_GTK_GTKINST_HXX
22 
23 #include <sal/config.h>
24 
25 #include <stack>
26 
27 #include <unx/salinst.h>
28 #include <unx/gensys.h>
29 #include <headless/svpinst.hxx>
30 #include <com/sun/star/datatransfer/DataFlavor.hpp>
31 #include <com/sun/star/datatransfer/dnd/XDragSource.hpp>
32 #include <com/sun/star/datatransfer/dnd/XDropTarget.hpp>
33 #include <com/sun/star/lang/XInitialization.hpp>
34 #include <com/sun/star/lang/XServiceInfo.hpp>
35 #include <com/sun/star/awt/XWindow.hpp>
36 #include <cppuhelper/compbase.hxx>
37 #include <vcl/weld.hxx>
38 #include <vcl/weldutils.hxx>
39 #include <gtk/gtk.h>
40 
41 vcl::Font pango_to_vcl(const PangoFontDescription* font, const css::lang::Locale& rLocale);
42 
43 class GenPspGraphics;
44 class GtkYieldMutex final : public SalYieldMutex
45 {
46  thread_local static std::stack<sal_uInt32> yieldCounts;
47 
48 public:
50  void ThreadsEnter();
51  void ThreadsLeave();
52 };
53 
54 class GtkSalFrame;
55 
57 {
58  std::vector<css::datatransfer::DataFlavor> aInfoToFlavor;
59  std::vector<GtkTargetEntry> FormatsToGtk(const css::uno::Sequence<css::datatransfer::DataFlavor> &rFormats);
60  void setSelectionData(const css::uno::Reference<css::datatransfer::XTransferable> &rTrans,
61  GtkSelectionData *selection_data, guint info);
62 private:
63  GtkTargetEntry makeGtkTargetEntry(const css::datatransfer::DataFlavor& rFlavor);
64 };
65 
66 class GtkTransferable : public cppu::WeakImplHelper<css::datatransfer::XTransferable>
67 {
68 protected:
69  std::map<OUString, GdkAtom> m_aMimeTypeToAtom;
70 
71  std::vector<css::datatransfer::DataFlavor> getTransferDataFlavorsAsVector(GdkAtom *targets, gint n_targets);
72 
73 public:
74  virtual css::uno::Any SAL_CALL getTransferData(const css::datatransfer::DataFlavor& rFlavor) override = 0;
75  virtual std::vector<css::datatransfer::DataFlavor> getTransferDataFlavorsAsVector() = 0;
76  virtual css::uno::Sequence<css::datatransfer::DataFlavor> SAL_CALL getTransferDataFlavors() override;
77  virtual sal_Bool SAL_CALL isDataFlavorSupported(const css::datatransfer::DataFlavor& rFlavor) override;
78 };
79 
80 class GtkDnDTransferable;
81 
82 class GtkDropTarget final : public cppu::WeakComponentImplHelper<css::datatransfer::dnd::XDropTarget,
83  css::lang::XInitialization,
84  css::lang::XServiceInfo>
85 {
86  osl::Mutex m_aMutex;
88  GtkDnDTransferable* m_pFormatConversionRequest;
89  bool m_bActive;
90  bool m_bInDrag;
92  std::vector<css::uno::Reference<css::datatransfer::dnd::XDropTargetListener>> m_aListeners;
93 public:
94  GtkDropTarget();
95  virtual ~GtkDropTarget() override;
96 
97  // XInitialization
98  virtual void SAL_CALL initialize(const css::uno::Sequence<css::uno::Any>& rArgs) override;
99  void deinitialize();
100 
101  // XDropTarget
102  virtual void SAL_CALL addDropTargetListener(const css::uno::Reference<css::datatransfer::dnd::XDropTargetListener>&) override;
103  virtual void SAL_CALL removeDropTargetListener(const css::uno::Reference<css::datatransfer::dnd::XDropTargetListener>&) override;
104  virtual sal_Bool SAL_CALL isActive() override;
105  virtual void SAL_CALL setActive(sal_Bool active) override;
106  virtual sal_Int8 SAL_CALL getDefaultActions() override;
107  virtual void SAL_CALL setDefaultActions(sal_Int8 actions) override;
108 
109  OUString SAL_CALL getImplementationName() override;
110 
111  sal_Bool SAL_CALL supportsService(OUString const & ServiceName) override;
112 
113  css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames() override;
114 
115  void fire_dragEnter(const css::datatransfer::dnd::DropTargetDragEnterEvent& dtdee);
116  void fire_dragOver(const css::datatransfer::dnd::DropTargetDragEvent& dtde);
117  void fire_drop(const css::datatransfer::dnd::DropTargetDropEvent& dtde);
118  void fire_dragExit(const css::datatransfer::dnd::DropTargetEvent& dte);
119 
120  void SetFormatConversionRequest(GtkDnDTransferable *pRequest)
121  {
122  m_pFormatConversionRequest = pRequest;
123  }
124 
125  gboolean signalDragDrop(GtkWidget* pWidget, GdkDragContext* context, gint x, gint y, guint time);
126  gboolean signalDragMotion(GtkWidget* pWidget, GdkDragContext* context, gint x, gint y, guint time);
127  void signalDragDropReceived(GtkWidget* pWidget, GdkDragContext* context, gint x, gint y, GtkSelectionData* data, guint ttype, guint time);
128  void signalDragLeave(GtkWidget* pWidget, GdkDragContext* context, guint time);
129 };
130 
131 class GtkDragSource final : public cppu::WeakComponentImplHelper<css::datatransfer::dnd::XDragSource,
132  css::lang::XInitialization,
133  css::lang::XServiceInfo>
134 {
135  osl::Mutex m_aMutex;
137  css::uno::Reference<css::datatransfer::dnd::XDragSourceListener> m_xListener;
138  css::uno::Reference<css::datatransfer::XTransferable> m_xTrans;
140 public:
142  : WeakComponentImplHelper(m_aMutex)
143  , m_pFrame(nullptr)
144  {
145  }
146 
147  void set_datatransfer(const css::uno::Reference<css::datatransfer::XTransferable>& rTrans,
148  const css::uno::Reference<css::datatransfer::dnd::XDragSourceListener>& rListener);
149 
150  std::vector<GtkTargetEntry> FormatsToGtk(const css::uno::Sequence<css::datatransfer::DataFlavor> &rFormats);
151 
152  void setActiveDragSource();
153 
154  virtual ~GtkDragSource() override;
155 
156  // XDragSource
157  virtual sal_Bool SAL_CALL isDragImageSupported() override;
158  virtual sal_Int32 SAL_CALL getDefaultCursor(sal_Int8 dragAction) override;
159  virtual void SAL_CALL startDrag(
160  const css::datatransfer::dnd::DragGestureEvent& trigger, sal_Int8 sourceActions, sal_Int32 cursor, sal_Int32 image,
161  const css::uno::Reference< css::datatransfer::XTransferable >& transferable,
162  const css::uno::Reference< css::datatransfer::dnd::XDragSourceListener >& listener) override;
163 
164  // XInitialization
165  virtual void SAL_CALL initialize(const css::uno::Sequence<css::uno::Any >& rArguments) override;
166  void deinitialize();
167 
168  OUString SAL_CALL getImplementationName() override;
169 
170  sal_Bool SAL_CALL supportsService(OUString const & ServiceName) override;
171 
172  css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames() override;
173 
174  void dragFailed();
175  void dragDelete();
176  void dragEnd(GdkDragContext* context);
177  void dragDataGet(GtkSelectionData *data, guint info);
178 
179  // For LibreOffice internal D&D we provide the Transferable without Gtk
180  // intermediaries as a shortcut, see tdf#100097 for how dbaccess depends on this
182  css::uno::Reference<css::datatransfer::XTransferable> const & GetTransferrable() const { return m_xTrans; }
183 };
184 
185 class GtkSalTimer;
186 class GtkInstance final : public SvpSalInstance
187 {
188 public:
189  GtkInstance( std::unique_ptr<SalYieldMutex> pMutex );
190  virtual ~GtkInstance() override;
191  void EnsureInit();
192  virtual void AfterAppInit() override;
193 
194  virtual SalFrame* CreateFrame( SalFrame* pParent, SalFrameStyleFlags nStyle ) override;
195  virtual SalFrame* CreateChildFrame( SystemParentData* pParent, SalFrameStyleFlags nStyle ) override;
196  virtual SalObject* CreateObject( SalFrame* pParent, SystemWindowData* pWindowData, bool bShow ) override;
197  virtual SalSystem* CreateSalSystem() override;
198  virtual SalInfoPrinter* CreateInfoPrinter(SalPrinterQueueInfo* pPrinterQueueInfo, ImplJobSetup* pJobSetup) override;
199  virtual std::unique_ptr<SalPrinter> CreatePrinter( SalInfoPrinter* pInfoPrinter ) override;
200  virtual std::unique_ptr<SalMenu> CreateMenu( bool, Menu* ) override;
201  virtual std::unique_ptr<SalMenuItem> CreateMenuItem( const SalItemParams& ) override;
202  virtual SalTimer* CreateSalTimer() override;
203  virtual void AddToRecentDocumentList(const OUString& rFileUrl, const OUString& rMimeType, const OUString& rDocumentService) override;
204  virtual std::unique_ptr<SalVirtualDevice>
206  tools::Long &nDX, tools::Long &nDY,
207  DeviceFormat eFormat,
208  const SystemGraphicsData* = nullptr ) override;
209  virtual std::shared_ptr<SalBitmap> CreateSalBitmap() override;
210 
211  virtual bool DoYield(bool bWait, bool bHandleAllCurrentEvents) override;
212  virtual bool AnyInput( VclInputFlags nType ) override;
213  // impossible to handle correctly, as "main thread" depends on the dispatch mutex
214  virtual bool IsMainThread() const override { return false; }
215 
216  virtual std::unique_ptr<GenPspGraphics> CreatePrintGraphics() override;
217 
218  virtual bool hasNativeFileSelection() const override { return true; }
219 
220  virtual css::uno::Reference< css::ui::dialogs::XFilePicker2 >
221  createFilePicker( const css::uno::Reference< css::uno::XComponentContext >& ) override;
222  virtual css::uno::Reference< css::ui::dialogs::XFolderPicker2 >
223  createFolderPicker( const css::uno::Reference< css::uno::XComponentContext >& ) override;
224 
225  virtual css::uno::Reference< css::uno::XInterface > CreateClipboard( const css::uno::Sequence< css::uno::Any >& i_rArguments ) override;
226  virtual css::uno::Reference< css::uno::XInterface > CreateDragSource() override;
227  virtual css::uno::Reference< css::uno::XInterface > CreateDropTarget() override;
228  virtual OpenGLContext* CreateOpenGLContext() override;
229  virtual weld::Builder* CreateBuilder(weld::Widget* pParent, const OUString& rUIRoot, const OUString& rUIFile) override;
230  virtual weld::Builder* CreateInterimBuilder(vcl::Window* pParent, const OUString& rUIRoot, const OUString& rUIFile,
231  bool bAllowCycleFocusOut, sal_uInt64 nLOKWindowId = 0) override;
232  virtual weld::MessageDialog* CreateMessageDialog(weld::Widget* pParent, VclMessageType eMessageType, VclButtonsType eButtonType, const OUString &rPrimaryMessage) override;
233  virtual weld::Window* GetFrameWeld(const css::uno::Reference<css::awt::XWindow>& rWindow) override;
234 
235  virtual const cairo_font_options_t* GetCairoFontOptions() override;
238 
239  void RemoveTimer ();
240 
241  void* CreateGStreamerSink(const SystemChildWindow*) override;
242 
243 private:
245  std::unordered_map< GdkAtom, css::uno::Reference<css::uno::XInterface> > m_aClipboards;
246  bool IsTimerExpired();
249 };
250 
252 {
253 private:
255  GtkWidget* m_pWidget;
256 public:
257 
258  SalGtkXWindow(weld::Window* pWeldWidget, GtkWidget* pWidget)
259  : TransportAsXWindow(pWeldWidget)
260  , m_pWeldWidget(pWeldWidget)
261  , m_pWidget(pWidget)
262  {
263  }
264 
265  virtual void clear() override
266  {
267  m_pWeldWidget = nullptr;
268  m_pWidget = nullptr;
269  TransportAsXWindow::clear();
270  }
271 
272  GtkWidget* getGtkWidget() const
273  {
274  return m_pWidget;
275  }
276 
278  {
279  return m_pWeldWidget;
280  }
281 };
282 
283 GdkPixbuf* load_icon_by_name(const OUString& rIconName);
284 
285 #endif // INCLUDED_VCL_INC_UNX_GTK_GTKINST_HXX
286 
287 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual bool hasNativeFileSelection() const override
Definition: gtkinst.hxx:218
virtual void AddToRecentDocumentList(const OUString &rFileUrl, const OUString &rMimeType, const OUString &rDocumentService) override
void dragEnd(GdkDragContext *context)
virtual std::unique_ptr< SalMenu > CreateMenu(bool, Menu *) override
std::vector< GtkTargetEntry > FormatsToGtk(const css::uno::Sequence< css::datatransfer::DataFlavor > &rFormats)
virtual const cairo_font_options_t * GetCairoFontOptions() override
void ThreadsEnter()
VclButtonsType
Definition: vclenum.hxx:244
TransportAsXWindow(weld::Widget *pWeldWidget, weld::Builder *pWeldWidgetBuilder=nullptr)
Definition: weldutils.hxx:52
css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
virtual void SAL_CALL initialize(const css::uno::Sequence< css::uno::Any > &rArguments) override
virtual css::uno::Any SAL_CALL getTransferData(const css::datatransfer::DataFlavor &rFlavor) override=0
weld::Window * getFrameWeld() const
Definition: gtkinst.hxx:277
signed char sal_Int8
virtual SalSystem * CreateSalSystem() override
virtual css::uno::Sequence< css::datatransfer::DataFlavor > SAL_CALL getTransferDataFlavors() override
long Long
GtkSalFrame * m_pFrame
Definition: gtkinst.hxx:136
void RemoveTimer()
void fire_dragOver(const css::datatransfer::dnd::DropTargetDragEvent &dtde)
gboolean signalDragMotion(GtkWidget *pWidget, GdkDragContext *context, gint x, gint y, guint time)
sal_Bool SAL_CALL supportsService(OUString const &ServiceName) override
virtual std::vector< css::datatransfer::DataFlavor > getTransferDataFlavorsAsVector()=0
void * CreateGStreamerSink(const SystemChildWindow *) override
virtual OpenGLContext * CreateOpenGLContext() override
virtual void SAL_CALL setDefaultActions(sal_Int8 actions) override
virtual void clear() override
Definition: gtkinst.hxx:265
void signalDragLeave(GtkWidget *pWidget, GdkDragContext *context, guint time)
virtual weld::Builder * CreateBuilder(weld::Widget *pParent, const OUString &rUIRoot, const OUString &rUIFile) override
virtual SalTimer * CreateSalTimer() override
GtkWidget * getGtkWidget() const
Definition: gtkinst.hxx:272
vcl::Font pango_to_vcl(const PangoFontDescription *font, const css::lang::Locale &rLocale)
const cairo_font_options_t * GetLastSeenCairoFontOptions() const
css::uno::Reference< css::datatransfer::XTransferable > m_xTrans
Definition: gtkinst.hxx:138
virtual sal_Int32 SAL_CALL getDefaultCursor(sal_Int8 dragAction) override
virtual ~GtkDropTarget() override
bool m_bActive
Definition: gtkinst.hxx:89
virtual void SAL_CALL addDropTargetListener(const css::uno::Reference< css::datatransfer::dnd::XDropTargetListener > &) override
virtual css::uno::Reference< css::ui::dialogs::XFilePicker2 > createFilePicker(const css::uno::Reference< css::uno::XComponentContext > &) override
VclInputFlags
Definition: inputtypes.hxx:25
GtkSalFrame * m_pFrame
Definition: gtkinst.hxx:87
virtual ~GtkDragSource() override
sal_Int8 m_nDefaultActions
Definition: gtkinst.hxx:91
virtual css::uno::Reference< css::ui::dialogs::XFolderPicker2 > createFolderPicker(const css::uno::Reference< css::uno::XComponentContext > &) override
std::vector< css::datatransfer::DataFlavor > aInfoToFlavor
Definition: gtkinst.hxx:58
virtual SalFrame * CreateFrame(SalFrame *pParent, SalFrameStyleFlags nStyle) override
GdkPixbuf * load_icon_by_name(const OUString &rIconName)
OUString SAL_CALL getImplementationName() override
virtual sal_Bool SAL_CALL isActive() override
void fire_dragExit(const css::datatransfer::dnd::DropTargetEvent &dte)
ttype
virtual css::uno::Reference< css::uno::XInterface > CreateDragSource() override
VclMessageType
Definition: vclenum.hxx:254
cairo_font_options_t * m_pLastCairoFontOptions
Definition: gtkinst.hxx:248
virtual void AfterAppInit() override
void ThreadsLeave()
virtual std::unique_ptr< SalMenuItem > CreateMenuItem(const SalItemParams &) override
void SetFormatConversionRequest(GtkDnDTransferable *pRequest)
Definition: gtkinst.hxx:120
osl::Mutex m_aMutex
Definition: gtkinst.hxx:86
virtual void SAL_CALL setActive(sal_Bool active) override
osl::Mutex m_aMutex
Definition: gtkinst.hxx:135
std::vector< GtkTargetEntry > FormatsToGtk(const css::uno::Sequence< css::datatransfer::DataFlavor > &rFormats)
virtual std::shared_ptr< SalBitmap > CreateSalBitmap() override
GtkSalTimer * m_pTimer
Definition: gtkinst.hxx:244
virtual bool AnyInput(VclInputFlags nType) override
void deinitialize()
std::map< OUString, GdkAtom > m_aMimeTypeToAtom
Definition: gtkinst.hxx:69
void deinitialize()
sal_Bool SAL_CALL supportsService(OUString const &ServiceName) override
void setActiveDragSource()
virtual bool IsMainThread() const override
Definition: gtkinst.hxx:214
unsigned char sal_Bool
bool m_bInDrag
Definition: gtkinst.hxx:90
virtual std::unique_ptr< SalVirtualDevice > CreateVirtualDevice(SalGraphics *, tools::Long &nDX, tools::Long &nDY, DeviceFormat eFormat, const SystemGraphicsData *=nullptr) override
virtual css::uno::Reference< css::uno::XInterface > CreateClipboard(const css::uno::Sequence< css::uno::Any > &i_rArguments) override
css::uno::Reference< css::datatransfer::XTransferable > const & GetTransferrable() const
Definition: gtkinst.hxx:182
virtual weld::Window * GetFrameWeld(const css::uno::Reference< css::awt::XWindow > &rWindow) override
void fire_dragEnter(const css::datatransfer::dnd::DropTargetDragEnterEvent &dtdee)
std::vector< css::uno::Reference< css::datatransfer::dnd::XDropTargetListener > > m_aListeners
Definition: gtkinst.hxx:92
static GtkDragSource * g_ActiveDragSource
Definition: gtkinst.hxx:181
DeviceFormat
Definition: salgtype.hxx:28
A SalFrame is a system window (e.g. an X11 window).
Definition: salframe.hxx:112
struct _cairo_font_options cairo_font_options_t
Definition: salinst.hxx:74
virtual void SAL_CALL removeDropTargetListener(const css::uno::Reference< css::datatransfer::dnd::XDropTargetListener > &) override
css::uno::Reference< css::datatransfer::dnd::XDragSourceListener > m_xListener
Definition: gtkinst.hxx:137
Definition: menu.hxx:123
gboolean signalDragDrop(GtkWidget *pWidget, GdkDragContext *context, gint x, gint y, guint time)
void setSelectionData(const css::uno::Reference< css::datatransfer::XTransferable > &rTrans, GtkSelectionData *selection_data, guint info)
void dragDelete()
virtual ~GtkInstance() override
virtual sal_Int8 SAL_CALL getDefaultActions() override
virtual SalObject * CreateObject(SalFrame *pParent, SystemWindowData *pWindowData, bool bShow) override
SalFrameStyleFlags
Definition: salframe.hxx:64
void dragDataGet(GtkSelectionData *data, guint info)
VclToGtkHelper m_aConversionHelper
Definition: gtkinst.hxx:139
virtual css::uno::Reference< css::uno::XInterface > CreateDropTarget() override
virtual SalFrame * CreateChildFrame(SystemParentData *pParent, SalFrameStyleFlags nStyle) override
SalGtkXWindow(weld::Window *pWeldWidget, GtkWidget *pWidget)
Definition: gtkinst.hxx:258
virtual std::unique_ptr< GenPspGraphics > CreatePrintGraphics() override
void set_datatransfer(const css::uno::Reference< css::datatransfer::XTransferable > &rTrans, const css::uno::Reference< css::datatransfer::dnd::XDragSourceListener > &rListener)
GtkDnDTransferable * m_pFormatConversionRequest
Definition: gtkinst.hxx:88
bool IsTimerExpired()
weld::Window * m_pWeldWidget
Definition: gtkinst.hxx:254
virtual sal_Bool SAL_CALL isDataFlavorSupported(const css::datatransfer::DataFlavor &rFlavor) override
QPRO_FUNC_TYPE nType
virtual weld::Builder * CreateInterimBuilder(vcl::Window *pParent, const OUString &rUIRoot, const OUString &rUIFile, bool bAllowCycleFocusOut, sal_uInt64 nLOKWindowId=0) override
virtual weld::MessageDialog * CreateMessageDialog(weld::Widget *pParent, VclMessageType eMessageType, VclButtonsType eButtonType, const OUString &rPrimaryMessage) override
virtual SalInfoPrinter * CreateInfoPrinter(SalPrinterQueueInfo *pPrinterQueueInfo, ImplJobSetup *pJobSetup) override
OUString SAL_CALL getImplementationName() override
virtual sal_Bool SAL_CALL isDragImageSupported() override
virtual std::unique_ptr< SalPrinter > CreatePrinter(SalInfoPrinter *pInfoPrinter) override
bool bNeedsInit
Definition: gtkinst.hxx:247
virtual void SAL_CALL initialize(const css::uno::Sequence< css::uno::Any > &rArgs) override
std::unordered_map< GdkAtom, css::uno::Reference< css::uno::XInterface > > m_aClipboards
Definition: gtkinst.hxx:245
virtual bool DoYield(bool bWait, bool bHandleAllCurrentEvents) override
Wait for the next event (if bWait) and dispatch it, includes posted events, and timers.
virtual void SAL_CALL startDrag(const css::datatransfer::dnd::DragGestureEvent &trigger, sal_Int8 sourceActions, sal_Int32 cursor, sal_Int32 image, const css::uno::Reference< css::datatransfer::XTransferable > &transferable, const css::uno::Reference< css::datatransfer::dnd::XDragSourceListener > &listener) override
void signalDragDropReceived(GtkWidget *pWidget, GdkDragContext *context, gint x, gint y, GtkSelectionData *data, guint ttype, guint time)
GtkTargetEntry makeGtkTargetEntry(const css::datatransfer::DataFlavor &rFlavor)
void dragFailed()
void fire_drop(const css::datatransfer::dnd::DropTargetDropEvent &dtde)
static thread_local std::stack< sal_uInt32 > yieldCounts
Definition: gtkinst.hxx:46
css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
GtkWidget * m_pWidget
Definition: gtkinst.hxx:255
void ResetLastSeenCairoFontOptions(const cairo_font_options_t *pOptions)
void EnsureInit()
GtkInstance(std::unique_ptr< SalYieldMutex > pMutex)