]> git.ktnx.net Git - mobile-ledger.git/blobdiff - app/src/main/java/net/ktnx/mobileledger/ui/activity/ProfileDetailActivity.java
wrap Log.d calls, skipping them on non-debug builds
[mobile-ledger.git] / app / src / main / java / net / ktnx / mobileledger / ui / activity / ProfileDetailActivity.java
index a5c973b096dff0c0fce6e2a664d0e7346e996200..ad7401de661079b75510f59eab70b5e4c6d79318 100644 (file)
@@ -18,7 +18,6 @@
 package net.ktnx.mobileledger.ui.activity;
 
 import android.os.Bundle;
-import android.util.Log;
 import android.view.Menu;
 
 import net.ktnx.mobileledger.R;
@@ -30,6 +29,8 @@ import net.ktnx.mobileledger.utils.Colors;
 import androidx.appcompat.app.ActionBar;
 import androidx.appcompat.widget.Toolbar;
 
+import static net.ktnx.mobileledger.utils.Logger.debug;
+
 /**
  * An activity representing a single Profile detail screen. This
  * activity is only used on narrow width devices. On tablet-size devices,
@@ -48,7 +49,7 @@ public class ProfileDetailActivity extends CrashReportingActivity {
             if (profile == null) throw new AssertionError(
                     String.format("Can't get profile " + "(index:%d) from the global list", index));
 
-            Log.d("profiles", String.format("Editing profile %s (%s); hue=%d", profile.getName(),
+            debug("profiles", String.format("Editing profile %s (%s); hue=%d", profile.getName(),
                     profile.getUuid(), profile.getThemeId()));
         }
 
@@ -87,7 +88,7 @@ public class ProfileDetailActivity extends CrashReportingActivity {
     @Override
     public boolean onCreateOptionsMenu(Menu menu) {
         super.onCreateOptionsMenu(menu);
-        Log.d("profiles", "[activity] Creating profile details options menu");
+        debug("profiles", "[activity] Creating profile details options menu");
         if (mFragment != null) mFragment.onCreateOptionsMenu(menu, getMenuInflater());
 
         return true;