Ejemplo n.º 1
0
        public FilesystemBrowser()
        {
            InitializeComponent();

            LanguageManager.ApplyToContainer(this, "FilesystemBrowser");

            UpdateFileInfo();

            //The ImageList is created here rather than in Visual Studio
            //because it looks like the Mono compiler can't handle ImageList resources.
            //So, please don't create ImageLists using the Designer!!

            fileTreeView.ImageList            = new ImageList();
            fileTreeView.ImageList.ColorDepth = ColorDepth.Depth32Bit;

            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.folder_open);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_narc);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_ncg);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_ncl);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_nsc);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_nsbmd);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_nsbtx);
            fileTreeView.ImageList.Images.Add(NSMBe4.Properties.Resources.file_sdat);
        }
Ejemplo n.º 2
0
 public TilemapEditorWindow(Tilemap t)
 {
     InitializeComponent();
     LanguageManager.ApplyToContainer(this, "TilemapEditor");
     this.t = t;
     t.beginEdit();
     tilemapEditor1.showSaveButton();
     tilemapEditor1.load(t);
 }
        public FilesystemBrowserDialog(Filesystem fs)
        {
            InitializeComponent();
            this.MdiParent = MdiParentForm.instance;
            LanguageManager.ApplyToContainer(this, "FilesystemBrowserDialog");

            this.fs = fs;
            filesystemBrowser1.Load(fs);

            this.Icon = Properties.Resources.nsmbe;
        }
Ejemplo n.º 4
0
        public CoordinateViewer()
        {
            InitializeComponent();
            LanguageManager.ApplyToContainer(this, "CoordinateViewer");

            xUpDown.Maximum      = 512 * 16;
            yUpDown.Maximum      = 256 * 16;
            widthUpDown.Minimum  = 1;
            heightUpDown.Minimum = 1;
            widthUpDown.Maximum  = 512 * 16;
            heightUpDown.Maximum = 256 * 16;
        }
Ejemplo n.º 5
0
        public FileHexEditor(File f)
        {
            InitializeComponent();

            this.MdiParent = MdiParentForm.instance;

            this.f = f;
            f.beginEdit(this);

            LanguageManager.ApplyToContainer(this, "FileHexEditor");
            this.Text = string.Format(LanguageManager.Get("FileHexEditor", "_TITLE"), f.name);

            hexBox1.ByteProvider = new DynamicByteProvider(f.getContents());
            this.Icon            = Properties.Resources.nsmbe;
        }
Ejemplo n.º 6
0
 public TilemapEditor()
 {
     InitializeComponent();
     LanguageManager.ApplyToContainer(this, "TilemapEditor");
     buttons = new ToolStripButton[] { drawToolButton, xFlipToolButton, yFlipToolButton, copyToolButton, pasteToolButton, changePalToolButton };
 }
Ejemplo n.º 7
0
        public FilesystemBrowser()
        {
            InitializeComponent();

            LanguageManager.ApplyToContainer(this, "FilesystemBrowser");
            UpdateFileInfo();

            //The ImageList is created here rather than in Visual Studio
            //because it looks like the Mono compiler can't handle ImageList resources.
            //So, please don't create ImageLists using the Designer!!

            fileTreeView.ImageList            = new ImageList();
            fileTreeView.ImageList.ColorDepth = ColorDepth.Depth32Bit;

            for (int i = 0; i < 4; i++)
            {
                List <Bitmap> bitmaps = new List <Bitmap>();

                bitmaps.Add(new Icon(Properties.Resources.folder_open, new Size(16, 16)).ToBitmap());
                bitmaps.Add(new Icon(Properties.Resources.file_unk, new Size(16, 16)).ToBitmap());
                bitmaps.Add(Properties.Resources.file_narc);
                bitmaps.Add(new Icon(Properties.Resources.file_ncg, new Size(16, 16)).ToBitmap());
                bitmaps.Add(Properties.Resources.file_ncl);
                bitmaps.Add(Properties.Resources.file_nsc);
                bitmaps.Add(Properties.Resources.file_nsbmd);
                bitmaps.Add(Properties.Resources.file_nsbtx);
                bitmaps.Add(Properties.Resources.file_sdat);
                bitmaps.Add(Properties.Resources.file_enpg);
                bitmaps.Add(Properties.Resources.file_nsbca);
                bitmaps.Add(Properties.Resources.file_nsbtp);
                bitmaps.Add(Properties.Resources.file_nsbta);
                bitmaps.Add(Properties.Resources.file_nsbma);
                bitmaps.Add(Properties.Resources.file_nsbva);
                bitmaps.Add(new Icon(Properties.Resources.file_txt, new Size(16, 16)).ToBitmap());
                bitmaps.Add(Properties.Resources.file_spa);
                bitmaps.Add(new Icon(Properties.Resources.file_config, new Size(16, 16)).ToBitmap());
                bitmaps.Add(Properties.Resources.file_bnbl);
                bitmaps.Add(Properties.Resources.file_bncl);

                foreach (Bitmap bitmap in bitmaps)
                {
                    Bitmap result = new Bitmap(bitmap, new Size(16, 16));

                    //Add LZ icons
                    Graphics g = Graphics.FromImage(result);
                    if (i == 1)
                    {
                        g.DrawImage(new Bitmap(Properties.Resources.lz_icon, new Size(16, 16)), new Point(0, 0));
                    }
                    else if (i == 2)
                    {
                        g.DrawImage(new Bitmap(Properties.Resources.lz_wh_icon, new Size(16, 16)), new Point(0, 0));
                    }
                    else if (i == 3)
                    {
                        g.DrawImage(new Bitmap(Properties.Resources.yaz0_icon, new Size(16, 16)), new Point(0, 0));
                    }

                    fileTreeView.ImageList.Images.Add(result);
                }
            }
        }