簡體   English   中英

已安裝的APK無法在本地或Play商店上使用

[英]Installed APK not working locally or on Play store

我使用monaca.io IDE的HTML5構建了一個混合Android應用程序。 我上載了在Google Play上成功構建的發行版,但是當我從商店安裝它時無法正常工作,並且在小部件上找不到該應用程序圖標,但是該應用程序已安裝。 當我從硬盤上安裝應用程序時,也會發生這種情況。 我不知道是什么問題

<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:hardwareAccelerated="true" android:versionCode="" android:versionName="1.0.0" android:windowSoftInputMode="adjustPan" package="com.notechsoft.petsbook">
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:resizeable="true" android:smallScreens="true" android:xlargeScreens="true"/>
<uses-permission android:name="android.permission.INTERNET"/>

<application android:hardwareAccelerated="true" android:icon="@drawable/icon" android:label="Pets-Book">
<activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale" android:label="Pets-Book" android:name="MainActivity" android:theme="@android:style/Theme.Black.NoTitleBar">
 <intent-filter>
    <action android:name="android.intent.action.MAIN"/>
    <data android:scheme="tel"/>
  </intent-filter>
</activity>
</application>
<uses-sdk android:minSdkVersion="10" android:targetSdkVersion="19"/>
</manifest>

您需要向AndroidManifest.xml添加另一個Intent過濾器

這是新的AndroidManifest.xml的樣子:

<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:hardwareAccelerated="true" android:versionCode="" android:versionName="1.0.0" android:windowSoftInputMode="adjustPan" package="com.notechsoft.petsbook">
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:resizeable="true" android:smallScreens="true" android:xlargeScreens="true"/>
<uses-permission android:name="android.permission.INTERNET"/>

<application android:hardwareAccelerated="true" android:icon="@drawable/icon" android:label="Pets-Book">
<activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale" android:label="Pets-Book" android:name="MainActivity" android:theme="@android:style/Theme.Black.NoTitleBar">
 <intent-filter>
    <action android:name="android.intent.action.MAIN"/>
    <category android:name="android.intent.category.LAUNCHER" />
    <data android:scheme="tel"/>
  </intent-filter>
</activity>
</application>
<uses-sdk android:minSdkVersion="10" android:targetSdkVersion="19"/>
</manifest>

我基本上在意圖過濾器中添加了<category android:name="android.intent.category.LAUNCHER" />行。 使用此清單重新編譯,這將在應用程序抽屜中獲得您應用程序的圖標。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM