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

#include <accel.hxx>

Collaboration diagram for Accelerator:
[legend]

Public Member Functions

 Accelerator ()
 
 Accelerator (const Accelerator &rAccel)
 
 ~Accelerator ()
 
void Activate ()
 
void Select ()
 
void InsertItem (sal_uInt16 nItemId, const vcl::KeyCode &rKeyCode)
 
sal_uInt16 GetCurItemId () const
 
sal_uInt16 GetItemCount () const
 
sal_uInt16 GetItemId (sal_uInt16 nPos) const
 
AcceleratorGetAccel (sal_uInt16 nItemId) const
 
void SetActivateHdl (const Link< Accelerator &, void > &rLink)
 
void SetSelectHdl (const Link< Accelerator &, void > &rLink)
 
Acceleratoroperator= (const Accelerator &rAccel)
 

Private Types

typedef ::std::map< sal_uLong, ImplAccelEntry * > ImplAccelMap
 

Private Member Functions

void ImplInit ()
 
void ImplCopyData (const Accelerator &rAccelData)
 
void ImplDeleteData ()
 
void ImplInsertAccel (sal_uInt16 nItemId, const vcl::KeyCode &rKeyCode, bool bEnable, Accelerator *pAutoAccel)
 
ImplAccelEntryImplGetAccelData (const vcl::KeyCode &rKeyCode) const
 

Private Attributes

ImplAccelMap maKeyMap
 
ImplAccelList maIdList
 
Link< Accelerator &, void > maActivateHdl
 
Link< Accelerator &, void > maSelectHdl
 
sal_uInt16 mnCurId
 
bool * mpDel
 

Friends

class ImplAccelManager
 

Detailed Description

Definition at line 47 of file accel.hxx.

Member Typedef Documentation

◆ ImplAccelMap

Definition at line 52 of file accel.hxx.

Constructor & Destructor Documentation

◆ Accelerator() [1/2]

Accelerator::Accelerator ( )

Definition at line 202 of file accel.cxx.

References ImplInit().

Referenced by ImplCopyData(), and ImplInsertAccel().

◆ Accelerator() [2/2]

Accelerator::Accelerator ( const Accelerator rAccel)

Definition at line 207 of file accel.cxx.

References ImplCopyData(), and ImplInit().

◆ ~Accelerator()

Accelerator::~Accelerator ( )

Definition at line 213 of file accel.cxx.

References ImplDeleteData(), and mpDel.

Member Function Documentation

◆ Activate()

void Accelerator::Activate ( )

Definition at line 223 of file accel.cxx.

References Link< typename Arg, typename Ret >::Call(), and maActivateHdl.

Referenced by ImplAccelManager::IsAccelKey().

◆ GetAccel()

Accelerator * Accelerator::GetAccel ( sal_uInt16  nItemId) const

Definition at line 253 of file accel.cxx.

References ACCELENTRY_NOTFOUND, ImplAccelEntryGetIndex(), maIdList, and nIndex.

Referenced by ImplAccelManager::RemoveAccel().

◆ GetCurItemId()

sal_uInt16 Accelerator::GetCurItemId ( ) const
inline

Definition at line 80 of file accel.hxx.

References mnCurId.

◆ GetItemCount()

sal_uInt16 Accelerator::GetItemCount ( ) const

Definition at line 238 of file accel.cxx.

References maIdList.

Referenced by ImplAccelManager::RemoveAccel().

◆ GetItemId()

sal_uInt16 Accelerator::GetItemId ( sal_uInt16  nPos) const

Definition at line 243 of file accel.cxx.

References get(), maIdList, ImplAccelEntry::mnId, and nPos.

Referenced by ImplAccelManager::RemoveAccel().

◆ ImplCopyData()

void Accelerator::ImplCopyData ( const Accelerator rAccelData)
private

Definition at line 121 of file accel.cxx.

References Accelerator(), i, maIdList, and maKeyMap.

Referenced by Accelerator(), and operator=().

◆ ImplDeleteData()

void Accelerator::ImplDeleteData ( )
private

Definition at line 142 of file accel.cxx.

References maIdList.

Referenced by operator=(), and ~Accelerator().

◆ ImplGetAccelData()

ImplAccelEntry * Accelerator::ImplGetAccelData ( const vcl::KeyCode rKeyCode) const
private

Definition at line 112 of file accel.cxx.

References vcl::KeyCode::GetFullCode(), and maKeyMap.

Referenced by ImplAccelManager::IsAccelKey().

◆ ImplInit()

void Accelerator::ImplInit ( )
private

Definition at line 106 of file accel.cxx.

References mnCurId, and mpDel.

Referenced by Accelerator().

◆ ImplInsertAccel()

void Accelerator::ImplInsertAccel ( sal_uInt16  nItemId,
const vcl::KeyCode rKeyCode,
bool  bEnable,
Accelerator pAutoAccel 
)
private

◆ InsertItem()

void Accelerator::InsertItem ( sal_uInt16  nItemId,
const vcl::KeyCode rKeyCode 
)

Definition at line 233 of file accel.cxx.

References ImplInsertAccel().

Referenced by ImplTBDragMgr::ImplTBDragMgr(), and SvInplaceEdit2::SvInplaceEdit2().

◆ operator=()

Accelerator & Accelerator::operator= ( const Accelerator rAccel)

Definition at line 263 of file accel.cxx.

References ImplCopyData(), ImplDeleteData(), maKeyMap, and mnCurId.

◆ Select()

void Accelerator::Select ( )

Definition at line 228 of file accel.cxx.

References Link< typename Arg, typename Ret >::Call(), and maSelectHdl.

Referenced by ImplAccelManager::IsAccelKey().

◆ SetActivateHdl()

void Accelerator::SetActivateHdl ( const Link< Accelerator &, void > &  rLink)
inline

Definition at line 87 of file accel.hxx.

References maActivateHdl.

Referenced by SvInplaceEdit2::SvInplaceEdit2().

◆ SetSelectHdl()

void Accelerator::SetSelectHdl ( const Link< Accelerator &, void > &  rLink)
inline

Definition at line 88 of file accel.hxx.

References maSelectHdl.

Referenced by ImplTBDragMgr::ImplTBDragMgr().

Friends And Related Function Documentation

◆ ImplAccelManager

friend class ImplAccelManager
friend

Definition at line 49 of file accel.hxx.

Member Data Documentation

◆ maActivateHdl

Link<Accelerator&,void> Accelerator::maActivateHdl
private

Definition at line 55 of file accel.hxx.

Referenced by Activate(), and SetActivateHdl().

◆ maIdList

ImplAccelList Accelerator::maIdList
private

◆ maKeyMap

ImplAccelMap Accelerator::maKeyMap
private

Definition at line 53 of file accel.hxx.

Referenced by ImplCopyData(), ImplGetAccelData(), ImplInsertAccel(), and operator=().

◆ maSelectHdl

Link<Accelerator&,void> Accelerator::maSelectHdl
private

Definition at line 56 of file accel.hxx.

Referenced by Select(), and SetSelectHdl().

◆ mnCurId

sal_uInt16 Accelerator::mnCurId
private

Definition at line 59 of file accel.hxx.

Referenced by GetCurItemId(), ImplInit(), ImplAccelManager::IsAccelKey(), and operator=().

◆ mpDel

bool* Accelerator::mpDel
private

Definition at line 60 of file accel.hxx.

Referenced by ImplInit(), ImplAccelManager::IsAccelKey(), and ~Accelerator().


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