liuyuqi-dellpc 3 years ago
parent
commit
88cdccf0e2

+ 0 - 242
app/src/main/java/com/epson/mobilephone/common/EpLog.java

@@ -1,242 +0,0 @@
-package com.epson.mobilephone.common;
-
-import android.os.Debug;
-import android.support.p000v4.media.session.PlaybackStateCompat;
-import android.util.Log;
-
-import epson.print.CommonDefine;
-
-import java.text.DecimalFormat;
-
-public final class EpLog {
-    public static final String TAG = "Epson App";
-    private static boolean isDebug = false;
-
-    private static String null2str(String str) {
-        return str == null ? "(null)" : str;
-    }
-
-    private EpLog() {
-    }
-
-    public static void setDebuggable(boolean z) {
-        if (z) {
-            isDebug = true;
-        } else {
-            isDebug = false;
-        }
-    }
-
-    /* renamed from: v */
-    public static void m79v() {
-        if (isDebug) {
-            Log.v("Epson App", getMetaInfo());
-        }
-    }
-
-    /* renamed from: v */
-    public static void m80v(String str) {
-        if (isDebug) {
-            Log.v("Epson App", getMetaInfo() + null2str(str));
-        }
-    }
-
-    /* renamed from: v */
-    public static void m81v(String str, String str2) {
-        if (isDebug) {
-            Log.v(str, getMetaInfo() + null2str(str2));
-        }
-    }
-
-    /* renamed from: d */
-    public static void m68d() {
-        if (isDebug) {
-            Log.d("Epson App", getMetaInfo());
-        }
-    }
-
-    /* renamed from: d */
-    public static void m69d(String str) {
-        if (isDebug) {
-            Log.d("Epson App", getMetaInfo() + null2str(str));
-        }
-    }
-
-    /* renamed from: d */
-    public static void m70d(String str, String str2) {
-        if (isDebug) {
-            Log.d(str, getMetaInfo() + null2str(str2));
-        }
-    }
-
-    /* renamed from: i */
-    public static void m76i() {
-        if (isDebug) {
-            Log.i("Epson App", getMetaInfo());
-        }
-    }
-
-    /* renamed from: i */
-    public static void m77i(String str) {
-        if (isDebug) {
-            Log.i("Epson App", getMetaInfo() + null2str(str));
-        }
-    }
-
-    /* renamed from: i */
-    public static void m78i(String str, String str2) {
-        if (isDebug) {
-            Log.i(str, getMetaInfo() + null2str(str2));
-        }
-    }
-
-    /* renamed from: w */
-    public static void m82w(String str) {
-        if (isDebug) {
-            Log.w("Epson App", getMetaInfo() + null2str(str));
-        }
-    }
-
-    /* renamed from: w */
-    public static void m83w(String str, String str2) {
-        if (isDebug) {
-            Log.w(str, getMetaInfo() + null2str(str2));
-        }
-    }
-
-    /* renamed from: w */
-    public static void m85w(String str, Throwable th) {
-        if (isDebug) {
-            Log.w("Epson App", getMetaInfo() + null2str(str), th);
-            printThrowable(th);
-            if (th.getCause() != null) {
-                printThrowable(th.getCause());
-            }
-        }
-    }
-
-    /* renamed from: w */
-    public static void m84w(String str, String str2, Throwable th) {
-        if (isDebug) {
-            Log.w(str, getMetaInfo() + null2str(str2), th);
-            printThrowable(str, th);
-            if (th.getCause() != null) {
-                printThrowable(th.getCause());
-            }
-        }
-    }
-
-    /* renamed from: e */
-    public static void m71e(String str) {
-        if (isDebug) {
-            Log.e("Epson App", getMetaInfo() + null2str(str));
-        }
-    }
-
-    /* renamed from: e */
-    public static void m72e(String str, String str2) {
-        if (isDebug) {
-            Log.e(str, getMetaInfo() + null2str(str2));
-        }
-    }
-
-    /* renamed from: e */
-    public static void m74e(String str, Throwable th) {
-        if (isDebug) {
-            Log.e("Epson App", getMetaInfo() + null2str(str), th);
-            printThrowable(th);
-            if (th.getCause() != null) {
-                printThrowable(th.getCause());
-            }
-        }
-    }
-
-    /* renamed from: e */
-    public static void m73e(String str, String str2, Throwable th) {
-        if (isDebug) {
-            Log.e(str, getMetaInfo() + null2str(str2), th);
-            printThrowable(str, th);
-            if (th.getCause() != null) {
-                printThrowable(th.getCause());
-            }
-        }
-    }
-
-    /* renamed from: e */
-    public static void m75e(Throwable th) {
-        if (isDebug) {
-            printThrowable(th);
-            if (th.getCause() != null) {
-                printThrowable(th.getCause());
-            }
-        }
-    }
-
-    private static void printThrowable(Throwable th) {
-        Log.e("Epson App", th.getClass().getName() + ": " + th.getMessage());
-        for (StackTraceElement stackTraceElement : th.getStackTrace()) {
-            Log.e("Epson App", "  at " + getMetaInfo(stackTraceElement));
-        }
-    }
-
-    private static void printThrowable(String str, Throwable th) {
-        Log.e(str, th.getClass().getName() + ": " + th.getMessage());
-        for (StackTraceElement stackTraceElement : th.getStackTrace()) {
-            Log.e("Epson App", "  at " + getMetaInfo(stackTraceElement));
-        }
-    }
-
-    private static String getMetaInfo() {
-        return getMetaInfo(Thread.currentThread().getStackTrace()[4]);
-    }
-
-    public static String getMetaInfo(StackTraceElement stackTraceElement) {
-        StringBuffer stringBuffer = new StringBuffer();
-        String className = stackTraceElement.getClassName();
-        String substring = className.substring(className.lastIndexOf(CommonDefine.DOT) + 1);
-        String methodName = stackTraceElement.getMethodName();
-        int lineNumber = stackTraceElement.getLineNumber();
-        stringBuffer.append("[");
-        stringBuffer.append(substring);
-        stringBuffer.append("#");
-        stringBuffer.append(methodName);
-        stringBuffer.append(":");
-        stringBuffer.append(lineNumber);
-        stringBuffer.append("]");
-        return new String(stringBuffer);
-    }
-
-    public static final void heap() {
-        heap("Epson App");
-    }
-
-    public static final void heap(String str) {
-        if (isDebug) {
-            DecimalFormat decimalFormat = new DecimalFormat("0.00");
-            StringBuffer stringBuffer = new StringBuffer();
-            stringBuffer.append("Native heap : Free=");
-            stringBuffer.append(Long.toString(Debug.getNativeHeapFreeSize() / PlaybackStateCompat.ACTION_PLAY_FROM_MEDIA_ID));
-            stringBuffer.append("kb");
-            stringBuffer.append(", Allocated=");
-            stringBuffer.append(decimalFormat.format(((Debug.getNativeHeapAllocatedSize()) / 1024.0d) / 1024.0d));
-            stringBuffer.append("MB");
-            stringBuffer.append(", Size=");
-            stringBuffer.append(decimalFormat.format(((Debug.getNativeHeapSize()) / 1024.0d) / 1024.0d));
-            stringBuffer.append("MB");
-            stringBuffer.append(System.getProperty("line.separator"));
-            stringBuffer.append("Dalvik heap : Free=");
-            stringBuffer.append(Long.toString(Runtime.getRuntime().freeMemory() / PlaybackStateCompat.ACTION_PLAY_FROM_MEDIA_ID));
-            stringBuffer.append("kb");
-            stringBuffer.append(", Total=");
-            stringBuffer.append(decimalFormat.format(((Runtime.getRuntime().totalMemory()) / 1024.0d) / 1024.0d));
-            stringBuffer.append("MB");
-            stringBuffer.append(", Now Size=");
-            stringBuffer.append(decimalFormat.format((((Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory())) / 1024.0d) / 1024.0d));
-            stringBuffer.append("MB");
-            stringBuffer.append(", MAX Size=");
-            stringBuffer.append(decimalFormat.format(((Runtime.getRuntime().maxMemory()) / 1024.0d) / 1024.0d));
-            stringBuffer.append("MB");
-            Log.i(str, new String(stringBuffer));
-        }
-    }
-}

