Merge "Remove zoom from app clips." into udc-dev

This commit is contained in:
Treehugger Robot
2023-05-04 12:42:49 +00:00
committed by Android (Google) Code Review

View File

@@ -53,7 +53,6 @@ import com.android.internal.logging.UiEventLogger.UiEventEnum;
import com.android.settingslib.Utils; import com.android.settingslib.Utils;
import com.android.systemui.R; import com.android.systemui.R;
import com.android.systemui.screenshot.CropView; import com.android.systemui.screenshot.CropView;
import com.android.systemui.screenshot.MagnifierView;
import com.android.systemui.settings.UserTracker; import com.android.systemui.settings.UserTracker;
import javax.inject.Inject; import javax.inject.Inject;
@@ -93,7 +92,6 @@ public class AppClipsActivity extends ComponentActivity {
private View mRoot; private View mRoot;
private ImageView mPreview; private ImageView mPreview;
private CropView mCropView; private CropView mCropView;
private MagnifierView mMagnifierView;
private Button mSave; private Button mSave;
private Button mCancel; private Button mCancel;
private AppClipsViewModel mViewModel; private AppClipsViewModel mViewModel;
@@ -156,9 +154,8 @@ public class AppClipsActivity extends ComponentActivity {
mSave.setOnClickListener(this::onClick); mSave.setOnClickListener(this::onClick);
mCancel.setOnClickListener(this::onClick); mCancel.setOnClickListener(this::onClick);
mMagnifierView = mLayout.findViewById(R.id.magnifier);
mCropView = mLayout.findViewById(R.id.crop_view); mCropView = mLayout.findViewById(R.id.crop_view);
mCropView.setCropInteractionListener(mMagnifierView);
mPreview = mLayout.findViewById(R.id.preview); mPreview = mLayout.findViewById(R.id.preview);
mPreview.addOnLayoutChangeListener( mPreview.addOnLayoutChangeListener(
@@ -218,8 +215,6 @@ public class AppClipsActivity extends ComponentActivity {
mPreview.setImageDrawable(drawable); mPreview.setImageDrawable(drawable);
mPreview.setAlpha(1f); mPreview.setAlpha(1f);
mMagnifierView.setDrawable(drawable, screenshot.getWidth(), screenshot.getHeight());
// Screenshot is now available so set content view. // Screenshot is now available so set content view.
setContentView(mLayout); setContentView(mLayout);
} }