"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "sfx2/source/control/recentdocsview.cxx" between
libreoffice-7.1.5.1.tar.xz and libreoffice-7.1.5.2.tar.xz

About: LibreOffice source code (core). "Fresh" packages (pre-release version).

recentdocsview.cxx  (libreoffice-7.1.5.1.tar.xz):recentdocsview.cxx  (libreoffice-7.1.5.2.tar.xz)
skipping to change at line 133 skipping to change at line 133
constexpr tools::Long gnItemPadding = 5; constexpr tools::Long gnItemPadding = 5;
RecentDocsView::RecentDocsView(std::unique_ptr<weld::ScrolledWindow> xWindow, st d::unique_ptr<weld::Menu> xMenu) RecentDocsView::RecentDocsView(std::unique_ptr<weld::ScrolledWindow> xWindow, st d::unique_ptr<weld::Menu> xMenu)
: ThumbnailView(std::move(xWindow), std::move(xMenu)) : ThumbnailView(std::move(xWindow), std::move(xMenu))
, mnFileTypes(ApplicationType::TYPE_NONE) , mnFileTypes(ApplicationType::TYPE_NONE)
, mnLastMouseDownItem(THUMBNAILVIEW_ITEM_NOTFOUND) , mnLastMouseDownItem(THUMBNAILVIEW_ITEM_NOTFOUND)
, maWelcomeImage() , maWelcomeImage()
, maWelcomeLine1(SfxResId(STR_WELCOME_LINE1)) , maWelcomeLine1(SfxResId(STR_WELCOME_LINE1))
, maWelcomeLine2(SfxResId(STR_WELCOME_LINE2)) , maWelcomeLine2(SfxResId(STR_WELCOME_LINE2))
, mpLoadRecentFile(nullptr) , mpLoadRecentFile(nullptr)
, m_nExecuteHdlId(nullptr)
{ {
tools::Rectangle aScreen = Application::GetScreenPosSizePixel(Application::G etDisplayBuiltInScreen()); tools::Rectangle aScreen = Application::GetScreenPosSizePixel(Application::G etDisplayBuiltInScreen());
mnItemMaxSize = std::min(aScreen.GetWidth(),aScreen.GetHeight()) > 800 ? 256 : 192; mnItemMaxSize = std::min(aScreen.GetWidth(),aScreen.GetHeight()) > 800 ? 256 : 192;
setItemMaxTextLength( 30 ); setItemMaxTextLength( 30 );
setItemDimensions( mnItemMaxSize, mnItemMaxSize, gnTextHeight, gnItemPadding ); setItemDimensions( mnItemMaxSize, mnItemMaxSize, gnTextHeight, gnItemPadding );
maFillColor = Color(officecfg::Office::Common::Help::StartCenter::StartCente rThumbnailsBackgroundColor::get()); maFillColor = Color(officecfg::Office::Common::Help::StartCenter::StartCente rThumbnailsBackgroundColor::get());
maTextColor = Color(officecfg::Office::Common::Help::StartCenter::StartCente rThumbnailsTextColor::get()); maTextColor = Color(officecfg::Office::Common::Help::StartCenter::StartCente rThumbnailsTextColor::get());
maHighlightColor = Color(officecfg::Office::Common::Help::StartCenter::Start CenterThumbnailsHighlightColor::get()); maHighlightColor = Color(officecfg::Office::Common::Help::StartCenter::Start CenterThumbnailsHighlightColor::get());
maHighlightTextColor = Color(officecfg::Office::Common::Help::StartCenter::S tartCenterThumbnailsHighlightTextColor::get()); maHighlightTextColor = Color(officecfg::Office::Common::Help::StartCenter::S tartCenterThumbnailsHighlightTextColor::get());
mfHighlightTransparence = 0.25; mfHighlightTransparence = 0.25;
UpdateColors(); UpdateColors();
} }
RecentDocsView::~RecentDocsView() RecentDocsView::~RecentDocsView()
{ {
Application::RemoveUserEvent(m_nExecuteHdlId);
m_nExecuteHdlId = nullptr;
if (mpLoadRecentFile) if (mpLoadRecentFile)
{ {
mpLoadRecentFile->pView = nullptr; mpLoadRecentFile->pView = nullptr;
mpLoadRecentFile = nullptr; mpLoadRecentFile = nullptr;
} }
} }
bool RecentDocsView::typeMatchesExtension(ApplicationType type, const OUString & rExt) bool RecentDocsView::typeMatchesExtension(ApplicationType type, const OUString & rExt)
{ {
bool bRet = false; bool bRet = false;
skipping to change at line 404 skipping to change at line 407
void RecentDocsView::Clear() void RecentDocsView::Clear()
{ {
Invalidate(); Invalidate();
ThumbnailView::Clear(); ThumbnailView::Clear();
} }
void RecentDocsView::PostLoadRecentUsedFile(LoadRecentFile* pLoadRecentFile) void RecentDocsView::PostLoadRecentUsedFile(LoadRecentFile* pLoadRecentFile)
{ {
assert(!mpLoadRecentFile); assert(!mpLoadRecentFile);
mpLoadRecentFile = pLoadRecentFile; mpLoadRecentFile = pLoadRecentFile;
Application::PostUserEvent(LINK(nullptr, RecentDocsView, ExecuteHdl_Impl), p LoadRecentFile); m_nExecuteHdlId = Application::PostUserEvent(LINK(this, RecentDocsView, Exec uteHdl_Impl), pLoadRecentFile);
} }
void RecentDocsView::DispatchedLoadRecentUsedFile() void RecentDocsView::DispatchedLoadRecentUsedFile()
{ {
mpLoadRecentFile = nullptr; mpLoadRecentFile = nullptr;
} }
IMPL_STATIC_LINK( RecentDocsView, ExecuteHdl_Impl, void*, p, void ) IMPL_LINK( RecentDocsView, ExecuteHdl_Impl, void*, p, void )
{ {
m_nExecuteHdlId = nullptr;
LoadRecentFile* pLoadRecentFile = static_cast<LoadRecentFile*>(p); LoadRecentFile* pLoadRecentFile = static_cast<LoadRecentFile*>(p);
try try
{ {
// Asynchronous execution as this can lead to our own destruction! // Asynchronous execution as this can lead to our own destruction!
// Framework can recycle our current frame and the layout manager dispos es all user interface // Framework can recycle our current frame and the layout manager dispos es all user interface
// elements if a component gets detached from its frame! // elements if a component gets detached from its frame!
pLoadRecentFile->xDispatch->dispatch( pLoadRecentFile->aTargetURL, pLoad RecentFile->aArgSeq ); pLoadRecentFile->xDispatch->dispatch( pLoadRecentFile->aTargetURL, pLoad RecentFile->aArgSeq );
} }
catch ( const Exception& ) catch ( const Exception& )
{ {
 End of changes. 5 change blocks. 
2 lines changed or deleted 6 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)