做任何你知道一个Android应用程序使用Adobe Flash可以访问硬件API的设备上内置的方法?
Do any of you know a method that an Android application built using Adobe Flash can access hardware API on the device?
例如,我启动Flash CS5和创建Android应用程序一个新的空气。该应用程序只包含一个按钮。当该按钮为pressed器件切换的无线。这很容易,只需创建一个wifiManager做Java的:
For example, I launch Flash CS5 and create a new AIR for Android application. The application consists only of a button. When that button is pressed the wireless on the device toggles. This is easy to do in Java by just creating a wifiManager:
WifiManager wifiManager = (WifiManager)this.getSystemService(Context.WIFI_SERVICE); wifiManager.setWifiEnabled(true/false);
但是,你会怎么做,在AIR应用程序?它甚至有可能?
But how would you do it in an AIR application? Is it even possible?
谢谢!
推荐答案不,你不能从AIR访问本机API。
No you can't access native API from AIR.
但是,如果你真的想要有一个黑客做到这一点...
But if you really want it there's a hack to do this ...
更多推荐
Android的硬件和Adobe AIR
发布评论