mirror of
https://github.com/moparisthebest/keepass2android
synced 2024-11-25 18:52:19 -05:00
tests for activity result
This commit is contained in:
parent
b2baa66b71
commit
d3c67d7c5d
@ -34,12 +34,15 @@ namespace ArtTestApp
|
||||
}
|
||||
|
||||
};
|
||||
FindViewById<Button>(Resource.Id.MyButton2).Click += (sender, args) => StartActivityForResult(typeof(Activity2),1);
|
||||
FindViewById<Button>(Resource.Id.MyButton2).Click += (sender, args) =>
|
||||
{
|
||||
Intent i = new Intent("blabla");
|
||||
StartActivityForResult(i, 1);
|
||||
};
|
||||
|
||||
|
||||
FindViewById<Button>(Resource.Id.MyButton3).Click += (sender, args) => StartActivityForResult(typeof(PrefActivity), 1);
|
||||
StartActivity(typeof(Activity2));
|
||||
Finish();
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -5,6 +5,7 @@ using System.Text;
|
||||
|
||||
using Android.App;
|
||||
using Android.Content;
|
||||
using Android.Content.PM;
|
||||
using Android.OS;
|
||||
using Android.Runtime;
|
||||
using Android.Views;
|
||||
@ -12,7 +13,11 @@ using Android.Widget;
|
||||
|
||||
namespace ArtTestApp
|
||||
{
|
||||
[Activity(Label = "My Activity")]
|
||||
[Activity(Label = "Activity2",
|
||||
ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden)]
|
||||
[IntentFilter(new[] { "blabla" },
|
||||
Categories = new[] { Intent.CategoryDefault })]
|
||||
|
||||
public class Activity2 : Activity
|
||||
{
|
||||
protected override void OnCreate(Bundle bundle)
|
||||
|
Loading…
Reference in New Issue
Block a user