Contents

조회 수 2290 댓글 0
Atachment
첨부 '1'
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄

android.jpg



# 내가 썼던 방법

if (android.os.Build.VERSION.SDK_INT > android.os.Build.VERSION_CODES.KITKAT) {
    Intent intent = new Intent();
    intent.setAction("android.settings.APP_NOTIFICATION_SETTINGS");
    intent.addCategory(Intent.CATEGORY_DEFAULT);
    //intent.setData(Uri.parse("package:" + getPackageName()));
    intent.putExtra("app_package", getPackageName());
    intent.putExtra("app_uid", getApplicationInfo().uid);
    intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
    startActivity(intent);
}else{
    String packageName = "com.ncsoft.nccomix";
    String SCHEME = "package";
    String APP_PKG_NAME_21 = "com.android.settings.ApplicationPkgName";
    String APP_PKG_NAME_22 = "pkg";
    String APP_DETAILS_PACKAGE_NAME = "com.android.settings";
    String APP_DETAILS_CLASS_NAME = "com.android.settings.InstalledAppDetails";
    Intent intent = new Intent();
    final int apiLevel = Build.VERSION.SDK_INT;
    if (apiLevel >= 9) { // above 2.3
        intent.setAction(Settings.ACTION_APPLICATION_DETAILS_SETTINGS);
        Uri uri = Uri.fromParts(SCHEME, packageName, null);
        intent.setData(uri);
    } else { // below 2.3
        final String appPkgName = (apiLevel == 8 ? APP_PKG_NAME_22 : APP_PKG_NAME_21);
        intent.setAction(Intent.ACTION_VIEW);
        intent.setClassName(APP_DETAILS_PACKAGE_NAME,
APP_DETAILS_CLASS_NAME);
        intent.putExtra(appPkgName, packageName);
    }
    startActivity(intent);
}


# 참고할 방법 (해보지는 않음 ㅋㅋ)

packageName = "your.package.name.here"

try {
    //Open the specific App Info page:
    Intent intent = new Intent(android.provider.Settings.ACTION_APPLICATION_DETAILS_SETTINGS);
    intent.setData(Uri.parse("package:" + packageName));
    startActivity(intent);

} catch ( ActivityNotFoundException e ) {
    //e.printStackTrace();

    //Open the generic Apps page:
    Intent intent = new Intent(android.provider.Settings.ACTION_MANAGE_APPLICATIONS_SETTINGS);
    startActivity(intent);

}


[참고] http://www.makeuseof.com/tag/stop-annoying-notifications-android/

[참고] http://stackoverflow.com/questions/4421527/how-can-i-start-android-application-info-screen-programmatically


?

  1. ISMS 인증기준 – 정보보호대책 (시스템개발보안)

    Date2016.12.01 CategoryEtc Byhooni Views1505
    Read More
  2. Configure Postfix to Use Gmail SMTP on Ubuntu 18.04

    Date2020.02.07 CategorySystem/OS Byhooni Views1509
    Read More
  3. 모바일 프로그래머가 갖추어야 할 필수 역량

    Date2017.02.16 CategoryEtc Byhooni Views1516
    Read More
  4. [ios] Swift 4 String, Date, DateFormatter 예제

    Date2018.10.18 CategoryDevelop Byhooni Views1519
    Read More
  5. 원어민이 매일 쓰는 일상표현 150개

    Date2023.09.17 CategoryEtc Byhooni Views1520
    Read More
  6. RPA란? 어디에 어떻게 쓰이고 누가 만드나?

    Date2020.01.28 CategorySystem/OS Byhooni Views1523
    Read More
  7. 아이폰의 터치스크린 정확도

    Date2015.04.01 CategoryEtc Byhooni Views1529
    Read More
  8. SSH Passwordless Login Using SSH Keygen in 5 Easy Steps

    Date2019.11.22 CategorySystem/OS Byhooni Views1548
    Read More
  9. How to Install and Use wget on Mac

    Date2020.09.03 CategorySystem/OS Byhooni Views1551
    Read More
  10. What is difference between Get, Post, Put and Delete?

    Date2018.02.28 CategoryDevelop Byhooni Views1576
    Read More
  11. How to Test SMTP AUTH using Telnet

    Date2018.04.05 CategoryDevelop Byhooni Views1594
    Read More
  12. [swift] popToRoot 모달뷰, 네비게이션컨트롤러 한꺼번에 닫기

    Date2021.01.29 CategoryDevelop Byhooni Views1608
    Read More
Board Pagination Prev 1 ... 10 11 12 13 14 15 16 17 18 19 ... 98 Next
/ 98