|
LibreOffice Module sfx2 (master) 1
|
#include <recentdocsview.hxx>
Public Member Functions | |
| RecentDocsView (std::unique_ptr< weld::ScrolledWindow > xWindow, std::unique_ptr< weld::Menu > xMenu) | |
| virtual | ~RecentDocsView () override |
| void | insertItem (const OUString &rURL, const OUString &rTitle, const OUString &rThumbnail, bool isReadOnly, bool isPinned, sal_uInt16 nId) |
| virtual void | Clear () override |
| virtual void | Reload () override |
| Update the information in the view. More... | |
| void | PostLoadRecentUsedFile (LoadRecentFile *pLoadRecentFile) |
| void | DispatchedLoadRecentUsedFile () |
| void | clearUnavailableFiles () |
| void | setFilter (ApplicationType aFilter) |
Public Member Functions inherited from ThumbnailView | |
| ThumbnailView (std::unique_ptr< weld::ScrolledWindow > xWindow, std::unique_ptr< weld::Menu > xMenu) | |
| virtual | ~ThumbnailView () override |
| virtual bool | MouseMove (const MouseEvent &rMEvt) override |
| virtual void | Reload () |
| Updates information in the view; used only in RecentDocsView ATM. More... | |
| void | AppendItem (std::unique_ptr< ThumbnailViewItem > pItem) |
| void | RemoveItem (sal_uInt16 nItemId) |
| virtual void | Clear () |
| void | updateItems (std::vector< std::unique_ptr< ThumbnailViewItem > > items) |
| size_t | GetItemPos (sal_uInt16 nItemId) const |
| sal_uInt16 | GetItemId (size_t nPos) const |
| sal_uInt16 | GetItemId (const Point &rPos) const |
| virtual bool | renameItem (ThumbnailViewItem *pItem, const OUString &sNewTitle) |
| bool | isDrawMnemonic () const |
| void | setItemMaxTextLength (sal_uInt32 nLength) |
| void | setItemDimensions (tools::Long ItemWidth, tools::Long ThumbnailHeight, tools::Long DisplayHeight, int itemPadding) |
| void | SelectItem (sal_uInt16 nItemId) |
| bool | IsItemSelected (sal_uInt16 nItemId) const |
| void | deselectItems () |
| deselect all current selected items. More... | |
| void | ShowTooltips (bool bShowTooltips) |
| void | DrawMnemonics (bool bDrawMnemonics) |
| void | filterItems (const std::function< bool(const ThumbnailViewItem *) > &func) |
| void | setItemStateHdl (const Link< const ThumbnailViewItem *, void > &aLink) |
| virtual void | Resize () override |
| virtual void | Show () override |
| virtual void | Hide () override |
| virtual void | SetDrawingArea (weld::DrawingArea *pDrawingArea) override |
Public Member Functions inherited from weld::CustomWidgetController | |
| virtual css::uno::Reference< css::accessibility::XAccessible > | CreateAccessible () |
| virtual void | Paint (vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect)=0 |
| virtual void | Resize () |
| virtual bool | MouseButtonDown (const MouseEvent &) |
| virtual bool | MouseMove (const MouseEvent &) |
| virtual bool | MouseButtonUp (const MouseEvent &) |
| virtual void | GetFocus () |
| virtual void | LoseFocus () |
| virtual void | StyleUpdated () |
| virtual bool | Command (const CommandEvent &) |
| virtual bool | KeyInput (const KeyEvent &) |
| virtual tools::Rectangle | GetFocusRect () |
| virtual FactoryFunction | GetUITestFactory () const |
| virtual OUString | RequestHelp (tools::Rectangle &) |
| virtual OUString | GetHelpText () const |
| Size const & | GetOutputSizePixel () const |
| void | SetOutputSizePixel (const Size &rSize) |
| virtual void | SetDrawingArea (weld::DrawingArea *pDrawingArea) |
| weld::DrawingArea * | GetDrawingArea () const |
| void | Invalidate () |
| void | Invalidate (const tools::Rectangle &rRect) |
| virtual void | Show () |
| virtual void | Hide () |
| void | SetCursor (void *pData) |
| void | GrabFocus () |
| bool | HasFocus () const |
| bool | HasChildFocus () const |
| bool | IsVisible () const |
| bool | IsReallyVisible () const |
| bool | IsEnabled () const |
| void | Enable () const |
| void | Disable () const |
| bool | IsActive () const |
| int | GetTextHeight () const |
| int | GetTextWidth (const OUString &rText) const |
| OUString | GetAccessibleName () const |
| OUString | GetAccessibleDescription () const |
| void | CaptureMouse () |
| bool | IsMouseCaptured () const |
| Point | GetPointerPosPixel () const |
| void | EnableRTL (bool bEnable) |
| bool | IsRTLEnabled () const |
| void | ReleaseMouse () |
| void | SetPointer (PointerStyle ePointerStyle) |
| void | SetHelpId (const OUString &rHelpId) |
| void | SetAccessibleName (const OUString &rName) |
| void | SetInputContext (const InputContext &rInputContext) |
| void | SetCursorRect (const tools::Rectangle &rCursorRect, int nExtTextInputWidth) |
| virtual int | GetSurroundingText (OUString &) |
| virtual bool | DeleteSurroundingText (const Selection &) |
| css::uno::Reference< css::datatransfer::dnd::XDropTarget > | GetDropTarget () |
| css::uno::Reference< css::datatransfer::clipboard::XClipboard > | GetClipboard () const |
| void | SetDragDataTransferable (rtl::Reference< TransferDataContainer > &rTransferable, sal_uInt8 eDNDConstants) |
| virtual bool | StartDrag () |
| void | set_size_request (int nWidth, int nHeight) |
| void | queue_resize () |
| CustomWidgetController () | |
| virtual | ~CustomWidgetController () |
| CustomWidgetController (CustomWidgetController const &)=default | |
| CustomWidgetController (CustomWidgetController &&)=default | |
| CustomWidgetController & | operator= (CustomWidgetController const &)=default |
| CustomWidgetController & | operator= (CustomWidgetController &&)=default |
Static Public Member Functions | |
| static bool | typeMatchesExtension (ApplicationType type, std::u16string_view rExt) |
Static Public Member Functions inherited from ThumbnailView | |
| static BitmapEx | readThumbnail (const OUString &msURL) |
Static Public Member Functions inherited from weld::CustomWidgetController | |
| static bool | IsUpdateMode () |
Public Attributes | |
| ApplicationType | mnFileTypes |
Private Member Functions | |
| virtual bool | MouseButtonDown (const MouseEvent &rMEvt) override |
| virtual bool | MouseButtonUp (const MouseEvent &rMEvt) override |
| virtual void | OnItemDblClicked (ThumbnailViewItem *pItem) override |
| virtual void | Paint (vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect) override |
| virtual void | LoseFocus () override |
| bool | isAcceptedFile (const INetURLObject &rURL) const |
| DECL_LINK (ExecuteHdl_Impl, void *, void) | |
Private Attributes | |
| tools::Long | mnItemMaxSize |
| size_t | mnLastMouseDownItem |
| BitmapEx | maWelcomeImage |
| Image that appears when there is no recent document. More... | |
| OUString | maWelcomeLine1 |
| OUString | maWelcomeLine2 |
| sfx2::LoadRecentFile * | mpLoadRecentFile |
| ImplSVEvent * | m_nExecuteHdlId |
Additional Inherited Members | |
Protected Member Functions inherited from ThumbnailView | |
| virtual bool | KeyInput (const KeyEvent &rKEvt) override |
| virtual bool | MouseButtonDown (const MouseEvent &rMEvt) override |
| virtual void | Paint (vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect) override |
| virtual void | GetFocus () override |
| virtual void | LoseFocus () override |
| virtual OUString | RequestHelp (tools::Rectangle &rRect) override |
| virtual css::uno::Reference< css::accessibility::XAccessible > | CreateAccessible () override |
| const css::uno::Reference< css::accessibility::XAccessible > & | getAccessible () const |
| void | DrawItem (ThumbnailViewItem const *pItem) |
| virtual void | OnItemDblClicked (ThumbnailViewItem *pItem) |
| void | UpdateColors () |
| void | CalculateItemPositions (bool bScrollBarUsed=false) |
| void | MakeItemVisible (sal_uInt16 nId) |
| void | ImplInit () |
| void | ImplDeleteItems () |
| size_t | ImplGetItem (const Point &rPoint) const |
| ThumbnailViewItem * | ImplGetItem (size_t nPos) |
| sal_uInt16 | ImplGetVisibleItemCount () const |
| ThumbnailViewItem * | ImplGetVisibleItem (sal_uInt16 nVisiblePos) |
| void | ImplFireAccessibleEvent (short nEventId, const css::uno::Any &rOldValue, const css::uno::Any &rNewValue) |
| bool | ImplHasAccessibleListeners () const |
| DECL_DLLPRIVATE_LINK (ImplScrollHdl, weld::ScrolledWindow &, void) | |
Protected Attributes inherited from ThumbnailView | |
| std::vector< std::unique_ptr< ThumbnailViewItem > > | mItemList |
| css::uno::Reference< css::accessibility::XAccessible > | mxAccessible |
| ThumbnailValueItemList | mFilteredItemList |
| Cache to store the filtered items. More... | |
| ThumbnailValueItemList::iterator | mpStartSelRange |
| tools::Long | mnItemWidth |
| tools::Long | mnItemHeight |
| tools::Long | mnItemPadding |
| tools::Long | mnThumbnailHeight |
| tools::Long | mnDisplayHeight |
| tools::Long | mnVItemSpace |
| tools::Long | mnVisLines |
| tools::Long | mnLines |
| sal_uInt16 | mnCols |
| sal_uInt16 | mnFirstLine |
| bool | mbScroll: 1 |
| bool | mbAllowVScrollBar: 1 |
| bool | mbHasVisibleItems: 1 |
| bool | mbShowTooltips: 1 |
| bool | mbDrawMnemonics: 1 |
| bool | mbSelectOnFocus: 1 |
| Color | maFillColor |
| Background color of the thumbnail view widget. More... | |
| Color | maTextColor |
| Text color. More... | |
| Color | maHighlightColor |
| Color of the highlight (background) of the hovered item. More... | |
| Color | maHighlightTextColor |
| Color of the text for the highlighted item. More... | |
| Color | maSelectHighlightColor |
| Color of the highlight (background) of the selected and hovered item. More... | |
| Color | maSelectHighlightTextColor |
| Color of the text of the selected and hovered item. More... | |
| double | mfHighlightTransparence |
| Transparence of the highlight. More... | |
| Link< const ThumbnailViewItem *, void > | maItemStateHdl |
| std::unique_ptr< ThumbnailItemAttributes > | mpItemAttrs |
| std::unique_ptr< weld::ScrolledWindow > | mxScrolledWindow |
| std::unique_ptr< weld::Menu > | mxContextMenu |
| std::function< bool(const ThumbnailViewItem *)> | maFilterFunc |
Definition at line 60 of file recentdocsview.hxx.
| sfx2::RecentDocsView::RecentDocsView | ( | std::unique_ptr< weld::ScrolledWindow > | xWindow, |
| std::unique_ptr< weld::Menu > | xMenu | ||
| ) |
Definition at line 62 of file recentdocsview.cxx.
References ColorTransparency, Application::GetDisplayBuiltInScreen(), tools::Rectangle::GetHeight(), Application::GetScreenPosSizePixel(), tools::Rectangle::GetWidth(), sfx2::gnItemPadding, sfx2::gnTextHeight, ThumbnailView::maFillColor, ThumbnailView::maHighlightColor, ThumbnailView::maHighlightTextColor, ThumbnailView::maTextColor, ThumbnailView::mfHighlightTransparence, mnItemMaxSize, ThumbnailView::setItemDimensions(), ThumbnailView::setItemMaxTextLength(), sfx2::TYPE_NONE, and ThumbnailView::UpdateColors().
|
overridevirtual |
Definition at line 86 of file recentdocsview.cxx.
References m_nExecuteHdlId, mpLoadRecentFile, sfx2::LoadRecentFile::pView, and Application::RemoveUserEvent().
|
overridevirtual |
Reimplemented from ThumbnailView.
Definition at line 293 of file recentdocsview.cxx.
References ThumbnailView::Clear(), and weld::CustomWidgetController::Invalidate().
Referenced by Reload().
| void sfx2::RecentDocsView::clearUnavailableFiles | ( | ) |
Definition at line 188 of file recentdocsview.cxx.
References SvtHistoryOptions::DeleteItem(), comphelper::DirectoryHelper::fileExists(), SvtHistoryOptions::GetList(), i, Reload(), and SvtHistoryOptions::HistoryItem::sURL.
|
private |
| void sfx2::RecentDocsView::DispatchedLoadRecentUsedFile | ( | ) |
Definition at line 306 of file recentdocsview.cxx.
References mpLoadRecentFile.
Referenced by sfx2::IMPL_LINK().
| void sfx2::RecentDocsView::insertItem | ( | const OUString & | rURL, |
| const OUString & | rTitle, | ||
| const OUString & | rThumbnail, | ||
| bool | isReadOnly, | ||
| bool | isPinned, | ||
| sal_uInt16 | nId | ||
| ) |
Definition at line 147 of file recentdocsview.cxx.
References ThumbnailView::AppendItem(), mnItemMaxSize, and nId.
Referenced by Reload().
|
private |
Definition at line 135 of file recentdocsview.cxx.
References INetURLObject::getExtension(), mnFileTypes, sfx2::TYPE_CALC, sfx2::TYPE_DATABASE, sfx2::TYPE_DRAW, sfx2::TYPE_IMPRESS, sfx2::TYPE_MATH, sfx2::TYPE_OTHER, sfx2::TYPE_WRITER, and typeMatchesExtension().
Referenced by Reload().
|
overrideprivatevirtual |
Reimplemented from ThumbnailView.
Definition at line 286 of file recentdocsview.cxx.
References ThumbnailView::deselectItems(), and ThumbnailView::LoseFocus().
|
overrideprivatevirtual |
Reimplemented from ThumbnailView.
Definition at line 200 of file recentdocsview.cxx.
References MouseEvent::GetPosPixel(), ThumbnailView::ImplGetItem(), MouseEvent::IsLeft(), mnLastMouseDownItem, and ThumbnailView::MouseButtonDown().
|
overrideprivatevirtual |
Reimplemented from weld::CustomWidgetController.
Definition at line 213 of file recentdocsview.cxx.
References MouseEvent::GetClicks(), MouseEvent::GetPosPixel(), ThumbnailView::ImplGetItem(), MouseEvent::IsLeft(), mnLastMouseDownItem, weld::CustomWidgetController::MouseButtonUp(), ThumbnailViewItem::MouseButtonUp(), nPos, ThumbnailViewItem::setHighlight(), and THUMBNAILVIEW_ITEM_NOTFOUND.
|
overrideprivatevirtual |
Reimplemented from ThumbnailView.
Definition at line 240 of file recentdocsview.cxx.
References RecentDocsViewItem::OpenDocument().
|
overrideprivatevirtual |
Reimplemented from ThumbnailView.
Definition at line 247 of file recentdocsview.cxx.
References OutputDevice::DrawBitmapEx(), OutputDevice::DrawText(), vcl::FONT, SfxApplication::GetApplicationLogo(), tools::Rectangle::GetHeight(), tools::Rectangle::getOpenHeight(), weld::CustomWidgetController::GetOutputSizePixel(), BitmapEx::GetSizePixel(), OutputDevice::GetTextHeight(), tools::Rectangle::GetWidth(), Size::Height(), BitmapEx::IsEmpty(), ThumbnailView::maTextColor, maWelcomeImage, maWelcomeLine1, maWelcomeLine2, ThumbnailView::mItemList, ThumbnailView::Paint(), OutputDevice::Pop(), OutputDevice::Push(), OutputDevice::SetTextColor(), vcl::TEXTCOLOR, and Size::Width().
| void sfx2::RecentDocsView::PostLoadRecentUsedFile | ( | LoadRecentFile * | pLoadRecentFile | ) |
Definition at line 299 of file recentdocsview.cxx.
References LINK, m_nExecuteHdlId, mpLoadRecentFile, and Application::PostUserEvent().
Referenced by RecentDocsViewItem::OpenDocument().
|
overridevirtual |
Update the information in the view.
Reimplemented from ThumbnailView.
Definition at line 155 of file recentdocsview.cxx.
References aURL, ThumbnailView::CalculateItemPositions(), Clear(), INetURLObject::GetBase(), SvtHistoryOptions::GetList(), i, insertItem(), weld::CustomWidgetController::Invalidate(), isAcceptedFile(), SvtHistoryOptions::HistoryItem::isPinned, SvtHistoryOptions::HistoryItem::isReadOnly, mnFileTypes, SvtHistoryOptions::HistoryItem::sThumbnail, SvtHistoryOptions::HistoryItem::sURL, and sfx2::TYPE_NONE.
Referenced by clearUnavailableFiles(), and setFilter().
| void sfx2::RecentDocsView::setFilter | ( | ApplicationType | aFilter | ) |
Definition at line 182 of file recentdocsview.cxx.
References mnFileTypes, and Reload().
|
static |
Definition at line 97 of file recentdocsview.cxx.
References type, sfx2::TYPE_CALC, sfx2::TYPE_DATABASE, sfx2::TYPE_DRAW, sfx2::TYPE_IMPRESS, sfx2::TYPE_MATH, sfx2::TYPE_OTHER, sfx2::TYPE_WRITER, and u.
Referenced by isAcceptedFile(), and RecentDocsViewItem::RecentDocsViewItem().
|
private |
Definition at line 112 of file recentdocsview.hxx.
Referenced by PostLoadRecentUsedFile(), and ~RecentDocsView().
|
private |
Image that appears when there is no recent document.
Definition at line 107 of file recentdocsview.hxx.
Referenced by Paint().
|
private |
Definition at line 108 of file recentdocsview.hxx.
Referenced by Paint().
|
private |
Definition at line 109 of file recentdocsview.hxx.
Referenced by Paint().
| ApplicationType sfx2::RecentDocsView::mnFileTypes |
Definition at line 71 of file recentdocsview.hxx.
Referenced by isAcceptedFile(), Reload(), and setFilter().
|
private |
Definition at line 103 of file recentdocsview.hxx.
Referenced by insertItem(), and RecentDocsView().
|
private |
Definition at line 104 of file recentdocsview.hxx.
Referenced by MouseButtonDown(), and MouseButtonUp().
|
private |
Definition at line 111 of file recentdocsview.hxx.
Referenced by DispatchedLoadRecentUsedFile(), PostLoadRecentUsedFile(), and ~RecentDocsView().