diff options
author | Noel Grandin <noel@peralex.com> | 2014-06-03 13:54:07 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-06-04 14:49:08 +0200 |
commit | 6f2edd4514dc59f5cbac8c653c6e4b1a96ec28a2 (patch) | |
tree | 3dda70a8a50943514c82c7c7493416fc84fc9cd7 /include/svtools | |
parent | 866a4436d3cfac1ff42d7996250bf96fb703aeaa (diff) |
new loplugin: inlinesimpleaccessmethods
Create a rewriting plugin for finding methods that simply return
object fields, and should therefore be declared in the header,
so that the compiler can reduce method calls into a simple
fixed-offset load instruction.
Change-Id: I7a620fc54250b79681918dc31ed9a8f21118c037
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'include/svtools')
-rw-r--r-- | include/svtools/fmtfield.hxx | 2 | ||||
-rw-r--r-- | include/svtools/ruler.hxx | 2 | ||||
-rw-r--r-- | include/svtools/treelistentry.hxx | 4 | ||||
-rw-r--r-- | include/svtools/viewdataentry.hxx | 12 |
4 files changed, 10 insertions, 10 deletions
diff --git a/include/svtools/fmtfield.hxx b/include/svtools/fmtfield.hxx index 792465f371ef..d7bd1f1f1eac 100644 --- a/include/svtools/fmtfield.hxx +++ b/include/svtools/fmtfield.hxx @@ -231,7 +231,7 @@ public: using F2 */ void UseInputStringForFormatting( bool bUseInputStr = true ); - bool IsUsingInputStringForFormatting() const; + bool IsUsingInputStringForFormatting() const { return m_bUseInputStringForFormatting;} protected: virtual bool Notify(NotifyEvent& rNEvt) SAL_OVERRIDE; diff --git a/include/svtools/ruler.hxx b/include/svtools/ruler.hxx index 1468ec452619..67eb55d84035 100644 --- a/include/svtools/ruler.hxx +++ b/include/svtools/ruler.hxx @@ -707,7 +707,7 @@ private: Ruler& operator= (const Ruler &); protected: - long GetRulerVirHeight() const; + long GetRulerVirHeight() const { return mnVirHeight;} MapMode GetCurrentMapMode() const { return maMapMode; } RulerUnitData GetCurrentRulerUnit() const; diff --git a/include/svtools/treelistentry.hxx b/include/svtools/treelistentry.hxx index d5cdf05eb06d..0f74d9757f8b 100644 --- a/include/svtools/treelistentry.hxx +++ b/include/svtools/treelistentry.hxx @@ -90,13 +90,13 @@ public: const SvLBoxItem* GetFirstItem( sal_uInt16 nId ) const; SvLBoxItem* GetFirstItem( sal_uInt16 nId ); size_t GetPos( const SvLBoxItem* pItem ) const; - void* GetUserData() const; + void* GetUserData() const { return pUserData;} void SetUserData( void* pPtr ); void EnableChildrenOnDemand( bool bEnable=true ); bool HasChildrenOnDemand() const; bool HasInUseEmphasis() const; - sal_uInt16 GetFlags() const; + sal_uInt16 GetFlags() const { return nEntryFlags;} void SetFlags( sal_uInt16 nFlags ); bool GetIsMarked() const { return bIsMarked; } diff --git a/include/svtools/viewdataentry.hxx b/include/svtools/viewdataentry.hxx index 31681af4dc19..b24910b7ce72 100644 --- a/include/svtools/viewdataentry.hxx +++ b/include/svtools/viewdataentry.hxx @@ -58,12 +58,12 @@ public: SvViewDataEntry( const SvViewDataEntry& ); ~SvViewDataEntry(); - bool IsSelected() const; - bool IsHighlighted() const; - bool IsExpanded() const; - bool HasFocus() const; - bool IsCursored() const; - bool IsSelectable() const; + bool IsSelected() const { return mbSelected;} + bool IsHighlighted() const { return mbHighlighted;} + bool IsExpanded() const { return mbExpanded;} + bool HasFocus() const { return mbFocused;} + bool IsCursored() const { return mbCursored;} + bool IsSelectable() const { return mbSelectable;} void SetFocus( bool bFocus ); void SetSelected( bool bSelected ); void SetHighlighted( bool bHighlighted ); |