Ejemplo n.º 1
1
        private void addToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var dialog = new Ookii.Dialogs.VistaFolderBrowserDialog();
            var result = dialog.ShowDialog();

            if (result == DialogResult.OK)
            {
                repoList.Items.Add(dialog.SelectedPath).SubItems.AddRange(new[] { "s1", "s2", "s3" });
            }

            //var fbd = new FolderBrowserDialog();
            //var newDir = fbd.ShowDialog();

            //// Prepare a dummy string, thos would appear in the dialog
            //string dummyFileName = "Save Here";

            //SaveFileDialog sf = new SaveFileDialog();
            //// Feed the dummy name to the save dialog
            //sf.FileName = dummyFileName;

            //if (sf.ShowDialog() == DialogResult.OK)
            //{
            //    // Now here's our save folder
            //    string savePath = Path.GetDirectoryName(sf.FileName);
            //    // Do whatever
            //}
        }
Ejemplo n.º 2
0
        private void btnOutputFolder_Click(object sender, EventArgs e)
        {
            try
            {
                var dlgOpenFolder = new Ookii.Dialogs.VistaFolderBrowserDialog()
                {
                    UseDescriptionForTitle = true,
                    Description            = "Please select the generated messages output folder",
                    ShowNewFolderButton    = false,
                    RootFolder             = System.Environment.SpecialFolder.MyComputer,
                    //NewStyle = false,
                };
                if (!String.IsNullOrEmpty(myUI.ContactsFile))
                {
                    dlgOpenFolder.SelectedPath = Path.GetDirectoryName(myUI.ContactsFile);
                }

                if (dlgOpenFolder.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                {
                    if (!Directory.Exists(dlgOpenFolder.SelectedPath))
                    {
                        MessageBox.Show(MSG.InvalidFolderPath);
                    }
                    else
                    {
                        myUI.OutputFolder = dlgOpenFolder.SelectedPath;
                    }
                }
            }
            catch (Exception x)
            {
                XLogger.Error(x);
            }
        }
Ejemplo n.º 3
0
 private string AskForFolder(string currentFolder)
 {
     if (Ookii.Dialogs.VistaFolderBrowserDialog.IsVistaFolderDialogSupported)
     {
         var dialog = new Ookii.Dialogs.VistaFolderBrowserDialog();
         dialog.SelectedPath        = currentFolder;
         dialog.ShowNewFolderButton = true;
         var result = dialog.ShowDialog();
         if (result == DialogResult.OK)
         {
             return(dialog.SelectedPath);
         }
     }
     else
     {
         var dialog = new FolderBrowserDialog();
         dialog.SelectedPath        = currentFolder;
         dialog.ShowNewFolderButton = true;
         var result = dialog.ShowDialog();
         if (result == DialogResult.OK)
         {
             return(dialog.SelectedPath);
         }
     }
     return(null);
 }
Ejemplo n.º 4
0
        public async Task LoadProject()
        {
#if PLATFORM_WINDOWS
            string project = null;

            var t = new Thread(new ThreadStart(() =>
            {
                var dialog = new Ookii.Dialogs.VistaFolderBrowserDialog();
                if (dialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                {
                    project = dialog.SelectedPath;
                }
            }));
            t.SetApartmentState(ApartmentState.STA);
            t.IsBackground = true;
            t.Start();

            while (t.IsAlive)
            {
                await Task.Yield();
            }

            _projectManager.LoadProject(project);
#endif
        }
Ejemplo n.º 5
0
        private void modFolderBrowse_Click(object sender, EventArgs e)
        {
            Ookii.Dialogs.VistaFolderBrowserDialog folderDialog = new Ookii.Dialogs.VistaFolderBrowserDialog();

            DialogResult result = folderDialog.ShowDialog();

            if (result == DialogResult.OK)
            {
                modFolder.Text = folderDialog.SelectedPath;
            }
        }
Ejemplo n.º 6
0
            public void Execute(object parameter)
            {
                var preferenciasVM = parameter as PreferenciasViewModel;
                var folderDialog   = new Ookii.Dialogs.VistaFolderBrowserDialog();

                folderDialog.SelectedPath = preferenciasVM.sPastaBlackhole;
                if (folderDialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                {
                    preferenciasVM.sPastaBlackhole = folderDialog.SelectedPath;
                }
            }
Ejemplo n.º 7
0
        /// <summary>
        ///     Opens an Open Folder Dialog, prompting the user to select a folder.
        ///
        ///     Returns the path of the folder that the user chose, or an empty string if the dialog was cancelled.
        /// </summary>
        public static string OpenFolderDialog()
        {
#if !MONO
            using (Ookii.Dialogs.VistaFolderBrowserDialog dlg = new Ookii.Dialogs.VistaFolderBrowserDialog())
#else
            using (FolderBrowserDialog dlg = new FolderBrowserDialog())
#endif
            {
                return(dlg.ShowDialog() == DialogResult.OK ? dlg.SelectedPath : string.Empty);
            }
        }
Ejemplo n.º 8
0
		private void modFolderBrowse_Click(object sender, EventArgs e)
		{
			Ookii.Dialogs.VistaFolderBrowserDialog folderDialog = new Ookii.Dialogs.VistaFolderBrowserDialog();

			DialogResult result = folderDialog.ShowDialog();

			if (result == DialogResult.OK)
			{
				modFolder.Text = folderDialog.SelectedPath;
			}
		}
Ejemplo n.º 9
0
        private void browseButton_Click(object sender, EventArgs e)
        {
            using (Ookii.Dialogs.VistaFolderBrowserDialog dialog = new Ookii.Dialogs.VistaFolderBrowserDialog()) {
                dialog.Description  = "Export Location";
                dialog.SelectedPath = this.exportFolderTextBox.Text;

                if (dialog.ShowDialog() == DialogResult.OK)
                {
                    this.exportFolderTextBox.Text = dialog.SelectedPath;
                }
            }
        }
Ejemplo n.º 10
0
        private void mnuCopiarArchivos_Click(object sender, EventArgs e)
        {
            Ookii.Dialogs.VistaFolderBrowserDialog fbd = new Ookii.Dialogs.VistaFolderBrowserDialog();

            fbd.ShowDialog(this);

            if (Directory.Exists(fbd.SelectedPath))
            {
                RutaCopia = fbd.SelectedPath;

                //Bloquear controles
                Des_HabilitarControles(false);
                pnlEngine.Visible  = true;
                pnlEngine.Enabled  = true;
                pbEngine.Enabled   = true;
                pnlEngine.Location = gbResultados.Location;
                pnlEngine.Size     = gbResultados.Size;
                pnlEngine.BringToFront();

                //Preparar copia
                FechaIni           = DateTime.Now;
                ListaArchivosCopia = new List <ArchivoCopia> {
                };
                ArchivoCopia archivoC = new ArchivoCopia();

                for (int w = 0; w < lstArchivos.Items.Count; w++)
                {
                    if (lstArchivos.Items[w].Checked)
                    {
                        archivoC = new ArchivoCopia(lstArchivos.Items[w].SubItems[cEquipo].Text,
                                                    lstArchivos.Items[w].SubItems[cRuta].Text,
                                                    lstArchivos.Items[w].SubItems[cArchivo].Text,
                                                    lstArchivos.Items[w].SubItems[cUnidad].Text);

                        ListaArchivosCopia.Add(archivoC);
                    }
                }

                pb01.Visible = true;
                pb01.Value   = 0;

                pbFile.Visible = true;
                pbFile.Value   = 0;

                pnlProgreso.Visible = true;

                wkrCopia.RunWorkerAsync();
            }
            else
            {
                MessageBox.Show("El directorio no existe.", "Error al copiar", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
            }
        }
Ejemplo n.º 11
0
 private void OpenGameFolder(string plaformName)
 {
     using (Ookii.Dialogs.VistaFolderBrowserDialog folderDialog = new Ookii.Dialogs.VistaFolderBrowserDialog())
     {
         folderDialog.Description            = $"Select {plaformName} game folder";
         folderDialog.SelectedPath           = Settings.Default.ImportFolderPath;
         folderDialog.UseDescriptionForTitle = true;
         System.Windows.Forms.DialogResult result = folderDialog.ShowDialog();
         if (result == System.Windows.Forms.DialogResult.OK)
         {
         }
     }
 }
            public void Execute(object parameter)
            {
                var adicionarConteudoVm = parameter as AdicionarConteudoViewModel;

                var folderDialog = new Ookii.Dialogs.VistaFolderBrowserDialog
                {
                    SelectedPath = adicionarConteudoVm?.oVideoSelecionado.sDsPasta
                };

                if (folderDialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                {
                    adicionarConteudoVm.oVideoSelecionado.sDsPasta = folderDialog.SelectedPath;
                }
            }
Ejemplo n.º 13
0
        private void changeDirectory_Click(object sender, EventArgs e)
        {
#if !MONO
            Ookii.Dialogs.VistaFolderBrowserDialog fbd = new Ookii.Dialogs.VistaFolderBrowserDialog();
#else
            FolderBrowserDialog fbd = new FolderBrowserDialog();
#endif
            //			fbd.SelectedPath = CurrentDirectory; // Uncomment this if you want the "change directory" dialog to start with the current directory selected
            if (fbd.ShowDialog() == DialogResult.OK)
            {
                Environment.CurrentDirectory = fbd.SelectedPath;
                readDir();
            }
        }
Ejemplo n.º 14
0
        private void OnExportButtonClicked(object sender, RoutedEventArgs e)
        {
            while (true)
            {
                using (Ookii.Dialogs.VistaFolderBrowserDialog folderDialog = new Ookii.Dialogs.VistaFolderBrowserDialog())
                {
                    folderDialog.ShowNewFolderButton    = true;
                    folderDialog.Description            = $"Select export folder. New folder '{GameStructure.Name}' will be created inside selected one";
                    folderDialog.SelectedPath           = Settings.Default.ExportFolderPath;
                    folderDialog.UseDescriptionForTitle = true;
#if VIRTUAL
                    System.Windows.Forms.DialogResult result = System.Windows.Forms.DialogResult.OK;
#else
                    System.Windows.Forms.DialogResult result = folderDialog.ShowDialog();
#endif
                    if (result == System.Windows.Forms.DialogResult.OK)
                    {
                        string path = Path.Combine(folderDialog.SelectedPath, GameStructure.Name);
                        if (File.Exists(path))
                        {
                            MessageBox.Show(this, "Unable to export assets into selected folder. Choose another one.",
                                            "Invalid folder", MessageBoxButton.OK, MessageBoxImage.Warning);
                            continue;
                        }
                        if (Directory.Exists(path))
                        {
                            if (Directory.EnumerateFiles(path).Any())
                            {
                                MessageBoxResult mbresult = MessageBox.Show(this, "There are files inside selected folder. They will be deleted.",
                                                                            "Are you sure?", MessageBoxButton.OKCancel, MessageBoxImage.Warning);
                                if (mbresult == MessageBoxResult.Cancel)
                                {
                                    continue;
                                }
                            }
                        }

                        IntroText.Text                    = "Exporting assets...";
                        ExportButton.Visibility           = Visibility.Hidden;
                        Settings.Default.ExportFolderPath = folderDialog.SelectedPath;
                        Settings.Default.Save();

                        ThreadPool.QueueUserWorkItem(new WaitCallback(ExportFiles), path);
                    }
                }
                break;
            }
        }
Ejemplo n.º 15
0
        private void OutputFolderButton_Click(object sender, RoutedEventArgs e)
        {
            using (Ookii.Dialogs.VistaFolderBrowserDialog dialog = new Ookii.Dialogs.VistaFolderBrowserDialog()
            {
                SelectedPath = outputFolder,
                ShowNewFolderButton = true,
                Description = "Select Output Folder",
                UseDescriptionForTitle = true,
            }) {
                DialogResult result = dialog.ShowDialog();
                outputFolder             = dialog.SelectedPath;
                OutputFolderTextBox.Text = outputFolder;
            }

            CalculateCaptureIndex();
        }
Ejemplo n.º 16
0
        private void VJoyOK_Click()
        {
            // Ookii: drop-in replacement for default dialog
            Ookii.Dialogs.VistaFolderBrowserDialog folderBrowser = new Ookii.Dialogs.VistaFolderBrowserDialog();
            folderBrowser.Description            = "Select vJoy Folder (usually C:\\Program Files\\vJoy)";
            folderBrowser.UseDescriptionForTitle = true;
            folderBrowser.ShowNewFolderButton    = false;

            DialogResult result = folderBrowser.ShowDialog();

            if (!string.IsNullOrWhiteSpace(folderBrowser.SelectedPath))
            {
                Properties.Settings.Default.VJoyDir = folderBrowser.SelectedPath;
                Properties.Settings.Default.Save();
            }
        }
Ejemplo n.º 17
0
        private string ShowFolderDialog(string root)
        {
            var dag = new Ookii.Dialogs.VistaFolderBrowserDialog()
            {
                Description            = "Bitter Verzeichniss wählen.",
                RootFolder             = Environment.SpecialFolder.MyDocuments,
                SelectedPath           = root,
                ShowNewFolderButton    = true,
                UseDescriptionForTitle = true
            };

            if (dag.ShowDialog(this) == DialogResult.OK)
            {
                return(dag.SelectedPath);
            }

            return(root);
        }
Ejemplo n.º 18
0
        private void button3_Click(object sender, EventArgs e)
        {
            var dialog = new Ookii.Dialogs.VistaFolderBrowserDialog();

            dialog.ShowDialog();
            textBox1.Text = dialog.SelectedPath;

            try
            {
                WhichMapsDoIHave(ref idk);
                button2.Enabled = true;
            }
            catch (DirectoryNotFoundException) { }
            for (int i = 0; i < idk.Count; i++)
            {
                idk[i] = idk[i].Split(' ')[0];
                idk[i] = idk[i].Split('\\')[idk[i].Split('\\').Length - 1];
            }
            button1.Enabled = true;
        }
Ejemplo n.º 19
0
        private void browseButton_Click(object sender, EventArgs e)
        {
            using (Ookii.Dialogs.VistaFolderBrowserDialog dialog = new Ookii.Dialogs.VistaFolderBrowserDialog()) {
                dialog.Description  = "Export Location";
                dialog.SelectedPath = this.exportFolderTextBox.Text;

                if (dialog.ShowDialog() == DialogResult.OK)
                {
                    string driveStr0 = Path.GetPathRoot(Workspace.Current.FileName);
                    string driveStr1 = Path.GetPathRoot(dialog.SelectedPath);

                    if (driveStr1 != driveStr0)
                    {
                        MessageBox.Show(Resources.WorkspaceExportRootWarning, Resources.Warning, MessageBoxButtons.OK);
                        return;
                    }

                    this.exportFolderTextBox.Text = dialog.SelectedPath;
                }
            }
        }
Ejemplo n.º 20
0
        private void ScreenCapBgLocText_Click(object sender, EventArgs e)
        {
#if !MONO
            using (Ookii.Dialogs.VistaFolderBrowserDialog d = new Ookii.Dialogs.VistaFolderBrowserDialog())
#else
            using (FolderBrowserDialog d = new FolderBrowserDialog())
#endif
            {
                d.SelectedPath = ScreenCapBgLocText.Text;
                d.Description  = "Choose a place to automatically save screen captures.";
                if (d.ShowDialog(this) == DialogResult.OK)
                {
                    ScreenCapBgLocText.Text = d.SelectedPath;
                }
            }

            if (string.IsNullOrEmpty(ScreenCapBgLocText.Text))
            {
                ScreenCapBgLocText.Text = Application.StartupPath + "\\ScreenCaptures";
            }
        }
Ejemplo n.º 21
0
        private void ts_unpack_Click(object sender, EventArgs e)
        {
            Ookii.Dialogs.VistaFolderBrowserDialog folderdialog = new Ookii.Dialogs.VistaFolderBrowserDialog();

            folderdialog.SelectedPath = Program.AConfig.FilePath[0];

            progressBar1.Value   = 0;
            progressBar1.Maximum = (int)xbbFile.getCount();

            if (folderdialog.ShowDialog() == DialogResult.OK)
            {
                string pathe = folderdialog.SelectedPath + @"\" + Path.GetFileName(path).Replace(Path.GetExtension(path), "") + @"\";

                if (!Directory.Exists(pathe))
                {
                    Directory.CreateDirectory(pathe);
                }

                Thread nTh = new Thread(
                    new ThreadStart(() =>
                {
                    for (int i = 0; i < xbbFile.getCount(); i++)
                    {
                        File.WriteAllBytes(pathe + xbbFile.getFileName(i).Replace("\0", "") + "", xbbFile.getSelectedfile(i));

                        progressBar1.BeginInvoke(new Action(() =>
                        {
                            progressBar1.Value += 1;
                        }));
                    }

                    GC.Collect(9, GCCollectionMode.Forced);
                }));

                nTh.Start();

                File.WriteAllText(pathe + @"\" + "uniqueIDList" + ".json", JsonConvert.SerializeObject(xbbFile.getselectedUniq(), Formatting.Indented), Encoding.UTF8);
            }
        }
Ejemplo n.º 22
0
        public LevelEditor(XElement xml)
        {
            TypeLookup.Rehydrate(xml);

            _properties = xml.Element(@"LevelProperties").DeserializedAs <LevelProperties>( );

            _previousContentRootFolder = _properties.ContentRootFolder;

            if (!Directory.Exists(_properties.ContentRootFolder))
            {
                string message = @"The level file has a content root folder that does not exist.
It says the content root is at ""{0}"". Images specified in this level file are relative to this folder so you should change it in order to load this level file correctly.
Would you like to change it?".FormatWith(_properties.ContentRootFolder);

                if (MessageBox.Show(message, @"Content root folder not found.", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
                {
                    var folderBrowserDialog = new Ookii.Dialogs.VistaFolderBrowserDialog( );

                    DialogResult dialogResult = folderBrowserDialog.ShowDialog( );

                    if (dialogResult == DialogResult.OK)
                    {
                        _properties.ContentRootFolder = folderBrowserDialog.SelectedPath;
                    }
                }
            }

            if (_properties.ContentRootFolder != _previousContentRootFolder)
            {
                //ObjectFactory.GetInstance<IEventHub>().Publish(new ContentRootChanged(_previousContentRootFolder, _properties.ContentRootFolder));
            }

            Behaviours = new BehaviourCollection(_properties, xml);

            Layers = new List <LayerEditor>(xml.CertainElement(@"Layers").Elements(@"Layer").Select(x => LayerEditor.FromXml(this, x)));

            ActiveLayer = Layers.FirstOrDefault( );
        }
Ejemplo n.º 23
0
        public LevelEditor(XElement xml)
        {
            TypeLookup.Rehydrate( xml );

            _properties = xml.Element( @"LevelProperties" ).DeserializedAs<LevelProperties>( ) ;

            _previousContentRootFolder = _properties.ContentRootFolder;

            if( !Directory.Exists( _properties.ContentRootFolder ) )
            {
                string message = @"The level file has a content root folder that does not exist.
            It says the content root is at ""{0}"". Images specified in this level file are relative to this folder so you should change it in order to load this level file correctly.
            Would you like to change it?".FormatWith( _properties.ContentRootFolder ) ;

                if(MessageBox.Show( message, @"Content root folder not found.", MessageBoxButtons.YesNo, MessageBoxIcon.Question )==DialogResult.Yes)
                {
                    var folderBrowserDialog = new Ookii.Dialogs.VistaFolderBrowserDialog( ) ;

                    DialogResult dialogResult = folderBrowserDialog.ShowDialog( ) ;

                    if( dialogResult == DialogResult.OK )
                    {
                        _properties.ContentRootFolder=folderBrowserDialog.SelectedPath ;
                    }
                }
            }

            if (_properties.ContentRootFolder != _previousContentRootFolder)
            {
                //ObjectFactory.GetInstance<IEventHub>().Publish(new ContentRootChanged(_previousContentRootFolder, _properties.ContentRootFolder));
            }

            Behaviours = new BehaviourCollection( _properties, xml );

            Layers = new List<LayerEditor>( xml.CertainElement( @"Layers" ).Elements( @"Layer" ).Select( x => LayerEditor.FromXml( this, x ) ) ) ;

            ActiveLayer = Layers.FirstOrDefault( ) ;
        }
Ejemplo n.º 24
0
        private void ts_unpack_Click(object sender, EventArgs e)
        {
            Ookii.Dialogs.VistaFolderBrowserDialog folderdialog = new Ookii.Dialogs.VistaFolderBrowserDialog();

            folderdialog.SelectedPath = Program.AConfig.FilePath[0];

            progressBar1.Value   = 0;
            progressBar1.Maximum = (int)ppFile.Count;

            if (folderdialog.ShowDialog() == DialogResult.OK)
            {
                string pathe = folderdialog.SelectedPath + @"\" + Path.GetFileName(path).Replace(Path.GetExtension(path), "") + @"\";

                if (!Directory.Exists(pathe))
                {
                    Directory.CreateDirectory(pathe);
                }

                Thread nTh = new Thread(
                    new ThreadStart(() =>
                {
                    for (int i = 0; i < ppFile.Count; i++)
                    {
                        File.WriteAllBytes(pathe + i + ".bin", ppFile.getSelectedData(i));

                        progressBar1.BeginInvoke(new Action(() =>
                        {
                            progressBar1.Value += 1;
                        }));
                    }

                    GC.Collect(9, GCCollectionMode.Forced);
                }));

                nTh.Start();
            }
        }
Ejemplo n.º 25
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.addButton          = new System.Windows.Forms.ButtonEx();
     this.exportButton       = new System.Windows.Forms.ButtonEx();
     this.columnHeader       = new System.Windows.Forms.ColumnHeader();
     this.contentsTextBox    = new System.Windows.Forms.TextBoxEx();
     this.deleteButton       = new System.Windows.Forms.ButtonEx();
     this.revertButton       = new System.Windows.Forms.ButtonEx();
     this.snippetNameTextBox = new System.Windows.Forms.TextBoxEx();
     this.nameLabel          = new System.Windows.Forms.Label();
     this.languageLabel      = new System.Windows.Forms.Label();
     this.snippetListView    = new System.Windows.Forms.ListViewEx();
     this.snippetsLabel      = new System.Windows.Forms.Label();
     this.saveButton         = new System.Windows.Forms.ButtonEx();
     this.insertLabel        = new System.Windows.Forms.Label();
     this.saveFileDialog     = new System.Windows.Forms.SaveFileDialog();
     this.browseDialog       = new Ookii.Dialogs.VistaFolderBrowserDialog();
     this.languageDropDown   = new System.Windows.Forms.FlatCombo();
     this.closeButton        = new System.Windows.Forms.ButtonEx();
     this.insertComboBox     = new System.Windows.Forms.FlatCombo();
     this.SuspendLayout();
     //
     // saveFileDialog
     //
     this.saveFileDialog.AddExtension = true;
     this.saveFileDialog.DefaultExt   = "fdz";
     this.saveFileDialog.Filter       = "FlashDevelop Zip Files|*.fdz";
     //
     // contentsTextBox
     //
     this.contentsTextBox.Anchor        = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right)));
     this.contentsTextBox.AcceptsTab    = true;
     this.contentsTextBox.AcceptsReturn = true;
     this.contentsTextBox.Font          = new System.Drawing.Font("Courier New", 8.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.contentsTextBox.Location      = new System.Drawing.Point(151, 53);
     this.contentsTextBox.ScrollBars    = ScrollBars.Vertical;
     this.contentsTextBox.Multiline     = true;
     this.contentsTextBox.Name          = "contentsTextBox";
     this.contentsTextBox.Size          = new System.Drawing.Size(453, 299);
     this.contentsTextBox.TabIndex      = 8;
     this.contentsTextBox.WordWrap      = false;
     this.contentsTextBox.TextChanged  += new System.EventHandler(this.ToggleCreate);
     //
     // addButton
     //
     this.addButton.Anchor    = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
     this.addButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.addButton.Location  = new System.Drawing.Point(254, 358);
     this.addButton.Name      = "addButton";
     this.addButton.Size      = new System.Drawing.Size(80, 23);
     this.addButton.TabIndex  = 3;
     this.addButton.Text      = "&Add";
     this.addButton.UseVisualStyleBackColor = true;
     this.addButton.Click += new System.EventHandler(this.AddButtonClick);
     //
     // deleteButton
     //
     this.deleteButton.Anchor    = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
     this.deleteButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.deleteButton.Location  = new System.Drawing.Point(343, 358);
     this.deleteButton.Name      = "deleteButton";
     this.deleteButton.Size      = new System.Drawing.Size(80, 23);
     this.deleteButton.TabIndex  = 3;
     this.deleteButton.Text      = "&Delete";
     this.deleteButton.UseVisualStyleBackColor = true;
     this.deleteButton.Click += new System.EventHandler(this.DeleteButtonClick);
     //
     // snippetNameTextBox
     //
     this.snippetNameTextBox.Location     = new System.Drawing.Point(151, 25);
     this.snippetNameTextBox.Name         = "snippetNameTextBox";
     this.snippetNameTextBox.Size         = new System.Drawing.Size(140, 19);
     this.snippetNameTextBox.TabIndex     = 6;
     this.snippetNameTextBox.TextChanged += new System.EventHandler(this.ToggleCreate);
     //
     // nameLabel
     //
     this.nameLabel.AutoSize  = true;
     this.nameLabel.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.nameLabel.Location  = new System.Drawing.Point(151, 8);
     this.nameLabel.Name      = "nameLabel";
     this.nameLabel.Size      = new System.Drawing.Size(85, 13);
     this.nameLabel.TabIndex  = 0;
     this.nameLabel.Text      = "Snippet name:";
     //
     // languageLabel
     //
     this.languageLabel.AutoSize  = true;
     this.languageLabel.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.languageLabel.Location  = new System.Drawing.Point(12, 8);
     this.languageLabel.Name      = "nameLabel";
     this.languageLabel.Size      = new System.Drawing.Size(85, 13);
     this.languageLabel.TabIndex  = 0;
     this.languageLabel.Text      = "Language:";
     //
     // snippetListView
     //
     this.snippetListView.Anchor        = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left)));
     this.snippetListView.MultiSelect   = false;
     this.snippetListView.HideSelection = false;
     this.snippetListView.Columns.Add(this.columnHeader);
     this.snippetListView.View                  = System.Windows.Forms.View.Details;
     this.snippetListView.Alignment             = System.Windows.Forms.ListViewAlignment.Left;
     this.snippetListView.HeaderStyle           = System.Windows.Forms.ColumnHeaderStyle.None;
     this.snippetListView.Location              = new System.Drawing.Point(12, 53);
     this.snippetListView.Name                  = "snippetListBox";
     this.snippetListView.Size                  = new System.Drawing.Size(130, 329);
     this.snippetListView.TabIndex              = 5;
     this.snippetListView.SelectedIndexChanged += new System.EventHandler(this.SnippetListViewSelectedIndexChanged);
     //
     // saveButton
     //
     this.saveButton.Anchor    = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
     this.saveButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.saveButton.Location  = new System.Drawing.Point(431, 358);
     this.saveButton.Name      = "saveButton";
     this.saveButton.Size      = new System.Drawing.Size(80, 23);
     this.saveButton.TabIndex  = 2;
     this.saveButton.Text      = "&Save";
     this.saveButton.UseVisualStyleBackColor = true;
     this.saveButton.Click += new System.EventHandler(this.SaveButtonClick);
     //
     // exportButton
     //
     this.exportButton.Anchor   = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
     this.exportButton.Name     = "exportButton";
     this.exportButton.TabIndex = 9;
     this.exportButton.Size     = new System.Drawing.Size(30, 23);
     this.exportButton.Location = new System.Drawing.Point(150, 358);
     this.exportButton.Click   += new System.EventHandler(this.ExportButtonClick);
     //
     // insertLabel
     //
     this.insertLabel.AutoSize  = true;
     this.insertLabel.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.insertLabel.Location  = new System.Drawing.Point(300, 8);
     this.insertLabel.Name      = "insertLabel";
     this.insertLabel.Size      = new System.Drawing.Size(93, 13);
     this.insertLabel.TabIndex  = 0;
     this.insertLabel.Text      = "Insert instruction:";
     //
     // languageDropDown
     //
     this.languageDropDown.DropDownStyle         = System.Windows.Forms.ComboBoxStyle.DropDownList;
     this.languageDropDown.MaxLength             = 200;
     this.languageDropDown.Name                  = "languageDropDown";
     this.languageDropDown.TabIndex              = 4;
     this.languageDropDown.Location              = new System.Drawing.Point(12, 25);
     this.languageDropDown.Size                  = new System.Drawing.Size(130, 23);
     this.languageDropDown.SelectedIndexChanged += new System.EventHandler(this.LanguagesSelectedIndexChanged);
     //
     // closeButton
     //
     this.closeButton.Anchor    = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
     this.closeButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this.closeButton.Location  = new System.Drawing.Point(519, 358);
     this.closeButton.Name      = "closeButton";
     this.closeButton.Size      = new System.Drawing.Size(85, 23);
     this.closeButton.TabIndex  = 1;
     this.closeButton.Text      = "&Close";
     this.closeButton.UseVisualStyleBackColor = true;
     this.closeButton.Click += new System.EventHandler(this.CloseButtonClick);
     //
     // revertButton
     //
     this.revertButton.Anchor   = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
     this.revertButton.Location = new System.Drawing.Point(188, 358);
     this.revertButton.Name     = "revertButton";
     this.revertButton.Size     = new System.Drawing.Size(30, 23);
     this.revertButton.TabIndex = 10;
     this.revertButton.UseVisualStyleBackColor = true;
     this.revertButton.Click += new System.EventHandler(this.RevertButtonClick);
     //
     // insertComboBox
     //
     this.insertComboBox.Anchor            = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right)));
     this.insertComboBox.DropDownStyle     = System.Windows.Forms.ComboBoxStyle.DropDownList;
     this.insertComboBox.FormattingEnabled = true;
     this.insertComboBox.Location          = new System.Drawing.Point(299, 25);
     this.insertComboBox.MaxDropDownItems  = 15;
     this.insertComboBox.Name                  = "insertComboBox";
     this.insertComboBox.Size                  = new System.Drawing.Size(305, 21);
     this.insertComboBox.TabIndex              = 7;
     this.insertComboBox.SelectedIndexChanged += new System.EventHandler(this.InsertComboBoxSelectedIndexChanged);
     //
     // SnippetDialog
     //
     this.ShowIcon            = false;
     this.MinimizeBox         = false;
     this.MaximizeBox         = false;
     this.ShowInTaskbar       = false;
     this.AcceptButton        = this.closeButton;
     this.CancelButton        = this.closeButton;
     this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
     this.AutoScaleMode       = System.Windows.Forms.AutoScaleMode.Font;
     this.ClientSize          = new System.Drawing.Size(615, 394);
     this.MinimumSize         = new System.Drawing.Size(615, 393);
     this.Controls.Add(this.languageDropDown);
     this.Controls.Add(this.insertComboBox);
     this.Controls.Add(this.closeButton);
     this.Controls.Add(this.snippetNameTextBox);
     this.Controls.Add(this.snippetListView);
     this.Controls.Add(this.contentsTextBox);
     this.Controls.Add(this.saveButton);
     this.Controls.Add(this.addButton);
     this.Controls.Add(this.revertButton);
     this.Controls.Add(this.exportButton);
     this.Controls.Add(this.deleteButton);
     this.Controls.Add(this.insertLabel);
     this.Controls.Add(this.languageLabel);
     this.Controls.Add(this.nameLabel);
     this.Name            = "SnippetDialog";
     this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.Sizable;
     this.StartPosition   = System.Windows.Forms.FormStartPosition.CenterParent;
     this.SizeGripStyle   = System.Windows.Forms.SizeGripStyle.Show;
     this.Text            = " Snippet Editor";
     this.ResumeLayout(false);
     this.PerformLayout();
 }
