Пример #1
0
 private void ListView_SelectedIndexChanged(object sender, EventArgs e)
 {
     activePalette = this;
     if (ItemListView.SelectedItems.Count > 0)
     {
         selectedBrush = (Brush)ItemListView.SelectedItems[0].Tag;
         UpdateEditor();
     }
 }
Пример #2
0
        private void brushClick(object sender, MouseEventArgs e)
        {
            activePalette = this;
            if (selectedPanelBrush != null)
            {
                selectedPanelBrush.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            }
            selectedPanelBrush             = (Panel)sender;
            selectedPanelBrush.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            selectedBrush = (Brush)selectedPanelBrush.Tag;


            UpdateEditor();
            UpdateDoodadBrush();
        }
Пример #3
0
        public static void JumpToItem()
        {
            FindItemForm form = new FindItemForm();

            form.Text = "Jump to Item";
            List <Brush> listBrush = new List <Brush>();

            foreach (TileSet tileSet in Materials.getInstance().getTileSetList())
            {
                TilesetCategory rawTc = tileSet.getCategory2(TilesetCategoryType.TILESET_RAW);
                if (rawTc != null)
                {
                    listBrush.AddRange(rawTc.brushlist);
                }
            }
            form.setBrushList(listBrush);
            form.ShowDialog();
            if (form.DialogResult == DialogResult.OK)
            {
                EditorPalette.SelectBrush(form.getSelectedBrush(), PaletteType.RAW);
            }
        }
Пример #4
0
 private void EditorPalette_Enter(object sender, EventArgs e)
 {
     activePalette = this;
 }