本文整理汇总了Java中cn.finalteam.toolsfinal.ActivityManager类的典型用法代码示例。如果您正苦于以下问题:Java ActivityManager类的具体用法?Java ActivityManager怎么用?Java ActivityManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ActivityManager类属于cn.finalteam.toolsfinal包,在下文中一共展示了ActivityManager类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: takeResult
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void takeResult(PhotoInfo info) {
if (!mFunctionConfig.isMutiSelect()) {
mPhotoList.clear();
mSelectPhotoMap.clear();
}
mPhotoList.add(info);
if(mFunctionConfig.isEnablePreview()){
mIvPreView.setVisibility(View.VISIBLE);
}
mSelectPhotoMap.put(info.getPhotoPath(), info);
mPhotoTempMap.put(info.getPhotoId(), new PhotoTempModel(info.getPhotoPath()));
mPhotoEditListAdapter.notifyDataSetChanged();
PhotoSelectActivity activity = (PhotoSelectActivity) ActivityManager.getActivityManager().getActivity(PhotoSelectActivity.class.getName());
if (activity != null) {
activity.takeRefreshGallery(info, true);
}
loadImage(info);
}
示例2: takeResult
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void takeResult(PhotoInfo info) {
if (!GalleryFinal.getFunctionConfig().isMutiSelect()) {
mPhotoList.clear();
mSelectPhotoMap.clear();
}
mPhotoList.add(0, info);
mSelectPhotoMap.put(info.getPhotoPath(), info);
mPhotoTempMap.put(info.getPhotoId(), new PhotoTempModel(info.getPhotoPath()));
if (!GalleryFinal.getFunctionConfig().isEditPhoto() && mTakePhotoAction) {
resultAction();
} else {
if (GalleryFinal.getFunctionConfig().isEnablePreview()) {
mIvPreView.setVisibility(View.VISIBLE);
}
mPhotoEditListAdapter.notifyDataSetChanged();
PhotoSelectActivity activity = (PhotoSelectActivity) ActivityManager.getActivityManager().getActivity(PhotoSelectActivity.class.getName());
if (activity != null) {
activity.takeRefreshGallery(info, true);
}
loadImage(info);
hasForceCrop();
}
}
示例3: takeResult
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void takeResult(PhotoInfo info) {
if (!GalleryFinal.getFunctionConfig().isMutiSelect()) {
mPhotoList.clear();
mSelectPhotoList.clear();
}
mPhotoList.add(0, info);
mSelectPhotoList.add(info);
mPhotoTempMap.put(info.getPhotoId(), new PhotoTempModel(info.getPhotoPath()));
if (!GalleryFinal.getFunctionConfig().isEditPhoto() && mTakePhotoAction) {
resultAction();
} else {
if (GalleryFinal.getFunctionConfig().isEnablePreview()) {
mIvPreView.setVisibility(View.VISIBLE);
}
mPhotoEditListAdapter.notifyDataSetChanged();
PhotoSelectActivity activity = (PhotoSelectActivity) ActivityManager.getActivityManager().getActivity(PhotoSelectActivity.class.getName());
if (activity != null) {
activity.takeRefreshGallery(info, true);
}
loadImage(info);
hasForceCrop();
}
}
示例4: onCreate
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
requestWindowFeature(Window.FEATURE_NO_TITLE);
super.onCreate(savedInstanceState);
ActivityManager.getActivityManager().addActivity(this);
mMediaScanner = new MediaScanner(this);
DisplayMetrics dm = DeviceUtils.getScreenPix(this);
mScreenWidth = dm.widthPixels;
mScreenHeight = dm.heightPixels;
}
示例5: onDestroy
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void onDestroy() {
System.gc();
super.onDestroy();
mMediaScanner.unScanFile();
ActivityManager.getActivityManager().finishActivity(this);
}
示例6: deleteIndex
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
public void deleteIndex(int position, PhotoInfo dPhoto) {
if (dPhoto != null) {
PhotoSelectActivity activity = (PhotoSelectActivity) ActivityManager.getActivityManager().getActivity(PhotoSelectActivity.class.getName());
if (activity != null) {
activity.deleteSelect(dPhoto.getPhotoId());
}
try {
Iterator<Map.Entry<String, PhotoInfo>> entries = mSelectPhotoMap.entrySet().iterator();
while (entries.hasNext()) {
Map.Entry<String, PhotoInfo> entry = entries.next();
if (entry.getValue() != null && entry.getValue().getPhotoId() == dPhoto.getPhotoId()) {
entries.remove();
}
}
} catch (Exception e){}
}
if (mPhotoList.size() == 0) {
mSelectIndex = 0;
mTvEmptyView.setText(R.string.no_photo);
mTvEmptyView.setVisibility(View.VISIBLE);
mIvSourcePhoto.setVisibility(View.GONE);
mIvCropPhoto.setVisibility(View.GONE);
mIvPreView.setVisibility(View.GONE);
} else {
if (position == 0) {
mSelectIndex = 0;
} else if (position == mPhotoList.size()) {
mSelectIndex = position - 1;
} else {
mSelectIndex = position;
}
PhotoInfo photoInfo = mPhotoList.get(mSelectIndex);
loadImage(photoInfo);
}
}
示例7: onCreate
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
requestWindowFeature(Window.FEATURE_NO_TITLE);
super.onCreate(savedInstanceState);
ActivityManager.getActivityManager().addActivity(this);
mMediaScanner = new MediaScanner(this);
DisplayMetrics dm = DeviceUtils.getScreenPix(this);
mScreenWidth = dm.widthPixels;
mScreenHeight = dm.heightPixels;
}
示例8: onDestroy
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void onDestroy() {
super.onDestroy();
if (mMediaScanner != null) {
mMediaScanner.unScanFile();
}
ActivityManager.getActivityManager().finishActivity(this);
}
示例9: finishGalleryFinalPage
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
private void finishGalleryFinalPage() {
ActivityManager.getActivityManager().finishActivity(PhotoEditActivity.class);
ActivityManager.getActivityManager().finishActivity(PhotoSelectActivity.class);
ActivityManager.getActivityManager().finishActivity(PhotoPreviewActivity.class);
Global.mPhotoSelectActivity = null;
System.gc();
}
示例10: deleteIndex
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
public void deleteIndex(int position, PhotoInfo dPhoto) {
if (dPhoto != null) {
PhotoSelectActivity activity = (PhotoSelectActivity) ActivityManager.getActivityManager().getActivity(PhotoSelectActivity.class.getName());
if (activity != null) {
activity.deleteSelect(dPhoto.getPhotoId());
}
try {
for(Iterator<PhotoInfo> iterator = mSelectPhotoList.iterator();iterator.hasNext();){
PhotoInfo info = iterator.next();
if (info != null && info.getPhotoId() == dPhoto.getPhotoId()) {
iterator.remove();
break;
}
}
} catch (Exception e){}
}
if (mPhotoList.size() == 0) {
mSelectIndex = 0;
mTvEmptyView.setText(R.string.no_photo);
mTvEmptyView.setVisibility(View.VISIBLE);
mIvSourcePhoto.setVisibility(View.GONE);
mIvCropPhoto.setVisibility(View.GONE);
mIvPreView.setVisibility(View.GONE);
} else {
if (position == 0) {
mSelectIndex = 0;
} else if (position == mPhotoList.size()) {
mSelectIndex = position - 1;
} else {
mSelectIndex = position;
}
PhotoInfo photoInfo = mPhotoList.get(mSelectIndex);
loadImage(photoInfo);
}
}
示例11: finishGalleryFinalPage
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
private void finishGalleryFinalPage() {
ActivityManager.getActivityManager().finishActivity(PhotoEditActivity.class);
ActivityManager.getActivityManager().finishActivity(PhotoSelectActivity.class);
}
示例12: finishGalleryFinalPage
import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
private void finishGalleryFinalPage() {
ActivityManager.getActivityManager().finishActivity(PhotoEditActivity.class);
ActivityManager.getActivityManager().finishActivity(PhotoSelectActivity.class);
Global.mPhotoSelectActivity = null;
System.gc();
}