Ejemplo n.º 26
0
        /// <summary>
        /// This method is required for Windows Forms designer support.
        /// Do not change the method contents inside the source code editor. The Forms designer might
        /// not be able to load this method if it was changed manually.
        /// </summary>
        private void InitializeComponent() 
        {
            this.watcher = new System.IO.FileSystemWatcher();
            this.modifiedHeader = new System.Windows.Forms.ColumnHeader();
            this.typeHeader = new System.Windows.Forms.ColumnHeader();
            this.fileView = new System.Windows.Forms.ListViewEx();
            this.fileHeader = new System.Windows.Forms.ColumnHeader();
            this.sizeHeader = new System.Windows.Forms.ColumnHeader();
            this.folderBrowserDialog = new Ookii.Dialogs.VistaFolderBrowserDialog();
            this.toolStrip = new PluginCore.Controls.ToolStripEx();
            this.selectedPath = new System.Windows.Forms.ToolStripSpringComboBox();
            this.syncronizeButton = new System.Windows.Forms.ToolStripButton();
            this.browseButton = new System.Windows.Forms.ToolStripButton();
            ((System.ComponentModel.ISupportInitialize)(this.watcher)).BeginInit();
            this.toolStrip.SuspendLayout();
            this.SuspendLayout();
            // 
            // watcher
            // 
            this.watcher.EnableRaisingEvents = true;
            this.watcher.NotifyFilter = ((System.IO.NotifyFilters)((System.IO.NotifyFilters.FileName | System.IO.NotifyFilters.DirectoryName)));
            this.watcher.SynchronizingObject = this;
            this.watcher.Renamed += new System.IO.RenamedEventHandler(this.WatcherRenamed);
            this.watcher.Deleted += new System.IO.FileSystemEventHandler(this.WatcherChanged);
            this.watcher.Created += new System.IO.FileSystemEventHandler(this.WatcherChanged);
            this.watcher.Changed += new System.IO.FileSystemEventHandler(this.WatcherChanged);
            // 
            // modifiedHeader
            // 
            this.modifiedHeader.Text = "Modified";
            this.modifiedHeader.Width = 120;
            // 
            // typeHeader
            // 
            this.typeHeader.Text = "Type";
            // 
            // fileView
            // 
            this.fileView.AllowDrop = true;
            this.fileView.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.fileView.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
            this.fileHeader,
            this.sizeHeader,
            this.typeHeader,
            this.modifiedHeader});
            this.fileView.Dock = System.Windows.Forms.DockStyle.Fill;
            this.fileView.LabelEdit = true;
            this.fileView.Name = "fileView";
            this.fileView.Size = new System.Drawing.Size(278, 327);
            this.fileView.TabIndex = 5;
            this.fileView.FullRowSelect = true;
            this.fileView.UseCompatibleStateImageBehavior = false;
            this.fileView.View = System.Windows.Forms.View.Details;
            this.fileView.ItemActivate += new System.EventHandler(this.FileViewItemActivate);
            this.fileView.AfterLabelEdit += new System.Windows.Forms.LabelEditEventHandler(this.FileViewAfterLabelEdit);
            this.fileView.MouseUp += new System.Windows.Forms.MouseEventHandler(this.FileViewMouseUp);
            this.fileView.DragDrop += new System.Windows.Forms.DragEventHandler(this.FileViewDragDrop);
            this.fileView.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.FileViewColumnClick);
            this.fileView.KeyUp += new System.Windows.Forms.KeyEventHandler(this.FileViewKeyUp);
            this.fileView.BeforeLabelEdit += new System.Windows.Forms.LabelEditEventHandler(this.FileViewBeforeLabelEdit);
            this.fileView.ItemDrag += new System.Windows.Forms.ItemDragEventHandler(this.FileViewDragItems);
            this.fileView.DragOver += new System.Windows.Forms.DragEventHandler(this.FileViewDragOver);
            // 
            // fileHeader
            // 
            this.fileHeader.Text = "Files";
            this.fileHeader.Width = 190;
            // 
            // sizeHeader
            // 
            this.sizeHeader.Text = "Size";
            this.sizeHeader.Width = 55;
            // 
            // folderBrowserDialog
            // 
            this.folderBrowserDialog.Description = "Open a folder to list the files in the folder";
            this.folderBrowserDialog.RootFolder = System.Environment.SpecialFolder.MyComputer;
            // 
            // toolStrip
            //
            this.toolStrip.CanOverflow = false;
            this.toolStrip.Dock = System.Windows.Forms.DockStyle.Top;
            this.toolStrip.GripStyle = System.Windows.Forms.ToolStripGripStyle.Hidden;
            this.toolStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.selectedPath,
            this.syncronizeButton,
            this.browseButton});
            this.toolStrip.Name = "toolStrip";
            this.toolStrip.Padding = new System.Windows.Forms.Padding(1, 1, 2, 2);
            this.toolStrip.Size = new System.Drawing.Size(278, 26);
            this.toolStrip.Stretch = true;
            this.toolStrip.TabIndex = 6;
            // 
            // selectedPath
            //
            this.selectedPath.Name = "selectedPath";
            this.selectedPath.Size = new System.Drawing.Size(200, 22);
            this.selectedPath.Padding = new System.Windows.Forms.Padding(0, 0, 1, 0);
            this.selectedPath.FlatCombo.SelectedIndexChanged += new System.EventHandler(this.SelectedPathSelectedIndexChanged);
            this.selectedPath.KeyDown += new System.Windows.Forms.KeyEventHandler(this.SelectedPathKeyDown);
            // 
            // syncronizeButton
            //
            this.syncronizeButton.Margin = new System.Windows.Forms.Padding(0, 1, 0, 1);
            this.syncronizeButton.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.syncronizeButton.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
            this.syncronizeButton.Name = "syncronizeButton";
            this.syncronizeButton.Size = new System.Drawing.Size(23, 22);
            this.syncronizeButton.Text = "Synchronize";
            this.syncronizeButton.Click += new System.EventHandler(this.SynchronizeView);
            // 
            // browseButton
            //
            this.browseButton.Margin = new System.Windows.Forms.Padding(0, 1, 0, 1);
            this.browseButton.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.browseButton.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
            this.browseButton.Name = "browseButton";
            this.browseButton.Size = new System.Drawing.Size(23, 22);
            this.browseButton.Text = "Browse";
            this.browseButton.Click += new System.EventHandler(this.BrowseButtonClick);
            // 
            // PluginUI
            //
            this.Name = "PluginUI";
            this.Controls.Add(this.fileView);
            this.Controls.Add(this.toolStrip);
            this.Size = new System.Drawing.Size(280, 352);
            ((System.ComponentModel.ISupportInitialize)(this.watcher)).EndInit();
            this.toolStrip.ResumeLayout(false);
            this.toolStrip.PerformLayout();
            this.ResumeLayout(false);
            this.PerformLayout();

        }
