summaryrefslogtreecommitdiffstats
path: root/heimdall-frontend/Source/mainwindow.h
diff options
context:
space:
mode:
authorBenjamin Dobell <benjamin.dobell@glassechidna.com.au>2011-07-05 18:58:28 +0200
committerBenjamin Dobell <benjamin.dobell@glassechidna.com.au>2011-07-05 18:58:28 +0200
commitb6ffa766b21fe2c985437aa80824a3cd4c384de8 (patch)
treeda9f5c33b33074748bd981175d36d2974ff3fb98 /heimdall-frontend/Source/mainwindow.h
parentMerge pull request #15 from alanorth/patch-1 (diff)
downloadHeimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.tar
Heimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.tar.gz
Heimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.tar.bz2
Heimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.tar.lz
Heimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.tar.xz
Heimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.tar.zst
Heimdall-b6ffa766b21fe2c985437aa80824a3cd4c384de8.zip
Diffstat (limited to '')
-rw-r--r--heimdall-frontend/Source/mainwindow.h85
1 files changed, 62 insertions, 23 deletions
diff --git a/heimdall-frontend/Source/mainwindow.h b/heimdall-frontend/Source/mainwindow.h
index added4e..7525d67 100644
--- a/heimdall-frontend/Source/mainwindow.h
+++ b/heimdall-frontend/Source/mainwindow.h
@@ -21,13 +21,21 @@
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
+// Qt
+#include <QList>
+#include <QMainWindow>
+#include <QProcess>
+#include <QTemporaryFile>
+
+// libpit
+#include "libpit.h"
+
// Heimdall Frontend
#include "aboutform.h"
#include "ui_mainwindow.h"
+#include "PackageData.h"
-// Qt
-#include <QMainWindow>
-#include <QProcess>
+using namespace libpit;
namespace HeimdallFrontend
{
@@ -45,11 +53,29 @@ namespace HeimdallFrontend
bool heimdallRunning;
QProcess process;
+ PackageData loadedPackageData;
+
+ PitData currentPitData;
+ PackageData workingPackageData;
+
+ bool populatingPartitionNames;
+ QList<unsigned int> unusedPartitionIds;
+
+ void UpdateUnusedPartitionIds(void);
+ bool ReadPit(QFile *file);
+
+ void UpdatePackageUserInterface(void);
+
bool IsArchive(QString path);
QString PromptFileSelection(void);
+ QString PromptFileCreation(void);
+
+ void UpdatePartitionNamesInterface(void);
void UpdateStartButton(void);
+ void UpdateBuildPackageButton(void);
+
public:
explicit MainWindow(QWidget *parent = 0);
@@ -60,30 +86,43 @@ namespace HeimdallFrontend
void OpenDonationWebpage(void);
void ShowAbout(void);
+ void SelectFirmwarePackage(void);
+ void OpenDeveloperHomepage(void);
+ void OpenDeveloperDonationWebpage(void);
+ void LoadFirmwarePackage(void);
+
+ void SelectPartitionName(int index);
+ void SelectPartitionFile(void);
+
+ void SelectPartition(int row);
+ void AddPartition(void);
+ void RemovePartition(void);
+
void SelectPit(void);
- void SelectFactoryfs(void);
- void SelectKernel(void);
- void SelectParam(void);
- void SelectPrimaryBootloader(void);
- void SelectSecondaryBootloader(void);
- void SelectCache(void);
- void SelectDatabase(void);
- void SelectModem(void);
- void SelectRecovery(void);
-
- void SetRepartionEnabled(int enabled);
- void SetFactoryfsEnabled(int enabled);
- void SetKernelEnabled(int enabled);
- void SetParamEnabled(int enabled);
- void SetPrimaryBootloaderEnabled(int enabled);
- void SetSecondaryBootloaderEnabled(int enabled);
- void SetCacheEnabled(int enabled);
- void SetDatabaseEnabled(int enabled);
- void SetModemEnabled(int enabled);
- void SetRecoveryEnabled(int enabled);
+ void SetRepartition(int enabled);
void StartFlash(void);
+ void FirmwareNameChanged(const QString& text);
+ void FirmwareVersionChanged(const QString& text);
+ void PlatformNameChanged(const QString& text);
+ void PlatformVersionChanged(const QString& text);
+
+ void HomepageUrlChanged(const QString& text);
+ void DonateUrlChanged(const QString& text);
+
+ void DeveloperNameChanged(const QString& text);
+ void SelectDeveloper(int row);
+ void AddDeveloper(void);
+ void RemoveDeveloper(void);
+
+ void DeviceInfoChanged(const QString& text);
+ void SelectDevice(int row);
+ void AddDevice(void);
+ void RemoveDevice(void);
+
+ void BuildPackage(void);
+
void HandleHeimdallStdout(void);
void HandleHeimdallReturned(int exitCode, QProcess::ExitStatus exitStatus);
void HandleHeimdallError(QProcess::ProcessError error);