Ejemplo n.º 1
0
 public DuckViewModel()
 {
     TinyPubSub.Subscribe(this, "fire", () =>
     {
         // This line should not be fired when the page is navigated away from
         int i = 10;
     });
     TinyPubSubLib.TinyPubSubForms.SubscribeOnMainThread("onmain", (obj) => {
         DuckCount++;
         PropertyChanged(this, new PropertyChangedEventArgs("DockCount"));
     });
 }
Ejemplo n.º 2
0
        public MainViewModel()
        {
            TinyPubSub.Subscribe("fire", () =>
            {
                // Do something here, but nuget was down at the time of writing this code
            });

            TinyPubSub.Subscribe <bool>("firebool", (obj) => {
                _toggleBool = obj;
                TheBool     = _toggleBool;
            });

            TinyPubSubLib.TinyPubSubForms.SubscribeOnMainThread("onmain", (obj) => {
                DuckCount++;
                PropertyChanged(this, new PropertyChangedEventArgs("DuckCount"));
            });
        }
Ejemplo n.º 3
0
 public BillingObserver()
 {
     TinyPubSub.Subscribe(Topics.Orders, (x) => BillOrderCommand(x));
 }
Ejemplo n.º 4
0
 public ShippingObserver()
 {
     TinyPubSub.Subscribe(Topics.Orders, (x) => ShipOrderCommand(x));
 }