+ 2 - 0
app/src/main/java/com/epson/mobilephone/common/StoreReview.java

@@ -3,6 +3,8 @@ package com.epson.mobilephone.common;
 import android.content.Context;
 import android.content.SharedPreferences;
 
+import androidx.annotation.NonNull;
+
 import java.text.SimpleDateFormat;
 import java.util.Date;
 import java.util.Locale;

+ 0 - 54
app/src/main/java/com/epson/mobilephone/common/wifidirect/EPLog.java

@@ -1,54 +0,0 @@
-package com.epson.mobilephone.common.wifidirect;
-
-import android.content.Context;
-import android.content.pm.ApplicationInfo;
-import android.content.pm.PackageManager;
-import android.util.Log;
-
-public class EPLog {
-    private static boolean isDebuggable = false;
-
-    public static boolean isDebuggable(Context context) {
-        ApplicationInfo applicationInfo;
-        try {
-            applicationInfo = context.getPackageManager().getApplicationInfo(context.getPackageName(), 0);
-        } catch (PackageManager.NameNotFoundException unused) {
-            isDebuggable = false;
-            applicationInfo = null;
-        }
-        if ((applicationInfo.flags & 2) == 2) {
-            isDebuggable = true;
-        }
-        return isDebuggable;
-    }
-
-    public static final void d(String str, String str2) {
-        if (isDebuggable) {
-            Log.d(str, str2);
-        }
-    }
-
-    public static final void e(String str, String str2) {
-        if (isDebuggable) {
-            Log.e(str, str2);
-        }
-    }
-
-    public static final void i(String str, String str2) {
-        if (isDebuggable) {
-            Log.i(str, str2);
-        }
-    }
-
-    public static final void v(String str, String str2) {
-        if (isDebuggable) {
-            Log.v(str, str2);
-        }
-    }
-
-    public static final void w(String str, String str2) {
-        if (isDebuggable) {
-            Log.w(str, str2);
-        }
-    }
-}

