Android 安卓警报消失

Android 安卓警报消失,android,browser,bitmap,alert,Android,Browser,Bitmap,Alert,我在我的应用程序中发出了警报 在我想做的主要活动中,它是完美的 但我希望它在三次警告之后消失。。不是每次我回到主要活动时,它都会出现 这是我的警报代码 new AlertDialog.Builder( this ) .setTitle( "Browser feature" ) .setMessage( "The browser feature is currently beta, so it won't work perfectly. To get an imag

我在我的应用程序中发出了警报 在我想做的主要活动中,它是完美的 但我希望它在三次警告之后消失。。不是每次我回到主要活动时,它都会出现

这是我的警报代码

        new AlertDialog.Builder( this )
    .setTitle( "Browser feature" )
    .setMessage( "The browser feature is currently beta, so it won't work perfectly. To get an image from the internet, click on the browser then google your image, and save it then import it using the gallery option." )
    .setPositiveButton( "Continue", new DialogInterface.OnClickListener() {
        public void onClick(DialogInterface dialog, int which) {
            Log.d( "AlertDialog", "Positive" );
        }
    })
    .show();

将此人被警告的次数存储为SharedReference。每次更新计数器时,仅当计数器计数小于3时才发出

共享首选项是保存此类全局信息的最佳位置