Ejemplo n.º 27
0
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.addButton = new System.Windows.Forms.Button();
            this.exportButton = new System.Windows.Forms.Button();
            this.columnHeader = new System.Windows.Forms.ColumnHeader();
            this.contentsTextBox = new System.Windows.Forms.TextBox();
            this.deleteButton = new System.Windows.Forms.Button();
            this.revertButton = new System.Windows.Forms.Button();
            this.snippetNameTextBox = new System.Windows.Forms.TextBox();
            this.nameLabel = new System.Windows.Forms.Label();
            this.languageLabel = new System.Windows.Forms.Label();
            this.snippetListView = new System.Windows.Forms.ListView();
            this.snippetsLabel = new System.Windows.Forms.Label();
            this.saveButton = new System.Windows.Forms.Button();
            this.insertLabel = new System.Windows.Forms.Label();
            this.saveFileDialog = new System.Windows.Forms.SaveFileDialog();
            this.browseDialog = new Ookii.Dialogs.VistaFolderBrowserDialog();
            this.languageDropDown = new System.Windows.Forms.ComboBox();
            this.closeButton = new System.Windows.Forms.Button();
            this.insertComboBox = new System.Windows.Forms.ComboBox();
            this.SuspendLayout();
            // 
            // saveFileDialog
            //
            this.saveFileDialog.AddExtension = true;
            this.saveFileDialog.DefaultExt = "fdz";
            this.saveFileDialog.Filter = "FlashDevelop Zip Files|*.fdz";
            // 
            // contentsTextBox
            //
            this.contentsTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right)));
            this.contentsTextBox.AcceptsTab = true;
            this.contentsTextBox.AcceptsReturn = true;
            this.contentsTextBox.Font = new System.Drawing.Font("Courier New", 8.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.contentsTextBox.Location = new System.Drawing.Point(151, 53);
            this.contentsTextBox.ScrollBars = ScrollBars.Vertical;
            this.contentsTextBox.Multiline = true;
            this.contentsTextBox.Name = "contentsTextBox";
            this.contentsTextBox.Size = new System.Drawing.Size(453, 299);
            this.contentsTextBox.TabIndex = 8;
            this.contentsTextBox.WordWrap = false;
            this.contentsTextBox.TextChanged += new System.EventHandler(this.ToggleCreate);
            // 
            // addButton
            //
            this.addButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.addButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.addButton.Location = new System.Drawing.Point(254, 358);
            this.addButton.Name = "addButton";
            this.addButton.Size = new System.Drawing.Size(80, 23);
            this.addButton.TabIndex = 3;
            this.addButton.Text = "&Add";
            this.addButton.UseVisualStyleBackColor = true;
            this.addButton.Click += new System.EventHandler(this.AddButtonClick);
            // 
            // deleteButton
            //
            this.deleteButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.deleteButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.deleteButton.Location = new System.Drawing.Point(343, 358);
            this.deleteButton.Name = "deleteButton";
            this.deleteButton.Size = new System.Drawing.Size(80, 23);
            this.deleteButton.TabIndex = 3;
            this.deleteButton.Text = "&Delete";
            this.deleteButton.UseVisualStyleBackColor = true;
            this.deleteButton.Click += new System.EventHandler(this.DeleteButtonClick);
            // 
            // snippetNameTextBox
            //
            this.snippetNameTextBox.Location = new System.Drawing.Point(151, 26);
            this.snippetNameTextBox.Name = "snippetNameTextBox";
            this.snippetNameTextBox.Size = new System.Drawing.Size(140, 19);
            this.snippetNameTextBox.TabIndex = 6;
            this.snippetNameTextBox.TextChanged += new System.EventHandler(this.ToggleCreate);
            // 
            // nameLabel
            // 
            this.nameLabel.AutoSize = true;
            this.nameLabel.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.nameLabel.Location = new System.Drawing.Point(151, 8);
            this.nameLabel.Name = "nameLabel";
            this.nameLabel.Size = new System.Drawing.Size(85, 13);
            this.nameLabel.TabIndex = 0;
            this.nameLabel.Text = "Snippet name:";
            // 
            // languageLabel
            // 
            this.languageLabel.AutoSize = true;
            this.languageLabel.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.languageLabel.Location = new System.Drawing.Point(12, 8);
            this.languageLabel.Name = "nameLabel";
            this.languageLabel.Size = new System.Drawing.Size(85, 13);
            this.languageLabel.TabIndex = 0;
            this.languageLabel.Text = "Language:";
            // 
            // snippetListView
            //
            this.snippetListView.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left)));
            this.snippetListView.MultiSelect = false;
            this.snippetListView.HideSelection = false;
            this.snippetListView.Columns.Add(this.columnHeader);
            this.snippetListView.View = System.Windows.Forms.View.Details;
            this.snippetListView.Alignment = System.Windows.Forms.ListViewAlignment.Left;
            this.snippetListView.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
            this.snippetListView.Location = new System.Drawing.Point(12, 53);
            this.snippetListView.Name = "snippetListBox";
            this.snippetListView.Size = new System.Drawing.Size(130, 329);
            this.snippetListView.TabIndex = 5;
            this.snippetListView.SelectedIndexChanged += new System.EventHandler(this.SnippetListViewSelectedIndexChanged);
            // 
            // saveButton
            //
            this.saveButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.saveButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.saveButton.Location = new System.Drawing.Point(431, 358);
            this.saveButton.Name = "saveButton";
            this.saveButton.Size = new System.Drawing.Size(80, 23);
            this.saveButton.TabIndex = 2;
            this.saveButton.Text = "&Save";
            this.saveButton.UseVisualStyleBackColor = true;
            this.saveButton.Click += new System.EventHandler(this.SaveButtonClick);
            // 
            // exportButton
            //
            this.exportButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
            this.exportButton.Name = "exportButton";
            this.exportButton.TabIndex = 9;
            this.exportButton.Size = new System.Drawing.Size(30, 23);
            this.exportButton.Location = new System.Drawing.Point(150, 358);
            this.exportButton.Click += new System.EventHandler(this.ExportButtonClick);
            // 
            // insertLabel
            // 
            this.insertLabel.AutoSize = true;
            this.insertLabel.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.insertLabel.Location = new System.Drawing.Point(300, 8);
            this.insertLabel.Name = "insertLabel";
            this.insertLabel.Size = new System.Drawing.Size(93, 13);
            this.insertLabel.TabIndex = 0;
            this.insertLabel.Text = "Insert instruction:";
            // 
            // languageDropDown
            // 
            this.languageDropDown.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.languageDropDown.MaxLength = 200;
            this.languageDropDown.Name = "languageDropDown";
            this.languageDropDown.TabIndex = 4;
            this.languageDropDown.Location = new System.Drawing.Point(12, 25);
            this.languageDropDown.Size = new System.Drawing.Size(130, 23);
            this.languageDropDown.SelectedIndexChanged += new System.EventHandler(this.LanguagesSelectedIndexChanged);
            // 
            // closeButton
            //
            this.closeButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.closeButton.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.closeButton.Location = new System.Drawing.Point(519, 358);
            this.closeButton.Name = "closeButton";
            this.closeButton.Size = new System.Drawing.Size(85, 23);
            this.closeButton.TabIndex = 1;
            this.closeButton.Text = "&Close";
            this.closeButton.UseVisualStyleBackColor = true;
            this.closeButton.Click += new System.EventHandler(this.CloseButtonClick);
            // 
            // revertButton
            //
            this.revertButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
            this.revertButton.Location = new System.Drawing.Point(188, 358);
            this.revertButton.Name = "revertButton";
            this.revertButton.Size = new System.Drawing.Size(30, 23);
            this.revertButton.TabIndex = 10;
            this.revertButton.UseVisualStyleBackColor = true;
            this.revertButton.Click += new System.EventHandler(this.RevertButtonClick);
            // 
            // insertComboBox
            //
            this.insertComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right)));
            this.insertComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.insertComboBox.FormattingEnabled = true;
            this.insertComboBox.Location = new System.Drawing.Point(299, 25);
            this.insertComboBox.MaxDropDownItems = 15;
            this.insertComboBox.Name = "insertComboBox";
            this.insertComboBox.Size = new System.Drawing.Size(305, 21);
            this.insertComboBox.TabIndex = 7;
            this.insertComboBox.SelectedIndexChanged += new System.EventHandler(this.InsertComboBoxSelectedIndexChanged);
            // 
            // SnippetDialog
            //
            this.ShowIcon = false;
            this.MinimizeBox = false;
            this.MaximizeBox = false;
            this.ShowInTaskbar = false;
            this.AcceptButton = this.closeButton;
            this.CancelButton = this.closeButton;
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(615, 393);
            this.MinimumSize = new System.Drawing.Size(615, 393);
            this.Controls.Add(this.languageDropDown);
            this.Controls.Add(this.insertComboBox);
            this.Controls.Add(this.closeButton);
            this.Controls.Add(this.snippetNameTextBox);
            this.Controls.Add(this.snippetListView);
            this.Controls.Add(this.contentsTextBox);
            this.Controls.Add(this.saveButton);
            this.Controls.Add(this.addButton);
            this.Controls.Add(this.revertButton);
            this.Controls.Add(this.exportButton);
            this.Controls.Add(this.deleteButton);
            this.Controls.Add(this.insertLabel);
            this.Controls.Add(this.languageLabel);
            this.Controls.Add(this.nameLabel);
            this.Name = "SnippetDialog";
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.Sizable;
            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
            this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Show;
            this.Text = " Snippet Editor";
            this.ResumeLayout(false);
            this.PerformLayout();

        }
