当前位置: 首页>>代码示例>>Java>>正文


Java ActivityManager类代码示例

本文整理汇总了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);
}
 
开发者ID:YuanPengandy,项目名称:GalleryFinal-master,代码行数:21,代码来源:PhotoEditActivity.java

示例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();
    }
}
 
开发者ID:Liar1995,项目名称:GeneqiaoGallery,代码行数:27,代码来源:PhotoEditActivity.java

示例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();
    }
}
 
开发者ID:pengjianbo,项目名称:GalleryFinal,代码行数:27,代码来源:PhotoEditActivity.java

示例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;
}
 
开发者ID:YuanPengandy,项目名称:GalleryFinal-master,代码行数:11,代码来源:PhotoBaseActivity.java

示例5: onDestroy

import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void onDestroy() {
    System.gc();
    super.onDestroy();
    mMediaScanner.unScanFile();
    ActivityManager.getActivityManager().finishActivity(this);
}
 
开发者ID:YuanPengandy,项目名称:GalleryFinal-master,代码行数:8,代码来源:PhotoBaseActivity.java

示例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);
    }
}
 
开发者ID:YuanPengandy,项目名称:GalleryFinal-master,代码行数:39,代码来源:PhotoEditActivity.java

示例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;

}
 
开发者ID:Liar1995,项目名称:GeneqiaoGallery,代码行数:12,代码来源:PhotoBaseActivity.java

示例8: onDestroy

import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
@Override
protected void onDestroy() {
    super.onDestroy();
    if (mMediaScanner != null) {
        mMediaScanner.unScanFile();
    }
    ActivityManager.getActivityManager().finishActivity(this);
}
 
开发者ID:Liar1995,项目名称:GeneqiaoGallery,代码行数:9,代码来源:PhotoBaseActivity.java

示例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();
}
 
开发者ID:Liar1995,项目名称:GeneqiaoGallery,代码行数:8,代码来源:PhotoBaseActivity.java

示例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);
    }
}
 
开发者ID:pengjianbo,项目名称:GalleryFinal,代码行数:39,代码来源:PhotoEditActivity.java

示例11: finishGalleryFinalPage

import cn.finalteam.toolsfinal.ActivityManager; //导入依赖的package包/类
private void finishGalleryFinalPage() {
    ActivityManager.getActivityManager().finishActivity(PhotoEditActivity.class);
    ActivityManager.getActivityManager().finishActivity(PhotoSelectActivity.class);
}
 
开发者ID:YuanPengandy,项目名称:GalleryFinal-master,代码行数:5,代码来源:PhotoBaseActivity.java

示例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();
}
 
开发者ID:pengjianbo,项目名称:GalleryFinal,代码行数:7,代码来源:PhotoBaseActivity.java


注:本文中的cn.finalteam.toolsfinal.ActivityManager类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。