diff options
author | Noel Grandin <noel@peralex.com> | 2014-11-18 10:01:21 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2014-11-18 12:44:28 +0200 |
commit | 0063cf285696951e336b9cec1da8881997b286ce (patch) | |
tree | be70dfd8127c35f9e4a6d18d4db459a587813bf4 /odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment | |
parent | 250391009aec9930abcc57930ddd4b6f56f4df9c (diff) |
java: make fields final where possible
found by PMD
Change-Id: I87780366119c141cd2dafe6ca1bf2d9798b10aec
Diffstat (limited to 'odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment')
6 files changed, 20 insertions, 20 deletions
diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java index 3f86aeff0581..1acb6eae6a40 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java @@ -80,9 +80,9 @@ public class CustomizeView extends JPanel * @member m_aToolBarListener listener for status events of the tool bar * @member m_aObjectBarListener listener for status events of the object bar */ - private JCheckBox m_cbMenuBar ; - private JCheckBox m_cbToolBar ; - private JCheckBox m_cbObjectBar ; + private final JCheckBox m_cbMenuBar ; + private final JCheckBox m_cbToolBar ; + private final JCheckBox m_cbObjectBar ; private StatusListener m_aMenuBarListener ; private StatusListener m_aToolBarListener ; @@ -175,9 +175,9 @@ public class CustomizeView extends JPanel com.sun.star.lang.XEventListener { /// URL, to toogle the requested UI item - private String m_sURL; + private final String m_sURL; /// name of the property which must be used in combination with the URL - private String m_sProp; + private final String m_sProp; /// we must use this frame to dispatch a request private com.sun.star.frame.XFrame m_xFrame; diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java index 2a3bad305c94..c6e657c06483 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java @@ -99,10 +99,10 @@ public class DocumentView extends JFrame private CustomizeView maCustomizeView ; private Interceptor maInterceptor ; - private String msName ; + private final String msName; - private JButton mbtSave ; - private JButton mbtExport ; + private final JButton mbtSave; + private final JButton mbtExport; private boolean mbDead ; diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java index 2d07f9642d9c..51fba4d12725 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java @@ -40,7 +40,7 @@ class JavaWindowPeerFake implements com.sun.star.awt.XSystemDependentWindowPeer, com.sun.star.awt.XWindowPeer { - private NativeView maView; + private final NativeView maView; public JavaWindowPeerFake(NativeView aNative) { diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java index cc3b79cf19ea..815355114bc0 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java @@ -74,9 +74,9 @@ class OnewayExecutor extends Thread * called oneyway method) * @member m_lParams list of parameters of the original request */ - private IOnewayLink m_rLink ; - private int m_nRequest ; - private ArrayList<Object> m_lParams ; + private final IOnewayLink m_rLink ; + private final int m_nRequest ; + private final ArrayList<Object> m_lParams ; diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java index 02fc79d337e9..038c80ff92f1 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java @@ -80,9 +80,9 @@ class StatusListener implements com.sun.star.frame.XStatusListener, * @member m_bIsStatusListener indicates if we are currently registered as a listener for status events or not * @member m_bDead there exist more than one way to finish an object of this class - we must know it sometimes */ - private Component m_rControl ; - private String m_sTrueText ; - private String m_sFalseText ; + private final Component m_rControl ; + private final String m_sTrueText ; + private final String m_sFalseText ; private com.sun.star.frame.XDispatch m_xDispatch ; private com.sun.star.frame.XFrame m_xFrame ; private com.sun.star.util.URL m_aURL ; diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java index ae7625bfff7e..c4eb32ed4adb 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java @@ -105,11 +105,11 @@ public class StatusView extends JPanel * @member maUnderlineListener threadsafe(!) helper to listen for status event which describe font style underline * @member maItalicListener threadsafe(!) helper to listen for status event which describe font style italic */ - private JLabel m_laFontValue ; - private JLabel m_laSizeValue ; - private JLabel m_laBoldValue ; - private JLabel m_laUnderlineValue ; - private JLabel m_laItalicValue ; + private final JLabel m_laFontValue ; + private final JLabel m_laSizeValue ; + private final JLabel m_laBoldValue ; + private final JLabel m_laUnderlineValue ; + private final JLabel m_laItalicValue ; private StatusListener m_aFontListener ; private StatusListener m_aSizeListener ; |