Ejemplo n.º 28
0
        private void browseButton_Click(object sender, EventArgs e) {
            using(Ookii.Dialogs.VistaFolderBrowserDialog dialog = new Ookii.Dialogs.VistaFolderBrowserDialog()) {
                dialog.Description = "Export Location";
                dialog.SelectedPath = this.exportFolderTextBox.Text;

                if (dialog.ShowDialog() == DialogResult.OK) {
                    string driveStr0 = Path.GetPathRoot(Workspace.Current.FileName);
                    string driveStr1 = Path.GetPathRoot(dialog.SelectedPath);

                    if (driveStr1 != driveStr0)
                    {
                        MessageBox.Show(Resources.WorkspaceExportRootWarning, Resources.Warning, MessageBoxButtons.OK);
                        return;
                    }

                    this.exportFolderTextBox.Text = dialog.SelectedPath;
                }
            }
        }
Ejemplo n.º 29
0
 private void button3_Click(object sender, EventArgs e)
 {
     var dialog = new Ookii.Dialogs.VistaFolderBrowserDialog();
     dialog.ShowDialog();     
     textBox1.Text = dialog.SelectedPath;
     
     try
     {
         WhichMapsDoIHave(ref idk);
         button2.Enabled = true;
     }
     catch (DirectoryNotFoundException) { }
     for (int i = 0; i < idk.Count; i++)
     {
         idk[i] = idk[i].Split(' ')[0];
         idk[i] = idk[i].Split('\\')[idk[i].Split('\\').Length - 1];
     }
     button1.Enabled = true;
 }
