// Draw the loaded list public override void DrawLoaded(Rect box) { // Setup the layout Rect pos = box; pos.x += ImagePack.innerMargin; pos.y += ImagePack.innerMargin; pos.width -= ImagePack.innerMargin; pos.height = ImagePack.fieldHeight; if (dataRegister.Count <= 0) { pos.y += ImagePack.fieldHeight; ImagePack.DrawLabel (pos.x, pos.y, "You must create a Dialogue before edit it."); return; } // Draw the content database info ImagePack.DrawLabel (pos.x, pos.y, "Dialogue Configuration"); if (newItemCreated) { newItemCreated = false; LoadSelectList(); newSelectedDisplay = displayKeys.Count - 1; } // Draw data Editor if (newSelectedDisplay != selectedDisplay) { selectedDisplay = newSelectedDisplay; int displayKey = displayKeys [selectedDisplay]; editingDisplay = dataRegister [displayKey]; originalDisplay = editingDisplay.Clone(); requestedDisplay = selectedDisplay; } //if (!displayList.showList) { pos.y += ImagePack.fieldHeight; pos.x -= ImagePack.innerMargin; pos.y -= ImagePack.innerMargin; pos.width += ImagePack.innerMargin; DrawEditor (pos, false); pos.y -= ImagePack.fieldHeight; //pos.x += ImagePack.innerMargin; pos.y += ImagePack.innerMargin; pos.width -= ImagePack.innerMargin; //} if (state != State.Loaded) { // Draw combobox pos.width /= 2; pos.x += pos.width; newSelectedDisplay = ImagePack.DrawCombobox (pos, "", selectedDisplay, displayList); //requestedDisplay = newSelectedDisplay; pos.x -= pos.width; pos.width *= 2; } if(requestedDisplay != -1 && requestedDisplay != selectedDisplay) newSelectedDisplay = requestedDisplay; }