正在评估是否和如何建立一个合作框架。 该网络的企业应用可以安装在安乐器上。 视窗移动电话的应用程序以千丝万.的方式运行,在接线后,申请自动启动全部屏幕上,用户不能意外或自愿地进入电话的任何其他部分。
www.un.org/Depts/DGACM/index_spanish.htm 是否在安乐斯,在boot后只有一次自动启动申请,防止用户意外(或自愿)进入安乐器的任何其他部分?
正在评估是否和如何建立一个合作框架。 该网络的企业应用可以安装在安乐器上。 视窗移动电话的应用程序以千丝万.的方式运行,在接线后,申请自动启动全部屏幕上,用户不能意外或自愿地进入电话的任何其他部分。
www.un.org/Depts/DGACM/index_spanish.htm 是否在安乐斯,在boot后只有一次自动启动申请,防止用户意外(或自愿)进入安乐器的任何其他部分?
可以通过倾听广播台的<代码>android.intent.action.BOOT_COMPLETED意向,从那里开始活动,使申请站自动启动。 在这项活动中,你可以将采购处登记为新的缺省房屋屏幕?
我认为,在某些情况下,你可以在不修改框架的情况下处理(例如,在家中用长期压力表示目前积极的申请),但我也会被错。
但是,对于一个足够原型而言。
Have!
***
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.HOME" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
在新的《圣经》审查中,谷歌宣布了Task Locking, 确实如此。 但这似乎需要根基。
The L Developer Preview introduces a new task locking API that lets you temporarily restrict users from leaving your app or being interrupted by notifications. This could be used, for example, if you are developing an education app to support high stakes assessment requirements on Android. Once your app activates this mode, users will not be able to see notifications, access other apps, or return to the Home screen, until your app exits the mode.
To prevent unauthorized usage, only authorized apps can activate task locking. Furthermore, task locking authorization must be granted by a specially-configured device owner app, through the
android.app.admin.DevicePolicyManager.setLockTaskComponents()
method.建立装置所有人,遵循这些步骤:
- Attach a device running an Android
userdebug
build to your development machine.- Install your device owner app.
- Create a
device_owner.xml
file and save it to the/data/system
directory on the device.
$ adb root
$ adb shell stop
$ rm /tmp/device_owner.xml
$ echo "<?xml version= 1.0 encoding= utf-8 standalone= yes ?>" >> /tmp/device_owner.xml
$ echo "&device-owner package="<your_device_owner_package>" name="*<your_organization_name>" />" >> /tmp/device_owner.xml
$ adb push /tmp/device_owner.xml /data/system/device_owner.xml
$ adb reboot
Before using the task locking API in your app, verify that your activity is authorized by calling DevicePolicyManager.isLockTaskPermitted().
To activate task locking, call
android.app.Activity.startLockTask()
from your authorized activity.在执行任务时,采取下列行动:
- The status bar is blank, and user notifications and status information is hidden.
- The Home and Recent Apps buttons are hidden.
- Other apps may not launch new activities.
- The current app may start new activities, as long as doing so does not create new tasks.
- The user remains locked on your app until an authorized activity calls
Activity.stopLockTask()
.
页: 1
我在寻求这一点后,便提出了一个很好的解决办法。 但我猜测,如果仅仅为了这一目的,就把它根植起来就是一个问题。
添加如下内容,使发射国申请成为发射国
<category android:name="android.intent.category.HOME" />
目 录
• 确保您的 app倒成为工具,使你无法达到通知要求,见。 http://blog.vogella.com
然后,停止任何其它方案,不误开门,使用无障碍服务来检查温得克邦的变换情况,将一揽子计划与白人或黑人名单进行比较,并利用活动管理。 如果 t倒,杀人过程就会发生。
还检查http://thebitplague.wordpress.com/04/05/kiosk-mode-on-the-nexus7/。 另一种方式
实现这一目的的方法是确定你作为发射者的意愿。
<activity ...
android:launchMode="singleInstance"
android:windowActionBar="false">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.HOME" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
最可靠的方式是使用一种带有Lollipop或更大程度的装置,并利用这种装置。
startLockTask
首先,你们必须把自己的东西作为装置所有人。 贵重装置必须不预设:如果你登记,你就应进行工厂重建,并加快账户登记。
您必须首先建立感化器部件。
package com.example.myapp;
public class MyDeviceAdminReceiver extends android.app.admin.DeviceAdminReceiver {
@Override
public void onEnabled(Context context, Intent intent) {
Toast.makeText(context, "Device admin permission received", Toast.LENGTH_SHORT).show();
}
@Override
public CharSequence onDisableRequested(Context context, Intent intent) {
return "are you sure?";
}
@Override
public void onDisabled(Context context, Intent intent) {
Toast.makeText(context, "Device admin permission revoked", Toast.LENGTH_SHORT).show();
}
@Override
public void onLockTaskModeExiting(Context context, Intent intent) {
// here you must re-lock your app. make your activity know of this event and make it call startLockTask again!
}
}
一旦有了未经预想的装置,你就可以从旁边发射以下指挥器(no fundamental required)。
adb shell dpm set-device-owner com.example.myapp/.MyDeviceAdminReceiver
to avoid android asking the user permissions to pin your app you must call setLockTaskPackages
最后!
@Override
public void onResume(){
super.onResume();
DevicePolicyManager mDevicePolicyManager = (DevicePolicyManager) getSystemService(
Context.DEVICE_POLICY_SERVICE);
ComponentName mAdminComponentName = new ComponentName(getApplicationContext(), MyDeviceAdminReceiver.class);
mDevicePolicyManager.setLockTaskPackages(mAdminComponentName, new String[]{getPackageName()});
startLockTask();
}
@Override
public void finish(){
stopLockTask();
super.finish();
}
谷歌最近发行了Android Management AP,该软件允许方便地为任何有色人种的 Android装置安装Kiosk模式,并制定了其他各种政策。
rel=“nofollow> 安装单一波束装置()和甲状腺开发商已经描述了你可以轻易从那里获得更多东西。
现在很容易将Android 6.0 marmallow和作为公司拥有的单一用途装置。
http://www.basic4ppc.com/forum/basic4android-started-tutorials/10839-android-kiosk-mode-tutorial.html“rel=“nofollow”>forum post。 指定该员额:
Using the following methods you can build an application that will prevent "regular" users from playing with anything other than your application.
The application is made of two modules. The main activity and a service. The service is configured to start at boot. When the service is started it checks if the activity is running or not. If it is not running it uses a timer to start the main activity.
When the activity is paused it schedules the service to start in one second: Code:
Sub Activity_Pause (UserClosed As Boolean)
If kiosk Then StartServiceAt(KioskService, DateTime.Now + 1 * DateTime.TicksPerSecond, false)
End Sub
If the user presses on the home screen, the home screen will appear for several seconds. However your application will return to the front after a few seconds and the user will not be able to interact with any other applications or change the settings.
The service is set to be a foreground service. This prevents Android from killing our service. Press on the Stop button to deactivate kiosk mode.
http://www.basic4ppc.com/android/forum/attachments/kiosk-zip.17108/“rel=“nofollow”>example kiosk-modecode ZIP 也可下载。
www.un.org/Depts/DGACM/index_spanish.htm 具有框架的可做到这一点。 它需要根基,而且有可能在每一个平台和所有平台上赢得工作。 参看<<>可拆卸(>)类方法android.app.Status BarManager。
Look here on how to write your own module: Xposed development tutorial
这比你当初想象的要容易得多。 Good Luck!
加上与一个BOOT接收器和共同申请 这一解决办法是防止地位的扩大的。
位于贵岛:
final View view = (View) findViewById(android.R.id.content);
if (view != null) {
//"hides" back, home and return button on screen.
view.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LOW_PROFILE |
View.SYSTEM_UI_FLAG_HIDE_NAVIGATION |
View.SYSTEM_UI_FLAG_IMMERSIVE |
View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY |
View.SYSTEM_UI_FLAG_FULLSCREEN);
view.setOnSystemUiVisibilityChangeListener
(new View.OnSystemUiVisibilityChangeListener() {
@Override
public void onSystemUiVisibilityChange(int visibility) {
// Note that system bars will only be "visible" if none of the
// LOW_PROFILE, HIDE_NAVIGATION, or FULLSCREEN flags are set.
if ((visibility & View.SYSTEM_UI_FLAG_FULLSCREEN) == 0) {
view.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LOW_PROFILE |
View.SYSTEM_UI_FLAG_HIDE_NAVIGATION |
View.SYSTEM_UI_FLAG_IMMERSIVE |
View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY |
View.SYSTEM_UI_FLAG_FULLSCREEN);
}
}
});
}
这将完全掩盖背纽州、 app和 home。
当你转而使用一种roid器时,基斯克模式只是锁定一种或一套应用。 可以通过锁定任务模式做到这一点。 当装置以锁定任务方式运行时,使用者通常不能看到通知、接触非清单的器具或返回家庭屏幕。
装置政策控制员可以把系统处于锁定任务模式时能够操作的器具划出。 由于其专用装置,使用该装置的人可以放弃锁定任务模式。 Android5级以上的装置可以锁定任务。
• Whitelisting the applications
First step is to whitelist the application by DPC. DPC can whitelist the apps which can be used in lock task mode by calling
避孕器具
▪ Start lock task mode
一旦完成白色名单,排雷中心就可把以下职能称为24小时任务。
活动选择.setLockTaskEnabled()
您可以找到更多有关24小时工作模式的细节:https://developer.android.com/work/dpc/dedicated-devices/lock-task-mode。
I m relatively new to Android development. I m developing an app with a ListView. I ve followed the info in #1338475 and have my app recognizing the fling gesture, but after the gesture is complete, ...
I m converting my code from using Handler to AsyncTask. The latter is great at what it does - asynchronous updates and handling of results in the main UI thread. What s unclear to me is how to handle ...
I want to be able to download a file with a particular extension from the net, and have it passed to my application to deal with it, but I haven t been able to figure out the intent filter. The ...
I am quite impressed by the workflow I follow when developing Android applications: Define a layout in an xml file and then write all the code in a code-behind style. Is there an equivalent style for ...
To draw landscapes, backgrounds with patterns etc, we used TiledLayer in J2ME. Is there an android counterpart for that. Does android provide an option to set such tiled patterns in the layout XML?
When following the Android Open Source Project instructions on installing repo for use with Git, after running the repo init command, I run into this error: /c/Users/Andrew Rabon/bin/repo: line ...
I read in the Android documentation that by setting my Activity s launchMode property to singleTop OR by adding the FLAG_ACTIVITY_SINGLE_TOP flag to my Intent, that calling startActivity(intent) would ...
I have pretty good skills in PHP , Mysql and Javascript for a junior developer. If I wanted to try my hand as Android Development do you think I might find it tough ? Also what new languages would I ...