+ 3 - 5
app/src/main/java/epson/common/ExternalFileUtils.java

@@ -1,12 +1,10 @@
 package epson.common;
 
 import android.content.Context;
-
-
-import android.support.annotation.VisibleForTesting;
-
+import androidx.annotation.NonNull;
+import androidx.annotation.Nullable;
+import androidx.annotation.VisibleForTesting;
 import epson.print.Util.EPLog;
-
 import java.io.File;
 import java.util.Locale;
 

+ 28 - 113
app/src/main/java/epson/common/ImageUtil.java

@@ -17,17 +17,25 @@ import android.net.Uri;
 import android.provider.MediaStore;
 import android.view.Display;
 
-import epson.print.CommonDefine;
-
 import java.io.ByteArrayOutputStream;
 import java.io.File;
 import java.io.FileInputStream;
-import java.io.FileNotFoundException;
 import java.io.FileOutputStream;
 import java.io.IOException;
 
+import epson.print.CommonDefine;
+
 public class ImageUtil {
-    public static String png2jpeg(Context context, String str, int i) {
+    /**
+     * png转jpg
+     *
+     * @param context 上下文
+     * @param str
+     * @param i
+     * @return
+     * @throws IOException
+     */
+    public static String png2jpeg(Context context, String str, int i) throws IOException {
         File file;
         Bitmap createBitmap;
         String str2;
@@ -35,36 +43,20 @@ public class ImageUtil {
         Bitmap bitmap = null;
         Bitmap bitmap2 = null;
         while (true) {
-            try {
-                file = new File(str);
-                FileInputStream fileInputStream = new FileInputStream(file);
-                BitmapFactory.Options options = new BitmapFactory.Options();
-                options.inSampleSize = i;
-                Bitmap decodeStream = BitmapFactory.decodeStream(fileInputStream, (Rect) null, options);
-                createBitmap = Bitmap.createBitmap(decodeStream.getWidth(), decodeStream.getHeight(), Bitmap.Config.ARGB_8888);
-                Canvas canvas = new Canvas(createBitmap);
-                canvas.drawColor(-1);
-                canvas.drawBitmap(decodeStream, 0.0f, 0.0f, (Paint) null);
-                str2 = String.valueOf(System.currentTimeMillis()) + ".jpg";
-                file2 = new File(ExternalFileUtils.getInstance(context).getTempViewDir(), str2);
-                break;
-            } catch (FileNotFoundException e) {
-                e.printStackTrace();
-            } catch (IOException e2) {
-                e2.printStackTrace();
-            } catch (OutOfMemoryError e3) {
-                e3.printStackTrace();
-                i++;
-                if (bitmap != null) {
-                    bitmap.recycle();
-                    bitmap = null;
-                }
-                if (bitmap2 != null) {
-                    bitmap2.recycle();
-                    bitmap2 = null;
-                }
-                System.gc();
-            }
+
+            file = new File(str);
+            FileInputStream fileInputStream = new FileInputStream(file);
+            BitmapFactory.Options options = new BitmapFactory.Options();
+            options.inSampleSize = i;
+            Bitmap decodeStream = BitmapFactory.decodeStream(fileInputStream, (Rect) null, options);
+            createBitmap = Bitmap.createBitmap(decodeStream.getWidth(), decodeStream.getHeight(), Bitmap.Config.ARGB_8888);
+            Canvas canvas = new Canvas(createBitmap);
+            canvas.drawColor(-1);
+            canvas.drawBitmap(decodeStream, 0.0f, 0.0f, (Paint) null);
+            str2 = String.valueOf(System.currentTimeMillis()) + ".jpg";
+            file2 = new File(ExternalFileUtils.getInstance(context).getTempViewDir(), str2);
+            break;
+
         }
         if (file.exists()) {
             file2.delete();
@@ -162,86 +154,9 @@ public class ImageUtil {
         return true;
     }
 
-    /* JADX WARNING: Removed duplicated region for block: B:39:0x0055 A[SYNTHETIC, Splitter:B:39:0x0055] */
-    /* JADX WARNING: Removed duplicated region for block: B:51:0x0067 A[SYNTHETIC, Splitter:B:51:0x0067] */
-    /* JADX WARNING: Removed duplicated region for block: B:57:0x0072  */
-    /* JADX WARNING: Removed duplicated region for block: B:60:? A[RETURN, SYNTHETIC] */
-    /* Code decompiled incorrectly, please refer to instructions dump. */
+
     public static boolean convertHEIFtoJPEG(java.lang.String r6, java.lang.String r7) {
-        /*
-            r0 = 0
-            r1 = 0
-            android.graphics.Bitmap r2 = android.graphics.BitmapFactory.decodeFile(r6)     // Catch:{ Exception -> 0x0064, all -> 0x0051 }
-            if (r2 != 0) goto L_0x0014
-            if (r2 == 0) goto L_0x0013
-            boolean r6 = r2.isRecycled()
-            if (r6 != 0) goto L_0x0013
-            r2.recycle()
-        L_0x0013:
-            return r0
-        L_0x0014:
-            java.io.File r3 = new java.io.File     // Catch:{ Exception -> 0x0065, all -> 0x004f }
-            r3.<init>(r7)     // Catch:{ Exception -> 0x0065, all -> 0x004f }
-            java.io.FileOutputStream r4 = new java.io.FileOutputStream     // Catch:{ Exception -> 0x0065, all -> 0x004f }
-            r4.<init>(r3)     // Catch:{ Exception -> 0x0065, all -> 0x004f }
-            android.graphics.Bitmap$CompressFormat r3 = android.graphics.Bitmap.CompressFormat.JPEG     // Catch:{ Exception -> 0x004d, all -> 0x004a }
-            r5 = 100
-            boolean r3 = r2.compress(r3, r5, r4)     // Catch:{ Exception -> 0x004d, all -> 0x004a }
-            if (r3 != 0) goto L_0x0037
-            r4.close()     // Catch:{ IOException -> 0x002b }
-        L_0x002b:
-            if (r2 == 0) goto L_0x0036
-            boolean r6 = r2.isRecycled()
-            if (r6 != 0) goto L_0x0036
-            r2.recycle()
-        L_0x0036:
-            return r0
-        L_0x0037:
-            r4.close()     // Catch:{ Exception -> 0x004d, all -> 0x004a }
-            epson.common.ExifCopy.copyExif(r6, r7)     // Catch:{ Exception -> 0x0065, all -> 0x004f }
-            if (r2 == 0) goto L_0x0048
-            boolean r6 = r2.isRecycled()
-            if (r6 != 0) goto L_0x0048
-            r2.recycle()
-        L_0x0048:
-            r0 = 1
-            goto L_0x0075
-        L_0x004a:
-            r6 = move-exception
-            r1 = r4
-            goto L_0x0053
-        L_0x004d:
-            r1 = r4
-            goto L_0x0065
-        L_0x004f:
-            r6 = move-exception
-            goto L_0x0053
-        L_0x0051:
-            r6 = move-exception
-            r2 = r1
-        L_0x0053:
-            if (r1 == 0) goto L_0x0058
-            r1.close()     // Catch:{ IOException -> 0x0058 }
-        L_0x0058:
-            if (r2 == 0) goto L_0x0063
-            boolean r7 = r2.isRecycled()
-            if (r7 != 0) goto L_0x0063
-            r2.recycle()
-        L_0x0063:
-            throw r6
-        L_0x0064:
-            r2 = r1
-        L_0x0065:
-            if (r1 == 0) goto L_0x006a
-            r1.close()     // Catch:{ IOException -> 0x006a }
-        L_0x006a:
-            if (r2 == 0) goto L_0x0075
-            boolean r6 = r2.isRecycled()
-            if (r6 != 0) goto L_0x0075
-            r2.recycle()
-        L_0x0075:
-            return r0
-        */
+
         throw new UnsupportedOperationException("Method not decompiled: epson.common.ImageUtil.convertHEIFtoJPEG(java.lang.String, java.lang.String):boolean");
     }
 }

+ 2 - 0
app/src/main/java/epson/common/IprintAppRecord.java

@@ -4,6 +4,8 @@ import android.content.Context;
 import android.content.SharedPreferences;
 import android.preference.PreferenceManager;
 
+import androidx.annotation.NonNull;
+
 
 public class IprintAppRecord {
     private static final String KEY_LICENSE_AGREE_TIME = "license_agree_time";

+ 1 - 0
app/src/main/java/epson/common/MimeType.java

@@ -3,6 +3,7 @@ package epson.common;
 import epson.print.CommonDefine;
 
 public enum MimeType {
+
     IMAGE_TYPE("image/jpeg"),
     PDF_TYPE("application/pdf"),
     DOC_TYPE_1(CommonDefine.DOC_TYPE_1),

+ 40 - 40
app/src/main/java/epson/common/ScalableImageView.java

@@ -30,21 +30,21 @@ public class ScalableImageView extends View {
     private float mScaleFactor = 1.0f;
     private final GestureDetector.SimpleOnGestureListener onGestureListener = new GestureDetector.SimpleOnGestureListener() {
         public boolean onDoubleTap(MotionEvent motionEvent) {
-            EPLog.m305d(ScalableImageView.TAG, "DOBULE TAP");
-            if (ScalableImageView.mScaleFactor == 1.0f) {
-                float x = (((-ScalableImageView.mOffsetX) + motionEvent.getX()) / ScalableImageView.mScaleFactor) / ((float) ScalableImageView.this.canvasRect.width());
-                float y = (((-ScalableImageView.mOffsetY) + motionEvent.getY()) / ScalableImageView.mScaleFactor) / ((float) ScalableImageView.this.canvasRect.height());
-                float unused = ScalableImageView.mScaleFactor = ScalableImageView.MAX_SCALE_FACTOR;
-                float width = ((float) ScalableImageView.this.canvasRect.width()) * ScalableImageView.mScaleFactor;
-                float height = ((float) ScalableImageView.this.canvasRect.height()) * ScalableImageView.mScaleFactor;
-                float unused2 = ScalableImageView.mOffsetX = motionEvent.getX() - (width * x);
-                float unused3 = ScalableImageView.mOffsetY = motionEvent.getY() - (height * y);
+            EPLog.m305d(TAG, "DOBULE TAP");
+            if (mScaleFactor == 1.0f) {
+                float x = (((-mOffsetX) + motionEvent.getX()) / mScaleFactor) / ( canvasRect.width());
+                float y = (((-mOffsetY) + motionEvent.getY()) / mScaleFactor) / ( canvasRect.height());
+                float unused = mScaleFactor = MAX_SCALE_FACTOR;
+                float width = ( canvasRect.width()) * mScaleFactor;
+                float height = ( canvasRect.height()) * mScaleFactor;
+                float unused2 = mOffsetX = motionEvent.getX() - (width * x);
+                float unused3 = mOffsetY = motionEvent.getY() - (height * y);
             } else {
-                float unused4 = ScalableImageView.mScaleFactor = 1.0f;
-                float unused5 = ScalableImageView.mOffsetX = 0.0f;
-                float unused6 = ScalableImageView.mOffsetY = 0.0f;
+                float unused4 = mScaleFactor = 1.0f;
+                float unused5 = mOffsetX = 0.0f;
+                float unused6 = mOffsetY = 0.0f;
             }
-            ScalableImageView.this.invalidate();
+            invalidate();
             return true;
         }
 
@@ -53,20 +53,20 @@ public class ScalableImageView extends View {
             float f4 = -f2;
             if (f3 > 0.0f) {
                 ScalableImageView scalableImageView = ScalableImageView.this;
-                float unused = scalableImageView.mOffsetX = Math.min(scalableImageView.mOffsetX + f3, 0.0f);
+                float unused = mOffsetX = Math.min(mOffsetX + f3, 0.0f);
             } else {
                 ScalableImageView scalableImageView2 = ScalableImageView.this;
-                float unused2 = scalableImageView2.mOffsetX = Math.max(scalableImageView2.mOffsetX + f3, ((float) ScalableImageView.this.canvasRect.width()) - (((float) ScalableImageView.this.canvasRect.width()) * ScalableImageView.mScaleFactor));
+                float unused2 = scalableImageView2.mOffsetX = Math.max(scalableImageView2.mOffsetX + f3, ( canvasRect.width()) - (( canvasRect.width()) * mScaleFactor));
             }
             if (f4 > 0.0f) {
                 ScalableImageView scalableImageView3 = ScalableImageView.this;
                 float unused3 = scalableImageView3.mOffsetY = Math.min(scalableImageView3.mOffsetY + f4, 0.0f);
             } else {
                 ScalableImageView scalableImageView4 = ScalableImageView.this;
-                float unused4 = scalableImageView4.mOffsetY = Math.max(scalableImageView4.mOffsetY + f4, ((float) ScalableImageView.this.canvasRect.height()) - (((float) ScalableImageView.this.canvasRect.height()) * ScalableImageView.mScaleFactor));
+                float unused4 = scalableImageView4.mOffsetY = Math.max(scalableImageView4.mOffsetY + f4, ( canvasRect.height()) - (( canvasRect.height()) * mScaleFactor));
             }
-            EPLog.m305d(ScalableImageView.TAG, "mOffsetX = " + ScalableImageView.mOffsetX + " mOffsetY = " + ScalableImageView.mOffsetY);
-            ScalableImageView.this.invalidate();
+            EPLog.m305d(TAG, "mOffsetX = " + mOffsetX + " mOffsetY = " + mOffsetY);
+            invalidate();
             return true;
         }
     };
@@ -79,35 +79,35 @@ public class ScalableImageView extends View {
         public boolean onScaleBegin(ScaleGestureDetector scaleGestureDetector) {
             focusX = scaleGestureDetector.getFocusX();
             focusY = scaleGestureDetector.getFocusY();
-            perFocusX = (((-ScalableImageView.mOffsetX) + focusX) / ScalableImageView.mScaleFactor) / ((float) ScalableImageView.this.canvasRect.width());
-            perFocusY = (((-ScalableImageView.mOffsetY) + focusY) / ScalableImageView.mScaleFactor) / ((float) ScalableImageView.this.canvasRect.height());
+            perFocusX = (((-mOffsetX) + focusX) / mScaleFactor) / ( canvasRect.width());
+            perFocusY = (((-mOffsetY) + focusY) / mScaleFactor) / ( canvasRect.height());
             return super.onScaleBegin(scaleGestureDetector);
         }
 
         public boolean onScale(ScaleGestureDetector scaleGestureDetector) {
-            ScalableImageView scalableImageView = ScalableImageView.this;
-            float unused = scalableImageView.mScaleFactor = scalableImageView.mScaleFactor * scaleGestureDetector.getScaleFactor();
-            ScalableImageView scalableImageView2 = ScalableImageView.this;
-            float unused2 = scalableImageView2.mScaleFactor = Math.max(1.0f, Math.min(scalableImageView2.mScaleFactor, ScalableImageView.MAX_SCALE_FACTOR));
-            if (ScalableImageView.mScaleFactor == 1.0f) {
-                float unused3 = ScalableImageView.mOffsetX = 0.0f;
-                float unused4 = ScalableImageView.mOffsetY = 0.0f;
+            ScalableImageView scalableImageView = this;
+            float unused = mScaleFactor = mScaleFactor * scaleGestureDetector.getScaleFactor();
+            ScalableImageView scalableImageView2 = this;
+            float unused2 = scalableImageView2.mScaleFactor = Math.max(1.0f, Math.min(scalableImageView2.mScaleFactor, MAX_SCALE_FACTOR));
+            if (mScaleFactor == 1.0f) {
+                float unused3 = mOffsetX = 0.0f;
+                float unused4 = mOffsetY = 0.0f;
             } else {
-                float width = ((float) ScalableImageView.this.canvasRect.width()) * ScalableImageView.mScaleFactor;
-                float height = ((float) ScalableImageView.this.canvasRect.height()) * ScalableImageView.mScaleFactor;
-                float unused5 = ScalableImageView.mOffsetX = focusX - (width * perFocusX);
-                float unused6 = ScalableImageView.mOffsetY = focusY - (height * perFocusY);
+                float width = ( canvasRect.width()) * mScaleFactor;
+                float height = ( canvasRect.height()) * mScaleFactor;
+                float unused5 = mOffsetX = focusX - (width * perFocusX);
+                float unused6 = mOffsetY = focusY - (height * perFocusY);
                 ScalableImageView scalableImageView3 = ScalableImageView.this;
                 float unused7 = scalableImageView3.mOffsetX = Math.min(0.0f, scalableImageView3.mOffsetX);
                 ScalableImageView scalableImageView4 = ScalableImageView.this;
                 float unused8 = scalableImageView4.mOffsetY = Math.min(0.0f, scalableImageView4.mOffsetY);
                 ScalableImageView scalableImageView5 = ScalableImageView.this;
-                float unused9 = scalableImageView5.mOffsetX = Math.max(scalableImageView5.mOffsetX, ((float) ScalableImageView.this.canvasRect.width()) - (((float) ScalableImageView.this.canvasRect.width()) * ScalableImageView.mScaleFactor));
+                float unused9 = scalableImageView5.mOffsetX = Math.max(scalableImageView5.mOffsetX, ( canvasRect.width()) - (( canvasRect.width()) * mScaleFactor));
                 ScalableImageView scalableImageView6 = ScalableImageView.this;
-                float unused10 = scalableImageView6.mOffsetY = Math.max(scalableImageView6.mOffsetY, ((float) ScalableImageView.this.canvasRect.height()) - (((float) ScalableImageView.this.canvasRect.height()) * ScalableImageView.mScaleFactor));
+                float unused10 = scalableImageView6.mOffsetY = Math.max(scalableImageView6.mOffsetY, ( canvasRect.height()) - (( canvasRect.height()) * mScaleFactor));
             }
-            EPLog.m305d(ScalableImageView.TAG, "mScaleFactor = " + ScalableImageView.mScaleFactor + " mOffsetX = " + ScalableImageView.mOffsetX + " mOffsetY = " + ScalableImageView.mOffsetY);
-            ScalableImageView.this.invalidate();
+            EPLog.m305d(TAG, "mScaleFactor = " + mScaleFactor + " mOffsetX = " + mOffsetX + " mOffsetY = " + mOffsetY);
+            invalidate();
             return true;
         }
     };
@@ -128,7 +128,7 @@ public class ScalableImageView extends View {
     }
 
     public void SetImageBitmap(Bitmap bitmap, Resources resources) {
-        if (this.f332bm != bitmap) {
+        if (f332bm != bitmap) {
             f332bm = bitmap;
         }
     }
@@ -165,11 +165,11 @@ public class ScalableImageView extends View {
 
     protected void onDraw(Canvas canvas) {
         super.onDraw(canvas);
-        if (this.f332bm != null) {
+        if (f332bm != null) {
             canvasRect.right = canvas.getWidth();
             canvasRect.bottom = canvas.getHeight();
-            float min = Math.min(((float) canvasRect.width()) / ((float) f332bm.getWidth()), ((float) canvasRect.height()) / ((float) f332bm.getHeight()));
-            Rect rect = new Rect(((((float) canvasRect.width()) / 2.0f) - ((((float) f332bm.getWidth()) * min) / 2.0f)), ((((float) canvasRect.height()) / 2.0f) - ((((float) f332bm.getHeight()) * min) / 2.0f)), ((((float) canvasRect.width()) / 2.0f) + ((((float) f332bm.getWidth()) * min) / 2.0f)), ((((float) canvasRect.height()) / 2.0f) + ((((float) f332bm.getHeight()) * min) / 2.0f)));
+            float min = Math.min(( canvasRect.width()) / ( f332bm.getWidth()), ( canvasRect.height()) / ( f332bm.getHeight()));
+            Rect rect = new Rect(((( canvasRect.width()) / 2.0f) - ((( f332bm.getWidth()) * min) / 2.0f)), ((( canvasRect.height()) / 2.0f) - ((( f332bm.getHeight()) * min) / 2.0f)), ((( canvasRect.width()) / 2.0f) + ((( f332bm.getWidth()) * min) / 2.0f)), ((( canvasRect.height()) / 2.0f) + ((( f332bm.getHeight()) * min) / 2.0f)));
             canvas.save();
             canvas.translate(mOffsetX, mOffsetY);
             float f = mScaleFactor;
@@ -185,7 +185,7 @@ public class ScalableImageView extends View {
             return false;
         }
         scaleGesDetect.onTouchEvent(motionEvent);
-        if (this.scaleGesDetect.isInProgress()) {
+        if (scaleGesDetect.isInProgress()) {
             return true;
         }
         gesDetect.onTouchEvent(motionEvent);

+ 5 - 1
app/src/main/java/epson/epsonconnectregistration/SoapAUTHENTICATIONDataInfo.java

@@ -13,8 +13,12 @@ public class SoapAUTHENTICATIONDataInfo extends SoapConfigDataParser {
         super(GROUP_ID);
     }
 
+    /**
+     * 是否是admin模式
+     * @return
+     */
     public boolean isAdminMode() {
-        EpLog.m78i(TAG, "Enter isAdminMode");
+        EpLog.i(TAG, "Enter isAdminMode");
         if (!getRetVal()) {
             EpLog.m78i(TAG, "return = " + getRetVal());
             return false;

+ 1 - 2
app/src/main/java/epson/epsonconnectregistration/SoapWEBSETUPDataInfo.java

@@ -1,8 +1,7 @@
 package epson.epsonconnectregistration;
 
+import android.media.ExifInterface;
 import android.net.Uri;
-import android.support.media.ExifInterface;
-
 import com.box.androidsdk.content.BoxConstants;
 
 import epson.print.BuildConfig;

+ 0 - 1
app/src/main/java/epson/support/DeviceInformationActivity.java

@@ -17,7 +17,6 @@ import androidx.annotation.NonNull;
 import androidx.annotation.Nullable;
 
 import com.epson.memcardacc.DirectorySelecterActivity;
-import com.epson.mobilephone.common.EpLog;
 import com.epson.mobilephone.common.maintain2.MaintainPrinter2;
 import com.epson.mobilephone.common.wifidirect.ManageDefaultNetwork;
 import com.epson.mobilephone.common.wifidirect.WiFiControl;