Ejemplo n.º 1
0
        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);


            // Set our view from the "main" layout resource
            SetContentView(Resource.Layout.Main);

            FindViewById <Button>(Resource.Id.add_to_cart_btn).Click += (sender, e) => BuyStuff();
            FindViewById <Button>(Resource.Id.upload_btn).Click      += (sender, e) => Upload();
            Initialize               = FindViewById <Button>(Resource.Id.initialize_btn);
            Initialize.Click        += (sender, e) => Init();
            Login                    = FindViewById <Button>(Resource.Id.login_btn);
            Login.Click             += (sender, e) => SampleCalls.LoginNewUser();
            Login.Visibility         = ViewStates.Invisible;
            Modify                   = FindViewById <Button>(Resource.Id.modify_btn);
            Modify.Click            += (sender, e) => SampleCalls.ModifyUser();
            Modify.Visibility        = ViewStates.Invisible;
            MakeTestCalls            = FindViewById <Button>(Resource.Id.test_calls_btn);
            MakeTestCalls.Visibility = ViewStates.Invisible;
            OptedInButton            = FindViewById <Button>(Resource.Id.opted_in_btn);
            OptedInText              = FindViewById <TextView>(Resource.Id.opted_in_tv);
            OptedInButton.Click     += (sender, e) =>
            {
                optedOut = !optedOut;
                MParticle.Instance.SetOptOut(optedOut);
                OptedInText.Text   = optedOut.ToString();
                OptedInButton.Text = "Opt " + (optedOut ? "Out" : "In");
            };
        }
Ejemplo n.º 2
0
 public void Init()
 {
     SampleCalls.Init();
     MakeTestCalls.Visibility = ViewStates.Visible;
     Modify.Visibility        = ViewStates.Visible;
     Login.Visibility         = ViewStates.Visible;
     Initialize.Visibility    = ViewStates.Gone;
 }
Ejemplo n.º 3
0
        public App()
        {
            InitializeComponent();

            SampleCalls.Init();

            MainPage = new mParticle_Xamarin_Forms_SamplePage();
        }
Ejemplo n.º 4
0
        public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
        {
            // Override point for customization after application launch.
            // If not required for your application you can safely delete this method

            SampleCalls.Init();

            return(true);
        }
 public override void ViewDidLoad()
 {
     base.ViewDidLoad();
     SampleCalls.MakeTestCalls();
 }
Ejemplo n.º 6
0
 public void MakeSampleCalls()
 {
     SampleCalls.MakeTestCalls();
 }
Ejemplo n.º 7
0
 public override void OnCreate()
 {
     base.OnCreate();
     SampleCalls.Init();
 }
Ejemplo n.º 8
0
 protected override void OnStart()
 {
     SampleCalls.MakeTestCalls();
 }