diff --git a/src/org/sflphone/client/AccountEditionActivity.java b/src/org/sflphone/client/AccountEditionActivity.java
index e23b551336b7ceb955bfe9f50764dc58257801f8..8d8af4edd46d54cf78fb685bbc76b652dd3dc7e5 100644
--- a/src/org/sflphone/client/AccountEditionActivity.java
+++ b/src/org/sflphone/client/AccountEditionActivity.java
@@ -32,31 +32,11 @@
 
 package org.sflphone.client;
 
-import java.util.ArrayList;
-import java.util.Locale;
-import java.util.Observable;
-import java.util.Observer;
-
-import org.sflphone.R;
-import org.sflphone.fragments.AdvancedAccountFragment;
-import org.sflphone.fragments.AudioManagementFragment;
-import org.sflphone.fragments.GeneralAccountFragment;
-import org.sflphone.fragments.NestedSettingsFragment;
-import org.sflphone.fragments.SecurityAccountFragment;
-import org.sflphone.model.account.Account;
-import org.sflphone.service.ISipService;
-import org.sflphone.service.SipService;
-import org.sflphone.views.PagerSlidingTabStrip;
-
 import android.app.Activity;
 import android.app.AlertDialog;
 import android.app.Fragment;
 import android.app.FragmentManager;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.DialogInterface;
-import android.content.Intent;
-import android.content.ServiceConnection;
+import android.content.*;
 import android.os.Bundle;
 import android.os.IBinder;
 import android.os.RemoteException;
@@ -66,6 +46,17 @@ import android.util.Log;
 import android.view.Menu;
 import android.view.MenuInflater;
 import android.view.MenuItem;
+import org.sflphone.R;
+import org.sflphone.fragments.*;
+import org.sflphone.model.account.Account;
+import org.sflphone.service.ISipService;
+import org.sflphone.service.SipService;
+import org.sflphone.views.PagerSlidingTabStrip;
+
+import java.util.ArrayList;
+import java.util.Locale;
+import java.util.Observable;
+import java.util.Observer;
 
 public class AccountEditionActivity extends Activity implements GeneralAccountFragment.Callbacks, AudioManagementFragment.Callbacks,
         AdvancedAccountFragment.Callbacks, SecurityAccountFragment.Callbacks, NestedSettingsFragment.Callbacks {
@@ -75,8 +66,6 @@ public class AccountEditionActivity extends Activity implements GeneralAccountFr
     private ISipService service;
     private Account acc_selected;
 
-    private ViewPager mViewPager;
-
     private NestedSettingsFragment toDisplay;
 
     private Observer mAccountObserver = new Observer() {
@@ -108,7 +97,7 @@ public class AccountEditionActivity extends Activity implements GeneralAccountFr
 				}
             }
 
-            mViewPager = (ViewPager) findViewById(R.id.pager);
+            ViewPager mViewPager = (ViewPager) findViewById(R.id.pager);
 
             mPreferencesPagerAdapter = new PreferencesPagerAdapter(AccountEditionActivity.this, getFragmentManager(), fragments);
             mViewPager.setAdapter(mPreferencesPagerAdapter);
diff --git a/src/org/sflphone/client/AccountWizard.java b/src/org/sflphone/client/AccountWizard.java
index 788b1f702585c433e84d5f80a1f9251744d88ce6..85f30dfeac62e8975bf0e088b891440d9bbd0079 100644
--- a/src/org/sflphone/client/AccountWizard.java
+++ b/src/org/sflphone/client/AccountWizard.java
@@ -31,16 +31,6 @@
 
 package org.sflphone.client;
 
-import java.util.ArrayList;
-import java.util.Locale;
-
-import org.sflphone.R;
-import org.sflphone.fragments.AccountCreationFragment;
-import org.sflphone.fragments.AccountCreationFragment.Callbacks;
-import org.sflphone.interfaces.AccountsInterface;
-import org.sflphone.service.ISipService;
-import org.sflphone.service.SipService;
-
 import android.app.Activity;
 import android.app.Fragment;
 import android.app.FragmentManager;
@@ -54,13 +44,20 @@ import android.support.v13.app.FragmentStatePagerAdapter;
 import android.support.v4.view.ViewPager;
 import android.util.Log;
 import android.view.MenuItem;
