async void OnItemSelected(object sender, SelectedItemChangedEventArgs args)
        {
            var item = args.SelectedItem as SmartMirrorModel;

            if (item == null)
            {
                return;
            }
            var smSvc = App.Container.GetInstance <ISmartMirrorService>();

            // if (smSvc.GetInstance() == null)
            //     return;
            smSvc.SetInstance(item);
            deviceListView.SelectedItem = null;
            SmartMirror selectedMirror = new SmartMirror(item);
            var         _db            = App.Container.GetInstance <IDatabaseProvider>();
            await _db.AddOrUpdateAsync(selectedMirror);

            //await Navigation.PushAsync(new RssFeedsPage());
            MessagingCenter.Send(this, "MirrorSelected", selectedMirror);
        }
 public SmartMirrorModel(SmartMirror sm)
 {
     Id       = sm.Id;
     HostName = sm.HostName;
     IP       = IPAddress.Parse(sm.IpAddress);
 }