LibreOffice Module vcl (master) 1
svmain.cxx
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#include <sal/config.h>
21#include <sal/log.hxx>
22
23#include <cassert>
24
25#include <osl/file.hxx>
26#include <osl/signal.h>
27
28#include <desktop/exithelper.h>
29
36#include <utility>
37#include <vcl/QueueInfo.hxx>
38#include <vcl/svapp.hxx>
39#include <vcl/vclmain.hxx>
40#include <vcl/wrkwin.hxx>
41#include <vcl/cvtgrf.hxx>
42#include <vcl/scheduler.hxx>
43#include <vcl/image.hxx>
44#include <vcl/ImageTree.hxx>
45#include <vcl/settings.hxx>
47#include <configsettings.hxx>
48#include <vcl/lazydelete.hxx>
51#include <vcl/menu.hxx>
52#include <vcl/virdev.hxx>
53#include <vcl/print.hxx>
54#include <debugevent.hxx>
55#include <scrwnd.hxx>
56#include <windowdev.hxx>
57#include <svdata.hxx>
58
59#ifdef _WIN32
60#include <svsys.h>
61#include <process.h>
62#include <ole2.h>
63#else
64#include <stdlib.h>
65#endif
66
67#ifdef ANDROID
69#include <jni.h>
70#endif
71
72#include <impfontcache.hxx>
73#include <salinst.hxx>
74#include <vcl/svmain.hxx>
75#include <dbggui.hxx>
76#include <accmgr.hxx>
78#include <print.h>
79#include <salsys.hxx>
80#include <saltimer.hxx>
82
83#include <config_features.h>
84#include <config_feature_opencl.h>
85
86#include <osl/process.h>
87#include <com/sun/star/lang/XComponent.hpp>
88#include <com/sun/star/frame/Desktop.hpp>
89
90#ifdef _WIN32
91#include <com/sun/star/datatransfer/clipboard/XClipboard.hpp>
92#endif
93
94#include <comphelper/lok.hxx>
96#include <uno/current_context.hxx>
97
98#include <opencl/OpenCLZone.hxx>
99#include <opengl/zone.hxx>
100#include <skia/zone.hxx>
101#include <watchdog.hxx>
102
105
106#if OSL_DEBUG_LEVEL > 0
107#include <typeinfo>
108#include <rtl/strbuf.hxx>
109#endif
110
111#ifdef LINUX
112#include <unx/gendata.hxx>
113#endif
114
115using namespace ::com::sun::star;
116
118
119static oslSignalAction VCLExceptionSignal_impl( void* /*pData*/, oslSignalInfo* pInfo)
120{
121 static volatile bool bIn = false;
122
123 // if we crash again, bail out immediately
124 if ( bIn || g_bIsLeanException)
125 return osl_Signal_ActCallNextHdl;
126
128
129 // UAE
130 if ( (pInfo->Signal == osl_Signal_AccessViolation) ||
131 (pInfo->Signal == osl_Signal_IntegerDivideByZero) ||
132 (pInfo->Signal == osl_Signal_FloatDivideByZero) ||
133 (pInfo->Signal == osl_Signal_DebugBreak) )
134 {
135 nVCLException = ExceptionCategory::System;
136#if HAVE_FEATURE_OPENGL
139#endif
140#if HAVE_FEATURE_SKIA
141 if (SkiaZone::isInZone())
143#endif
144#if HAVE_FEATURE_OPENCL
145 if (OpenCLZone::isInZone())
146 {
148#ifdef _WIN32
149 if (OpenCLInitialZone::isInZone())
150 TerminateProcess(GetCurrentProcess(), EXITHELPER_NORMAL_RESTART);
151#endif
152 }
153#endif
154 }
155
156 // DISPLAY-Unix
157 if ((pInfo->Signal == osl_Signal_User) &&
158 (pInfo->UserSignal == OSL_SIGNAL_USER_X11SUBSYSTEMERROR) )
159 nVCLException = ExceptionCategory::UserInterface;
160
161 if ( nVCLException != ExceptionCategory::NONE )
162 {
163 bIn = true;
164
166 if( aLock.isAcquired())
167 {
168 // do not stop timer because otherwise the UAE-Box will not be painted as well
169 ImplSVData* pSVData = ImplGetSVData();
170 if ( pSVData->mpApp )
171 {
174 pSVData->mpApp->Exception( nVCLException );
176 }
177 }
178 bIn = false;
179 }
180
181 return osl_Signal_ActCallNextHdl;
182
183}
184
186{
187 // The 'real' SVMain()
188 ImplSVData* pSVData = ImplGetSVData();
189
190 SAL_WARN_IF( !pSVData->mpApp, "vcl", "no instance of class Application" );
191
192 int nReturn = EXIT_FAILURE;
193
194 const bool bWasInitVCL = IsVCLInit();
195 const bool bInit = bWasInitVCL || InitVCL();
196 int nRet = 0;
197 if (!bWasInitVCL && bInit && pSVData->mpDefInst->SVMainHook(&nRet))
198 return nRet;
199
200 if( bInit )
201 {
202 // call application main
203 pSVData->maAppData.mbInAppMain = true;
204 nReturn = pSVData->mpApp->Main();
205 pSVData->maAppData.mbInAppMain = false;
206 }
207
208 if( pSVData->mxDisplayConnection.is() )
209 {
210 pSVData->mxDisplayConnection->terminate();
211 pSVData->mxDisplayConnection.clear();
212 }
213
214 // This is a hack to work around the problem of the asynchronous nature
215 // of bridging accessibility through Java: on shutdown there might still
216 // be some events in the AWT EventQueue, which need the SolarMutex which
217 // - on the other hand - is destroyed in DeInitVCL(). So empty the queue
218 // here ..
219 if( pSVData->mxAccessBridge.is() )
220 {
221 {
222 SolarMutexReleaser aReleaser;
223 pSVData->mxAccessBridge->dispose();
224 }
225 pSVData->mxAccessBridge.clear();
226 }
227
229 DeInitVCL();
230
231 return nReturn;
232}
233
235{
236 return ImplSVMain();
237}
238
239// This variable is set when no Application object has been instantiated
240// before InitVCL is called
241static Application * pOwnSvApp = nullptr;
242
243// Exception handler. pExceptionHandler != NULL => VCL already inited
244static oslSignalHandler pExceptionHandler = nullptr;
245
246namespace {
247
248class DesktopEnvironmentContext: public cppu::WeakImplHelper< css::uno::XCurrentContext >
249{
250public:
251 explicit DesktopEnvironmentContext( css::uno::Reference< css::uno::XCurrentContext > ctx)
252 : m_xNextContext(std::move( ctx )) {}
253
254 // XCurrentContext
255 virtual css::uno::Any SAL_CALL getValueByName( const OUString& Name ) override;
256
257private:
258 css::uno::Reference< css::uno::XCurrentContext > m_xNextContext;
259};
260
261}
262
263uno::Any SAL_CALL DesktopEnvironmentContext::getValueByName( const OUString& Name)
264{
265 uno::Any retVal;
266
267 if ( Name == "system.desktop-environment" )
268 {
270 }
271 else if( m_xNextContext.is() )
272 {
273 // Call next context in chain if found
274 retVal = m_xNextContext->getValueByName( Name );
275 }
276 return retVal;
277}
278
280{
281 ImplSVData* pSVData = ImplGetSVData();
282 return pExceptionHandler != nullptr &&
283 pSVData->mpApp != nullptr &&
284 pSVData->mpDefInst != nullptr;
285}
286
287#ifdef DBG_UTIL
288namespace vclmain
289{
290 bool isAlive()
291 {
292 return ImplGetSVData()->mpDefInst;
293 }
294}
295#endif
296
297
299{
300 if (IsVCLInit())
301 {
302 SAL_INFO("vcl.app", "Double initialization of vcl");
303 return true;
304 }
305
306 if( pExceptionHandler != nullptr )
307 return false;
308
310
311 if( !ImplGetSVData()->mpApp )
312 {
313 pOwnSvApp = new Application();
314 }
315
316 ImplSVData* pSVData = ImplGetSVData();
317
318 // remember Main-Thread-Id
319 pSVData->mnMainThreadId = ::osl::Thread::getCurrentIdentifier();
320
321 // Initialize Sal
322 pSVData->mpDefInst = CreateSalInstance();
323 if ( !pSVData->mpDefInst )
324 return false;
325 pSVData->mpDefInst->AcquireYieldMutex();
326
327 // Desktop Environment context (to be able to get value of "system.desktop-environment" as soon as possible)
328 css::uno::setCurrentContext(
329 new DesktopEnvironmentContext( css::uno::getCurrentContext() ) );
330
331 // Initialize application instance (should be done after initialization of VCL SAL part)
332 if (pSVData->mpApp)
333 {
334 // call init to initialize application class
335 // soffice/sfx implementation creates the global service manager
336 pSVData->mpApp->Init();
337 }
338
339 try
340 {
341 //Now that uno has been bootstrapped we can ask the config what the UI language is so that we can
342 //force that in as $LANGUAGE. That way we can get gtk to render widgets RTL
343 //if we have a RTL UI in an otherwise LTR locale and get gettext using externals (e.g. python)
344 //to match their translations to our preferred UI language
345 OUString aLocaleString(SvtSysLocaleOptions().GetRealUILanguageTag().getGlibcLocaleString(u".UTF-8"));
346 if (!aLocaleString.isEmpty())
347 {
348 MsLangId::getSystemUILanguage(); //call this now to pin what the system UI really was
349 OUString envVar("LANGUAGE");
350 osl_setEnvironment(envVar.pData, aLocaleString.pData);
351 }
352 }
353 catch (const uno::Exception &)
354 {
355 TOOLS_INFO_EXCEPTION("vcl.app", "Unable to get ui language:");
356 }
357
358 pSVData->mpDefInst->AfterAppInit();
359
360 // Fetch AppFileName and make it absolute before the workdir changes...
361 OUString aExeFileName;
362 osl_getExecutableFile( &aExeFileName.pData );
363
364 // convert path to native file format
365 OUString aNativeFileName;
366 osl::FileBase::getSystemPathFromFileURL( aExeFileName, aNativeFileName );
367 pSVData->maAppData.mxAppFileName = aNativeFileName;
368
369 // Initialize global data
370 pSVData->maGDIData.mxScreenFontList = std::make_shared<vcl::font::PhysicalFontCollection>();
371 pSVData->maGDIData.mxScreenFontCache = std::make_shared<ImplFontCache>();
372 pSVData->maGDIData.mxGrfConverter.reset(new GraphicConverter);
373
374 g_bIsLeanException = getenv("LO_LEAN_EXCEPTION") != nullptr;
375 // Set exception handler
376 pExceptionHandler = osl_addSignalHandler(VCLExceptionSignal_impl, nullptr);
377
378#ifndef NDEBUG
380#endif
381
382#if OSL_DEBUG_LEVEL > 0
384#endif
385
386#ifndef _WIN32
387 // Clear startup notification details for child processes
388 // See https://bugs.freedesktop.org/show_bug.cgi?id=11375 for discussion
389 unsetenv("DESKTOP_STARTUP_ID");
390#endif
391
392 return true;
393}
394
395namespace
396{
397
403class VCLUnoWrapperDeleter : public cppu::WeakImplHelper<css::lang::XEventListener>
404{
405 virtual void SAL_CALL disposing(lang::EventObject const& rSource) override;
406};
407
408void
409VCLUnoWrapperDeleter::disposing(lang::EventObject const& /* rSource */)
410{
411 ImplSVData* const pSVData = ImplGetSVData();
412 if (pSVData && pSVData->mpUnoWrapper)
413 {
414 pSVData->mpUnoWrapper->Destroy();
415 pSVData->mpUnoWrapper = nullptr;
416 }
417}
418
419}
420
422{
423 // The LOK Windows map container should be empty
425
426 //rhbz#1444437, when using LibreOffice like a library you can't realistically
427 //tear everything down and recreate them on the next call, there's too many
428 //(c++) singletons that point to stuff that gets deleted during shutdown
429 //which won't be recreated on restart.
431 return;
432
433 {
434 SolarMutexReleaser r; // unblock threads blocked on that so we can join
435 ::comphelper::JoinAsyncEventNotifiers();
436 }
437 ImplSVData* pSVData = ImplGetSVData();
438
439 // lp#1560328: clear cache before disposing rest of VCL
440 if(pSVData->mpBlendFrameCache)
441 pSVData->mpBlendFrameCache->m_aLastResult.Clear();
442 pSVData->mbDeInit = true;
443
445
446#if OSL_DEBUG_LEVEL > 0
447 OStringBuffer aBuf( 256 );
448 aBuf.append( "DeInitVCL: some top Windows are still alive\n" );
450 tools::Long nBadTopWindows = nTopWindowCount;
451 for( tools::Long i = 0; i < nTopWindowCount; i++ )
452 {
454 // default window will be destroyed further down
455 // but may still be useful during deinit up to that point
456 if( pWin == pSVData->mpDefaultWin )
457 nBadTopWindows--;
458 else
459 {
460 aBuf.append( "text = \""
461 + OUStringToOString( pWin->GetText(), osl_getThreadTextEncoding() )
462 + "\" type = \""
463 + typeid(*pWin).name()
464 + "\", ptr = 0x"
465 + OString::number(reinterpret_cast<sal_Int64>( pWin ), 16 )
466 + "\n" );
467 }
468 }
469 SAL_WARN_IF( nBadTopWindows!=0, "vcl", aBuf.getStr() );
470#endif
471
473
474 osl_removeSignalHandler( pExceptionHandler);
475 pExceptionHandler = nullptr;
476
477 // free global data
478 pSVData->maGDIData.mxGrfConverter.reset();
479 pSVData->mpSettingsConfigItem.reset();
480
481 // prevent unnecessary painting during Scheduler shutdown
482 // as this processes all pending events in debug builds.
484
486
487 pSVData->mpWinData->maMsgBoxImgList.clear();
488 pSVData->maCtrlData.maCheckImgList.clear();
489 pSVData->maCtrlData.maRadioImgList.clear();
490 pSVData->maCtrlData.moDisclosurePlus.reset();
491 pSVData->maCtrlData.moDisclosureMinus.reset();
492 pSVData->mpDefaultWin.disposeAndClear();
493
494#if defined _WIN32
495 // See GetSystemClipboard (vcl/source/treelist/transfer2.cxx):
496 if (auto const comp = css::uno::Reference<css::lang::XComponent>(
497 pSVData->m_xSystemClipboard, css::uno::UNO_QUERY))
498 {
499 SolarMutexReleaser r; // unblock pending "clipboard content changed" notifications
500 comp->dispose(); // will use s_aClipboardSingletonMutex for CWinClipboard
501 }
502 pSVData->m_xSystemClipboard.clear();
503#endif
504
505#ifndef NDEBUG
507#endif
508
509 if ( pSVData->mpUnoWrapper )
510 {
511 try
512 {
513 uno::Reference<frame::XDesktop2> const xDesktop = frame::Desktop::create(
515 xDesktop->addEventListener(new VCLUnoWrapperDeleter);
516 }
517 catch (uno::Exception const&)
518 {
519 // ignore
520 }
521 }
522
523 if( pSVData->mpApp || pSVData->maDeInitHook.IsSet() )
524 {
525 SolarMutexReleaser aReleaser;
526 // call deinit to deinitialize application class
527 // soffice/sfx implementation disposes the global service manager
528 // Warning: After this call you can't call uno services
529 if( pSVData->mpApp )
530 {
531 pSVData->mpApp->DeInit();
532 }
533 if( pSVData->maDeInitHook.IsSet() )
534 {
535 pSVData->maDeInitHook.Call(nullptr);
536 }
537 }
538
539 if ( pSVData->maAppData.mxSettings )
540 {
541 if ( pSVData->maAppData.mpCfgListener )
542 {
543 pSVData->maAppData.mxSettings->GetSysLocale().GetOptions().RemoveListener( pSVData->maAppData.mpCfgListener );
544 delete pSVData->maAppData.mpCfgListener;
545 }
546
547 pSVData->maAppData.mxSettings.reset();
548 }
549 if ( pSVData->maAppData.mpAccelMgr )
550 {
551 delete pSVData->maAppData.mpAccelMgr;
552 pSVData->maAppData.mpAccelMgr = nullptr;
553 }
554 pSVData->maAppData.maKeyListeners.clear();
555 pSVData->mpBlendFrameCache.reset();
556
558
559 // destroy all Sal interfaces before destroying the instance
560 // and thereby unloading the plugin
561 pSVData->mpSalSystem.reset();
562 assert( !pSVData->maSchedCtx.mpSalTimer );
563 delete pSVData->maSchedCtx.mpSalTimer;
564 pSVData->maSchedCtx.mpSalTimer = nullptr;
565
566 pSVData->mpDefaultWin = nullptr;
567 pSVData->mpIntroWindow = nullptr;
568 pSVData->maAppData.mpActivePopupMenu = nullptr;
569 pSVData->maAppData.mpWheelWindow = nullptr;
570 pSVData->maGDIData.mpFirstWinGraphics = nullptr;
571 pSVData->maGDIData.mpLastWinGraphics = nullptr;
572 pSVData->maGDIData.mpFirstVirGraphics = nullptr;
573 pSVData->maGDIData.mpLastVirGraphics = nullptr;
574 pSVData->maGDIData.mpFirstPrnGraphics = nullptr;
575 pSVData->maGDIData.mpLastPrnGraphics = nullptr;
576 pSVData->maGDIData.mpFirstVirDev = nullptr;
577 pSVData->maGDIData.mpFirstPrinter = nullptr;
578 pSVData->maFrameData.mpFirstFrame = nullptr;
579 pSVData->maFrameData.mpAppWin = nullptr;
580 pSVData->maFrameData.mpActiveApplicationFrame = nullptr;
581 pSVData->mpWinData->mpCaptureWin = nullptr;
582 pSVData->mpWinData->mpLastDeacWin = nullptr;
583 pSVData->mpWinData->mpFirstFloat = nullptr;
584 pSVData->mpWinData->mpExecuteDialogs.clear();
585 pSVData->mpWinData->mpExtTextInputWin = nullptr;
586 pSVData->mpWinData->mpTrackWin = nullptr;
587 pSVData->mpWinData->mpAutoScrollWin = nullptr;
588 pSVData->mpWinData->mpLastWheelWindow = nullptr;
589
590 pSVData->maGDIData.mxScreenFontList.reset();
591 pSVData->maGDIData.mxScreenFontCache.reset();
592 pSVData->dropCaches();
593
595
596 // Deinit Sal
597 if (pSVData->mpDefInst)
598 {
600 DestroySalInstance( pSVData->mpDefInst );
601 pSVData->mpDefInst = nullptr;
602 }
603
604 // This only works on Linux. On Mac and Windows I get very
605 // weird segment violations.
606#if defined LINUX
607 delete pSVData->mpSalData;
608#endif
609
610 if( pOwnSvApp )
611 {
612 delete pOwnSvApp;
613 pOwnSvApp = nullptr;
614 }
615
617}
618
619namespace {
620
621// only one call is allowed
622struct WorkerThreadData
623{
624 oslWorkerFunction pWorker;
625 void * pThreadData;
626 WorkerThreadData( oslWorkerFunction pWorker_, void * pThreadData_ )
627 : pWorker( pWorker_ )
628 , pThreadData( pThreadData_ )
629 {
630 }
631};
632
633}
634
635#ifdef _WIN32
636static HANDLE hThreadID = nullptr;
637static DWORD WINAPI threadmain( _In_ LPVOID pArgs )
638{
639 OleInitialize( nullptr );
640 static_cast<WorkerThreadData*>(pArgs)->pWorker( static_cast<WorkerThreadData*>(pArgs)->pThreadData );
641 delete static_cast<WorkerThreadData*>(pArgs);
642 OleUninitialize();
643 hThreadID = nullptr;
644 return 0;
645}
646#else
647static oslThread hThreadID = nullptr;
648extern "C"
649{
650static void MainWorkerFunction( void* pArgs )
651{
652 static_cast<WorkerThreadData*>(pArgs)->pWorker( static_cast<WorkerThreadData*>(pArgs)->pThreadData );
653 delete static_cast<WorkerThreadData*>(pArgs);
654 hThreadID = nullptr;
655}
656} // extern "C"
657#endif
658
659void CreateMainLoopThread( oslWorkerFunction pWorker, void * pThreadData )
660{
661#ifdef _WIN32
662 // sal thread always call CoInitializeEx, so a system dependent implementation is necessary
663
664 DWORD uThreadID;
665 hThreadID = CreateThread(
666 nullptr, // no security handle
667 0, // stacksize 0 means default
668 threadmain, // thread worker function
669 new WorkerThreadData( pWorker, pThreadData ), // arguments for worker function
670 0, // 0 means: create immediately otherwise use CREATE_SUSPENDED
671 &uThreadID ); // thread id to fill
672#else
673 hThreadID = osl_createThread( MainWorkerFunction, new WorkerThreadData( pWorker, pThreadData ) );
674#endif
675}
676
678{
679 if( hThreadID )
680 {
681#ifdef _WIN32
682 WaitForSingleObject(hThreadID, INFINITE);
683#else
684 osl_joinWithThread(hThreadID);
685 osl_destroyThread( hThreadID );
686#endif
687 }
688}
689
690/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Base class used mainly for the LibreOffice Desktop class.
Definition: svapp.hxx:237
static tools::Long GetTopWindowCount()
Return the number of top-level windows being used by the application.
Definition: svapp.cxx:1072
virtual void Init()
Initialize the application itself.
Definition: svapp.cxx:200
static vcl::Window * GetTopWindow(tools::Long nIndex)
Get the nth top window.
Definition: svapp.cxx:1086
static SystemWindowFlags GetSystemWindowMode()
Get the system window mode of dialogs.
Definition: svapp.cxx:1449
virtual void Exception(ExceptionCategory nCategory)
Handles an error.
Definition: svapp.cxx:245
static void SetSystemWindowMode(SystemWindowFlags nMode)
Make a dialog box a system window or not.
Definition: svapp.cxx:1444
virtual int Main()
Pure virtual entrypoint to the application.
Definition: svapp.cxx:179
static const OUString & GetDesktopEnvironment()
Get the desktop environment the process is currently running in.
Definition: svapp.cxx:1583
virtual void DeInit()
Deinitialized the application itself.
Definition: svapp.cxx:208
static bool isInZone()
static DebugEventInjector * getCreate()
Definition: debugevent.cxx:258
static void clearTemporaryFontFiles()
Removes all temporary fonts in the path used by fileUrlForTemporaryFont().
static VCL_DLLPUBLIC ImageTree & get()
Definition: ImageTree.cxx:16
VCL_DLLPUBLIC void shutdown()
a crude form of life cycle control (called from DeInitVCL; otherwise, if the ImplImageTree singleton ...
Definition: ImageTree.cxx:62
static LanguageType getSystemUILanguage()
static void hardDisable()
static void hardDisable()
Called from a signal handler or watchdog thread if we get a crash or hang in some GL code.
virtual bool SVMainHook(int *)
Definition: salinst.hxx:95
void AcquireYieldMutex(sal_uInt32 nCount=1)
Definition: salvtables.cxx:147
sal_uInt32 ReleaseYieldMutexAll()
Definition: salvtables.cxx:145
virtual void AfterAppInit()
Definition: salinst.hxx:94
static void ImplDeInitScheduler()
Definition: scheduler.cxx:101
static void hardDisable()
A helper class that calls Application::ReleaseSolarMutex() in its constructor and restores the mutex ...
Definition: svapp.hxx:1414
virtual void Destroy()=0
void disposeAndClear()
Definition: vclptr.hxx:200
static void stop()
Definition: watchdog.cxx:148
static void SAL_DLLPRIVATE ImplDeleteOnDeInit()
Definition: lazydelete.cxx:46
guard class that uses tryToAcquire() and has isAcquired() to check
Definition: svapp.hxx:1365
static bool IsLOKWindowsEmpty()
check if LOK Window container is empty
Definition: window.cxx:3209
virtual OUString GetText() const
Definition: window.cxx:3055
void DbgGUIInitSolarMutexCheck()
Definition: dbggui.cxx:38
void DbgGUIDeInitSolarMutexCheck()
Definition: dbggui.cxx:43
#define TOOLS_INFO_EXCEPTION(area, stream)
float u
ExceptionCategory
EXITHELPER_NORMAL_RESTART
#define SAL_WARN_IF(condition, area, stream)
#define SAL_INFO(area, stream)
aBuf
Reference< XComponentContext > getProcessComponentContext()
int i
ctx
OString OUStringToOString(std::u16string_view str, ConnectionSettings const *settings)
comp
long Long
bool isAlive()
Definition: svmain.cxx:290
void ImplDeletePrnQueueList()
Definition: print.cxx:381
void DestroySalInstance(SalInstance *pInst)
Definition: salplug.cxx:387
SalInstance * CreateSalInstance()
Definition: salplug.cxx:305
VclPtr< ImplWheelWindow > mpWheelWindow
Definition: svdata.hxx:157
std::vector< Link< VclWindowEvent &, bool > > maKeyListeners
Definition: svdata.hxx:148
std::optional< OUString > mxAppFileName
Definition: svdata.hxx:152
std::optional< AllSettings > mxSettings
Definition: svdata.hxx:144
VclPtr< PopupMenu > mpActivePopupMenu
Definition: svdata.hxx:156
LocaleConfigurationListener * mpCfgListener
Definition: svdata.hxx:145
ImplAccelManager * mpAccelMgr
Definition: svdata.hxx:150
bool mbInAppMain
Definition: svdata.hxx:162
std::vector< Image > maCheckImgList
Definition: svdata.hxx:275
std::optional< Image > moDisclosureMinus
Definition: svdata.hxx:278
std::optional< Image > moDisclosurePlus
Definition: svdata.hxx:277
std::vector< Image > maRadioImgList
Definition: svdata.hxx:276
ImplSVCtrlData maCtrlData
Definition: svdata.hxx:401
ImplSchedulerContext maSchedCtx
Definition: svdata.hxx:396
bool mbDeInit
Definition: svdata.hxx:392
ImplSVFrameData maFrameData
Definition: svdata.hxx:399
void dropCaches()
Definition: svdata.cxx:421
oslThreadIdentifier mnMainThreadId
Definition: svdata.hxx:409
UnoWrapperBase * mpUnoWrapper
Definition: svdata.hxx:404
SalInstance * mpDefInst
Definition: svdata.hxx:389
rtl::Reference< vcl::DisplayConnectionDispatch > mxDisplayConnection
Definition: svdata.hxx:410
ImplSVGDIData maGDIData
Definition: svdata.hxx:398
std::unique_ptr< BlendFrameCache > mpBlendFrameCache
Definition: svdata.hxx:407
Application * mpApp
Definition: svdata.hxx:390
Link< LinkParamNone *, void > maDeInitHook
Definition: svdata.hxx:423
css::uno::Reference< css::lang::XComponent > mxAccessBridge
Definition: svdata.hxx:412
VclPtr< WorkWindow > mpDefaultWin
Definition: svdata.hxx:391
ImplSVWinData * mpWinData
Definition: svdata.hxx:400
ImplSVAppData maAppData
Definition: svdata.hxx:397
std::unique_ptr< SalSystem > mpSalSystem
Definition: svdata.hxx:393
std::unique_ptr< vcl::SettingsConfigItem > mpSettingsConfigItem
Definition: svdata.hxx:413
SalData * mpSalData
Definition: svdata.hxx:388
VclPtr< vcl::Window > mpIntroWindow
Definition: svdata.hxx:405
VclPtr< WorkWindow > mpAppWin
Definition: svdata.hxx:243
VclPtr< vcl::Window > mpFirstFrame
Definition: svdata.hxx:241
VclPtr< vcl::Window > mpActiveApplicationFrame
Definition: svdata.hxx:242
VclPtr< vcl::WindowOutputDevice > mpLastWinGraphics
Definition: svdata.hxx:216
VclPtr< OutputDevice > mpLastVirGraphics
Definition: svdata.hxx:218
VclPtr< Printer > mpFirstPrnGraphics
Definition: svdata.hxx:219
std::shared_ptr< vcl::font::PhysicalFontCollection > mxScreenFontList
Definition: svdata.hxx:225
VclPtr< Printer > mpFirstPrinter
Definition: svdata.hxx:223
std::shared_ptr< ImplFontCache > mxScreenFontCache
Definition: svdata.hxx:226
std::unique_ptr< GraphicConverter > mxGrfConverter
Definition: svdata.hxx:229
VclPtr< VirtualDevice > mpFirstVirDev
Definition: svdata.hxx:221
VclPtr< OutputDevice > mpFirstVirGraphics
Definition: svdata.hxx:217
VclPtr< vcl::WindowOutputDevice > mpFirstWinGraphics
Definition: svdata.hxx:215
VclPtr< Printer > mpLastPrnGraphics
Definition: svdata.hxx:220
VclPtr< vcl::Window > mpLastWheelWindow
Definition: svdata.hxx:261
VclPtr< FloatingWindow > mpFirstFloat
Definition: svdata.hxx:254
VclPtr< vcl::Window > mpLastDeacWin
Definition: svdata.hxx:253
std::vector< Image > maMsgBoxImgList
Definition: svdata.hxx:259
VclPtr< vcl::Window > mpAutoScrollWin
Definition: svdata.hxx:260
VclPtr< vcl::Window > mpCaptureWin
Definition: svdata.hxx:252
VclPtr< vcl::Window > mpTrackWin
Definition: svdata.hxx:257
VclPtr< vcl::Window > mpExtTextInputWin
Definition: svdata.hxx:256
std::vector< VclPtr< Dialog > > mpExecuteDialogs
Stack of dialogs that are Execute()'d - the last one is the top most one.
Definition: svdata.hxx:255
SalTimer * mpSalTimer
interface to sal event loop / system timer
Definition: svdata.hxx:376
SystemWindowFlags
Definition: svapp.hxx:90
ImplSVData * ImplGetSVData()
Definition: svdata.cxx:77
basegfx::SystemDependentDataManager & ImplGetSystemDependentDataManager()
Definition: svdata.cxx:204
void JoinMainLoopThread()
Definition: svmain.cxx:677
void DeInitVCL()
Definition: svmain.cxx:421
bool IsVCLInit()
Definition: svmain.cxx:279
int ImplSVMain()
Definition: svmain.cxx:185
static void MainWorkerFunction(void *pArgs)
Definition: svmain.cxx:650
static Application * pOwnSvApp
Definition: svmain.cxx:241
static oslThread hThreadID
Definition: svmain.cxx:647
static oslSignalHandler pExceptionHandler
Definition: svmain.cxx:244
static bool g_bIsLeanException
Definition: svmain.cxx:117
bool InitVCL()
Definition: svmain.cxx:298
int SVMain()
Definition: svmain.cxx:234
static oslSignalAction VCLExceptionSignal_impl(void *, oslSignalInfo *pInfo)
Definition: svmain.cxx:119
void CreateMainLoopThread(oslWorkerFunction pWorker, void *pThreadData)
Definition: svmain.cxx:659
OUString Name