Exemple #1
0
        // --------------------------------------------------------------------------------------------------
        #region GUI Callbacks

        /// <summary>
        /// Handle the Async Loading
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void StackPanel_LayoutUpdated(object sender, EventArgs e)
        {
            //LimeMsg.Debug("wxPropCtrl_LayoutUpdated -------------");
            if (wxPropCtrl.DataContext is LimeMetadata meta && meta != _Metadata)
            {
                LimePerson.Cancel();

                _Metadata = meta;

                meta.LoadAsync((int)Global.User.PersonAutoDownload);
            }
        }
Exemple #2
0
        // --------------------------------------------------------------------------------------------------
        #region GUI Callbacks

        /// <summary>
        /// Handle the Async Loading
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void ScrollViewer_LayoutUpdated(object sender, EventArgs e)
        {
            if (wxPropCtrl.DataContext is LimeMetadata meta && meta != _Metadata)
            {
                LimePerson.Cancel();

                _Metadata = meta;
                _Metadata.PropertyChangedWeak += Metadata_PropertyChanged;

#if TRACE
                //StopWatch.Stop();
                //var time = StopWatch.Elapsed;
                //LimeMsg.Info("TraceStopWatch", time);
#endif
                // Force to start the Loading of person metadata asynchronously and after the main page has been rendered
                meta.LoadAsync((int)Global.User.PersonAutoDownload);
            }
        }