mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-01 00:06:47 +00:00
Update AllApps to defered surface attachment for RS.
This commit is contained in:
@@ -157,6 +157,13 @@ public class AllAppsView extends RSSurfaceView
|
||||
setOnLongClickListener(this);
|
||||
setZOrderOnTop(true);
|
||||
getHolder().setFormat(PixelFormat.TRANSLUCENT);
|
||||
|
||||
mRS = createRenderScript(true);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDetachedFromWindow() {
|
||||
destroyRenderScript();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -192,8 +199,7 @@ public class AllAppsView extends RSSurfaceView
|
||||
|
||||
super.surfaceChanged(holder, format, w, h);
|
||||
|
||||
if (mRS == null) {
|
||||
mRS = createRenderScript(true);
|
||||
if (mRollo == null) {
|
||||
mRollo = new RolloRS();
|
||||
mRollo.mHasSurface = true;
|
||||
mRollo.init(getResources(), w, h);
|
||||
@@ -204,11 +210,10 @@ public class AllAppsView extends RSSurfaceView
|
||||
gainFocus();
|
||||
mShouldGainFocus = false;
|
||||
}
|
||||
mRollo.dirtyCheck();
|
||||
} else {
|
||||
mRollo.mHasSurface = true;
|
||||
mRollo.dirtyCheck();
|
||||
}
|
||||
mRollo.dirtyCheck();
|
||||
|
||||
mRS.mMessageCallback = mMessageProc = new AAMessage();
|
||||
|
||||
@@ -298,7 +303,7 @@ public class AllAppsView extends RSSurfaceView
|
||||
public boolean onKeyDown(int keyCode, KeyEvent event) {
|
||||
|
||||
boolean handled = false;
|
||||
|
||||
|
||||
if (!isVisible()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user