From 7363635e9019e29395f834c1f5ea2976e543530b Mon Sep 17 00:00:00 2001 From: Niklas K Date: Sat, 7 Apr 2018 03:30:36 +0200 Subject: [PATCH] we qt now --- .clang-format | 4 + .gitattributes | 63 ------ .gitignore | 244 +-------------------- SCXParser.sln | 33 --- SCXParser/SCXParser.vcxproj | 172 --------------- SCXParser/SCXParser.vcxproj.filters | 84 ------- SCXParser/targetver.h | 8 - scxparser.pro | 39 ++++ {SCXParser => src}/CCDisassembler.cpp | 0 {SCXParser => src}/CCDisassembler.h | 0 {SCXParser => src}/DisassemblerMacros.h | 0 {SCXParser => src}/SC3Argument.cpp | 0 {SCXParser => src}/SC3Argument.h | 0 {SCXParser => src}/SC3BaseDisassembler.cpp | 0 {SCXParser => src}/SC3BaseDisassembler.h | 0 {SCXParser => src}/SC3CodeBlock.cpp | 0 {SCXParser => src}/SC3CodeBlock.h | 0 {SCXParser => src}/SC3Expression.cpp | 0 {SCXParser => src}/SC3Expression.h | 0 {SCXParser => src}/SC3Instruction.cpp | 0 {SCXParser => src}/SC3Instruction.h | 0 {SCXParser => src}/SCXFile.cpp | 0 {SCXParser => src}/SCXFile.h | 0 {SCXParser => src}/SCXParser.cpp | 0 {SCXParser => src}/SCXTypes.h | 0 {SCXParser => src}/SGHDDisassembler.cpp | 0 {SCXParser => src}/SGHDDisassembler.h | 0 {SCXParser => src}/ZeroDisassembler.cpp | 0 {SCXParser => src}/ZeroDisassembler.h | 0 29 files changed, 45 insertions(+), 602 deletions(-) create mode 100644 .clang-format delete mode 100644 .gitattributes delete mode 100644 SCXParser.sln delete mode 100644 SCXParser/SCXParser.vcxproj delete mode 100644 SCXParser/SCXParser.vcxproj.filters delete mode 100644 SCXParser/targetver.h create mode 100644 scxparser.pro rename {SCXParser => src}/CCDisassembler.cpp (100%) rename {SCXParser => src}/CCDisassembler.h (100%) rename {SCXParser => src}/DisassemblerMacros.h (100%) rename {SCXParser => src}/SC3Argument.cpp (100%) rename {SCXParser => src}/SC3Argument.h (100%) rename {SCXParser => src}/SC3BaseDisassembler.cpp (100%) rename {SCXParser => src}/SC3BaseDisassembler.h (100%) rename {SCXParser => src}/SC3CodeBlock.cpp (100%) rename {SCXParser => src}/SC3CodeBlock.h (100%) rename {SCXParser => src}/SC3Expression.cpp (100%) rename {SCXParser => src}/SC3Expression.h (100%) rename {SCXParser => src}/SC3Instruction.cpp (100%) rename {SCXParser => src}/SC3Instruction.h (100%) rename {SCXParser => src}/SCXFile.cpp (100%) rename {SCXParser => src}/SCXFile.h (100%) rename {SCXParser => src}/SCXParser.cpp (100%) rename {SCXParser => src}/SCXTypes.h (100%) rename {SCXParser => src}/SGHDDisassembler.cpp (100%) rename {SCXParser => src}/SGHDDisassembler.h (100%) rename {SCXParser => src}/ZeroDisassembler.cpp (100%) rename {SCXParser => src}/ZeroDisassembler.h (100%) diff --git a/.clang-format b/.clang-format new file mode 100644 index 0000000..dc37402 --- /dev/null +++ b/.clang-format @@ -0,0 +1,4 @@ +--- +BasedOnStyle: Google +SortIncludes: false +UseTab: Never \ No newline at end of file diff --git a/.gitattributes b/.gitattributes deleted file mode 100644 index 1ff0c42..0000000 --- a/.gitattributes +++ /dev/null @@ -1,63 +0,0 @@ -############################################################################### -# Set default behavior to automatically normalize line endings. -############################################################################### -* text=auto - -############################################################################### -# Set default behavior for command prompt diff. -# -# This is need for earlier builds of msysgit that does not have it on by -# default for csharp files. -# Note: This is only used by command line -############################################################################### -#*.cs diff=csharp - -############################################################################### -# Set the merge driver for project and solution files -# -# Merging from the command prompt will add diff markers to the files if there -# are conflicts (Merging from VS is not affected by the settings below, in VS -# the diff markers are never inserted). Diff markers may cause the following -# file extensions to fail to load in VS. An alternative would be to treat -# these files as binary and thus will always conflict and require user -# intervention with every merge. To do so, just uncomment the entries below -############################################################################### -#*.sln merge=binary -#*.csproj merge=binary -#*.vbproj merge=binary -#*.vcxproj merge=binary -#*.vcproj merge=binary -#*.dbproj merge=binary -#*.fsproj merge=binary -#*.lsproj merge=binary -#*.wixproj merge=binary -#*.modelproj merge=binary -#*.sqlproj merge=binary -#*.wwaproj merge=binary - -############################################################################### -# behavior for image files -# -# image files are treated as binary by default. -############################################################################### -#*.jpg binary -#*.png binary -#*.gif binary - -############################################################################### -# diff behavior for common document formats -# -# Convert binary document formats to text before diffing them. This feature -# is only available from the command line. Turn it on by uncommenting the -# entries below. -############################################################################### -#*.doc diff=astextplain -#*.DOC diff=astextplain -#*.docx diff=astextplain -#*.DOCX diff=astextplain -#*.dot diff=astextplain -#*.DOT diff=astextplain -#*.pdf diff=astextplain -#*.PDF diff=astextplain -#*.rtf diff=astextplain -#*.RTF diff=astextplain diff --git a/.gitignore b/.gitignore index 1c9a181..04655a3 100644 --- a/.gitignore +++ b/.gitignore @@ -1,242 +1,2 @@ -## Ignore Visual Studio temporary files, build results, and -## files generated by popular Visual Studio add-ons. - -# User-specific files -*.suo -*.user -*.userosscache -*.sln.docstates - -# User-specific files (MonoDevelop/Xamarin Studio) -*.userprefs - -# Build results -[Dd]ebug/ -[Dd]ebugPublic/ -[Rr]elease/ -[Rr]eleases/ -[Xx]64/ -[Xx]86/ -[Bb]uild/ -bld/ -[Bb]in/ -[Oo]bj/ - -# Visual Studio 2015 cache/options directory -.vs/ -# Uncomment if you have tasks that create the project's static files in wwwroot -#wwwroot/ - -# MSTest test Results -[Tt]est[Rr]esult*/ -[Bb]uild[Ll]og.* - -# NUNIT -*.VisualState.xml -TestResult.xml - -# Build Results of an ATL Project -[Dd]ebugPS/ -[Rr]eleasePS/ -dlldata.c - -# DNX -project.lock.json -artifacts/ - -*_i.c -*_p.c -*_i.h -*.ilk -*.meta -*.obj -*.pch -*.pdb -*.pgc -*.pgd -*.rsp -*.sbr -*.tlb -*.tli -*.tlh -*.tmp -*.tmp_proj -*.log -*.vspscc -*.vssscc -.builds -*.pidb -*.svclog -*.scc - -# Chutzpah Test files -_Chutzpah* - -# Visual C++ cache files -ipch/ -*.aps -*.ncb -*.opendb -*.opensdf -*.sdf -*.cachefile -*.VC.db - -# Visual Studio profiler -*.psess -*.vsp -*.vspx -*.sap - -# TFS 2012 Local Workspace -$tf/ - -# Guidance Automation Toolkit -*.gpState - -# ReSharper is a .NET coding add-in -_ReSharper*/ -*.[Rr]e[Ss]harper -*.DotSettings.user - -# JustCode is a .NET coding add-in -.JustCode - -# TeamCity is a build add-in -_TeamCity* - -# DotCover is a Code Coverage Tool -*.dotCover - -# 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 - -# TODO: Un-comment the next line if you do not want to checkin -# your web deploy settings because they may include unencrypted -# passwords -#*.pubxml -*.publishproj - -# NuGet Packages -*.nupkg -# The packages folder can be ignored because of Package Restore -**/packages/* -# except build/, which is used as an MSBuild target. -!**/packages/build/ -# Uncomment if necessary however generally it will be regenerated when needed -#!**/packages/repositories.config -# NuGet v3's project.json files produces more ignoreable files -*.nuget.props -*.nuget.targets - -# Microsoft Azure Build Output -csx/ -*.build.csdef - -# Microsoft Azure Emulator -ecf/ -rcf/ - -# Windows Store app package directory -AppPackages/ -BundleArtifacts/ - -# 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/ -[Ss]tyle[Cc]op.* -~$* -*~ -*.dbmdl -*.dbproj.schemaview -*.pfx -*.publishsettings -node_modules/ -orleans.codegen.cs - -# 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 - -# SQL Server files -*.mdf -*.ldf - -# Business Intelligence projects -*.rdl.data -*.bim.layout -*.bim_*.settings - -# Microsoft Fakes -FakesAssemblies/ - -# GhostDoc plugin setting file -*.GhostDoc.xml - -# Node.js Tools for Visual Studio -.ntvs_analysis.dat - -# Visual Studio 6 build log -*.plg - -# Visual Studio 6 workspace options file -*.opt - -# Visual Studio LightSwitch build output -**/*.HTMLClient/GeneratedArtifacts -**/*.DesktopClient/GeneratedArtifacts -**/*.DesktopClient/ModelManifest.xml -**/*.Server/GeneratedArtifacts -**/*.Server/ModelManifest.xml -_Pvt_Extensions - -# LightSwitch generated files -GeneratedArtifacts/ -ModelManifest.xml - -# Paket dependency manager -.paket/paket.exe - -# FAKE - F# Make -.fake/ +build/ +*.user \ No newline at end of file diff --git a/SCXParser.sln b/SCXParser.sln deleted file mode 100644 index 4e32cec..0000000 --- a/SCXParser.sln +++ /dev/null @@ -1,33 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 14 -VisualStudioVersion = 14.0.25420.1 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SCXParser", "SCXParser\SCXParser.vcxproj", "{FE8EC040-03CA-447F-BF9F-15D8B5D387A9}" -EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{755E31E8-FCAE-494D-BA01-21CB6158EFB7}" - ProjectSection(SolutionItems) = preProject - README.md = README.md - EndProjectSection -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|x64 = Debug|x64 - Debug|x86 = Debug|x86 - Release|x64 = Release|x64 - Release|x86 = Release|x86 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Debug|x64.ActiveCfg = Debug|x64 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Debug|x64.Build.0 = Debug|x64 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Debug|x86.ActiveCfg = Debug|Win32 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Debug|x86.Build.0 = Debug|Win32 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Release|x64.ActiveCfg = Release|x64 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Release|x64.Build.0 = Release|x64 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Release|x86.ActiveCfg = Release|Win32 - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9}.Release|x86.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/SCXParser/SCXParser.vcxproj b/SCXParser/SCXParser.vcxproj deleted file mode 100644 index a919c55..0000000 --- a/SCXParser/SCXParser.vcxproj +++ /dev/null @@ -1,172 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - Debug - x64 - - - Release - x64 - - - - {FE8EC040-03CA-447F-BF9F-15D8B5D387A9} - Win32Proj - SCXParser - 8.1 - - - - Application - true - v140 - Unicode - - - Application - false - v140 - true - Unicode - - - Application - true - v140 - Unicode - - - Application - false - v140 - true - Unicode - - - - - - - - - - - - - - - - - - - - - true - - - true - - - false - - - false - - - - NotUsing - Level3 - Disabled - WIN32;_DEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - true - - - Console - true - - - - - NotUsing - Level3 - Disabled - _DEBUG;_CONSOLE;%(PreprocessorDefinitions) - true - - - Console - true - - - - - Level3 - NotUsing - MaxSpeed - true - true - WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) - true - - - Console - true - true - true - - - - - Level3 - NotUsing - true - true - NDEBUG;_CONSOLE;%(PreprocessorDefinitions) - true - Full - - - Console - true - true - true - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/SCXParser/SCXParser.vcxproj.filters b/SCXParser/SCXParser.vcxproj.filters deleted file mode 100644 index 9410ce1..0000000 --- a/SCXParser/SCXParser.vcxproj.filters +++ /dev/null @@ -1,84 +0,0 @@ - - - - - {4FC737F1-C7A5-4376-A066-2A32D752A2FF} - cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx - - - {93995380-89BD-4b04-88EB-625FBE52EBFB} - h;hh;hpp;hxx;hm;inl;inc;xsd - - - {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} - rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms - - - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - \ No newline at end of file diff --git a/SCXParser/targetver.h b/SCXParser/targetver.h deleted file mode 100644 index 87c0086..0000000 --- a/SCXParser/targetver.h +++ /dev/null @@ -1,8 +0,0 @@ -#pragma once - -// Including SDKDDKVer.h defines the highest available Windows platform. - -// If you wish to build your application for a previous Windows platform, include WinSDKVer.h and -// set the _WIN32_WINNT macro to the platform you wish to support before including SDKDDKVer.h. - -#include diff --git a/scxparser.pro b/scxparser.pro new file mode 100644 index 0000000..19a0329 --- /dev/null +++ b/scxparser.pro @@ -0,0 +1,39 @@ +QT += core gui widgets + +TARGET = scxparser +TEMPLATE = app +CONFIG += console + +# The following define makes your compiler emit warnings if you use +# any feature of Qt which has been marked as deprecated (the exact warnings +# depend on your compiler). Please consult the documentation of the +# deprecated API in order to know how to port your code away from it. +DEFINES += QT_DEPRECATED_WARNINGS + +# This crap lets us run files with the same name, in the same project, through moc, without conflicts. +# Good idea? Probably not. + +CONFIG += object_parallel_to_source +CONFIG += no_batch # above doesn't properly work with nmake without this + +defineReplace(fnPath) { + variable = $$1 + variable = $$replace(variable, $$basename(variable), "") + variable = $$replace(variable, "\\\\", "_") + variable = $$replace(variable, "\.", "_") + variable = $$replace(variable, "/", "_") + return($$variable) +} + +QMAKE_H_MOD_MOC = moc_${QMAKE_FUNC_fnPath} +QMAKE_CPP_MOD_MOC = moc_${QMAKE_FUNC_fnPath} +QMAKE_MOD_RCC = qrc${QMAKE_FUNC_fnPath} + +# But I'm going with it anyway. + +INCLUDEPATH += src + +SOURCES += $$files(src/*.cpp, true) +SOURCES += $$files(src/*.c, true) +HEADERS += $$files(src/*.h, true) +FORMS += $$files(src/*.ui, true) diff --git a/SCXParser/CCDisassembler.cpp b/src/CCDisassembler.cpp similarity index 100% rename from SCXParser/CCDisassembler.cpp rename to src/CCDisassembler.cpp diff --git a/SCXParser/CCDisassembler.h b/src/CCDisassembler.h similarity index 100% rename from SCXParser/CCDisassembler.h rename to src/CCDisassembler.h diff --git a/SCXParser/DisassemblerMacros.h b/src/DisassemblerMacros.h similarity index 100% rename from SCXParser/DisassemblerMacros.h rename to src/DisassemblerMacros.h diff --git a/SCXParser/SC3Argument.cpp b/src/SC3Argument.cpp similarity index 100% rename from SCXParser/SC3Argument.cpp rename to src/SC3Argument.cpp diff --git a/SCXParser/SC3Argument.h b/src/SC3Argument.h similarity index 100% rename from SCXParser/SC3Argument.h rename to src/SC3Argument.h diff --git a/SCXParser/SC3BaseDisassembler.cpp b/src/SC3BaseDisassembler.cpp similarity index 100% rename from SCXParser/SC3BaseDisassembler.cpp rename to src/SC3BaseDisassembler.cpp diff --git a/SCXParser/SC3BaseDisassembler.h b/src/SC3BaseDisassembler.h similarity index 100% rename from SCXParser/SC3BaseDisassembler.h rename to src/SC3BaseDisassembler.h diff --git a/SCXParser/SC3CodeBlock.cpp b/src/SC3CodeBlock.cpp similarity index 100% rename from SCXParser/SC3CodeBlock.cpp rename to src/SC3CodeBlock.cpp diff --git a/SCXParser/SC3CodeBlock.h b/src/SC3CodeBlock.h similarity index 100% rename from SCXParser/SC3CodeBlock.h rename to src/SC3CodeBlock.h diff --git a/SCXParser/SC3Expression.cpp b/src/SC3Expression.cpp similarity index 100% rename from SCXParser/SC3Expression.cpp rename to src/SC3Expression.cpp diff --git a/SCXParser/SC3Expression.h b/src/SC3Expression.h similarity index 100% rename from SCXParser/SC3Expression.h rename to src/SC3Expression.h diff --git a/SCXParser/SC3Instruction.cpp b/src/SC3Instruction.cpp similarity index 100% rename from SCXParser/SC3Instruction.cpp rename to src/SC3Instruction.cpp diff --git a/SCXParser/SC3Instruction.h b/src/SC3Instruction.h similarity index 100% rename from SCXParser/SC3Instruction.h rename to src/SC3Instruction.h diff --git a/SCXParser/SCXFile.cpp b/src/SCXFile.cpp similarity index 100% rename from SCXParser/SCXFile.cpp rename to src/SCXFile.cpp diff --git a/SCXParser/SCXFile.h b/src/SCXFile.h similarity index 100% rename from SCXParser/SCXFile.h rename to src/SCXFile.h diff --git a/SCXParser/SCXParser.cpp b/src/SCXParser.cpp similarity index 100% rename from SCXParser/SCXParser.cpp rename to src/SCXParser.cpp diff --git a/SCXParser/SCXTypes.h b/src/SCXTypes.h similarity index 100% rename from SCXParser/SCXTypes.h rename to src/SCXTypes.h diff --git a/SCXParser/SGHDDisassembler.cpp b/src/SGHDDisassembler.cpp similarity index 100% rename from SCXParser/SGHDDisassembler.cpp rename to src/SGHDDisassembler.cpp diff --git a/SCXParser/SGHDDisassembler.h b/src/SGHDDisassembler.h similarity index 100% rename from SCXParser/SGHDDisassembler.h rename to src/SGHDDisassembler.h diff --git a/SCXParser/ZeroDisassembler.cpp b/src/ZeroDisassembler.cpp similarity index 100% rename from SCXParser/ZeroDisassembler.cpp rename to src/ZeroDisassembler.cpp diff --git a/SCXParser/ZeroDisassembler.h b/src/ZeroDisassembler.h similarity index 100% rename from SCXParser/ZeroDisassembler.h rename to src/ZeroDisassembler.h