Optimized code(again), TXLib added to resources, and compiling is in new thread now
This commit is contained in:
parent
4d22e9dbbc
commit
f5b399abf7
24 changed files with 9005 additions and 8619 deletions
380
.gitignore
vendored
380
.gitignore
vendored
|
@ -1,32 +1,362 @@
|
||||||
# Prerequisites
|
## Ignore Visual Studio temporary files, build results, and
|
||||||
*.d
|
## files generated by popular Visual Studio add-ons.
|
||||||
|
##
|
||||||
|
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
|
||||||
|
|
||||||
# Compiled Object files
|
# User-specific files
|
||||||
*.slo
|
*.rsuser
|
||||||
*.lo
|
*.suo
|
||||||
*.o
|
*.user
|
||||||
|
*.userosscache
|
||||||
|
*.sln.docstates
|
||||||
|
|
||||||
|
# User-specific files (MonoDevelop/Xamarin Studio)
|
||||||
|
*.userprefs
|
||||||
|
|
||||||
|
# Mono auto generated files
|
||||||
|
mono_crash.*
|
||||||
|
|
||||||
|
# Build results
|
||||||
|
[Dd]ebug/
|
||||||
|
[Dd]ebugPublic/
|
||||||
|
[Rr]elease/
|
||||||
|
[Rr]eleases/
|
||||||
|
x64/
|
||||||
|
x86/
|
||||||
|
[Ww][Ii][Nn]32/
|
||||||
|
[Aa][Rr][Mm]/
|
||||||
|
[Aa][Rr][Mm]64/
|
||||||
|
bld/
|
||||||
|
[Bb]in/
|
||||||
|
[Oo]bj/
|
||||||
|
[Ll]og/
|
||||||
|
[Ll]ogs/
|
||||||
|
|
||||||
|
# Visual Studio 2015/2017 cache/options directory
|
||||||
|
.vs/
|
||||||
|
# Uncomment if you have tasks that create the project's static files in wwwroot
|
||||||
|
#wwwroot/
|
||||||
|
|
||||||
|
# Visual Studio 2017 auto generated files
|
||||||
|
Generated\ Files/
|
||||||
|
|
||||||
|
# MSTest test Results
|
||||||
|
[Tt]est[Rr]esult*/
|
||||||
|
[Bb]uild[Ll]og.*
|
||||||
|
|
||||||
|
# NUnit
|
||||||
|
*.VisualState.xml
|
||||||
|
TestResult.xml
|
||||||
|
nunit-*.xml
|
||||||
|
|
||||||
|
# Build Results of an ATL Project
|
||||||
|
[Dd]ebugPS/
|
||||||
|
[Rr]eleasePS/
|
||||||
|
dlldata.c
|
||||||
|
|
||||||
|
# Benchmark Results
|
||||||
|
BenchmarkDotNet.Artifacts/
|
||||||
|
|
||||||
|
# .NET Core
|
||||||
|
project.lock.json
|
||||||
|
project.fragment.lock.json
|
||||||
|
artifacts/
|
||||||
|
|
||||||
|
# ASP.NET Scaffolding
|
||||||
|
ScaffoldingReadMe.txt
|
||||||
|
|
||||||
|
# StyleCop
|
||||||
|
StyleCopReport.xml
|
||||||
|
|
||||||
|
# Files built by Visual Studio
|
||||||
|
*_i.c
|
||||||
|
*_p.c
|
||||||
|
*_h.h
|
||||||
|
*.ilk
|
||||||
|
*.meta
|
||||||
*.obj
|
*.obj
|
||||||
|
*.iobj
|
||||||
# Precompiled Headers
|
|
||||||
*.gch
|
|
||||||
*.pch
|
*.pch
|
||||||
|
*.pdb
|
||||||
|
*.ipdb
|
||||||
|
*.pgc
|
||||||
|
*.pgd
|
||||||
|
*.rsp
|
||||||
|
*.sbr
|
||||||
|
*.tlb
|
||||||
|
*.tli
|
||||||
|
*.tlh
|
||||||
|
*.tmp
|
||||||
|
*.tmp_proj
|
||||||
|
*_wpftmp.csproj
|
||||||
|
*.log
|
||||||
|
*.vspscc
|
||||||
|
*.vssscc
|
||||||
|
.builds
|
||||||
|
*.pidb
|
||||||
|
*.svclog
|
||||||
|
*.scc
|
||||||
|
|
||||||
# Compiled Dynamic libraries
|
# Chutzpah Test files
|
||||||
*.so
|
_Chutzpah*
|
||||||
*.dylib
|
|
||||||
*.dll
|
|
||||||
|
|
||||||
# Fortran module files
|
# Visual C++ cache files
|
||||||
*.mod
|
ipch/
|
||||||
*.smod
|
*.aps
|
||||||
|
*.ncb
|
||||||
|
*.opendb
|
||||||
|
*.opensdf
|
||||||
|
*.sdf
|
||||||
|
*.cachefile
|
||||||
|
*.VC.db
|
||||||
|
*.VC.VC.opendb
|
||||||
|
|
||||||
# Compiled Static libraries
|
# Visual Studio profiler
|
||||||
*.lai
|
*.psess
|
||||||
*.la
|
*.vsp
|
||||||
*.a
|
*.vspx
|
||||||
*.lib
|
*.sap
|
||||||
|
|
||||||
# Executables
|
# Visual Studio Trace Files
|
||||||
*.exe
|
*.e2e
|
||||||
*.out
|
|
||||||
*.app
|
# TFS 2012 Local Workspace
|
||||||
|
$tf/
|
||||||
|
|
||||||
|
# Guidance Automation Toolkit
|
||||||
|
*.gpState
|
||||||
|
|
||||||
|
# ReSharper is a .NET coding add-in
|
||||||
|
_ReSharper*/
|
||||||
|
*.[Rr]e[Ss]harper
|
||||||
|
*.DotSettings.user
|
||||||
|
|
||||||
|
# TeamCity is a build add-in
|
||||||
|
_TeamCity*
|
||||||
|
|
||||||
|
# DotCover is a Code Coverage Tool
|
||||||
|
*.dotCover
|
||||||
|
|
||||||
|
# AxoCover is a Code Coverage Tool
|
||||||
|
.axoCover/*
|
||||||
|
!.axoCover/settings.json
|
||||||
|
|
||||||
|
# Coverlet is a free, cross platform Code Coverage Tool
|
||||||
|
coverage*.json
|
||||||
|
coverage*.xml
|
||||||
|
coverage*.info
|
||||||
|
|
||||||
|
# Visual Studio code coverage results
|
||||||
|
*.coverage
|
||||||
|
*.coveragexml
|
||||||
|
|
||||||
|
# NCrunch
|
||||||
|
_NCrunch_*
|
||||||
|
.*crunch*.local.xml
|
||||||
|
nCrunchTemp_*
|
||||||
|
|
||||||
|
# MightyMoose
|
||||||
|
*.mm.*
|
||||||
|
AutoTest.Net/
|
||||||
|
|
||||||
|
# Web workbench (sass)
|
||||||
|
.sass-cache/
|
||||||
|
|
||||||
|
# Installshield output folder
|
||||||
|
[Ee]xpress/
|
||||||
|
|
||||||
|
# DocProject is a documentation generator add-in
|
||||||
|
DocProject/buildhelp/
|
||||||
|
DocProject/Help/*.HxT
|
||||||
|
DocProject/Help/*.HxC
|
||||||
|
DocProject/Help/*.hhc
|
||||||
|
DocProject/Help/*.hhk
|
||||||
|
DocProject/Help/*.hhp
|
||||||
|
DocProject/Help/Html2
|
||||||
|
DocProject/Help/html
|
||||||
|
|
||||||
|
# Click-Once directory
|
||||||
|
publish/
|
||||||
|
|
||||||
|
# Publish Web Output
|
||||||
|
*.[Pp]ublish.xml
|
||||||
|
*.azurePubxml
|
||||||
|
# Note: Comment the next line if you want to checkin your web deploy settings,
|
||||||
|
# but database connection strings (with potential passwords) will be unencrypted
|
||||||
|
*.pubxml
|
||||||
|
*.publishproj
|
||||||
|
|
||||||
|
# Microsoft Azure Web App publish settings. Comment the next line if you want to
|
||||||
|
# checkin your Azure Web App publish settings, but sensitive information contained
|
||||||
|
# in these scripts will be unencrypted
|
||||||
|
PublishScripts/
|
||||||
|
|
||||||
|
# NuGet Packages
|
||||||
|
*.nupkg
|
||||||
|
# NuGet Symbol Packages
|
||||||
|
*.snupkg
|
||||||
|
# The packages folder can be ignored because of Package Restore
|
||||||
|
**/[Pp]ackages/*
|
||||||
|
# except build/, which is used as an MSBuild target.
|
||||||
|
!**/[Pp]ackages/build/
|
||||||
|
# Uncomment if necessary however generally it will be regenerated when needed
|
||||||
|
#!**/[Pp]ackages/repositories.config
|
||||||
|
# NuGet v3's project.json files produces more ignorable files
|
||||||
|
*.nuget.props
|
||||||
|
*.nuget.targets
|
||||||
|
|
||||||
|
# Microsoft Azure Build Output
|
||||||
|
csx/
|
||||||
|
*.build.csdef
|
||||||
|
|
||||||
|
# Microsoft Azure Emulator
|
||||||
|
ecf/
|
||||||
|
rcf/
|
||||||
|
|
||||||
|
# Windows Store app package directories and files
|
||||||
|
AppPackages/
|
||||||
|
BundleArtifacts/
|
||||||
|
Package.StoreAssociation.xml
|
||||||
|
_pkginfo.txt
|
||||||
|
*.appx
|
||||||
|
*.appxbundle
|
||||||
|
*.appxupload
|
||||||
|
|
||||||
|
# Visual Studio cache files
|
||||||
|
# files ending in .cache can be ignored
|
||||||
|
*.[Cc]ache
|
||||||
|
# but keep track of directories ending in .cache
|
||||||
|
!?*.[Cc]ache/
|
||||||
|
|
||||||
|
# Others
|
||||||
|
ClientBin/
|
||||||
|
~$*
|
||||||
|
*~
|
||||||
|
*.dbmdl
|
||||||
|
*.dbproj.schemaview
|
||||||
|
*.jfm
|
||||||
|
*.pfx
|
||||||
|
*.publishsettings
|
||||||
|
orleans.codegen.cs
|
||||||
|
|
||||||
|
# Including strong name files can present a security risk
|
||||||
|
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
|
||||||
|
#*.snk
|
||||||
|
|
||||||
|
# Since there are multiple workflows, uncomment next line to ignore bower_components
|
||||||
|
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
|
||||||
|
#bower_components/
|
||||||
|
|
||||||
|
# RIA/Silverlight projects
|
||||||
|
Generated_Code/
|
||||||
|
|
||||||
|
# Backup & report files from converting an old project file
|
||||||
|
# to a newer Visual Studio version. Backup files are not needed,
|
||||||
|
# because we have git ;-)
|
||||||
|
_UpgradeReport_Files/
|
||||||
|
Backup*/
|
||||||
|
UpgradeLog*.XML
|
||||||
|
UpgradeLog*.htm
|
||||||
|
ServiceFabricBackup/
|
||||||
|
*.rptproj.bak
|
||||||
|
|
||||||
|
# SQL Server files
|
||||||
|
*.mdf
|
||||||
|
*.ldf
|
||||||
|
*.ndf
|
||||||
|
|
||||||
|
# Business Intelligence projects
|
||||||
|
*.rdl.data
|
||||||
|
*.bim.layout
|
||||||
|
*.bim_*.settings
|
||||||
|
*.rptproj.rsuser
|
||||||
|
*- [Bb]ackup.rdl
|
||||||
|
*- [Bb]ackup ([0-9]).rdl
|
||||||
|
*- [Bb]ackup ([0-9][0-9]).rdl
|
||||||
|
|
||||||
|
# Microsoft Fakes
|
||||||
|
FakesAssemblies/
|
||||||
|
|
||||||
|
# GhostDoc plugin setting file
|
||||||
|
*.GhostDoc.xml
|
||||||
|
|
||||||
|
# Node.js Tools for Visual Studio
|
||||||
|
.ntvs_analysis.dat
|
||||||
|
node_modules/
|
||||||
|
|
||||||
|
# Visual Studio 6 build log
|
||||||
|
*.plg
|
||||||
|
|
||||||
|
# Visual Studio 6 workspace options file
|
||||||
|
*.opt
|
||||||
|
|
||||||
|
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
|
||||||
|
*.vbw
|
||||||
|
|
||||||
|
# Visual Studio LightSwitch build output
|
||||||
|
**/*.HTMLClient/GeneratedArtifacts
|
||||||
|
**/*.DesktopClient/GeneratedArtifacts
|
||||||
|
**/*.DesktopClient/ModelManifest.xml
|
||||||
|
**/*.Server/GeneratedArtifacts
|
||||||
|
**/*.Server/ModelManifest.xml
|
||||||
|
_Pvt_Extensions
|
||||||
|
|
||||||
|
# Paket dependency manager
|
||||||
|
.paket/paket.exe
|
||||||
|
paket-files/
|
||||||
|
|
||||||
|
# FAKE - F# Make
|
||||||
|
.fake/
|
||||||
|
|
||||||
|
# CodeRush personal settings
|
||||||
|
.cr/personal
|
||||||
|
|
||||||
|
# Python Tools for Visual Studio (PTVS)
|
||||||
|
__pycache__/
|
||||||
|
*.pyc
|
||||||
|
|
||||||
|
# Cake - Uncomment if you are using it
|
||||||
|
# tools/**
|
||||||
|
# !tools/packages.config
|
||||||
|
|
||||||
|
# Tabs Studio
|
||||||
|
*.tss
|
||||||
|
|
||||||
|
# Telerik's JustMock configuration file
|
||||||
|
*.jmconfig
|
||||||
|
|
||||||
|
# BizTalk build output
|
||||||
|
*.btp.cs
|
||||||
|
*.btm.cs
|
||||||
|
*.odx.cs
|
||||||
|
*.xsd.cs
|
||||||
|
|
||||||
|
# OpenCover UI analysis results
|
||||||
|
OpenCover/
|
||||||
|
|
||||||
|
# Azure Stream Analytics local run output
|
||||||
|
ASALocalRun/
|
||||||
|
|
||||||
|
# MSBuild Binary and Structured Log
|
||||||
|
*.binlog
|
||||||
|
|
||||||
|
# NVidia Nsight GPU debugger configuration file
|
||||||
|
*.nvuser
|
||||||
|
|
||||||
|
# MFractors (Xamarin productivity tool) working folder
|
||||||
|
.mfractor/
|
||||||
|
|
||||||
|
# Local History for Visual Studio
|
||||||
|
.localhistory/
|
||||||
|
|
||||||
|
# BeatPulse healthcheck temp database
|
||||||
|
healthchecksdb
|
||||||
|
|
||||||
|
# Backup folder for Package Reference Convert tool in Visual Studio 2017
|
||||||
|
MigrationBackup/
|
||||||
|
|
||||||
|
# Ionide (cross platform F# VS Code tools) working folder
|
||||||
|
.ionide/
|
||||||
|
|
||||||
|
# Fody - auto-generated XML schema
|
||||||
|
FodyWeavers.xsd
|
||||||
|
|
Binary file not shown.
|
@ -2,6 +2,7 @@
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
|
using System.Threading;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace WindowsFormsApplication1
|
namespace WindowsFormsApplication1
|
||||||
|
@ -47,29 +48,7 @@ namespace WindowsFormsApplication1
|
||||||
textBox2.Text += ("Компиляция " + codeFilename + " в " +
|
textBox2.Text += ("Компиляция " + codeFilename + " в " +
|
||||||
Path.GetFileNameWithoutExtension(codeFilename) + ".exe с помощью " +
|
Path.GetFileNameWithoutExtension(codeFilename) + ".exe с помощью " +
|
||||||
mingwDir + "\\bin\\mingw32-g++.exe:" + Environment.NewLine + Environment.NewLine);
|
mingwDir + "\\bin\\mingw32-g++.exe:" + Environment.NewLine + Environment.NewLine);
|
||||||
|
new Thread(new ThreadStart(CompilingFunction)).Start();
|
||||||
Process mingwp = new Process();
|
|
||||||
mingwp.StartInfo = new ProcessStartInfo()
|
|
||||||
{
|
|
||||||
FileName = mingwDir + "\\bin\\mingw32-g++.exe",
|
|
||||||
Arguments = codeFilename + " -o " + Path.GetDirectoryName(codeFilename) + "\\" +
|
|
||||||
Path.GetFileNameWithoutExtension(codeFilename) + ".exe",
|
|
||||||
UseShellExecute = false,
|
|
||||||
WindowStyle = ProcessWindowStyle.Hidden,
|
|
||||||
StandardOutputEncoding = Encoding.GetEncoding(866),
|
|
||||||
StandardErrorEncoding = Encoding.GetEncoding(866),
|
|
||||||
CreateNoWindow = true,
|
|
||||||
RedirectStandardOutput = true,
|
|
||||||
RedirectStandardError = true
|
|
||||||
};
|
|
||||||
mingwp.OutputDataReceived += new DataReceivedEventHandler(CompilerOutputHandler);
|
|
||||||
mingwp.ErrorDataReceived += new DataReceivedEventHandler(CompilerOutputHandler);
|
|
||||||
mingwp.Start();
|
|
||||||
mingwp.BeginOutputReadLine();
|
|
||||||
mingwp.BeginErrorReadLine();
|
|
||||||
mingwp.WaitForExit(10000);
|
|
||||||
|
|
||||||
_ = MessageBox.Show("Готово!");
|
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
@ -83,9 +62,34 @@ namespace WindowsFormsApplication1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void CompilingFunction()
|
||||||
|
{
|
||||||
|
Process mingwp = new Process();
|
||||||
|
mingwp.StartInfo = new ProcessStartInfo()
|
||||||
|
{
|
||||||
|
FileName = mingwDir + "\\bin\\mingw32-g++.exe",
|
||||||
|
Arguments = codeFilename + " -o " + Path.GetDirectoryName(codeFilename) + "\\" +
|
||||||
|
Path.GetFileNameWithoutExtension(codeFilename) + ".exe",
|
||||||
|
UseShellExecute = false,
|
||||||
|
WindowStyle = ProcessWindowStyle.Hidden,
|
||||||
|
StandardOutputEncoding = Encoding.GetEncoding(866),
|
||||||
|
StandardErrorEncoding = Encoding.GetEncoding(866),
|
||||||
|
CreateNoWindow = true,
|
||||||
|
RedirectStandardOutput = true,
|
||||||
|
RedirectStandardError = true
|
||||||
|
};
|
||||||
|
mingwp.OutputDataReceived += new DataReceivedEventHandler(CompilerOutputHandler);
|
||||||
|
mingwp.ErrorDataReceived += new DataReceivedEventHandler(CompilerOutputHandler);
|
||||||
|
mingwp.Start();
|
||||||
|
mingwp.BeginOutputReadLine();
|
||||||
|
mingwp.BeginErrorReadLine();
|
||||||
|
mingwp.WaitForExit(20000);
|
||||||
|
textBox2.Invoke(new Action(() => { textBox2.AppendText("Готово!" + Environment.NewLine); }));
|
||||||
|
}
|
||||||
|
|
||||||
private void CompilerOutputHandler(object sendingProcess, DataReceivedEventArgs outputLine)
|
private void CompilerOutputHandler(object sendingProcess, DataReceivedEventArgs outputLine)
|
||||||
{
|
{
|
||||||
textBox2.Invoke(new Action(() => { textBox2.Text += (outputLine.Data + Environment.NewLine); }));
|
textBox2.Invoke(new Action(() => { textBox2.AppendText(outputLine.Data + Environment.NewLine); }));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -239,78 +239,86 @@ namespace WindowsFormsApplication1
|
||||||
|
|
||||||
if (saveFileDialog1.ShowDialog() == DialogResult.OK)
|
if (saveFileDialog1.ShowDialog() == DialogResult.OK)
|
||||||
{
|
{
|
||||||
mainFilename = saveFileDialog1.FileName;
|
try
|
||||||
|
|
||||||
//Adding TXLibrary and pictures
|
|
||||||
File.Copy("TXLib.h", Path.GetDirectoryName(mainFilename) + "\\TXLib.h", true);
|
|
||||||
string dir_path = Path.GetDirectoryName(mainFilename) + "\\Pictures";
|
|
||||||
if (!Directory.Exists(dir_path))
|
|
||||||
{
|
{
|
||||||
Directory.CreateDirectory(dir_path);
|
mainFilename = saveFileDialog1.FileName;
|
||||||
}
|
|
||||||
|
|
||||||
if (addressBackground != dir_path + "\\" + Path.GetFileName(addressBackground))
|
//Adding TXLibrary and pictures
|
||||||
{
|
File.WriteAllText(Path.GetDirectoryName(mainFilename) + "\\TXLib.h", Properties.Resources.TXLib);
|
||||||
File.Copy(addressBackground, dir_path + "\\" + Path.GetFileName(addressBackground), true);
|
string dir_path = Path.GetDirectoryName(mainFilename) + "\\Pictures";
|
||||||
}
|
if (!Directory.Exists(dir_path))
|
||||||
|
{
|
||||||
Files.CreateStruct(mainFilename);
|
Directory.CreateDirectory(dir_path);
|
||||||
Files.OpenMain(mainFilename, PictureBoxBackground, addressBackground);
|
}
|
||||||
|
|
||||||
for (int nomer = 0; nomer < nomerPersa; nomer++)
|
|
||||||
{
|
|
||||||
File.Copy(persons[nomer].address, dir_path + "\\" + Path.GetFileName(persons[nomer].address), true);
|
|
||||||
|
|
||||||
if (dir_path == dir_path + "\\" + Path.GetFileName(persons[nomer].address))
|
if (addressBackground != dir_path + "\\" + Path.GetFileName(addressBackground))
|
||||||
|
{
|
||||||
|
File.Copy(addressBackground, dir_path + "\\" + Path.GetFileName(addressBackground), true);
|
||||||
|
}
|
||||||
|
|
||||||
|
Files.CreateStruct(mainFilename);
|
||||||
|
Files.OpenMain(mainFilename, PictureBoxBackground, addressBackground);
|
||||||
|
|
||||||
|
for (int nomer = 0; nomer < nomerPersa; nomer++)
|
||||||
{
|
{
|
||||||
File.Copy(persons[nomer].address, dir_path + "\\" + Path.GetFileName(persons[nomer].address), true);
|
File.Copy(persons[nomer].address, dir_path + "\\" + Path.GetFileName(persons[nomer].address), true);
|
||||||
|
|
||||||
|
if (dir_path == dir_path + "\\" + Path.GetFileName(persons[nomer].address))
|
||||||
|
{
|
||||||
|
File.Copy(persons[nomer].address, dir_path + "\\" + Path.GetFileName(persons[nomer].address), true);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (persons[nomer].moveside == "Прямо")
|
||||||
|
{
|
||||||
|
Line.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
|
}
|
||||||
|
else if (persons[nomer].moveside == "Волнами")
|
||||||
|
{
|
||||||
|
Sinus.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
|
}
|
||||||
|
else if (persons[nomer].moveside == "Кругами")
|
||||||
|
{
|
||||||
|
Circle.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
|
}
|
||||||
|
else if (persons[nomer].moveside == "Диагонально")
|
||||||
|
{
|
||||||
|
Line.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (persons[nomer].moveside == "Прямо")
|
Files.OpenWhile(mainFilename, maxTime);
|
||||||
|
|
||||||
|
for (int nomer = 0; nomer < nomerPersa; nomer++)
|
||||||
{
|
{
|
||||||
Line.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
if (persons[nomer].moveside == "Прямо")
|
||||||
}
|
{
|
||||||
else if (persons[nomer].moveside == "Волнами")
|
Line.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
{
|
}
|
||||||
Sinus.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
else if (persons[nomer].moveside == "Волнами")
|
||||||
}
|
{
|
||||||
else if (persons[nomer].moveside == "Кругами")
|
Sinus.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
{
|
}
|
||||||
Circle.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
else if (persons[nomer].moveside == "Кругами")
|
||||||
}
|
{
|
||||||
else if (persons[nomer].moveside == "Диагонально")
|
Circle.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
{
|
}
|
||||||
Line.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
else if (persons[nomer].moveside == "Диагонально")
|
||||||
|
{
|
||||||
|
Line.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Files.CloseWhile(mainFilename);
|
||||||
|
DeletePics(mainFilename, nomerPersa);
|
||||||
|
Files.Ending(mainFilename, checkBox1.Checked);
|
||||||
|
|
||||||
|
MessageBox.Show("Готово!");
|
||||||
}
|
}
|
||||||
|
catch (Exception ex)
|
||||||
Files.OpenWhile(mainFilename, maxTime);
|
|
||||||
|
|
||||||
for (int nomer = 0; nomer < nomerPersa; nomer++)
|
|
||||||
{
|
{
|
||||||
if (persons[nomer].moveside == "Прямо")
|
_ = MessageBox.Show("Произошла ошибка!\n" + ex.Message, "Ошибка",
|
||||||
{
|
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||||
Line.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
|
||||||
}
|
|
||||||
else if (persons[nomer].moveside == "Волнами")
|
|
||||||
{
|
|
||||||
Sinus.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
|
||||||
}
|
|
||||||
else if (persons[nomer].moveside == "Кругами")
|
|
||||||
{
|
|
||||||
Circle.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
|
||||||
}
|
|
||||||
else if (persons[nomer].moveside == "Диагонально")
|
|
||||||
{
|
|
||||||
Line.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Files.CloseWhile(mainFilename);
|
|
||||||
DeletePics(mainFilename, nomerPersa);
|
|
||||||
Files.Ending(mainFilename, checkBox1.Checked);
|
|
||||||
|
|
||||||
MessageBox.Show("Готово!");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -344,11 +352,11 @@ namespace WindowsFormsApplication1
|
||||||
|
|
||||||
private void Char_Info_Click(object sender, EventArgs e)
|
private void Char_Info_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
this.leftPanel.Controls.Remove(persons[nomerPersa - 1].l1);
|
leftPanel.Controls.Remove(persons[nomerPersa - 1].l1);
|
||||||
this.leftPanel.Controls.Remove(persons[nomerPersa - 1].l2);
|
leftPanel.Controls.Remove(persons[nomerPersa - 1].l2);
|
||||||
this.leftPanel.Controls.Remove(persons[nomerPersa - 1].l3);
|
leftPanel.Controls.Remove(persons[nomerPersa - 1].l3);
|
||||||
this.leftPanel.Controls.Remove(persons[nomerPersa - 1].b1);
|
leftPanel.Controls.Remove(persons[nomerPersa - 1].b1);
|
||||||
this.leftPanel.Controls.Remove(persons[nomerPersa - 1].b2);
|
leftPanel.Controls.Remove(persons[nomerPersa - 1].b2);
|
||||||
nomerPersa--;
|
nomerPersa--;
|
||||||
yPersa -= 30;
|
yPersa -= 30;
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 10 KiB |
Binary file not shown.
Before Width: | Height: | Size: 147 KiB After Width: | Height: | Size: 147 KiB |
|
@ -19,7 +19,7 @@ namespace WindowsFormsApplication1.Properties {
|
||||||
// с помощью такого средства, как ResGen или Visual Studio.
|
// с помощью такого средства, как ResGen или Visual Studio.
|
||||||
// Чтобы добавить или удалить член, измените файл .ResX и снова запустите ResGen
|
// Чтобы добавить или удалить член, измените файл .ResX и снова запустите ResGen
|
||||||
// с параметром /str или перестройте свой проект VS.
|
// с параметром /str или перестройте свой проект VS.
|
||||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")]
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")]
|
||||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
internal class Resources {
|
internal class Resources {
|
||||||
|
@ -59,5 +59,20 @@ namespace WindowsFormsApplication1.Properties {
|
||||||
resourceCulture = value;
|
resourceCulture = value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Ищет локализованную строку, похожую на //=================================================================================================================
|
||||||
|
///// [These sections are for folding control in Code::Blocks]
|
||||||
|
/////{ [Best viewed with "Fold all on file open" option enabled] [best screen width is 115 chars]
|
||||||
|
/////=================================================================================================================
|
||||||
|
/////!
|
||||||
|
/////! @file TXLib.h
|
||||||
|
/////! @brief Библиотека Тупого Художника (The Dumb Artist Libr [остаток строки не уместился]";.
|
||||||
|
/// </summary>
|
||||||
|
internal static string TXLib {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("TXLib", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,7 +46,7 @@
|
||||||
|
|
||||||
mimetype: application/x-microsoft.net.object.binary.base64
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
value : The object must be serialized with
|
value : The object must be serialized with
|
||||||
: System.Serialization.Formatters.Binary.BinaryFormatter
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
: and then encoded with base64 encoding.
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
mimetype: application/x-microsoft.net.object.soap.base64
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
@ -60,6 +60,7 @@
|
||||||
: and then encoded with base64 encoding.
|
: and then encoded with base64 encoding.
|
||||||
-->
|
-->
|
||||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
<xsd:element name="root" msdata:IsDataSet="true">
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
<xsd:complexType>
|
<xsd:complexType>
|
||||||
<xsd:choice maxOccurs="unbounded">
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
@ -68,9 +69,10 @@
|
||||||
<xsd:sequence>
|
<xsd:sequence>
|
||||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
</xsd:sequence>
|
</xsd:sequence>
|
||||||
<xsd:attribute name="name" type="xsd:string" />
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
<xsd:attribute name="type" type="xsd:string" />
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
</xsd:complexType>
|
</xsd:complexType>
|
||||||
</xsd:element>
|
</xsd:element>
|
||||||
<xsd:element name="assembly">
|
<xsd:element name="assembly">
|
||||||
|
@ -85,9 +87,10 @@
|
||||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
</xsd:sequence>
|
</xsd:sequence>
|
||||||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
</xsd:complexType>
|
</xsd:complexType>
|
||||||
</xsd:element>
|
</xsd:element>
|
||||||
<xsd:element name="resheader">
|
<xsd:element name="resheader">
|
||||||
|
@ -109,9 +112,13 @@
|
||||||
<value>2.0</value>
|
<value>2.0</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="reader">
|
<resheader name="reader">
|
||||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="writer">
|
<resheader name="writer">
|
||||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
|
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||||
|
<data name="TXLib" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\TXLib.h;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;windows-1251</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
File diff suppressed because it is too large
Load diff
|
@ -94,6 +94,9 @@
|
||||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
</Compile>
|
</Compile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="TXLib.h" />
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
Other similar extension points exist, see Microsoft.Common.targets.
|
Other similar extension points exist, see Microsoft.Common.targets.
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<configuration>
|
||||||
|
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1"/></startup></configuration>
|
Binary file not shown.
Binary file not shown.
Before Width: | Height: | Size: 10 KiB |
|
@ -0,0 +1,4 @@
|
||||||
|
// <autogenerated />
|
||||||
|
using System;
|
||||||
|
using System.Reflection;
|
||||||
|
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.6.1", FrameworkDisplayName = ".NET Framework 4.6.1")]
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -0,0 +1 @@
|
||||||
|
a71191b9b8c49cadecaa2e05cc537d361f14ffd5
|
|
@ -0,0 +1,11 @@
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe.config
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.pdb
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csprojAssemblyReference.cache
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.CompileForm.resources
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.MainForm.resources
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.Properties.Resources.resources
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.GenerateResource.cache
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.CoreCompileInputs.cache
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.exe
|
||||||
|
C:\Users\Acer\VisualStudio\source\repos\MultRedactor\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.pdb
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Add table
Reference in a new issue