private void LoadMaps() { mapManager_ = new MapManager(); roomTreeView.Nodes.Clear(); // Set up room list roomTreeView.BeginUpdate(); int subsection = 0; foreach (MapManager.Area area in mapManager_.MapAreas) { var areaName = "Area " + StringUtil.AsStringHex2(area.Index); var areaKey = new Tuple <int, int>(area.Index, -1); if (Project.Instance.roomNames.ContainsKey(areaKey)) { areaName = Project.Instance.roomNames[areaKey]; } var areaNode = roomTreeView.Nodes.Add(areaName); areaNode.Name = StringUtil.AsStringHex(area.Index, 1); foreach (Room room in area.Rooms) { var roomName = "Room " + StringUtil.AsStringHex2(room.Index); var roomKey = new Tuple <int, int>(area.Index, room.Index); if (Project.Instance.roomNames.ContainsKey(roomKey)) { roomName = Project.Instance.roomNames[roomKey]; } var roomNode = areaNode.Nodes.Add(roomName); roomNode.Name = StringUtil.AsStringHex(room.Index, 1); } subsection++; } roomTreeView.EndUpdate(); }