/// <summary> /// Is executed when subscriber (viewmodel) sends an Xml layout string /// notification that wants to receive the load <seealso cref="LoadLayoutEvent"/>. /// /// Save layout is triggered by the containing window onClosed event. /// </summary> /// <param name="args"></param> public void OnLoadLayout(object sender, LoadLayoutEventArgs args) { if (args == null) { return; } if (string.IsNullOrEmpty(args.XmlLayout)) { return; } _mOnLoadXmlLayout = args.XmlLayout; if (_mDockManager == null) { return; } LoadXmlLayout(_mOnLoadXmlLayout); }
/// <summary> /// Is executed when PRISM sends an Xml layout string notification /// via a sender which could be a viewmodel that wants to receive /// the load the <seealso cref="LoadLayoutEvent"/>. /// /// Save layout is triggered by the containing window onClosed event. /// </summary> /// <param name="args"></param> public void OnLoadLayout(LoadLayoutEventArgs args) { if (args == null) { return; } if (string.IsNullOrEmpty(args.XmlLayout) == true) { return; } this.mOnLoadXmlLayout = args.XmlLayout; if (this.mDockManager == null) { return; } this.LoadXmlLayout(this.mOnLoadXmlLayout); }