initial commit
63
.gitattributes
vendored
Normal file
@@ -0,0 +1,63 @@
|
||||
###############################################################################
|
||||
# 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
|
||||
350
.gitignore
vendored
Normal file
@@ -0,0 +1,350 @@
|
||||
## Ignore Visual Studio temporary files, build results, and
|
||||
## files generated by popular Visual Studio add-ons.
|
||||
##
|
||||
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
|
||||
|
||||
# User-specific files
|
||||
*.rsuser
|
||||
*.suo
|
||||
*.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/
|
||||
[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/
|
||||
|
||||
# StyleCop
|
||||
StyleCopReport.xml
|
||||
|
||||
# Files built by Visual Studio
|
||||
*_i.c
|
||||
*_p.c
|
||||
*_h.h
|
||||
*.ilk
|
||||
*.meta
|
||||
*.obj
|
||||
*.iobj
|
||||
*.pch
|
||||
*.pdb
|
||||
*.ipdb
|
||||
*.pgc
|
||||
*.pgd
|
||||
*.rsp
|
||||
*.sbr
|
||||
*.tlb
|
||||
*.tli
|
||||
*.tlh
|
||||
*.tmp
|
||||
*.tmp_proj
|
||||
*_wpftmp.csproj
|
||||
*.log
|
||||
*.vspscc
|
||||
*.vssscc
|
||||
.builds
|
||||
*.pidb
|
||||
*.svclog
|
||||
*.scc
|
||||
|
||||
# Chutzpah Test files
|
||||
_Chutzpah*
|
||||
|
||||
# Visual C++ cache files
|
||||
ipch/
|
||||
*.aps
|
||||
*.ncb
|
||||
*.opendb
|
||||
*.opensdf
|
||||
*.sdf
|
||||
*.cachefile
|
||||
*.VC.db
|
||||
*.VC.VC.opendb
|
||||
|
||||
# Visual Studio profiler
|
||||
*.psess
|
||||
*.vsp
|
||||
*.vspx
|
||||
*.sap
|
||||
|
||||
# Visual Studio Trace Files
|
||||
*.e2e
|
||||
|
||||
# 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
|
||||
|
||||
# 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/
|
||||
25
ModpackUpdater.sln
Normal file
@@ -0,0 +1,25 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.2.32526.322
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{778DAE3C-4631-46EA-AA77-85C1314464D9}") = "ModpackUpdater", "ModpackUpdater\ModpackUpdater.vbproj", "{33DD239C-1F33-40F9-908F-54BC02FBA420}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{33DD239C-1F33-40F9-908F-54BC02FBA420}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{33DD239C-1F33-40F9-908F-54BC02FBA420}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{33DD239C-1F33-40F9-908F-54BC02FBA420}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{33DD239C-1F33-40F9-908F-54BC02FBA420}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {322E6A6B-9F3E-4E88-8945-C98A9EF613BF}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
6
ModpackUpdater/App.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<appSettings>
|
||||
<add key="TelerikWinFormsThemeName" value="Office2019Dark" />
|
||||
</appSettings>
|
||||
</configuration>
|
||||
50
ModpackUpdater/AppConfig.vb
Normal file
@@ -0,0 +1,50 @@
|
||||
Imports System.IO
|
||||
|
||||
Imports Newtonsoft.Json.Linq
|
||||
|
||||
Public Class AppConfig
|
||||
|
||||
Public Property LastMinecraftProfilePath As string
|
||||
Public Property LastConfigFilePath As string
|
||||
|
||||
Public Shared ReadOnly Property Instance As AppConfig
|
||||
Get
|
||||
Static myInstance As AppConfig = Nothing
|
||||
|
||||
If myInstance Is Nothing Then
|
||||
If File.Exists(SettingsPath) Then
|
||||
myInstance = LoadConfig(SettingsPath)
|
||||
Else
|
||||
myInstance = New AppConfig
|
||||
End If
|
||||
End If
|
||||
|
||||
Return myInstance
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private Shared ReadOnly Property SettingsPath As string
|
||||
Get
|
||||
Static myPath As String = String.Empty
|
||||
Const AppDataDirectoryName As String = "MinecraftModpackUpdater"
|
||||
Const SettingsFileName As String = "Settings.json"
|
||||
|
||||
If String.IsNullOrEmpty(myPath) Then
|
||||
myPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), AppDataDirectoryName)
|
||||
Directory.CreateDirectory(myPath)
|
||||
myPath = Path.Combine(myPath, SettingsFileName)
|
||||
End If
|
||||
|
||||
Return myPath
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public Sub SaveConfig()
|
||||
File.WriteAllText(SettingsPath, JObject.FromObject(Me).ToString)
|
||||
End Sub
|
||||
|
||||
Private Shared Function LoadConfig(filePath As String) As AppConfig
|
||||
Return JObject.Parse(File.ReadAllText(filePath)).ToObject(Of AppConfig)
|
||||
End Function
|
||||
|
||||
End Class
|
||||
40
ModpackUpdater/ApplicationEvents.vb
Normal file
@@ -0,0 +1,40 @@
|
||||
Imports Microsoft.VisualBasic.ApplicationServices
|
||||
|
||||
Imports Telerik.WinControls
|
||||
|
||||
Namespace My
|
||||
' The following events are available for MyApplication:
|
||||
' Startup: Raised when the application starts, before the startup form is created.
|
||||
' Shutdown: Raised after all application forms are closed. This event is not raised if the application terminates abnormally.
|
||||
' UnhandledException: Raised if the application encounters an unhandled exception.
|
||||
' StartupNextInstance: Raised when launching a single-instance application and the application is already active.
|
||||
' NetworkAvailabilityChanged: Raised when the network connection is connected or disconnected.
|
||||
|
||||
' **NEW** ApplyApplicationDefaults: Raised when the application queries default values to be set for the application.
|
||||
|
||||
' Example:
|
||||
' Private Sub MyApplication_ApplyApplicationDefaults(sender As Object, e As ApplyApplicationDefaultsEventArgs) Handles Me.ApplyApplicationDefaults
|
||||
'
|
||||
' ' Setting the application-wide default Font:
|
||||
' e.Font = New Font(FontFamily.GenericSansSerif, 12, FontStyle.Regular)
|
||||
'
|
||||
' ' Setting the HighDpiMode for the Application:
|
||||
' e.HighDpiMode = HighDpiMode.PerMonitorV2
|
||||
'
|
||||
' ' If a splash dialog is used, this sets the minimum display time:
|
||||
' e.MinimumSplashScreenDisplayTime = 4000
|
||||
' End Sub
|
||||
|
||||
Partial Friend Class MyApplication
|
||||
|
||||
Private Sub MyApplication_ApplyApplicationDefaults(sender As Object, e As ApplyApplicationDefaultsEventArgs) Handles Me.ApplyApplicationDefaults
|
||||
Dim validTheme As Boolean =
|
||||
ThemeResolutionService.LoadPackageResource("ModpackUpdater.Office2019DarkBluePurple.tssp")
|
||||
|
||||
If validTheme Then
|
||||
ThemeResolutionService.ApplicationThemeName = "Office2019DarkBluePurple"
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
End Namespace
|
||||
|
After Width: | Height: | Size: 7.3 KiB |
355
ModpackUpdater/CustomThemes/Office2019DarkBluePurple.tssp
Normal file
85
ModpackUpdater/FiledialogFilters.Designer.vb
generated
Normal file
@@ -0,0 +1,85 @@
|
||||
'------------------------------------------------------------------------------
|
||||
' <auto-generated>
|
||||
' Dieser Code wurde von einem Tool generiert.
|
||||
' Laufzeitversion:4.0.30319.42000
|
||||
'
|
||||
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||
' der Code erneut generiert wird.
|
||||
' </auto-generated>
|
||||
'------------------------------------------------------------------------------
|
||||
|
||||
Option Strict On
|
||||
Option Explicit On
|
||||
|
||||
Imports System
|
||||
|
||||
Namespace My.Resources
|
||||
|
||||
'Diese Klasse wurde von der StronglyTypedResourceBuilder automatisch generiert
|
||||
'-Klasse über ein Tool wie ResGen oder Visual Studio automatisch generiert.
|
||||
'Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
|
||||
'mit der /str-Option erneut aus, oder Sie erstellen Ihr VS-Projekt neu.
|
||||
'''<summary>
|
||||
''' Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
|
||||
'''</summary>
|
||||
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0"), _
|
||||
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
||||
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute()> _
|
||||
Friend Class FiledialogFilters
|
||||
|
||||
Private Shared resourceMan As Global.System.Resources.ResourceManager
|
||||
|
||||
Private Shared resourceCulture As Global.System.Globalization.CultureInfo
|
||||
|
||||
<Global.System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")> _
|
||||
Friend Sub New()
|
||||
MyBase.New
|
||||
End Sub
|
||||
|
||||
'''<summary>
|
||||
''' Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
|
||||
'''</summary>
|
||||
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||
Friend Shared ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
|
||||
Get
|
||||
If Object.ReferenceEquals(resourceMan, Nothing) Then
|
||||
Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ModpackUpdater.FiledialogFilters", GetType(FiledialogFilters).Assembly)
|
||||
resourceMan = temp
|
||||
End If
|
||||
Return resourceMan
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
|
||||
''' Ressourcenzuordnungen, die diese stark typisierte Ressourcenklasse verwenden.
|
||||
'''</summary>
|
||||
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||
Friend Shared Property Culture() As Global.System.Globalization.CultureInfo
|
||||
Get
|
||||
Return resourceCulture
|
||||
End Get
|
||||
Set
|
||||
resourceCulture = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Json files (*.json) ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property JSON_Display() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("JSON_Display", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die *.json ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property JSON_Filter() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("JSON_Filter", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
End Class
|
||||
End Namespace
|
||||
126
ModpackUpdater/FiledialogFilters.resx
Normal file
@@ -0,0 +1,126 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: 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:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<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:sequence>
|
||||
<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="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="JSON_Display" xml:space="preserve">
|
||||
<value>Json files (*.json)</value>
|
||||
</data>
|
||||
<data name="JSON_Filter" xml:space="preserve">
|
||||
<value>*.json</value>
|
||||
</data>
|
||||
</root>
|
||||
242
ModpackUpdater/Form1.Designer.vb
generated
Normal file
@@ -0,0 +1,242 @@
|
||||
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
|
||||
Partial Class Form1
|
||||
|
||||
Inherits Telerik.WinControls.UI.RadForm
|
||||
|
||||
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
Try
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
Finally
|
||||
MyBase.Dispose(disposing)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
'Wird vom Windows Form-Designer benötigt.
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
|
||||
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(Form1))
|
||||
Me.RadLabel1 = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.RadLabel2 = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.RadLabel3 = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.RadLabel_Status = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder = New Telerik.WinControls.UI.RadTextBoxControl()
|
||||
Me.RadTextBoxControl_ModpackConfig = New Telerik.WinControls.UI.RadTextBoxControl()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.RadButton_Install = New Telerik.WinControls.UI.RadButton()
|
||||
Me.RadButton_CheckForUpdates = New Telerik.WinControls.UI.RadButton()
|
||||
Me.RadButton_EditModpackConfig = New Telerik.WinControls.UI.RadButton()
|
||||
Me.RadButton_SearchModpackConfig = New Telerik.WinControls.UI.RadButton()
|
||||
Me.RadButton_SearchMinecraftProfileFolder = New Telerik.WinControls.UI.RadButton()
|
||||
CType(Me.RadLabel1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadLabel2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadLabel3, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadLabel_Status, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadTextBoxControl_MinecraftProfileFolder, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadTextBoxControl_ModpackConfig, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.Panel1.SuspendLayout()
|
||||
CType(Me.RadButton_Install, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadButton_CheckForUpdates, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadButton_EditModpackConfig, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadButton_SearchModpackConfig, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadButton_SearchMinecraftProfileFolder, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'RadLabel1
|
||||
'
|
||||
Me.RadLabel1.Location = New System.Drawing.Point(3, 5)
|
||||
Me.RadLabel1.Name = "RadLabel1"
|
||||
Me.RadLabel1.Size = New System.Drawing.Size(135, 19)
|
||||
Me.RadLabel1.TabIndex = 0
|
||||
Me.RadLabel1.Text = "Minecraft profile folder:"
|
||||
'
|
||||
'RadLabel2
|
||||
'
|
||||
Me.RadLabel2.Location = New System.Drawing.Point(3, 63)
|
||||
Me.RadLabel2.Name = "RadLabel2"
|
||||
Me.RadLabel2.Size = New System.Drawing.Size(98, 19)
|
||||
Me.RadLabel2.TabIndex = 1
|
||||
Me.RadLabel2.Text = "Modpack config:"
|
||||
'
|
||||
'RadLabel3
|
||||
'
|
||||
Me.RadLabel3.Location = New System.Drawing.Point(3, 121)
|
||||
Me.RadLabel3.Name = "RadLabel3"
|
||||
Me.RadLabel3.Size = New System.Drawing.Size(43, 19)
|
||||
Me.RadLabel3.TabIndex = 2
|
||||
Me.RadLabel3.Text = "Status:"
|
||||
'
|
||||
'RadLabel_Status
|
||||
'
|
||||
Me.RadLabel_Status.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
|
||||
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadLabel_Status.AutoSize = False
|
||||
Me.RadLabel_Status.Location = New System.Drawing.Point(144, 119)
|
||||
Me.RadLabel_Status.Name = "RadLabel_Status"
|
||||
Me.RadLabel_Status.Size = New System.Drawing.Size(273, 22)
|
||||
Me.RadLabel_Status.TabIndex = 3
|
||||
Me.RadLabel_Status.Text = "-"
|
||||
Me.RadLabel_Status.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText
|
||||
'
|
||||
'RadTextBoxControl_MinecraftProfileFolder
|
||||
'
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
|
||||
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.IsReadOnly = True
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.Location = New System.Drawing.Point(144, 3)
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.Name = "RadTextBoxControl_MinecraftProfileFolder"
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.NullText = "No file loaded!"
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.Size = New System.Drawing.Size(273, 22)
|
||||
Me.RadTextBoxControl_MinecraftProfileFolder.TabIndex = 4
|
||||
'
|
||||
'RadTextBoxControl_ModpackConfig
|
||||
'
|
||||
Me.RadTextBoxControl_ModpackConfig.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
|
||||
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadTextBoxControl_ModpackConfig.IsReadOnly = True
|
||||
Me.RadTextBoxControl_ModpackConfig.Location = New System.Drawing.Point(144, 61)
|
||||
Me.RadTextBoxControl_ModpackConfig.Name = "RadTextBoxControl_ModpackConfig"
|
||||
Me.RadTextBoxControl_ModpackConfig.NullText = "No file loaded!"
|
||||
Me.RadTextBoxControl_ModpackConfig.Size = New System.Drawing.Size(273, 22)
|
||||
Me.RadTextBoxControl_ModpackConfig.TabIndex = 5
|
||||
'
|
||||
'Panel1
|
||||
'
|
||||
Me.Panel1.BackColor = System.Drawing.Color.Transparent
|
||||
Me.Panel1.Controls.Add(Me.RadButton_Install)
|
||||
Me.Panel1.Controls.Add(Me.RadButton_CheckForUpdates)
|
||||
Me.Panel1.Controls.Add(Me.RadButton_EditModpackConfig)
|
||||
Me.Panel1.Controls.Add(Me.RadButton_SearchModpackConfig)
|
||||
Me.Panel1.Controls.Add(Me.RadButton_SearchMinecraftProfileFolder)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel1)
|
||||
Me.Panel1.Controls.Add(Me.RadTextBoxControl_ModpackConfig)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel2)
|
||||
Me.Panel1.Controls.Add(Me.RadTextBoxControl_MinecraftProfileFolder)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel3)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel_Status)
|
||||
Me.Panel1.Dock = System.Windows.Forms.DockStyle.Fill
|
||||
Me.Panel1.Location = New System.Drawing.Point(0, 0)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
Me.Panel1.Size = New System.Drawing.Size(420, 176)
|
||||
Me.Panel1.TabIndex = 6
|
||||
'
|
||||
'RadButton_Install
|
||||
'
|
||||
Me.RadButton_Install.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadButton_Install.Image = Global.ModpackUpdater.My.Resources.MySymbols.icons8_software_installer_16px
|
||||
Me.RadButton_Install.ImageAlignment = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.RadButton_Install.Location = New System.Drawing.Point(337, 149)
|
||||
Me.RadButton_Install.Name = "RadButton_Install"
|
||||
Me.RadButton_Install.Size = New System.Drawing.Size(80, 24)
|
||||
Me.RadButton_Install.TabIndex = 10
|
||||
Me.RadButton_Install.Text = "Install"
|
||||
Me.RadButton_Install.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.RadButton_Install.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText
|
||||
'
|
||||
'RadButton_CheckForUpdates
|
||||
'
|
||||
Me.RadButton_CheckForUpdates.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadButton_CheckForUpdates.Image = Global.ModpackUpdater.My.Resources.MySymbols.icons8_update_16px
|
||||
Me.RadButton_CheckForUpdates.ImageAlignment = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.RadButton_CheckForUpdates.Location = New System.Drawing.Point(191, 149)
|
||||
Me.RadButton_CheckForUpdates.Name = "RadButton_CheckForUpdates"
|
||||
Me.RadButton_CheckForUpdates.Size = New System.Drawing.Size(140, 24)
|
||||
Me.RadButton_CheckForUpdates.TabIndex = 0
|
||||
Me.RadButton_CheckForUpdates.Text = "Check for Updates"
|
||||
Me.RadButton_CheckForUpdates.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.RadButton_CheckForUpdates.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText
|
||||
'
|
||||
'RadButton_EditModpackConfig
|
||||
'
|
||||
Me.RadButton_EditModpackConfig.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadButton_EditModpackConfig.Image = Global.ModpackUpdater.My.Resources.MySymbols.icons8_wrench_16px
|
||||
Me.RadButton_EditModpackConfig.ImageAlignment = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.RadButton_EditModpackConfig.Location = New System.Drawing.Point(3, 149)
|
||||
Me.RadButton_EditModpackConfig.Name = "RadButton_EditModpackConfig"
|
||||
Me.RadButton_EditModpackConfig.Size = New System.Drawing.Size(150, 24)
|
||||
Me.RadButton_EditModpackConfig.TabIndex = 8
|
||||
Me.RadButton_EditModpackConfig.Text = "Edit modpack config"
|
||||
Me.RadButton_EditModpackConfig.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.RadButton_EditModpackConfig.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText
|
||||
'
|
||||
'RadButton_SearchModpackConfig
|
||||
'
|
||||
Me.RadButton_SearchModpackConfig.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadButton_SearchModpackConfig.Image = CType(resources.GetObject("RadButton_SearchModpackConfig.Image"), System.Drawing.Image)
|
||||
Me.RadButton_SearchModpackConfig.ImageAlignment = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.RadButton_SearchModpackConfig.Location = New System.Drawing.Point(327, 89)
|
||||
Me.RadButton_SearchModpackConfig.Name = "RadButton_SearchModpackConfig"
|
||||
Me.RadButton_SearchModpackConfig.Size = New System.Drawing.Size(90, 24)
|
||||
Me.RadButton_SearchModpackConfig.TabIndex = 7
|
||||
Me.RadButton_SearchModpackConfig.Text = "Search"
|
||||
Me.RadButton_SearchModpackConfig.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.RadButton_SearchModpackConfig.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText
|
||||
'
|
||||
'RadButton_SearchMinecraftProfileFolder
|
||||
'
|
||||
Me.RadButton_SearchMinecraftProfileFolder.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.RadButton_SearchMinecraftProfileFolder.Image = CType(resources.GetObject("RadButton_SearchMinecraftProfileFolder.Image"), System.Drawing.Image)
|
||||
Me.RadButton_SearchMinecraftProfileFolder.ImageAlignment = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.RadButton_SearchMinecraftProfileFolder.Location = New System.Drawing.Point(327, 31)
|
||||
Me.RadButton_SearchMinecraftProfileFolder.Name = "RadButton_SearchMinecraftProfileFolder"
|
||||
Me.RadButton_SearchMinecraftProfileFolder.Size = New System.Drawing.Size(90, 24)
|
||||
Me.RadButton_SearchMinecraftProfileFolder.TabIndex = 6
|
||||
Me.RadButton_SearchMinecraftProfileFolder.Text = "Search"
|
||||
Me.RadButton_SearchMinecraftProfileFolder.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.RadButton_SearchMinecraftProfileFolder.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText
|
||||
'
|
||||
'Form1
|
||||
'
|
||||
Me.AutoScaleBaseSize = New System.Drawing.Size(7, 15)
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 15.0!)
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.ClientSize = New System.Drawing.Size(420, 176)
|
||||
Me.Controls.Add(Me.Panel1)
|
||||
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
|
||||
Me.MaximizeBox = False
|
||||
Me.Name = "Form1"
|
||||
'
|
||||
'
|
||||
'
|
||||
Me.RootElement.ApplyShapeToControl = True
|
||||
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||
Me.Text = "Minecraft Modpack Updater"
|
||||
CType(Me.RadLabel1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadLabel2, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadLabel3, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadLabel_Status, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadTextBoxControl_MinecraftProfileFolder, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadTextBoxControl_ModpackConfig, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
Me.Panel1.PerformLayout()
|
||||
CType(Me.RadButton_Install, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadButton_CheckForUpdates, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadButton_EditModpackConfig, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadButton_SearchModpackConfig, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadButton_SearchMinecraftProfileFolder, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
Friend WithEvents RadLabel1 As Telerik.WinControls.UI.RadLabel
|
||||
Friend WithEvents RadLabel2 As Telerik.WinControls.UI.RadLabel
|
||||
Friend WithEvents RadLabel3 As Telerik.WinControls.UI.RadLabel
|
||||
Friend WithEvents RadLabel_Status As Telerik.WinControls.UI.RadLabel
|
||||
Friend WithEvents RadTextBoxControl_MinecraftProfileFolder As Telerik.WinControls.UI.RadTextBoxControl
|
||||
Friend WithEvents RadTextBoxControl_ModpackConfig As Telerik.WinControls.UI.RadTextBoxControl
|
||||
Friend WithEvents Panel1 As System.Windows.Forms.Panel
|
||||
Friend WithEvents RadButton_Install As Telerik.WinControls.UI.RadButton
|
||||
Friend WithEvents RadButton_CheckForUpdates As Telerik.WinControls.UI.RadButton
|
||||
Friend WithEvents RadButton_EditModpackConfig As Telerik.WinControls.UI.RadButton
|
||||
Friend WithEvents RadButton_SearchModpackConfig As Telerik.WinControls.UI.RadButton
|
||||
Friend WithEvents RadButton_SearchMinecraftProfileFolder As Telerik.WinControls.UI.RadButton
|
||||
End Class
|
||||
1877
ModpackUpdater/Form1.resx
Normal file
173
ModpackUpdater/Form1.vb
Normal file
@@ -0,0 +1,173 @@
|
||||
Imports System.IO
|
||||
|
||||
Imports ModpackUpdater.My.Resources
|
||||
|
||||
Imports Telerik.WinControls.UI
|
||||
|
||||
Public Class Form1
|
||||
|
||||
Private updateConfig As New UpdateConfig
|
||||
Private currentUpdating As Boolean = False
|
||||
|
||||
Public Sub New()
|
||||
InitializeComponent()
|
||||
End Sub
|
||||
|
||||
Private Function IsMinecaftProfileLoaded() As Boolean
|
||||
Return Not String.IsNullOrEmpty(GetMinecraftProfilePath)
|
||||
End Function
|
||||
|
||||
Private Function GetMinecraftProfilePath() As string
|
||||
Return RadTextBoxControl_MinecraftProfileFolder.Text.Trim
|
||||
End Function
|
||||
|
||||
Private Function IsUpdateConfigLoaded() As Boolean
|
||||
Return Not String.IsNullOrEmpty(GetUpdateconfigPath)
|
||||
End Function
|
||||
|
||||
Private Function GetUpdateconfigPath() As string
|
||||
Return RadTextBoxControl_ModpackConfig.Text.Trim
|
||||
End Function
|
||||
|
||||
Private Function CheckStatus() As Boolean
|
||||
If Not IsMinecaftProfileLoaded() OrElse Not MinecraftProfileChecker.CheckProfile(GetMinecraftProfilePath) Then
|
||||
SetStatus(LangRes.StatusText_MinecraftProfileWarning, MySymbols.icons8_general_warning_sign_16px)
|
||||
CheckStatus = False
|
||||
ElseIf Not IsUpdateConfigLoaded() Then
|
||||
SetStatus(LangRes.StatusText_MinecraftProfileWarning, MySymbols.icons8_general_warning_sign_16px)
|
||||
CheckStatus = False
|
||||
Else
|
||||
CheckStatus = True
|
||||
End If
|
||||
End Function
|
||||
|
||||
Private Sub SetStatus(statusText As string, image As Image)
|
||||
RadLabel_Status.Text = statusText
|
||||
RadLabel_Status.Image = image
|
||||
End Sub
|
||||
|
||||
Private Sub ClearStatus()
|
||||
RadLabel_Status.Text = "-"
|
||||
RadLabel_Status.Image = Nothing
|
||||
End Sub
|
||||
|
||||
Private Sub LoadMinecraftProfile(folderPath As string)
|
||||
RadTextBoxControl_MinecraftProfileFolder.Text = folderPath
|
||||
|
||||
If IsUpdateConfigLoaded() Then
|
||||
RadButton_CheckForUpdates.PerformClick()
|
||||
Else
|
||||
ClearStatus()
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub LoadUpdateConfigFile(filePath As string)
|
||||
RadTextBoxControl_ModpackConfig.Text = filePath
|
||||
|
||||
If IsUpdateConfigLoaded() Then
|
||||
updateConfig = UpdateConfig.LoadFromFile(filePath)
|
||||
End If
|
||||
|
||||
If IsMinecaftProfileLoaded() Then
|
||||
RadButton_CheckForUpdates.PerformClick()
|
||||
Else
|
||||
ClearStatus()
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Async Function ExecuteUpdate(allowInstall As Boolean) As Task
|
||||
SetStatus(LangRes.StatusText_CheckingForUpdates, MySymbols.icons8_update_16px)
|
||||
|
||||
Dim updater As New UpdateInstaller(updateConfig, GetMinecraftProfilePath)
|
||||
AddHandler updater.InstallProgessUpdated, AddressOf Update_InstallProgessUpdated
|
||||
AddHandler updater.CheckingProgressUpdated, AddressOf Updated_CheckingProgresssUpdated
|
||||
|
||||
Dim result As UpdateCheckResult = Await updater.CheckForUpdates(True)
|
||||
Dim everytingOk As Boolean = False
|
||||
|
||||
If result Is Nothing Then
|
||||
SetStatus(LangRes.StatusText_ErrorWhileUpdateCheckOrUpdate, MySymbols.icons8_delete_16px)
|
||||
ElseIf result.HasUpdates Then
|
||||
SetStatus(LangRes.StatusText_UpdateAvailable, MySymbols.icons8_software_installer_16px)
|
||||
|
||||
If allowInstall Then
|
||||
currentUpdating = True
|
||||
SetStatus(LangRes.StatusText_Installing, MySymbols.icons8_software_installer_16px)
|
||||
|
||||
If Await updater.InstallUpdates(result) Then
|
||||
everytingOk = True
|
||||
End If
|
||||
|
||||
currentUpdating = False
|
||||
End If
|
||||
Else
|
||||
everytingOk = True
|
||||
End If
|
||||
|
||||
If everytingOk Then
|
||||
SetStatus(LangRes.StatusTest_EverythingOk, MySymbols.icons8_checkmark_16px)
|
||||
End If
|
||||
End Function
|
||||
|
||||
Private Sub Update_InstallProgessUpdated(result As UpdateCheckResult, processedSyncs As Integer)
|
||||
SetStatus(Math.Round(processedSyncs / result.SyncFiles.Count * 100, 1) & "%", MySymbols.icons8_software_installer_16px)
|
||||
End Sub
|
||||
|
||||
Private Sub Updated_CheckingProgresssUpdated(toCheck As Integer, processed As Integer)
|
||||
SetStatus(Math.Round(processed / toCheck * 100, 1) & "%", MySymbols.icons8_update_16px)
|
||||
End Sub
|
||||
|
||||
Private Sub ButtonX_SearchMinecraftProfile_Click(sender As Object, e As EventArgs) Handles RadButton_SearchMinecraftProfileFolder.Click
|
||||
Dim ofd As New RadOpenFolderDialog
|
||||
|
||||
If ofd.ShowDialog(Me) = DialogResult.OK Then
|
||||
LoadMinecraftProfile(ofd.FileName)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub ButtonX_SearchUpdateConfig_Click(sender As Object, e As EventArgs) Handles RadButton_SearchModpackConfig.Click
|
||||
Dim ofd As New RadOpenFileDialog
|
||||
ofd.Filter = FiledialogFilters.JSON_Display & "|" & FiledialogFilters.JSON_Filter
|
||||
|
||||
If ofd.ShowDialog(Me) = DialogResult.OK Then
|
||||
LoadUpdateConfigFile(ofd.FileName)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub ButtonX_EditUpdateConfig_Click(sender As Object, e As EventArgs) Handles RadButton_EditModpackConfig.Click
|
||||
Dim frm As New FormSettings(updateConfig)
|
||||
frm.ShowDialog(Me)
|
||||
End Sub
|
||||
|
||||
Private Async Sub ButtonX_CheckForUpdates_Click(sender As Object, e As EventArgs) Handles RadButton_CheckForUpdates.Click
|
||||
ClearStatus()
|
||||
If CheckStatus() Then
|
||||
Await ExecuteUpdate(False)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Async Sub ButtonX_StartUpdate_Click(sender As Object, e As EventArgs) Handles RadButton_Install.Click
|
||||
If Not currentUpdating Then
|
||||
ClearStatus()
|
||||
If CheckStatus() Then
|
||||
Await ExecuteUpdate(True)
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub Form1_FormClosing(sender As Object, e As FormClosingEventArgs) Handles Me.FormClosing
|
||||
AppConfig.Instance.LastMinecraftProfilePath = RadTextBoxControl_MinecraftProfileFolder.Text
|
||||
AppConfig.Instance.LastConfigFilePath = RadTextBoxControl_ModpackConfig.Text
|
||||
AppConfig.Instance.SaveConfig()
|
||||
End Sub
|
||||
|
||||
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
If Directory.Exists(AppConfig.Instance.LastMinecraftProfilePath) Then
|
||||
LoadMinecraftProfile(AppConfig.Instance.LastMinecraftProfilePath)
|
||||
End If
|
||||
If File.Exists(AppConfig.Instance.LastConfigFilePath) Then
|
||||
LoadUpdateConfigFile(AppConfig.Instance.LastConfigFilePath)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
138
ModpackUpdater/FormSettings.Designer.vb
generated
Normal file
@@ -0,0 +1,138 @@
|
||||
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
|
||||
Partial Class FormSettings
|
||||
Inherits Telerik.WinControls.UI.RadForm
|
||||
|
||||
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
Try
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
Finally
|
||||
MyBase.Dispose(disposing)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
'Wird vom Windows Form-Designer benötigt.
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
|
||||
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(FormSettings))
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.RadTextBoxControl_WebdavPassword = New Telerik.WinControls.UI.RadTextBoxControl()
|
||||
Me.RadTextBoxControl_WebdavUsername = New Telerik.WinControls.UI.RadTextBoxControl()
|
||||
Me.RadTextBoxControl_WebdavURL = New Telerik.WinControls.UI.RadTextBoxControl()
|
||||
Me.RadButton_SaveAndClose = New Telerik.WinControls.UI.RadButton()
|
||||
Me.RadButton_SaveAs = New Telerik.WinControls.UI.RadButton()
|
||||
Me.RadLabel3 = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.RadLabel2 = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.RadLabel1 = New Telerik.WinControls.UI.RadLabel()
|
||||
Me.Panel1.SuspendLayout()
|
||||
CType(Me.RadTextBoxControl_WebdavPassword, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadTextBoxControl_WebdavUsername, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadTextBoxControl_WebdavURL, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadButton_SaveAndClose, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadButton_SaveAs, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadLabel3, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadLabel2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.RadLabel1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'Panel1
|
||||
'
|
||||
resources.ApplyResources(Me.Panel1, "Panel1")
|
||||
Me.Panel1.BackColor = System.Drawing.Color.Transparent
|
||||
Me.Panel1.Controls.Add(Me.RadTextBoxControl_WebdavPassword)
|
||||
Me.Panel1.Controls.Add(Me.RadTextBoxControl_WebdavUsername)
|
||||
Me.Panel1.Controls.Add(Me.RadTextBoxControl_WebdavURL)
|
||||
Me.Panel1.Controls.Add(Me.RadButton_SaveAndClose)
|
||||
Me.Panel1.Controls.Add(Me.RadButton_SaveAs)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel3)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel2)
|
||||
Me.Panel1.Controls.Add(Me.RadLabel1)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
'
|
||||
'RadTextBoxControl_WebdavPassword
|
||||
'
|
||||
resources.ApplyResources(Me.RadTextBoxControl_WebdavPassword, "RadTextBoxControl_WebdavPassword")
|
||||
Me.RadTextBoxControl_WebdavPassword.Name = "RadTextBoxControl_WebdavPassword"
|
||||
'
|
||||
'RadTextBoxControl_WebdavUsername
|
||||
'
|
||||
resources.ApplyResources(Me.RadTextBoxControl_WebdavUsername, "RadTextBoxControl_WebdavUsername")
|
||||
Me.RadTextBoxControl_WebdavUsername.Name = "RadTextBoxControl_WebdavUsername"
|
||||
'
|
||||
'RadTextBoxControl_WebdavURL
|
||||
'
|
||||
resources.ApplyResources(Me.RadTextBoxControl_WebdavURL, "RadTextBoxControl_WebdavURL")
|
||||
Me.RadTextBoxControl_WebdavURL.Name = "RadTextBoxControl_WebdavURL"
|
||||
'
|
||||
'RadButton_SaveAndClose
|
||||
'
|
||||
resources.ApplyResources(Me.RadButton_SaveAndClose, "RadButton_SaveAndClose")
|
||||
Me.RadButton_SaveAndClose.Image = Global.ModpackUpdater.My.Resources.MySymbols.icons8_save_16px
|
||||
Me.RadButton_SaveAndClose.Name = "RadButton_SaveAndClose"
|
||||
'
|
||||
'RadButton_SaveAs
|
||||
'
|
||||
resources.ApplyResources(Me.RadButton_SaveAs, "RadButton_SaveAs")
|
||||
Me.RadButton_SaveAs.Image = Global.ModpackUpdater.My.Resources.MySymbols.icons8_opened_folder_16px
|
||||
Me.RadButton_SaveAs.Name = "RadButton_SaveAs"
|
||||
'
|
||||
'RadLabel3
|
||||
'
|
||||
resources.ApplyResources(Me.RadLabel3, "RadLabel3")
|
||||
Me.RadLabel3.Name = "RadLabel3"
|
||||
'
|
||||
'RadLabel2
|
||||
'
|
||||
resources.ApplyResources(Me.RadLabel2, "RadLabel2")
|
||||
Me.RadLabel2.Name = "RadLabel2"
|
||||
'
|
||||
'RadLabel1
|
||||
'
|
||||
resources.ApplyResources(Me.RadLabel1, "RadLabel1")
|
||||
Me.RadLabel1.Name = "RadLabel1"
|
||||
'
|
||||
'FormSettings
|
||||
'
|
||||
resources.ApplyResources(Me, "$this")
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.Controls.Add(Me.Panel1)
|
||||
Me.MaximizeBox = False
|
||||
Me.Name = "FormSettings"
|
||||
'
|
||||
'
|
||||
'
|
||||
Me.RootElement.ApplyShapeToControl = True
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
Me.Panel1.PerformLayout()
|
||||
CType(Me.RadTextBoxControl_WebdavPassword, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadTextBoxControl_WebdavUsername, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadTextBoxControl_WebdavURL, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadButton_SaveAndClose, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadButton_SaveAs, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadLabel3, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadLabel2, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.RadLabel1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
|
||||
Friend WithEvents Panel1 As Panel
|
||||
Friend WithEvents RadLabel1 As Telerik.WinControls.UI.RadLabel
|
||||
Friend WithEvents RadTextBoxControl_WebdavPassword As Telerik.WinControls.UI.RadTextBoxControl
|
||||
Friend WithEvents RadTextBoxControl_WebdavUsername As Telerik.WinControls.UI.RadTextBoxControl
|
||||
Friend WithEvents RadTextBoxControl_WebdavURL As Telerik.WinControls.UI.RadTextBoxControl
|
||||
Friend WithEvents RadButton_SaveAndClose As Telerik.WinControls.UI.RadButton
|
||||
Friend WithEvents RadButton_SaveAs As Telerik.WinControls.UI.RadButton
|
||||
Friend WithEvents RadLabel3 As Telerik.WinControls.UI.RadLabel
|
||||
Friend WithEvents RadLabel2 As Telerik.WinControls.UI.RadLabel
|
||||
End Class
|
||||
1938
ModpackUpdater/FormSettings.de.resx
Normal file
2153
ModpackUpdater/FormSettings.resx
Normal file
44
ModpackUpdater/FormSettings.vb
Normal file
@@ -0,0 +1,44 @@
|
||||
Imports ModpackUpdater.My.Resources
|
||||
|
||||
Imports Telerik.WinControls.UI
|
||||
|
||||
Public Class FormSettings
|
||||
|
||||
Private ReadOnly updateConfig As UpdateConfig
|
||||
|
||||
Public Sub New(updateConfig As UpdateConfig)
|
||||
InitializeComponent()
|
||||
Me.updateConfig = updateConfig
|
||||
End Sub
|
||||
|
||||
Private Sub LoadConfig()
|
||||
RadTextBoxControl_WebdavURL.Text = updateConfig.WebdavURL
|
||||
RadTextBoxControl_WebdavUsername.Text = updateConfig.WebdavUsername
|
||||
RadTextBoxControl_WebdavPassword.Text = updateConfig.WebdavPassword
|
||||
End Sub
|
||||
|
||||
Private Sub SaveConfig()
|
||||
updateConfig.WebdavURL = RadTextBoxControl_WebdavURL.Text.Trim
|
||||
updateConfig.WebdavUsername = RadTextBoxControl_WebdavUsername.Text.Trim
|
||||
updateConfig.WebdavPassword = RadTextBoxControl_WebdavPassword.Text
|
||||
End Sub
|
||||
|
||||
Private Sub ButtonX_SaveAs_Click(sender As Object, e As EventArgs) Handles RadButton_SaveAs.Click
|
||||
Dim ofd As New RadSaveFileDialog
|
||||
ofd.Filter = FiledialogFilters.JSON_Display & "|" & FiledialogFilters.JSON_Filter
|
||||
|
||||
If ofd.ShowDialog(Me) = DialogResult.OK Then
|
||||
updateConfig.SaveToFile(ofd.FileName)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub ButtonX_SaveAndClose_Click(sender As Object, e As EventArgs) Handles RadButton_SaveAndClose.Click
|
||||
SaveConfig()
|
||||
Close()
|
||||
End Sub
|
||||
|
||||
Private Sub FormSettings_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
LoadConfig()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
130
ModpackUpdater/LangRes.Designer.vb
generated
Normal file
@@ -0,0 +1,130 @@
|
||||
'------------------------------------------------------------------------------
|
||||
' <auto-generated>
|
||||
' Dieser Code wurde von einem Tool generiert.
|
||||
' Laufzeitversion:4.0.30319.42000
|
||||
'
|
||||
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||
' der Code erneut generiert wird.
|
||||
' </auto-generated>
|
||||
'------------------------------------------------------------------------------
|
||||
|
||||
Option Strict On
|
||||
Option Explicit On
|
||||
|
||||
Imports System
|
||||
|
||||
Namespace My.Resources
|
||||
|
||||
'Diese Klasse wurde von der StronglyTypedResourceBuilder automatisch generiert
|
||||
'-Klasse über ein Tool wie ResGen oder Visual Studio automatisch generiert.
|
||||
'Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
|
||||
'mit der /str-Option erneut aus, oder Sie erstellen Ihr VS-Projekt neu.
|
||||
'''<summary>
|
||||
''' Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
|
||||
'''</summary>
|
||||
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0"), _
|
||||
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
||||
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute()> _
|
||||
Friend Class LangRes
|
||||
|
||||
Private Shared resourceMan As Global.System.Resources.ResourceManager
|
||||
|
||||
Private Shared resourceCulture As Global.System.Globalization.CultureInfo
|
||||
|
||||
<Global.System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")> _
|
||||
Friend Sub New()
|
||||
MyBase.New
|
||||
End Sub
|
||||
|
||||
'''<summary>
|
||||
''' Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
|
||||
'''</summary>
|
||||
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||
Friend Shared ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
|
||||
Get
|
||||
If Object.ReferenceEquals(resourceMan, Nothing) Then
|
||||
Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ModpackUpdater.LangRes", GetType(LangRes).Assembly)
|
||||
resourceMan = temp
|
||||
End If
|
||||
Return resourceMan
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
|
||||
''' Ressourcenzuordnungen, die diese stark typisierte Ressourcenklasse verwenden.
|
||||
'''</summary>
|
||||
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||
Friend Shared Property Culture() As Global.System.Globalization.CultureInfo
|
||||
Get
|
||||
Return resourceCulture
|
||||
End Get
|
||||
Set
|
||||
resourceCulture = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Everything is right and up-to-date. ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusTest_EverythingOk() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusTest_EverythingOk", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Checking for Updates... ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusText_CheckingForUpdates() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusText_CheckingForUpdates", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Config incomplete or not loaded! ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusText_ConfigIncompleteOrNotLoaded() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusText_ConfigIncompleteOrNotLoaded", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Error on update check or while updating! ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusText_ErrorWhileUpdateCheckOrUpdate() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusText_ErrorWhileUpdateCheckOrUpdate", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Installing... ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusText_Installing() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusText_Installing", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die Minecraft profile folder seems to be not valid. ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusText_MinecraftProfileWarning() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusText_MinecraftProfileWarning", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Zeichenfolge, die An update is available! ähnelt.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property StatusText_UpdateAvailable() As String
|
||||
Get
|
||||
Return ResourceManager.GetString("StatusText_UpdateAvailable", resourceCulture)
|
||||
End Get
|
||||
End Property
|
||||
End Class
|
||||
End Namespace
|
||||
141
ModpackUpdater/LangRes.resx
Normal file
@@ -0,0 +1,141 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: 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:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<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:sequence>
|
||||
<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="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="StatusTest_EverythingOk" xml:space="preserve">
|
||||
<value>Everything is right and up-to-date.</value>
|
||||
</data>
|
||||
<data name="StatusText_CheckingForUpdates" xml:space="preserve">
|
||||
<value>Checking for Updates...</value>
|
||||
</data>
|
||||
<data name="StatusText_ConfigIncompleteOrNotLoaded" xml:space="preserve">
|
||||
<value>Config incomplete or not loaded!</value>
|
||||
</data>
|
||||
<data name="StatusText_ErrorWhileUpdateCheckOrUpdate" xml:space="preserve">
|
||||
<value>Error on update check or while updating!</value>
|
||||
</data>
|
||||
<data name="StatusText_Installing" xml:space="preserve">
|
||||
<value>Installing...</value>
|
||||
</data>
|
||||
<data name="StatusText_MinecraftProfileWarning" xml:space="preserve">
|
||||
<value>Minecraft profile folder seems to be not valid.</value>
|
||||
</data>
|
||||
<data name="StatusText_UpdateAvailable" xml:space="preserve">
|
||||
<value>An update is available!</value>
|
||||
</data>
|
||||
</root>
|
||||
8
ModpackUpdater/MinecraftProfileChecker.vb
Normal file
@@ -0,0 +1,8 @@
|
||||
Public Class MinecraftProfileChecker
|
||||
|
||||
Public Shared Function CheckProfile(folderPath As string) As Boolean
|
||||
'Todo: Adds some checks to verify, if the current folder is a minecraft folder.
|
||||
Return True
|
||||
End Function
|
||||
|
||||
End Class
|
||||
79
ModpackUpdater/ModpackUpdater.vbproj
Normal file
@@ -0,0 +1,79 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<StartupObject>Sub Main</StartupObject>
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<MyType>WindowsForms</MyType>
|
||||
<ApplicationIcon>icons8_download_from_ftp.ico</ApplicationIcon>
|
||||
<AssemblyName>Minecraft Modpack Updater</AssemblyName>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<None Remove="CustomThemes\Office2019DarkBluePurple.tssp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Include="CustomThemes\Office2019DarkBluePurple.tssp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Import Include="System.Data" />
|
||||
<Import Include="System.Drawing" />
|
||||
<Import Include="System.Windows.Forms" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Update="FiledialogFilters.Designer.vb">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>FiledialogFilters.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Update="LangRes.Designer.vb">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>LangRes.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Update="My Project\Application.Designer.vb">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Application.myapp</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Update="MySymbols.Designer.vb">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>MySymbols.resx</DependentUpon>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Update="My Project\Application.myapp">
|
||||
<Generator>MyApplicationCodeGenerator</Generator>
|
||||
<LastGenOutput>Application.Designer.vb</LastGenOutput>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Update="FiledialogFilters.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||
<LastGenOutput>FiledialogFilters.Designer.vb</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Update="LangRes.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||
<LastGenOutput>LangRes.Designer.vb</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Update="MySymbols.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||
<LastGenOutput>MySymbols.Designer.vb</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
<PackageReference Include="UI.for.WinForms.AllControls.Net60">
|
||||
<Version>2022.2.510</Version>
|
||||
</PackageReference>
|
||||
<PackageReference Include="WebDav.Client" Version="2.8.0" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Pilz.Cryptography">
|
||||
<HintPath>..\SharedLibs\Pilz.Cryptography.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
38
ModpackUpdater/My Project/Application.Designer.vb
generated
Normal file
@@ -0,0 +1,38 @@
|
||||
'------------------------------------------------------------------------------
|
||||
' <auto-generated>
|
||||
' Dieser Code wurde von einem Tool generiert.
|
||||
' Laufzeitversion:4.0.30319.42000
|
||||
'
|
||||
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||
' der Code erneut generiert wird.
|
||||
' </auto-generated>
|
||||
'------------------------------------------------------------------------------
|
||||
|
||||
Option Strict On
|
||||
Option Explicit On
|
||||
|
||||
|
||||
Namespace My
|
||||
|
||||
'HINWEIS: Diese Datei wird automatisch generiert und darf nicht direkt bearbeitet werden. Wenn Sie Änderungen vornehmen möchten
|
||||
' oder in dieser Datei Buildfehler auftreten, wechseln Sie zum Projekt-Designer.
|
||||
' (Wechseln Sie dazu zu den Projekteigenschaften, oder doppelklicken Sie auf den Knoten "Mein Projekt" im
|
||||
' Projektmappen-Explorer). Nehmen Sie auf der Registerkarte "Anwendung" entsprechende Änderungen vor.
|
||||
'
|
||||
Partial Friend Class MyApplication
|
||||
|
||||
<Global.System.Diagnostics.DebuggerStepThroughAttribute()> _
|
||||
Public Sub New()
|
||||
MyBase.New(Global.Microsoft.VisualBasic.ApplicationServices.AuthenticationMode.Windows)
|
||||
Me.IsSingleInstance = false
|
||||
Me.EnableVisualStyles = true
|
||||
Me.SaveMySettingsOnExit = true
|
||||
Me.ShutDownStyle = Global.Microsoft.VisualBasic.ApplicationServices.ShutdownMode.AfterMainFormCloses
|
||||
End Sub
|
||||
|
||||
<Global.System.Diagnostics.DebuggerStepThroughAttribute()> _
|
||||
Protected Overrides Sub OnCreateMainForm()
|
||||
Me.MainForm = Global.ModpackUpdater.Form1
|
||||
End Sub
|
||||
End Class
|
||||
End Namespace
|
||||
10
ModpackUpdater/My Project/Application.myapp
Normal file
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<MyApplicationData xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
|
||||
<MySubMain>true</MySubMain>
|
||||
<MainForm>Form1</MainForm>
|
||||
<SingleInstance>false</SingleInstance>
|
||||
<ShutdownMode>0</ShutdownMode>
|
||||
<EnableVisualStyles>true</EnableVisualStyles>
|
||||
<AuthenticationMode>0</AuthenticationMode>
|
||||
<SaveMySettingsOnExit>true</SaveMySettingsOnExit>
|
||||
</MyApplicationData>
|
||||
157
ModpackUpdater/MySymbols.Designer.vb
generated
Normal file
@@ -0,0 +1,157 @@
|
||||
'------------------------------------------------------------------------------
|
||||
' <auto-generated>
|
||||
' Dieser Code wurde von einem Tool generiert.
|
||||
' Laufzeitversion:4.0.30319.42000
|
||||
'
|
||||
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||
' der Code erneut generiert wird.
|
||||
' </auto-generated>
|
||||
'------------------------------------------------------------------------------
|
||||
|
||||
Option Strict On
|
||||
Option Explicit On
|
||||
|
||||
Imports System
|
||||
|
||||
Namespace My.Resources
|
||||
|
||||
'Diese Klasse wurde von der StronglyTypedResourceBuilder automatisch generiert
|
||||
'-Klasse über ein Tool wie ResGen oder Visual Studio automatisch generiert.
|
||||
'Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
|
||||
'mit der /str-Option erneut aus, oder Sie erstellen Ihr VS-Projekt neu.
|
||||
'''<summary>
|
||||
''' Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
|
||||
'''</summary>
|
||||
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0"), _
|
||||
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
||||
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute()> _
|
||||
Friend Class MySymbols
|
||||
|
||||
Private Shared resourceMan As Global.System.Resources.ResourceManager
|
||||
|
||||
Private Shared resourceCulture As Global.System.Globalization.CultureInfo
|
||||
|
||||
<Global.System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")> _
|
||||
Friend Sub New()
|
||||
MyBase.New
|
||||
End Sub
|
||||
|
||||
'''<summary>
|
||||
''' Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
|
||||
'''</summary>
|
||||
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||
Friend Shared ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
|
||||
Get
|
||||
If Object.ReferenceEquals(resourceMan, Nothing) Then
|
||||
Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ModpackUpdater.MySymbols", GetType(MySymbols).Assembly)
|
||||
resourceMan = temp
|
||||
End If
|
||||
Return resourceMan
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
|
||||
''' Ressourcenzuordnungen, die diese stark typisierte Ressourcenklasse verwenden.
|
||||
'''</summary>
|
||||
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||
Friend Shared Property Culture() As Global.System.Globalization.CultureInfo
|
||||
Get
|
||||
Return resourceCulture
|
||||
End Get
|
||||
Set
|
||||
resourceCulture = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_checkmark_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_checkmark_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_delete_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_delete_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_download_from_ftp_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_download_from_ftp_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_general_warning_sign_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_general_warning_sign_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_opened_folder_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_opened_folder_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_save_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_save_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_software_installer_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_software_installer_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_update_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_update_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend Shared ReadOnly Property icons8_wrench_16px() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("icons8_wrench_16px", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
End Class
|
||||
End Namespace
|
||||
148
ModpackUpdater/MySymbols.resx
Normal file
@@ -0,0 +1,148 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: 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:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<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:sequence>
|
||||
<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="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="icons8_checkmark_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_checkmark_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_delete_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_delete_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_download_from_ftp_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_download_from_ftp_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_general_warning_sign_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_general_warning_sign_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_opened_folder_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_opened_folder_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_save_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_save_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_software_installer_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_software_installer_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_update_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_update_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="icons8_wrench_16px" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>Resources\icons8_wrench_16px.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
</root>
|
||||
BIN
ModpackUpdater/Resources/icons8_checkmark_16px.png
Normal file
|
After Width: | Height: | Size: 337 B |
BIN
ModpackUpdater/Resources/icons8_delete_16px.png
Normal file
|
After Width: | Height: | Size: 417 B |
BIN
ModpackUpdater/Resources/icons8_download_from_ftp_16px.png
Normal file
|
After Width: | Height: | Size: 494 B |
BIN
ModpackUpdater/Resources/icons8_general_warning_sign_16px.png
Normal file
|
After Width: | Height: | Size: 588 B |
BIN
ModpackUpdater/Resources/icons8_opened_folder_16px.png
Normal file
|
After Width: | Height: | Size: 334 B |
BIN
ModpackUpdater/Resources/icons8_save_16px.png
Normal file
|
After Width: | Height: | Size: 321 B |
BIN
ModpackUpdater/Resources/icons8_software_installer_16px.png
Normal file
|
After Width: | Height: | Size: 430 B |
BIN
ModpackUpdater/Resources/icons8_update_16px.png
Normal file
|
After Width: | Height: | Size: 631 B |
BIN
ModpackUpdater/Resources/icons8_wrench_16px.png
Normal file
|
After Width: | Height: | Size: 490 B |
11
ModpackUpdater/UpdateCheckResult.vb
Normal file
@@ -0,0 +1,11 @@
|
||||
Public Class UpdateCheckResult
|
||||
|
||||
Public ReadOnly Property SyncFiles As New List(Of UpdateSyncFile)
|
||||
|
||||
Public ReadOnly Property HasUpdates As Boolean
|
||||
Get
|
||||
Return SyncFiles.Where(Function(n) n.SyncAction <> UpdateSyncAction.None).Any
|
||||
End Get
|
||||
End Property
|
||||
|
||||
End Class
|
||||
21
ModpackUpdater/UpdateConfig.vb
Normal file
@@ -0,0 +1,21 @@
|
||||
Imports System.IO
|
||||
|
||||
Imports Newtonsoft.Json.Linq
|
||||
|
||||
Imports Pilz.Cryptography
|
||||
|
||||
Public Class UpdateConfig
|
||||
|
||||
Public Property WebdavURL As SecureString
|
||||
Public Property WebdavUsername As SecureString
|
||||
Public Property WebdavPassword As SecureString
|
||||
|
||||
Public Sub SaveToFile(filePath As string)
|
||||
File.WriteAllText(filePath, JObject.FromObject(Me).ToString)
|
||||
End Sub
|
||||
|
||||
Public Shared Function LoadFromFile(filePath As string)
|
||||
Return JObject.Parse(File.ReadAllText(filePath)).ToObject(Of UpdateConfig)
|
||||
End Function
|
||||
|
||||
End Class
|
||||
153
ModpackUpdater/UpdateInstaller.vb
Normal file
@@ -0,0 +1,153 @@
|
||||
Imports System.IO
|
||||
Imports System.Net
|
||||
|
||||
Imports WebDav
|
||||
|
||||
Public Class UpdateInstaller
|
||||
|
||||
Public Event InstallProgessUpdated(result As UpdateCheckResult, processedSyncs As Integer)
|
||||
Public Event CheckingProgressUpdated(toCheck As Integer, processed As Integer)
|
||||
|
||||
Private ReadOnly updateConfig As UpdateConfig
|
||||
Private ReadOnly localPath As String
|
||||
Private webdavClient As WebDavClient = Nothing
|
||||
|
||||
Public Sub New(updateConfig As UpdateConfig, localPath As String)
|
||||
Me.updateConfig = updateConfig
|
||||
Me.localPath = localPath
|
||||
End Sub
|
||||
|
||||
Private Function CreateClient() As WebDavClient
|
||||
If webdavClient Is Nothing Then
|
||||
Dim params As New WebDavClientParams With {
|
||||
.BaseAddress = New Uri(updateConfig.WebdavURL),
|
||||
.Credentials = New NetworkCredential(updateConfig.WebdavUsername, updateConfig.WebdavPassword)
|
||||
}
|
||||
webdavClient = New WebDavClient(params)
|
||||
End If
|
||||
|
||||
Return webdavClient
|
||||
End Function
|
||||
|
||||
Public Async Function CheckForUpdates(ignoreRevmoedFiles As Boolean) As Task(Of UpdateCheckResult)
|
||||
Dim result As New UpdateCheckResult
|
||||
Dim client As WebDavClient = CreateClient()
|
||||
Dim resTopFolder As WebDavResource = Nothing
|
||||
Dim checkedFiles = New List(Of String)()
|
||||
Dim responseSuccessfull As Boolean = False
|
||||
|
||||
'Check for new & updated files
|
||||
Dim response = Await client.Propfind(String.Empty, New PropfindParameters() With {.ApplyTo = ApplyTo.Propfind.ResourceAndAncestors})
|
||||
If resTopFolder Is Nothing AndAlso response.IsSuccessful AndAlso response.Resources.Any() Then
|
||||
resTopFolder = response.Resources.ElementAtOrDefault(0)
|
||||
responseSuccessfull = True
|
||||
End If
|
||||
|
||||
If responseSuccessfull AndAlso response.Resources.Count > 1 Then
|
||||
Dim i As Integer = 1
|
||||
Dim loopTo As Integer = response.Resources.Count - 1
|
||||
|
||||
Do While i <= loopTo
|
||||
Dim res = response.Resources.ElementAtOrDefault(i)
|
||||
Dim isFolder As Boolean = res.Uri.EndsWith("/")
|
||||
|
||||
If Not isFolder Then
|
||||
Dim syncAction? As UpdateSyncAction = Nothing
|
||||
Dim localFile As String
|
||||
Dim remoteFile As String
|
||||
|
||||
'Get remote file path
|
||||
remoteFile = res.Uri
|
||||
|
||||
'Get local file path
|
||||
localFile = Path.Combine(localPath, Uri.UnescapeDataString(res.Uri.Substring(resTopFolder.Uri.Length)).Replace("/", "\"))
|
||||
|
||||
'Check action
|
||||
If File.Exists(localFile) Then
|
||||
If File.GetLastWriteTime(localFile) < res.LastModifiedDate = True Then
|
||||
syncAction = UpdateSyncAction.UpdatedFile
|
||||
End If
|
||||
Else
|
||||
syncAction = UpdateSyncAction.NewFile
|
||||
End If
|
||||
|
||||
'Add to list
|
||||
checkedFiles.Add(localFile)
|
||||
If syncAction IsNot Nothing Then
|
||||
result.SyncFiles.Add(New UpdateSyncFile(syncAction, localFile, remoteFile))
|
||||
End If
|
||||
End If
|
||||
|
||||
i += 1
|
||||
|
||||
RaiseEvent CheckingProgressUpdated(loopTo, i)
|
||||
Loop
|
||||
End If
|
||||
|
||||
'Find all old files to remove
|
||||
If responseSuccessfull Then
|
||||
Dim allLocalFiles = Directory.GetFiles(localPath, "*", SearchOption.AllDirectories)
|
||||
For Each lf As String In allLocalFiles
|
||||
Dim isKnown As Boolean = False
|
||||
|
||||
For Each checkedFile As String In checkedFiles
|
||||
If Not isKnown AndAlso If(checkedFile, "") = If(lf, "") Then
|
||||
isKnown = True
|
||||
End If
|
||||
Next
|
||||
|
||||
If Not isKnown Then
|
||||
result.SyncFiles.Add(New UpdateSyncFile(If(ignoreRevmoedFiles, UpdateSyncAction.None, UpdateSyncAction.RemovedFile), lf, String.Empty))
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
|
||||
Return result
|
||||
End Function
|
||||
|
||||
Public Async Function InstallUpdates(checkResult As UpdateCheckResult, Optional ignoreActions As UpdateSyncAction = UpdateSyncAction.None) As Task(Of Boolean?)
|
||||
Dim client As WebDavClient = CreateClient()
|
||||
Dim success As Boolean? = False
|
||||
Dim processed As Integer = 0
|
||||
|
||||
'Init process update
|
||||
RaiseEvent InstallProgessUpdated(checkResult, processed)
|
||||
|
||||
For Each syncFile In checkResult.SyncFiles
|
||||
If syncFile.SyncAction <> (ignoreActions And syncFile.SyncAction) Then
|
||||
If syncFile.SyncAction = UpdateSyncAction.UpdatedFile OrElse
|
||||
syncFile.SyncAction = UpdateSyncAction.RemovedFile Then
|
||||
|
||||
If File.Exists(syncFile.LocalFile) Then
|
||||
File.Delete(syncFile.LocalFile)
|
||||
End If
|
||||
End If
|
||||
|
||||
If syncFile.SyncAction = UpdateSyncAction.UpdatedFile OrElse
|
||||
syncFile.SyncAction = UpdateSyncAction.NewFile Then
|
||||
|
||||
Dim response = Await client.GetProcessedFile(syncFile.RemoveFile)
|
||||
Dim dirParent As New DirectoryInfo(Path.GetDirectoryName(syncFile.LocalFile))
|
||||
|
||||
If response.IsSuccessful Then
|
||||
If Not dirParent.Exists Then
|
||||
dirParent.Create()
|
||||
End If
|
||||
|
||||
Dim fs As New FileStream(syncFile.LocalFile, FileMode.Create, FileAccess.Write)
|
||||
response.Stream.CopyTo(fs)
|
||||
fs.Close()
|
||||
|
||||
success = True
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
processed += 1
|
||||
RaiseEvent InstallProgessUpdated(checkResult, processed)
|
||||
Next
|
||||
|
||||
Return success
|
||||
End Function
|
||||
|
||||
End Class
|
||||
6
ModpackUpdater/UpdateSyncAction.vb
Normal file
@@ -0,0 +1,6 @@
|
||||
Public Enum UpdateSyncAction
|
||||
None
|
||||
NewFile
|
||||
RemovedFile
|
||||
UpdatedFile = 4
|
||||
End Enum
|
||||
13
ModpackUpdater/UpdateSyncFile.vb
Normal file
@@ -0,0 +1,13 @@
|
||||
Public Class UpdateSyncFile
|
||||
|
||||
Public ReadOnly Property SyncAction As UpdateSyncAction
|
||||
Public ReadOnly Property LocalFile As string
|
||||
Public ReadOnly Property RemoveFile As string
|
||||
|
||||
Public Sub New(syncAction As UpdateSyncAction, localFile As string, remoteFile As string)
|
||||
Me.SyncAction = syncAction
|
||||
Me.LocalFile = localFile
|
||||
Me.RemoveFile = remoteFile
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
BIN
ModpackUpdater/icons8_download_from_ftp.ico
Normal file
|
After Width: | Height: | Size: 105 KiB |
7
NuGet.Config
Normal file
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<packageSources>
|
||||
<add key="Telerik UI for WinForms 2022.2.510.0" value="C:\Program Files (x86)\Progress\Telerik UI for WinForms R2 2022\Bin60\NuGet" />
|
||||
<add key="Telerik UI for WinForms UI.for.WinForms.AllControls.Net60.2022.2.510" value="C:\Program Files (x86)\Progress\Telerik UI for WinForms R2 2022\Bin60\NuGet" />
|
||||
</packageSources>
|
||||
</configuration>
|
||||