Ejemplo n.º 30
0
        private void browseButton_Click(object sender, EventArgs e) {
            using(Ookii.Dialogs.VistaFolderBrowserDialog dialog = new Ookii.Dialogs.VistaFolderBrowserDialog()) {
                dialog.Description = "Export Location";
                dialog.SelectedPath = this.exportFolderTextBox.Text;

                if (dialog.ShowDialog() == DialogResult.OK) {
                    this.exportFolderTextBox.Text = dialog.SelectedPath;
                }
            }
        }
Ejemplo n.º 31
0
        private void InitializeComponent()
        {
            components = new Container();
            dlgOpen    = new OpenFileDialog();
            dlgSave    = new SaveFileDialog();
#if !MONO
            folderBrowserDialog1 = new Ookii.Dialogs.VistaFolderBrowserDialog();
#else
            folderBrowserDialog1 = new FolderBrowserDialog();
#endif
            pnlKeyframes                   = new Panel();
            pnlBones                       = new Panel();
            lstBones                       = new CheckedListBox();
            boneTree                       = new TreeView();
            panel1                         = new Panel();
            txtSearchBone                  = new TextBox();
            chkContains                    = new CheckBox();
            chkFlat                        = new CheckBox();
            ctxBones                       = new ContextMenuStrip(components);
            nameToolStripMenuItem          = new ToolStripMenuItem();
            boneIndex                      = new ToolStripMenuItem();
            renameBoneToolStripMenuItem    = new ToolStripMenuItem();
            ctxBonesDivider1               = new ToolStripSeparator();
            addToParentToolStripMenuItem   = new ToolStripMenuItem();
            addToNextUpToolStripMenuItem   = new ToolStripMenuItem();
            addToNextDownToolStripMenuItem = new ToolStripMenuItem();
            ctxBonesDivider2               = new ToolStripSeparator();
            _moveUpToolStripMenuItem       = new ToolStripMenuItem();
            _moveDownToolStripMenuItem     = new ToolStripMenuItem();
            imageList1                     = new ImageList(components);
            pnlKeyframes.SuspendLayout();
            pnlBones.SuspendLayout();
            panel1.SuspendLayout();
            ctxBones.SuspendLayout();
            SuspendLayout();
            //
            // pnlKeyframes
            //
            pnlKeyframes.AutoScroll  = true;
            pnlKeyframes.BorderStyle = BorderStyle.Fixed3D;
            pnlKeyframes.Controls.Add(pnlBones);
            pnlKeyframes.Dock     = DockStyle.Fill;
            pnlKeyframes.Location = new Drawing.Point(0, 0);
            pnlKeyframes.Name     = "pnlKeyframes";
            pnlKeyframes.Size     = new Drawing.Size(164, 398);
            pnlKeyframes.TabIndex = 26;
            //
            // pnlBones
            //
            pnlBones.Controls.Add(lstBones);
            pnlBones.Controls.Add(boneTree);
            pnlBones.Controls.Add(panel1);
            pnlBones.Dock     = DockStyle.Fill;
            pnlBones.Location = new Drawing.Point(0, 0);
            pnlBones.Name     = "pnlBones";
            pnlBones.Size     = new Drawing.Size(160, 394);
            pnlBones.TabIndex = 10;
            //
            // lstBones
            //
            lstBones.Dock = DockStyle.Fill;
            lstBones.FormattingEnabled = true;
            lstBones.IntegralHeight    = false;
            lstBones.Location          = new Drawing.Point(0, 21);
            lstBones.Name                  = "lstBones";
            lstBones.Size                  = new Drawing.Size(160, 373);
            lstBones.TabIndex              = 32;
            lstBones.ItemCheck            += new ItemCheckEventHandler(lstBones_ItemCheck);
            lstBones.SelectedValueChanged += lstBones_SelectedValueChanged;
            lstBones.KeyDown              += new KeyEventHandler(lstBones_KeyDown);
            lstBones.MouseDown            += new MouseEventHandler(lstBones_MouseDown);
            //
            // boneTree
            //
            boneTree.CheckBoxes    = true;
            boneTree.Dock          = DockStyle.Fill;
            boneTree.FullRowSelect = true;
            boneTree.HideSelection = false;
            boneTree.HotTracking   = true;
            boneTree.Indent        = 14;
            boneTree.ItemHeight    = 16;
            boneTree.Location      = new Drawing.Point(0, 21);
            boneTree.Name          = "boneTree";
            boneTree.Size          = new Drawing.Size(160, 373);
            boneTree.TabIndex      = 29;
            boneTree.Visible       = false;
            boneTree.AfterCheck   += new TreeViewEventHandler(boneTree_AfterCheck);
            boneTree.AfterSelect  += new TreeViewEventHandler(boneTree_AfterSelect);
            boneTree.MouseDown    += new MouseEventHandler(lstBones_MouseDown);
            //
            // panel1
            //
            panel1.Controls.Add(txtSearchBone);
            panel1.Controls.Add(chkContains);
            panel1.Controls.Add(chkFlat);
            panel1.Dock     = DockStyle.Top;
            panel1.Location = new Drawing.Point(0, 0);
            panel1.Name     = "panel1";
            panel1.Size     = new Drawing.Size(160, 21);
            panel1.TabIndex = 31;
            //
            // txtSearchBone
            //
            txtSearchBone.Dock         = DockStyle.Fill;
            txtSearchBone.ForeColor    = Color.Gray;
            txtSearchBone.Location     = new Drawing.Point(44, 0);
            txtSearchBone.Name         = "txtSearchBone";
            txtSearchBone.Size         = new Drawing.Size(46, 20);
            txtSearchBone.TabIndex     = 30;
            txtSearchBone.Text         = "Search for a bone...";
            txtSearchBone.Visible      = false;
            txtSearchBone.TextChanged += textBox1_TextChanged;
            txtSearchBone.Enter       += textBox1_Enter;
            txtSearchBone.Leave       += textBox1_Leave;
            //
            // chkContains
            //
            chkContains.AutoSize = true;
            chkContains.Dock     = DockStyle.Right;
            chkContains.Location = new Drawing.Point(90, 0);
            chkContains.Margin   = new Padding(0);
            chkContains.Name     = "chkContains";
            chkContains.Padding  = new Padding(3, 0, 0, 0);
            chkContains.Size     = new Drawing.Size(70, 21);
            chkContains.TabIndex = 32;
            chkContains.Text     = "Contains";
            chkContains.UseVisualStyleBackColor = false;
            chkContains.Visible         = false;
            chkContains.CheckedChanged += chkContains_CheckedChanged;
            //
            // chkFlat
            //
            chkFlat.AutoSize   = true;
            chkFlat.Checked    = true;
            chkFlat.CheckState = CheckState.Checked;
            chkFlat.Dock       = DockStyle.Left;
            chkFlat.Location   = new Drawing.Point(0, 0);
            chkFlat.Margin     = new Padding(0);
            chkFlat.Name       = "chkFlat";
            chkFlat.Padding    = new Padding(1, 0, 0, 0);
            chkFlat.Size       = new Drawing.Size(44, 21);
            chkFlat.TabIndex   = 31;
            chkFlat.Text       = "Flat";
            chkFlat.UseVisualStyleBackColor = false;
            chkFlat.CheckedChanged         += chkFlat_CheckedChanged;
            //
            // ctxBones
            //
            ctxBones.Items.AddRange(new ToolStripItem[]
            {
                nameToolStripMenuItem,
                boneIndex,
                renameBoneToolStripMenuItem,
                ctxBonesDivider1,
                addToParentToolStripMenuItem,
                addToNextUpToolStripMenuItem,
                addToNextDownToolStripMenuItem,
                ctxBonesDivider2,
                _moveUpToolStripMenuItem,
                _moveDownToolStripMenuItem
            });
            ctxBones.Name = "ctxBones";
            ctxBones.Size = new Drawing.Size(175, 192);
            //
            // nameToolStripMenuItem
            //
            nameToolStripMenuItem.Enabled = false;
            nameToolStripMenuItem.Name    = "nameToolStripMenuItem";
            nameToolStripMenuItem.Size    = new Drawing.Size(174, 22);
            nameToolStripMenuItem.Text    = "<name>";
            //
            // boneIndex
            //
            boneIndex.Enabled = false;
            boneIndex.Name    = "boneIndex";
            boneIndex.Size    = new Drawing.Size(174, 22);
            boneIndex.Text    = "Bone Index";
            //
            // renameBoneToolStripMenuItem
            //
            renameBoneToolStripMenuItem.Name   = "renameBoneToolStripMenuItem";
            renameBoneToolStripMenuItem.Size   = new Drawing.Size(174, 22);
            renameBoneToolStripMenuItem.Text   = "Rename";
            renameBoneToolStripMenuItem.Click += renameBoneToolStripMenuItem_Click;
            //
            // ctxBonesDivider1
            //
            ctxBonesDivider1.Name = "ctxBonesDivider1";
            ctxBonesDivider1.Size = new Drawing.Size(171, 6);
            //
            // addToParentToolStripMenuItem
            //
            addToParentToolStripMenuItem.Name   = "addToParentToolStripMenuItem";
            addToParentToolStripMenuItem.Size   = new Drawing.Size(174, 22);
            addToParentToolStripMenuItem.Text   = "Add To Parent";
            addToParentToolStripMenuItem.Click += addToParentToolStripMenuItem_Click;
            //
            // addToNextUpToolStripMenuItem
            //
            addToNextUpToolStripMenuItem.Name   = "addToNextUpToolStripMenuItem";
            addToNextUpToolStripMenuItem.Size   = new Drawing.Size(174, 22);
            addToNextUpToolStripMenuItem.Text   = "Add To Next Up";
            addToNextUpToolStripMenuItem.Click += addToNextUpToolStripMenuItem_Click;
            //
            // addToNextDownToolStripMenuItem
            //
            addToNextDownToolStripMenuItem.Name   = "addToNextDownToolStripMenuItem";
            addToNextDownToolStripMenuItem.Size   = new Drawing.Size(174, 22);
            addToNextDownToolStripMenuItem.Text   = "Add To Next Down";
            addToNextDownToolStripMenuItem.Click += addToNextDownToolStripMenuItem_Click;
            //
            // ctxBonesDivider2
            //
            ctxBonesDivider2.Name = "ctxBonesDivider2";
            ctxBonesDivider2.Size = new Drawing.Size(171, 6);
            //
            // _moveUpToolStripMenuItem
            //
            _moveUpToolStripMenuItem.Name   = "_moveUpToolStripMenuItem";
            _moveUpToolStripMenuItem.Size   = new Drawing.Size(174, 22);
            _moveUpToolStripMenuItem.Text   = "Move Up";
            _moveUpToolStripMenuItem.Click += _moveUpToolStripMenuItem_Click;
            //
            // _moveDownToolStripMenuItem
            //
            _moveDownToolStripMenuItem.Name   = "_moveDownToolStripMenuItem";
            _moveDownToolStripMenuItem.Size   = new Drawing.Size(174, 22);
            _moveDownToolStripMenuItem.Text   = "Move Down";
            _moveDownToolStripMenuItem.Click += _moveDownToolStripMenuItem_Click;
            //
            // imageList1
            //
            imageList1.ColorDepth       = ColorDepth.Depth8Bit;
            imageList1.ImageSize        = new Drawing.Size(16, 16);
            imageList1.TransparentColor = Color.Transparent;
            //
            // BonesPanel
            //
            Controls.Add(pnlKeyframes);
            Name         = "BonesPanel";
            Size         = new Drawing.Size(164, 398);
            SizeChanged += BonesPanel_SizeChanged;
            pnlKeyframes.ResumeLayout(false);
            pnlBones.ResumeLayout(false);
            panel1.ResumeLayout(false);
            panel1.PerformLayout();
            ctxBones.ResumeLayout(false);
            ResumeLayout(false);
        }