LibreOffice Module vcl (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
SelectionEngine Class Reference

#include <seleng.hxx>

Collaboration diagram for SelectionEngine:
[legend]

Public Member Functions

 SelectionEngine (vcl::Window *pWindow, FunctionSet *pFunctions=nullptr)
 
 ~SelectionEngine ()
 
 SelectionEngine (const SelectionEngine &)=delete
 
 SelectionEngine (SelectionEngine &&)=delete
 
SelectionEngineoperator= (const SelectionEngine &)=delete
 
SelectionEngineoperator= (SelectionEngine &&)=delete
 
bool SelMouseButtonDown (const MouseEvent &rMEvt)
 
bool SelMouseButtonUp (const MouseEvent &rMEvt)
 
bool SelMouseMove (const MouseEvent &rMEvt)
 
void ReleaseMouse ()
 
void CaptureMouse ()
 
void CursorPosChanging (bool bShift, bool bMod1)
 
void SetVisibleArea (const tools::Rectangle &rNewArea)
 
void SetAddMode (bool)
 
bool IsAddMode () const
 
void AddAlways (bool bOn)
 
bool IsAlwaysAdding () const
 
void EnableDrag (bool bOn)
 
void SetSelectionMode (SelectionMode eMode)
 
SelectionMode GetSelectionMode () const
 
void SetFunctionSet (FunctionSet *pFuncs)
 
const FunctionSetGetFunctionSet () const
 
const PointGetMousePosPixel () const
 
const MouseEventGetMouseEvent () const
 
void SetWindow (vcl::Window *)
 
vcl::WindowGetWindow () const
 
void LockModifiers (sal_uInt16 nModifiers)
 
sal_uInt16 GetLockedModifiers () const
 
bool IsInSelection () const
 
void Reset ()
 
bool Command (const CommandEvent &rCEvt)
 
bool HasAnchor () const
 
void SetAnchor (bool bAnchor)
 
void SetUpdateInterval (sal_uLong nInterval)
 
void ExpandSelectionOnMouseMove (bool bExpand=true)
 

Private Member Functions

 DECL_DLLPRIVATE_LINK (ImpWatchDog, Timer *, void)
 
bool ShouldDeselect (bool bModifierKey1) const
 

Private Attributes

FunctionSetpFunctionSet
 
VclPtr< vcl::WindowpWin
 
tools::Rectangle aArea
 
Timer aWTimer
 
MouseEvent aLastMove
 
SelectionMode eSelMode
 
sal_uLong nUpdateInterval
 
sal_uInt16 nLockedMods
 
SelectionEngineFlags nFlags
 

Detailed Description

Definition at line 78 of file seleng.hxx.

Constructor & Destructor Documentation

◆ SelectionEngine() [1/3]

SelectionEngine::SelectionEngine ( vcl::Window pWindow,
FunctionSet pFunctions = nullptr 
)

◆ ~SelectionEngine()

SelectionEngine::~SelectionEngine ( )

Definition at line 51 of file seleng.cxx.

References aWTimer, and Task::Stop().

◆ SelectionEngine() [2/3]

SelectionEngine::SelectionEngine ( const SelectionEngine )
delete

◆ SelectionEngine() [3/3]

SelectionEngine::SelectionEngine ( SelectionEngine &&  )
delete

Member Function Documentation

◆ AddAlways()

void SelectionEngine::AddAlways ( bool  bOn)
inline

Definition at line 198 of file seleng.hxx.

References ADD_ALW, and nFlags.

Referenced by SvImpLBox::KeyInput(), SvImpLBox::SetSelectionMode(), and SvImpLBox::SetStyle().

◆ CaptureMouse()

void SelectionEngine::CaptureMouse ( )

Definition at line 306 of file seleng.cxx.

References vcl::Window::CaptureMouse(), vcl::Window::IsMouseCaptured(), and pWin.

Referenced by SelMouseButtonDown(), and SetWindow().

◆ Command()

bool SelectionEngine::Command ( const CommandEvent rCEvt)

◆ CursorPosChanging()

void SelectionEngine::CursorPosChanging ( bool  bShift,
bool  bMod1 
)

◆ DECL_DLLPRIVATE_LINK()

SelectionEngine::DECL_DLLPRIVATE_LINK ( ImpWatchDog  ,
Timer ,
void   
)
private

◆ EnableDrag()

void SelectionEngine::EnableDrag ( bool  bOn)
inline

Definition at line 190 of file seleng.hxx.

References DRG_ENAB, and nFlags.

Referenced by SvImpLBox::SetDragDropMode().

◆ ExpandSelectionOnMouseMove()

void SelectionEngine::ExpandSelectionOnMouseMove ( bool  bExpand = true)
inline

Definition at line 165 of file seleng.hxx.

References EXPANDONMOVE.

Referenced by SvImpLBox::SetDragDropMode(), and SvImpLBox::SvImpLBox().

◆ GetFunctionSet()

const FunctionSet * SelectionEngine::GetFunctionSet ( ) const
inline

Definition at line 141 of file seleng.hxx.

◆ GetLockedModifiers()

sal_uInt16 SelectionEngine::GetLockedModifiers ( ) const
inline

Definition at line 152 of file seleng.hxx.

◆ GetMouseEvent()

const MouseEvent & SelectionEngine::GetMouseEvent ( ) const
inline

Definition at line 145 of file seleng.hxx.

◆ GetMousePosPixel()

const Point & SelectionEngine::GetMousePosPixel ( ) const
inline

Definition at line 143 of file seleng.hxx.

References MouseEvent::GetPosPixel().

Referenced by SvImpLBox::BeginDrag().

◆ GetSelectionMode()

SelectionMode SelectionEngine::GetSelectionMode ( ) const
inline

◆ GetWindow()

vcl::Window * SelectionEngine::GetWindow ( ) const
inline

Definition at line 148 of file seleng.hxx.

◆ HasAnchor()

bool SelectionEngine::HasAnchor ( ) const
inline

Definition at line 222 of file seleng.hxx.

References HAS_ANCH, and nFlags.

◆ IsAddMode()

bool SelectionEngine::IsAddMode ( ) const
inline

Definition at line 174 of file seleng.hxx.

References ADD_ALW, IN_ADD, and nFlags.

Referenced by CursorPosChanging(), SvImpLBox::KeyInput(), SelMouseButtonDown(), and SvImpLBox::SetCursor().

◆ IsAlwaysAdding()

bool SelectionEngine::IsAlwaysAdding ( ) const
inline

Definition at line 206 of file seleng.hxx.

References ADD_ALW, and nFlags.

Referenced by SvImpLBox::KeyInput(), SvImpLBox::MouseButtonDown(), and SelMouseButtonUp().

◆ IsInSelection()

bool SelectionEngine::IsInSelection ( ) const
inline

Definition at line 214 of file seleng.hxx.

References IN_SEL, and nFlags.

◆ LockModifiers()

void SelectionEngine::LockModifiers ( sal_uInt16  nModifiers)
inline

Definition at line 150 of file seleng.hxx.

◆ operator=() [1/2]

SelectionEngine & SelectionEngine::operator= ( const SelectionEngine )
delete

◆ operator=() [2/2]

SelectionEngine & SelectionEngine::operator= ( SelectionEngine &&  )
delete

◆ ReleaseMouse()

void SelectionEngine::ReleaseMouse ( )

◆ Reset()

void SelectionEngine::Reset ( void  )

Definition at line 359 of file seleng.cxx.

References aWTimer, HAS_ANCH, IN_SEL, nFlags, nLockedMods, ReleaseMouse(), and Task::Stop().

Referenced by SvImpLBox::DestroyAnchor().

◆ SelMouseButtonDown()

bool SelectionEngine::SelMouseButtonDown ( const MouseEvent rMEvt)

◆ SelMouseButtonUp()

bool SelectionEngine::SelMouseButtonUp ( const MouseEvent rMEvt)

◆ SelMouseMove()

bool SelectionEngine::SelMouseMove ( const MouseEvent rMEvt)

◆ SetAddMode()

void SelectionEngine::SetAddMode ( bool  bNewMode)
inline

Definition at line 182 of file seleng.hxx.

References IN_ADD, and nFlags.

◆ SetAnchor()

void SelectionEngine::SetAnchor ( bool  bAnchor)
inline

Definition at line 230 of file seleng.hxx.

References HAS_ANCH, and nFlags.

◆ SetFunctionSet()

void SelectionEngine::SetFunctionSet ( FunctionSet pFuncs)
inline

Definition at line 139 of file seleng.hxx.

Referenced by SvImpLBox::SvImpLBox().

◆ SetSelectionMode()

void SelectionEngine::SetSelectionMode ( SelectionMode  eMode)

Definition at line 62 of file seleng.cxx.

References eMode, and eSelMode.

Referenced by SvImpLBox::SetSelectionMode().

◆ SetUpdateInterval()

void SelectionEngine::SetUpdateInterval ( sal_uLong  nInterval)

◆ SetVisibleArea()

void SelectionEngine::SetVisibleArea ( const tools::Rectangle rNewArea)
inline

Definition at line 125 of file seleng.hxx.

Referenced by SvImpLBox::AdjustScrollBars(), and IconViewImpl::AdjustScrollBars().

◆ SetWindow()

void SelectionEngine::SetWindow ( vcl::Window pNewWin)

Definition at line 347 of file seleng.cxx.

References CaptureMouse(), IN_SEL, nFlags, pWin, and ReleaseMouse().

◆ ShouldDeselect()

bool SelectionEngine::ShouldDeselect ( bool  bModifierKey1) const
inlineprivate

Definition at line 30 of file seleng.cxx.

References eSelMode, and Multiple.

Referenced by CursorPosChanging().

Member Data Documentation

◆ aArea

tools::Rectangle SelectionEngine::aArea
private

Definition at line 83 of file seleng.hxx.

Referenced by SelMouseMove().

◆ aLastMove

MouseEvent SelectionEngine::aLastMove
private

Definition at line 85 of file seleng.hxx.

Referenced by Command(), SelMouseButtonDown(), SelMouseButtonUp(), and SelMouseMove().

◆ aWTimer

Timer SelectionEngine::aWTimer
private

◆ eSelMode

SelectionMode SelectionEngine::eSelMode
private

◆ nFlags

SelectionEngineFlags SelectionEngine::nFlags
private

◆ nLockedMods

sal_uInt16 SelectionEngine::nLockedMods
private

Definition at line 88 of file seleng.hxx.

Referenced by Reset(), SelectionEngine(), SelMouseButtonDown(), and SelMouseButtonUp().

◆ nUpdateInterval

sal_uLong SelectionEngine::nUpdateInterval
private

Definition at line 87 of file seleng.hxx.

Referenced by SelectionEngine(), SelMouseMove(), and SetUpdateInterval().

◆ pFunctionSet

FunctionSet* SelectionEngine::pFunctionSet
private

◆ pWin

VclPtr<vcl::Window> SelectionEngine::pWin
private

Definition at line 82 of file seleng.hxx.

Referenced by CaptureMouse(), ReleaseMouse(), and SetWindow().


The documentation for this class was generated from the following files: