-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
211 changed files
with
135,961 additions
and
477 deletions.
There are no files selected for viewing
Binary file not shown.
Empty file.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,14 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<configuration> | ||
<startup> | ||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" /> | ||
</startup> | ||
<runtime> | ||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> | ||
<dependentAssembly> | ||
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /> | ||
<bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0" /> | ||
</dependentAssembly> | ||
</assemblyBinding> | ||
</runtime> | ||
</configuration> |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.ComponentModel; | ||
using System.Drawing; | ||
using System.Data; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using System.Windows.Forms; | ||
using System.Net; | ||
using System.IO; | ||
using Tweak_Installer.Core; | ||
|
||
namespace Tweak_Installer.Controls { | ||
public partial class PackageCard : UserControl { | ||
static string CurrentDirectory = Path.GetDirectoryName(Application.ExecutablePath); | ||
|
||
public Package package; | ||
|
||
public PackageCard(Package package) { | ||
InitializeComponent(); | ||
|
||
this.package = package; | ||
|
||
if (package.display == null) | ||
download.Enabled = false; | ||
|
||
display.Text = package.display; | ||
author.Text = "by " + package.author; | ||
version.Text = "Version: " + package.version; | ||
size.Text = "Size: " + package.size; | ||
description.Text = package.summary; | ||
|
||
if (package.section.Contains("Themes")) { | ||
download.Enabled = false; | ||
} | ||
|
||
pictureBox1.Load("http://cydia.saurik.com/icon@2x/" + package.name + ".png"); | ||
|
||
if (Base.UninstallerExists(package)) { | ||
download.Location = new Point(61, 372); | ||
uninstall.Show(); | ||
} | ||
} | ||
|
||
private void bunifuSeparator4_Load(object sender, EventArgs e) { | ||
|
||
} | ||
|
||
private void bunifuCards1_Paint(object sender, PaintEventArgs e) { | ||
|
||
} | ||
|
||
private void download_Click(object sender, EventArgs e) { | ||
Main.StartLoading("Installing " + package.name + "..."); | ||
// Download Tweak | ||
string downloadsDir = Path.Combine(CurrentDirectory, @"downloads"); | ||
string url = WebAPI.GetDownload(package.name); | ||
|
||
if (!Directory.Exists(downloadsDir)) | ||
Directory.CreateDirectory(downloadsDir); | ||
|
||
string fileDir = Path.Combine(downloadsDir, package.name + "_" + package.version + ".deb"); | ||
WebClient Client = new WebClient(); | ||
Client.DownloadFile(url, fileDir); | ||
|
||
// Install Tweak | ||
Base.install(fileDir); | ||
|
||
MessageBox.Show(package.display + " has been installed successfully!", "Tweak Installer"); | ||
|
||
download.Location = new Point(61, 372); | ||
uninstall.Show(); | ||
Main.StopLoading(); | ||
} | ||
|
||
private void bunifuFlatButton1_Click(object sender, EventArgs e) { | ||
Main.StartLoading("Uninstalling " + package.name + "..."); | ||
Base.uninstall(package); | ||
MessageBox.Show(package.display + " has been uninstalled successfully!", "Tweak Installer"); | ||
|
||
download.Location = new Point(166, 372); | ||
uninstall.Hide(); | ||
Main.StopLoading(); | ||
} | ||
} | ||
} |
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.