Here is my Manifest:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="net.clmitchell.ewtraker"
android:versionCode="1"
android:versionName="1.0"
android:installLocation="auto" >
<uses-sdk
android:minSdkVersion="11"
android:targetSdkVersion="17"
android:maxSdkVersion="17" />
<supports-screens android:resizeable="true"
android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:xlargeScreens="true"
android:anyDensity="true"
android:requiresSmallestWidthDp="320" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:allowBackup="true"
android:icon="#drawable/ic_launcher"
android:label="#string/app_name"
android:theme="#style/Theme.Sherlock">
<activity
android:name=".ActSplash"
android:label="#string/title_act_splash" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".pSectors.ActSectors"
android:label="#string/title_act_sectors" />
<activity
android:name=".ActDBMaint"
android:label="#string/title_act_dbmaint" />
<activity
android:name=".pSectors.ActSectorDetail"
android:label="#string/title_act_sectord" />
<activity
android:name=".pAlliances.ActAlliances"
android:label="#string/title_act_alliances" />
<activity
android:name=".pAlliances.ActDlgAddAllc"
android:label="#string/title_act_addallc" />
<activity
android:name=".pAlliances.ActAllianceDetail"
android:label="#string/title_act_allianced" />
<activity
android:name=".pPlayers.FrgActPlayers"
android:label="#string/title_act_players" />
<activity
android:name=".pPlayers.ActDlgAddPlyr"
android:label="#string/title_act_addplyr" />
<activity
android:name=".pPlayers.FrgActPlyrDtl"
android:label="#string/title_act_plyrd" />
<activity
android:name=".pBases.FrgActBases"
android:label="#string/title_act_bases" />
<activity
android:name=".pBases.ActDlgAddBase"
android:label="#string/title_act_addbase" />
<activity
android:name=".pBases.FrgActBaseDtl"
android:label="#string/title_act_based" />
<activity
android:name=".pBases.ActPlyrBases"
android:label="#string/title_act_pbases" />
<activity
android:name=".ActDropBox"
android:label="#string/title_act_dbox" />
<activity android:name="com.dropbox.sync.android.DbxAuthActivity" />
<activity
android:name="com.dropbox.client2.android.AuthActivity"
android:launchMode="singleTask" >
<intent-filter>
<data android:scheme="db-1njkuxldz7m7g4j" />
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<service
android:name="com.dropbox.sync.android.DbxSyncService"
android:enabled="true"
android:exported="false"
android:label="Dropbox Sync" />
<service
android:name=".CtlSplash"
android:exported="false"/>
<service
android:name=".pSectors.CtlSectors"
android:exported="false"/>
<service
android:name=".pAlliances.CtlAlliances"
android:exported="false"/>
<service
android:name=".pPlayers.CtlPlayers"
android:exported="false"/>
<service
android:name=".pBases.CtlBases"
android:exported="false"/>
</application>
</manifest>
I was in the act of setting up DropBox support when i noticed that my first two Activities (ActSectors & ActSectorDetail) were no longer responding to the menu item that loads the activity ActDBMaint. My app is VERY SQLite-intensive, so i suspect that the added entries for DropBox in the Manifest may be causing some trouble.
Here's the Logcat from the moment the menu item for ActDBMaint is pressed:
04-02 12:52:09.195: E/SurfaceFlinger(37): ro.sf.lcd_density must be defined as a build property
04-02 12:52:09.225: W/EGL_emulation(795): eglSurfaceAttrib not implemented
04-02 12:52:11.935: W/InputMethodManagerService(288): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy#40dc0508 attribute=null, token = android.os.BinderProxy#40f06190
I've read the following articles; but I fail to see how they apply to my app.
I'm a noob at Android programming, so I would appreciate some advice.
Thanks!
It turns out that the ids/names of the menu items (the menu xml entry and the listing in the activities' onOptionsItemSelected()) didn't match!
I noticed that these two Activities are the only ones in the package 'pSectors'. Did you by chance move the actual classes to a different package?
Related
So I need to integrate unity with android feature like connect to 3rd party app.
So I made .apk build after working at eclipse, but how to integrate between 2 AndroidManifest files?
First reference one is,
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.mygame.plugin"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="21" />
<application
android:allowBackup="true"
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" >
<activity
android:name=".MainActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<data android:scheme="ka67492508561297" />
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity android:name="com.kakao.unity.plugin.ThirdPartyPostStoryActivity" android:windowSoftInputMode="stateAlwaysVisible" android:theme="#android:style/Theme.Translucent.NoTitleBar"/>
</application>
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
and the main one my game currently uses is
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.mygame.mygame1"
android:installLocation="preferExternal"
android:theme="#android:style/Theme.NoTitleBar"
android:versionCode="2"
android:versionName="1.01">
<supports-screens
android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:xlargeScreens="true"
android:anyDensity="true"/>
<uses-sdk
android:minSdkVersion="9"
android:targetSdkVersion="22" />
<application
android:allowBackup="true"
android:icon="#drawable/app_icon"
android:label="#string/app_name">
<meta-data android:name="com.google.android.gms.version" android:value="#integer/google_play_services_version"/>
<activity
android:name=".MainActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<data android:scheme="ka7492508561297" />
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity android:name="com.unity3d.player.UnityPlayerProxyActivity"
android:launchMode="singleTask"
android:label="#string/app_name"
android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen">
<meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="true" />
</activity>
<activity android:name="com.unity3d.player.UnityPlayerActivity"
android:launchMode="singleTask"
android:label="#string/app_name"
android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen">
</activity>
<activity android:name="com.unity3d.player.UnityPlayerNativeActivity"
android:launchMode="singleTask"
android:label="#string/app_name"
android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen">
<meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="true" />
</activity>
<activity android:name="org.onepf.openiab.UnityProxyActivity"
android:launchMode="singleTask"
android:label="#string/app_name"
android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen">
</activity>
<activity android:name="com.google.android.gms.ads.AdActivity"
android:label="#string/app_name"
android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen">
</activity>
<activity android:name="com.ka.unity.plugin.ThirdPartyPostStoryActivity" android:windowSoftInputMode="stateAlwaysVisible" android:theme="#android:style/Theme.Translucent.NoTitleBar"/>
</application>
<uses-permission android:name="com.android.vending.BILLING"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="com.sec.android.iap.permission.BILLING"/>
<uses-permission android:name="org.onepf.openiab.permission.BILLING"/>
So I merged reference one to my main one like above,
But error says,
[UnityException: Unable to start activity!
No activity in the manifest with action MAIN and category LAUNCHER. Try launching the application manually on the device.]
I still can make .apk file, and can run on my phone, but can't connect to 3rd party app when in-game button touched that should launch connection.
So strange... how should I fix?
Thanks.
I'm developing a simple Android app on PhoneGap where the users can calculate their GPA's and CGPA's.
I sense something strange happening. Whenever the user tilts the screen and shifts from portrait to landscape mode, the app goes back to the previous page as if the back button was pressed.
This is how my manifest file looks,
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.firstVersion"
android:versionCode="3"
android:versionName="1.2" >
<uses-sdk
android:minSdkVersion="4"
android:targetSdkVersion="17" />
<supports-screens
android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true"
android:xlargeScreens="true"
android:resizeable="true"
android:anyDensity="true"
/>
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<application
android:configChanges="orientation|keyboardHidden"
android:allowBackup="true"
android:icon="#drawable/app_icon"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<activity
android:name="com.example.firstVersion.MainActivity"
android:label="#string/app_name" >
android:launchMode="singleTop"
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="org.apache.cordova.DroidGap"
android:label="#string/app_name"
android:configChanges="orientation|keyboardHidden">
<intent-filter></intent-filter>
</activity>
<receiver android:name="com.phonegap.plugin.localnotification.AlarmReceiver" >
</receiver>
<receiver android:name="com.phonegap.plugin.localnotification.AlarmRestoreOnBoot" >
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name="com.bicrement.plugins.localNotification.AlarmReceiver" >
</receiver>
<receiver android:name="com.bicrement.plugins.localNotification.AlarmRestoreOnBoot" >
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
</application>
</manifest>
Add android:configChanges under each activity tag not in application tag as you written in application tag and skip it to MainActivity tag
Try This:-
<activity
android:name="com.example.firstVersion.MainActivity"
android:configChanges="orientation|screenSize|keyboardHidden|keyboard|locale"
android:label="#string/app_name">
I am trying to fix the issue for hours but I couldn't. The app is not launching activity I mentioned in the manifest, see following
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="green.thumbup"
android:versionCode="1"
android:versionName="1.1" >
<uses-sdk
android:minSdkVersion="12"
android:targetSdkVersion="17" />
<uses-feature
android:glEsVersion="0x00020000"
android:required="true" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<permission
android:name="green.thumbup.permission.MAPS_RECEIVE"
android:protectionLevel="signature" />
<supports-screens android:anyDensity="true" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION" />
<application
android:icon="#drawable/app_icon"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<meta-data
android:name="com.google.android.maps.v2.API_KEY"
android:value="" />
<activity android:name=".driver.DriverMap" >
</activity>
<activity android:name=".driver.Journey" >
</activity>
<activity android:name=".journey.PassengerDestination" >
</activity>
<activity android:name=".login.Login" >
</activity>
<activity android:name=".passenger.PassengerDestination" >
</activity>
<activity android:name=".passenger.PassengerInfo" >
</activity>
<activity android:name=".users.RegisterUser" >
</activity>
<activity android:name=".users.UserChoice" >
</activity>
<activity android:name=".driver.ThumbUpGoogleMap" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
ThumbUpGoogleMap is in green.thumbup.driver.ThumbUpGoogleMap package.The application is always launching Loging activity from green.thumbup.login.Login, which is old main activity. Login was launch in the previous build but I completely removed and rebuilding the application.
I tried following but not success
I cleaned the code multiple times
I created a new AVD
I change activity path to android:name="green.thumbup.driver.ThumbUpGoogleMap"
Also tried
This is driving me crazy, any hint, suggestion would be of great help
Please write these two lines with activity declaration. And try to give full name for activity instead of just
.driver.ThumbUpGoogleMap
<activity android:name="green.thumbup.driver.ThumbUpGoogleMap" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
And remove <action android:name="android.intent.action.MAIN" /> from your Main Activity declaration.
Try this
<activity android:name=".driver.ThumbUpGoogleMap" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
EDIT:
If this doesnt solves the issue.. make this 4 lines
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
are used only once in the manifest file between any activity tags
I have a problem whith my application on Google Play. In fact my app it's not compatible with custom rom like miui, custom Ics...
For example I can't download my app from google play with my GS2 on miui and my friend can download it with is GS2 on ICS.
Please help me...
here is my manifest
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.notifyme"
android:versionCode="3"
android:versionName="1.0" >
<supports-screens
android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true"
android:anyDensity="true" />
<uses-sdk android:minSdkVersion="8" />
<permission android:name="com.notifyme.permission.C2D_MESSAGE" android:protectionLevel="signature" />
<uses-permission android:name="com.notifyme.permission.C2D_MESSAGE" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.SOUND" />
<uses-permission android:name="android.permission.LIGHTS" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:icon="#drawable/notifme_icon"
android:label="#string/app_name" >
<activity
android:name=".HomeActivity"
android:label="#string/app_name"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".ConnexionActivity"
android:windowSoftInputMode="stateHidden"
android:theme="#android:style/Theme.NoTitleBar"/>
<activity android:name=".MainActivity"
android:theme="#android:style/Theme.NoTitleBar"/>
<activity android:name=".InscriptionActivity"
android:windowSoftInputMode="stateHidden"
android:theme="#android:style/Theme.NoTitleBar"/>
<receiver
android:name=".ReceiverActivity"
android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter >
<action android:name="com.google.android.c2dm.intent.RECEIVE" > </action>
<category android:name="com.notifyme" />
</intent-filter>
<intent-filter >
<action android:name="com.google.android.c2dm.intent.REGISTRATION" ></action>
<category android:name="com.notifyme" />
</intent-filter>
</receiver>
</application>
thank you
I suspect that the problem lay withing your code. One of your activities might has a method that is supported only since API 13 (e.g. Android 3.2 and above). That's why it can be downloaded for newer version (ICS which is android 4) and not your.
double check your methods to figure that out.
I am currently trying to add a widget to my application and have been basing my implementation on this code http://developer.android.com/resources/samples/StackWidget/index.html
I have put all my stack widget related classes in their own package within my main package.
When I try to add the widget it is unable to bind and hence the cards are not displayed (it just states the default text "This is the empty view")
Below is my manifest.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.bencallis.dealpad" android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="11" android:targetSdkVersion="14" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application android:icon="#drawable/ic_launcher"
android:logo="#drawable/logo" android:theme="#style/DealPadTheme"
android:hardwareAccelerated="true" android:uiOptions="splitActionBarWhenNarrow">
<activity android:label="#string/app_name" android:name=".DealPadActivity"
android:configChanges="keyboardHidden|orientation|screenSize">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".SettingsActivity" />
<activity android:name="com.google.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize" />
<!-- Widgets -->
<receiver android:name=".stackwidget.StackWidgetProvider">
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
</intent-filter>
<meta-data android:name="android.appwidget.provider"
android:resource="#xml/stackwidgetinfo" />
</receiver>
<service android:name="stackwidget.StackWidgetService"
android:permission="android.permission.BIND_REMOTEVIEWS"
android:exported="false" />
</application>
</manifest>
Error message:
E/RemoteViewsAdapterServiceConnection(474): bind(): Unknown component ComponentInfo{com.bencallis.dealpad/com.bencallis.dealpad.stackwidget.StackWidgetService}
I am sure there is a simple mistake somewhere which is making the component info repeat com.bencallis.dealpad.
Any ideas?
It turned out it was to do with my manifest and a problem locating the service. I was missing a . in the name (which gives it the path).
Silly mistake!