Наследование: System.Windows.Forms.Form
Пример #1
0
        private void synchronizeMenuItem_Click(object sender, EventArgs e)
        {
            SynchronizePOs dialog = new SynchronizePOs();

            if (dialog.ShowDialog(this) != DialogResult.OK)
            {
                return;
            }

            PoAttributesDialog attributesDialog = new PoAttributesDialog();

            if (attributesDialog.ShowDialog(this) != DialogResult.OK)
            {
                return;
            }

            PoWriterAttributes attributes = new PoWriterAttributes()
            {
                Name     = attributesDialog.nameTextBox.Text,
                Email    = attributesDialog.emailTextBox.Text,
                Version  = attributesDialog.versionTextBox.Text,
                writePOT = true
            };


            SynchronizePoFiles(dialog.ResXDirectory, dialog.PODirectory,
                               attributesDialog.nameTextBox.Text, attributesDialog.emailTextBox.Text, attributesDialog.versionTextBox.Text);
        }
Пример #2
0
        private void createPOTToolStripMenuItem_Click(object sender, EventArgs e)
        {
            PoAttributesDialog attributesDialog = new PoAttributesDialog();

            if (attributesDialog.ShowDialog(this) != DialogResult.OK)
            {
                return;
            }

            PoWriterAttributes attributes = new PoWriterAttributes()
            {
                Name     = attributesDialog.nameTextBox.Text,
                Email    = attributesDialog.emailTextBox.Text,
                Version  = attributesDialog.versionTextBox.Text,
                writePOT = true
            };

            attributesDialog.Dispose();

            SaveFileDialog dialog = new SaveFileDialog();

            dialog.DefaultExt = ".pot";

            if (dialog.ShowDialog(this) == DialogResult.OK)
            {
                PoWriter potWriter = new PoWriter(dialog.FileName, attributes);
                potWriter.WritePot(resourceDirectory);
            }
        }
Пример #3
0
        private void createPOTToolStripMenuItem_Click(object sender, EventArgs e)
        {
            PoAttributesDialog attributesDialog = new PoAttributesDialog();
            if (attributesDialog.ShowDialog(this) != DialogResult.OK)
                return;

            PoWriterAttributes attributes = new PoWriterAttributes() {
                Name = attributesDialog.nameTextBox.Text,
                Email = attributesDialog.emailTextBox.Text,
                Version = attributesDialog.versionTextBox.Text,
                writePOT = true};

            attributesDialog.Dispose();

            SaveFileDialog dialog = new SaveFileDialog();
            dialog.DefaultExt = ".pot";

            if (dialog.ShowDialog(this) == DialogResult.OK) {
                PoWriter potWriter = new PoWriter(dialog.FileName, attributes);
                potWriter.WritePot(resourceDirectory);
            }
        }
Пример #4
0
        private void synchronizeMenuItem_Click(object sender, EventArgs e)
        {
            SynchronizePOs dialog = new SynchronizePOs();
            if (dialog.ShowDialog(this) != DialogResult.OK) {
                return;
            }

            PoAttributesDialog attributesDialog = new PoAttributesDialog();
            if (attributesDialog.ShowDialog(this) != DialogResult.OK)
                return;

            PoWriterAttributes attributes = new PoWriterAttributes() {
                Name = attributesDialog.nameTextBox.Text,
                Email = attributesDialog.emailTextBox.Text,
                Version = attributesDialog.versionTextBox.Text,
                writePOT = true
            };

            SynchronizePoFiles(dialog.ResXDirectory, dialog.PODirectory,
                attributesDialog.nameTextBox.Text, attributesDialog.emailTextBox.Text, attributesDialog.versionTextBox.Text);
        }