Exemplo n.º 1
0
		protected override void OnStart ()
		{
			base.OnStart ();

			var intentFilter = new IntentFilter (StockService.StocksUpdatedAction){Priority = (int)IntentFilterPriority.HighPriority};
			RegisterReceiver (stockReceiver, intentFilter);

			stockServiceConnection = new StockServiceConnection (this);
			BindService (stockServiceIntent, stockServiceConnection, Bind.AutoCreate);

			ScheduleStockUpdates ();
		}
Exemplo n.º 2
0
        protected override void OnStart()
        {
            base.OnStart();
            IntentFilter intentFilter = new IntentFilter(StockService.StockUpdatedAction)
            {
                Priority = (int)IntentFilterPriority.HighPriority
            };

            RegisterReceiver(_stockReceiver, intentFilter);
            _stockServiceConnection = new StockServiceConnection(this);
            BindService(_stockServiceIntent, _stockServiceConnection, Bind.AutoCreate);
            ScheduleStockUpdates();
        }