use of com.android.gallery3d.ui.GLRoot in project android_packages_apps_Gallery2 by LineageOS.
the class AbstractGalleryActivity method onBackPressed.
@Override
public void onBackPressed() {
// send the back event to the top sub-state
GLRoot root = getGLRoot();
root.lockRenderThread();
try {
getStateManager().onBackPressed();
} finally {
root.unlockRenderThread();
}
}
use of com.android.gallery3d.ui.GLRoot in project android_packages_apps_Gallery2 by LineageOS.
the class AbstractGalleryActivity method onOptionsItemSelected.
@Override
public boolean onOptionsItemSelected(MenuItem item) {
GLRoot root = getGLRoot();
root.lockRenderThread();
try {
return getStateManager().itemSelected(item);
} finally {
root.unlockRenderThread();
}
}
use of com.android.gallery3d.ui.GLRoot in project android_packages_apps_Gallery2 by LineageOS.
the class ManageCachePage method onClick.
@Override
public void onClick(View view) {
Utils.assertTrue(view.getId() == R.id.done);
GLRoot root = mActivity.getGLRoot();
root.lockRenderThread();
try {
ArrayList<Path> ids = mSelectionManager.getSelected(false);
if (ids.size() == 0) {
onBackPressed();
return;
}
showToast();
MenuExecutor menuExecutor = new MenuExecutor(mActivity, mSelectionManager);
menuExecutor.startAction(R.id.action_toggle_full_caching, R.string.process_caching_requests, this);
} finally {
root.unlockRenderThread();
}
}
Aggregations