我正在尝试在我的应用程序中使用ParseUI。我导入了所有必要的库,并使构建工作,甚至RUN工作,但没有任何显示。 这是我的 的的AndroidManifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.techiequickie.bharath.parsetest" >
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.parse.ui.ParseLoginActivity"
android:label="@string/app_name"
android:launchMode="singleTop">
<!-- For more options, see https://www.parse.com/docs/android_guide#ui-login -->
<meta-data
android:name="com.parse.ui.ParseLoginActivity.PARSE_LOGIN_ENABLED"
android:value="true"/>
<meta-data
android:name="com.parse.ui.ParseLoginActivity.PARSE_LOGIN_EMAIL_AS_USERNAME"
android:value="true"/>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:label="@string/app_name" >
</activity>
<activity
android:name=".Login_activity"
android:label="@string/title_activity_login_activity">
</activity>
<activity
android:name=".HomePage"
android:label="@string/title_activity_home_page" >
</activity>
<activity
android:name=".PlaceBet"
android:label="@string/title_activity_place_bet" >
</activity>
<activity
android:name=".NewBet"
android:label="@string/title_activity_new_bet" >
</activity>
<activity
android:name=".Account"
android:label="@string/title_activity_account" >
</activity>
<activity
android:name=".Listbets"
android:label="@string/title_activity_listbets" >
</activity>
</application>
</manifest>
如您所见,我希望登录活动成为开始活动。这是具有ParseUI登录代码的活动
LoginActivity
package com.techiequickie.bharath.parsetest;
import android.app.Activity;
import android.os.Bundle;
import com.parse.ui.ParseLoginBuilder;
public class Login_activity extends Activity //implements Validator.ValidationListener
{
@Override
protected void onCreate(Bundle savedInstanceState) {
//
super.onCreate(savedInstanceState);
ParseLoginBuilder builder = new ParseLoginBuilder(Login_activity.this);
startActivityForResult(builder.build(), 0);
}
}
当我跑步时,没有活动弹出
04-27 19:53:18.423: I/ActivityManager(764): START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 cmp=com.techiequickie.bharath.parsetest/.MainActivity} from pid 4741
04-27 19:53:18.423: W/ActivityManager(764): Permission Denial: starting Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 cmp=com.techiequickie.bharath.parsetest/.MainActivity } from null (pid=4741, uid=2000) not exported from uid 10325
完成后
我正在等待调试器错误
答案 0 :(得分:-1)
将此添加到AndroidManifest.xml文件中的LAUNCHER活动
bc
答案 1 :(得分:-1)
在AndroidManifest.xml中的activity标记中添加它,并相应地从LoginActivity中删除它。
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
您的活动将如下所示:
<activity
android:name="com.parse.ui.ParseLoginActivity"
android:label="@string/app_name"
android:launchMode="singleTop">
<!-- For more options, see https://www.parse.com/docs/android_guide#ui-login -->
<meta-data
android:name="com.parse.ui.ParseLoginActivity.PARSE_LOGIN_ENABLED"
android:value="true"/>
<meta-data
android:name="com.parse.ui.ParseLoginActivity.PARSE_LOGIN_EMAIL_AS_USERNAME"
android:value="true"/>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>