+import org.sflphone.R;
+import org.sflphone.fragments.AccountCreationFragment;
+import org.sflphone.fragments.AccountCreationFragment.Callbacks;
+import org.sflphone.service.ISipService;
+import org.sflphone.service.SipService;
+
+import java.util.ArrayList;
+import java.util.Locale;
 
 public class AccountWizard extends Activity implements Callbacks {
     static final String TAG = "AccountWizard";
     private boolean mBound = false;
     private ISipService service;
     ViewPager mViewPager;
-    private SectionsPagerAdapter mSectionsPagerAdapter;
 
     private ServiceConnection mConnection = new ServiceConnection() {
 
@@ -85,7 +82,7 @@ public class AccountWizard extends Activity implements Callbacks {
 
         getActionBar().setDisplayHomeAsUpEnabled(true);
         getActionBar().setHomeButtonEnabled(true);
-        mSectionsPagerAdapter = new SectionsPagerAdapter(AccountWizard.this, getFragmentManager());
+        SectionsPagerAdapter mSectionsPagerAdapter = new SectionsPagerAdapter(AccountWizard.this, getFragmentManager());
         mViewPager.setAdapter(mSectionsPagerAdapter);
 
         if (!mBound) {
diff --git a/src/org/sflphone/history/HistoryCall.java b/src/org/sflphone/history/HistoryCall.java
index 52d81a03cc229b85da530a83eabffa15c2c9e26e..7dd82b69b2ed738a0f3582b27bcebef2fd8b176c 100644
--- a/src/org/sflphone/history/HistoryCall.java
+++ b/src/org/sflphone/history/HistoryCall.java
@@ -108,8 +108,7 @@ public class HistoryCall implements Parcelable {
         Date date = new Date(stamp.getTime());
         SimpleDateFormat sdf = new SimpleDateFormat(format, Locale.getDefault());
         sdf.setTimeZone(TimeZone.getDefault());
-        String formattedDate = sdf.format(date);
-        return formattedDate;
+        return sdf.format(date);
 
     }
 
@@ -171,7 +170,7 @@ public class HistoryCall implements Parcelable {
         call_end = in.readLong();
         accountID = in.readString();
         number = in.readString();
-        missed = in.readByte() == 1 ? true : false;
+        missed = in.readByte() == 1;
         direction = in.readInt();
         recordPath = in.readString();
         contactID = in.readLong();
diff --git a/src/org/sflphone/history/HistoryEntry.java b/src/org/sflphone/history/HistoryEntry.java
index c2ef036f1665914c4eb4ecbc908c060ef6af8b6b..8ace33af0403e7d9a7d94c2c4bfcbd8cad7c296d 100644
--- a/src/org/sflphone/history/HistoryEntry.java
+++ b/src/org/sflphone/history/HistoryEntry.java
@@ -104,8 +104,8 @@ public class HistoryEntry implements Parcelable {
     public String getTotalDuration() {
         int duration = 0;
         ArrayList<HistoryCall> all_calls = new ArrayList<HistoryCall>(calls.values());
-        for (int i = 0; i < all_calls.size(); ++i) {
-            duration += all_calls.get(i).getDuration();
+        for (HistoryCall all_call : all_calls) {
+            duration += all_call.getDuration();
         }
 
         if (duration < 60)
diff --git a/src/org/sflphone/history/HistoryTimeModel.java b/src/org/sflphone/history/HistoryTimeModel.java
index 87d5c008d890e79d312e72ee8e290f4a7e816194..e6a6a8bc2a1e2b378a898b014e7552c640e469ea 100644
--- a/src/org/sflphone/history/HistoryTimeModel.java
+++ b/src/org/sflphone/history/HistoryTimeModel.java
@@ -95,7 +95,7 @@ public class HistoryTimeModel {
             for (int i = 1; i < 12; i++) {
                 if (currentTime - (i + 1) * 30.4f * 24 * 3600 < time2) // Not exact, but faster
                     return timeCategories.get(i + timeCategories.indexOf(HistoryTimeCategoryModel.LAST_MONTH) - 1);
-                ; // Last_month to Twelve_months ago
+                // Last_month to Twelve_months ago
             }
         }
         // if (QDate::currentDate().addYears(-1) >= date && QDate::currentDate().addYears(-2) < date)
diff --git a/src/org/sflphone/model/BubblesView.java b/src/org/sflphone/model/BubblesView.java
index e5c876e7950f19e7287db5119703df7956a1573b..79ca1207f6a54a43d3d9b3144c67ebe7b2aa102f 100644
--- a/src/org/sflphone/model/BubblesView.java
+++ b/src/org/sflphone/model/BubblesView.java
@@ -306,19 +306,18 @@ public class BubblesView extends GLSurfaceView implements SurfaceHolder.Callback
 
                 white_name_paint.setTextSize(18 * textDensity);
                 boolean suck_bubble = false;
-                for (int i = 0, n = acts.size(); i < n; i++) {
-                    Attractor a = acts.get(i);
+                for (Attractor a : acts) {
                     if (b.attractor == a) {
                         canvas.drawBitmap(ic_bg_sel, null, a.getBounds(showed * 2.f, b.getPos(), showed), action_paint);
                         suck_bubble = true;
                     } else
-                        canvas.drawBitmap(ic_bg, null, a.getBounds(showed*2.f, b.getPos(), showed), action_paint);
+                        canvas.drawBitmap(ic_bg, null, a.getBounds(showed * 2.f, b.getPos(), showed), action_paint);
                     canvas.drawBitmap(a.getBitmap(), null, a.getBounds(showed, b.getPos(), showed), null);
                     float dist_raw = FloatMath.sqrt((b.pos.x - a.pos.x) * (b.pos.x - a.pos.x) + (b.pos.y - a.pos.y) * (b.pos.y - a.pos.y));
                     float dist_min = a.radius + b.radius + bubbleActionTextDistMin;
                     float dist = Math.max(0, dist_raw - dist_min);
                     if (actions.enabled && dist < dist_range) {
-                        white_name_paint.setAlpha(255 - (int)(255*dist/dist_range));
+                        white_name_paint.setAlpha(255 - (int) (255 * dist / dist_range));
                         canvas.drawText(a.name, a.getBounds().centerX(), a.getBounds().centerY() - a.radius * 2.2f, white_name_paint);
                     }
                 }
diff --git a/src/org/sflphone/model/CallTimer.java b/src/org/sflphone/model/CallTimer.java
deleted file mode 100644
index 6e9c9bf10ae72cbc421ce641207f1a64b9c2c8ce..0000000000000000000000000000000000000000
--- a/src/org/sflphone/model/CallTimer.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- *  Copyright (C) 2004-2014 Savoir-Faire Linux Inc.
- *
- *  Author: Alexandre Lision <alexandre.lision@savoirfairelinux.com>
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 3 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  Additional permission under GNU GPL version 3 section 7:
- *
- *  If you modify this program, or any covered work, by linking or
- *  combining it with the OpenSSL project's OpenSSL library (or a
- *  modified version of that library), containing parts covered by the
- *  terms of the OpenSSL or SSLeay licenses, Savoir-Faire Linux Inc.
- *  grants you additional permission to convey the resulting work.
- *  Corresponding Source for a non-source form of such a combination
- *  shall include the source code for the parts of OpenSSL used as well
- *  as that of the covered work.
- */
-
-package org.sflphone.model;
-
-import java.util.Observable;
-
-import android.util.Log;
-
-public class CallTimer extends Observable implements Runnable {
-
-    boolean stop = false;
-    private static final String TAG = CallTimer.class.getSimpleName();
-
-    @Override
-    public void run() {
-
-        while (!stop) {
-            try {
-                synchronized (this) {
-                    this.wait(1000);
-                }
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            }
-            Log.i(TAG, "update!");
-            notifyObservers();
-        }
-
-    }
-
-    @Override
-    public boolean hasChanged() {
-        return true;
-    }
-
-}
diff --git a/src/org/sflphone/model/account/AccountCredentials.java b/src/org/sflphone/model/account/AccountCredentials.java
index 707ca4ad3e90622a3cd3b9ece7787ea31b60ee43..05b20e7f6db2ae692afcb58fc212a529ea00b0d2 100644
--- a/src/org/sflphone/model/account/AccountCredentials.java
+++ b/src/org/sflphone/model/account/AccountCredentials.java
@@ -91,10 +91,9 @@ public class AccountCredentials implements AccountDetail {
     }
 
     public void setDetailString(String key, String newValue) {
-        for (int i = 0; i < privateArray.size(); ++i) {
-            PreferenceEntry p = privateArray.get(i);
+        for (PreferenceEntry p : privateArray) {
             if (p.mKey.equals(key)) {
-                privateArray.get(i).mValue = newValue;
+                p.mValue = newValue;
             }
         }
 
diff --git a/src/org/sflphone/model/account/AccountDetail.java b/src/org/sflphone/model/account/AccountDetail.java
index 8c5dd98bb89fa389f8ead3ca1d93903c54f9c534..e26528767969b025fa76ad276e73b8584ea05af6 100644
--- a/src/org/sflphone/model/account/AccountDetail.java
+++ b/src/org/sflphone/model/account/AccountDetail.java
@@ -47,9 +47,7 @@ public interface AccountDetail {
         }
 
         public boolean isChecked() {
-            if (mValue.contentEquals("true"))
-                return true;
-            return false;
+            return mValue.contentEquals("true");
         }
     }
 
diff --git a/src/org/sflphone/model/account/AccountDetailAdvanced.java b/src/org/sflphone/model/account/AccountDetailAdvanced.java
index bbcfc9bdfb3f302f2daee4b6a2bee76d6aae42d2..de45b0db1adf73c12ff87366bd62fbd98f5a1e61 100644
--- a/src/org/sflphone/model/account/AccountDetailAdvanced.java
+++ b/src/org/sflphone/model/account/AccountDetailAdvanced.java
@@ -128,10 +128,9 @@ public class AccountDetailAdvanced implements AccountDetail {
     }
 
     public void setDetailString(String key, String newValue) {
-        for (int i = 0; i < privateArray.size(); ++i) {
-            PreferenceEntry p = privateArray.get(i);
+        for (PreferenceEntry p : privateArray) {
             if (p.mKey.equals(key)) {
-                privateArray.get(i).mValue = newValue;
+                p.mValue = newValue;
             }
         }
 
diff --git a/src/org/sflphone/model/account/AccountDetailBasic.java b/src/org/sflphone/model/account/AccountDetailBasic.java
index 2f0361675e486b591a6b65545abe78f13725db78..61d4a677da22be826823c995edae1f7f1eb5e90a 100644
--- a/src/org/sflphone/model/account/AccountDetailBasic.java
+++ b/src/org/sflphone/model/account/AccountDetailBasic.java
@@ -111,10 +111,9 @@ public class AccountDetailBasic implements AccountDetail {
     }
 
     public void setDetailString(String key, String newValue) {
-        for (int i = 0; i < privateArray.size(); ++i) {
-            PreferenceEntry p = privateArray.get(i);
+        for (PreferenceEntry p : privateArray) {
             if (p.mKey.equals(key)) {
-                privateArray.get(i).mValue = newValue;
+                p.mValue = newValue;
             }
         }
 
diff --git a/src/org/sflphone/model/account/AccountDetailSrtp.java b/src/org/sflphone/model/account/AccountDetailSrtp.java
index 7ca2b9fa91972820804f2bcfe843e0a577c2cc57..35df7276e2aa1797fa1b27fb5dc3da602935b83a 100644
--- a/src/org/sflphone/model/account/AccountDetailSrtp.java
+++ b/src/org/sflphone/model/account/AccountDetailSrtp.java
@@ -103,10 +103,9 @@ public class AccountDetailSrtp implements AccountDetail {
     }
 
     public void setDetailString(String key, String newValue) {
-        for (int i = 0; i < privateArray.size(); ++i) {
-            PreferenceEntry p = privateArray.get(i);
+        for (PreferenceEntry p : privateArray) {
             if (p.mKey.equals(key)) {
-                privateArray.get(i).mValue = newValue;
+                p.mValue = newValue;
             }
         }
 
diff --git a/src/org/sflphone/model/account/AccountDetailTls.java b/src/org/sflphone/model/account/AccountDetailTls.java
index db03ed7b9ed1f5d9b3db6d98128a99fc735cc900..e753d1262c524873ea77c0eb05f068735f196335 100644
--- a/src/org/sflphone/model/account/AccountDetailTls.java
+++ b/src/org/sflphone/model/account/AccountDetailTls.java
@@ -114,10 +114,9 @@ public class AccountDetailTls implements AccountDetail {
     }
 
     public void setDetailString(String key, String newValue) {
-        for (int i = 0; i < privateArray.size(); ++i) {
-            PreferenceEntry p = privateArray.get(i);
+        for (PreferenceEntry p : privateArray) {
             if (p.mKey.equals(key)) {
-                privateArray.get(i).mValue = newValue;
+                p.mValue = newValue;
             }
         }
 
diff --git a/src/org/sflphone/model/account/SRTPManager.java b/src/org/sflphone/model/account/SRTPManager.java
index 5189e252b6a5f073a15a72e182251268c34e8475..1813d399e85215f35282e2c6e33f5780227cc277 100644
--- a/src/org/sflphone/model/account/SRTPManager.java
+++ b/src/org/sflphone/model/account/SRTPManager.java
@@ -78,7 +78,7 @@ public class SRTPManager {
 
         @Override
         public boolean onPreferenceChange(Preference preference, Object newValue) {
-            Log.i("SRTP", "Setting " + preference.getKey() + " to" + (Boolean) newValue);
+            Log.i("SRTP", "Setting " + preference.getKey() + " to" + newValue);
             mAccount.getSrtpDetails().setDetailString(preference.getKey(), Boolean.toString((Boolean) newValue));
             mAccount.notifyObservers();
             return true;