コード例 #1
0
		public void Initialize() {
			this.DataSnapshotSerializer = new Serializer<ExceptionsControlDataSnapshot>(Assembler.InstanceInitialized.StatusReporter);
			bool createdNewFile = this.DataSnapshotSerializer.Initialize(Assembler.InstanceInitialized.AppDataPath,
				"Sq1.Widgets.ExceptionsControlDataSnapshot.json", "Workspaces",
				Assembler.InstanceInitialized.AssemblerDataSnapshot.CurrentWorkspaceName);
			this.DataSnapshot = this.DataSnapshotSerializer.Deserialize();
			if (createdNewFile) {
				this.DataSnapshot.SplitDistanceVertical = this.splitContainerVertical.SplitterDistance;
				this.DataSnapshot.SplitDistanceHorizontal = this.splitContainerHorizontal.SplitterDistance;
				this.DataSnapshotSerializer.Serialize();
			}
		}
コード例 #2
0
        public void Initialize()
        {
            this.DataSnapshotSerializer = new Serializer <ExceptionsControlDataSnapshot>(Assembler.InstanceInitialized.StatusReporter);
            bool createdNewFile = this.DataSnapshotSerializer.Initialize(Assembler.InstanceInitialized.AppDataPath,
                                                                         "Sq1.Widgets.ExceptionsControlDataSnapshot.json", "Workspaces",
                                                                         Assembler.InstanceInitialized.AssemblerDataSnapshot.CurrentWorkspaceName);

            this.DataSnapshot = this.DataSnapshotSerializer.Deserialize();
            if (createdNewFile)
            {
                this.DataSnapshot.SplitDistanceVertical   = this.splitContainerVertical.SplitterDistance;
                this.DataSnapshot.SplitDistanceHorizontal = this.splitContainerHorizontal.SplitterDistance;
                this.DataSnapshotSerializer.Serialize();
            }
        }