Ene*_*oma 37 iphone android windows-phone-7
我见过很多手机应用只是打开一个没有控件的网页.只是页面.
我正在寻找指导和链接,以开始这样简单的事情.
San*_*ich 16
如果您想在Android中包装一个网站,您可以使用此代码从Roskvist获取
package com.webview;
import android.app.Activity;
import android.os.Bundle;
import android.view.Window;
import android.webkit.WebView;
public class WebViewTest extends Activity {
WebView browserView;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
//Removes the title bar in the application
requestWindowFeature(Window.FEATURE_NO_TITLE);
setContentView(R.layout.main);
//Creation of the Webview found in the XML Layout file
browserView = (WebView)findViewById(R.id.webkit);
//Enable Javascripts
browserView.getSettings().setJavaScriptEnabled(true);
//Removes both vertical and horizontal scroll bars
browserView.setVerticalScrollBarEnabled(false);
browserView.setHorizontalScrollBarEnabled(false);
//The website which is wrapped to the webview
browserView.loadUrl("http://dev.openlayers.org/sandbox/camptocamp
/mobile/trunk/examples/iol-iui.html?rev=9962#_map");
}
}
Run Code Online (Sandbox Code Playgroud)
这是main.xml的内容
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<WebView
android:id = "@+id/webkit"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
/>
</RelativeLayout>
Run Code Online (Sandbox Code Playgroud)
然后,您必须通过USB编译并将其加载到您的设备.
如果我了解您所要求的内容,则在Windows Phone 7上无法获得Microsoft Marketplace中批准的此类应用程序.Windows Phone应用程序认证要求的第2.10节说:"您的应用程序必须具有独特,实质和合法的内容和目的.您的应用程序必须提供除启动网页之外的功能."
最近我的一位同事因为这个原因拒绝了苹果公司拒绝的类似款式申请.
我认为在这两个平台上,您可能已经能够在过去接受这些类型的应用程序,但不再是.
| 归档时间: |
|
| 查看次数: |
22310 次 |
| 最近记录: |