Fixed fossil operation termination flag
FossilOrigin-Name: f791fda7d73f7e7b71b28ecbaefd93330090a834
This commit is contained in:
@ -546,7 +546,7 @@ bool Bridge::runFossilRaw(const QStringList &args, QStringList *output, int *exi
|
||||
QString ans_always = 'a' + EOL_MARK;
|
||||
QString ans_convert = 'c' + EOL_MARK;
|
||||
|
||||
abortOperation = false;
|
||||
operationAborted = false;
|
||||
QString buffer;
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
@ -572,7 +572,7 @@ bool Bridge::runFossilRaw(const QStringList &args, QStringList *output, int *exi
|
||||
if(state!=QProcess::Running && bytes_avail<1)
|
||||
break;
|
||||
|
||||
if(abortOperation)
|
||||
if(operationAborted)
|
||||
{
|
||||
log("\n* "+QObject::tr("Terminated")+" *\n");
|
||||
#ifdef Q_OS_WIN // Verify this is still true on Qt5
|
||||
|
@ -41,7 +41,7 @@ public:
|
||||
|
||||
|
||||
Bridge()
|
||||
: abortOperation(false)
|
||||
: operationAborted(false)
|
||||
, uiCallback(0)
|
||||
{
|
||||
}
|
||||
@ -86,7 +86,6 @@ public:
|
||||
repositoryFile = filename;
|
||||
}
|
||||
|
||||
|
||||
bool openRepository(const QString &repositoryPath, const QString& workspacePath);
|
||||
bool newRepository(const QString &repositoryPath);
|
||||
bool closeRepository();
|
||||
@ -119,6 +118,8 @@ public:
|
||||
bool stashDrop(const QString& name);
|
||||
bool stashDiff(const QString& name);
|
||||
|
||||
void abortOperation() { operationAborted = true; }
|
||||
|
||||
private:
|
||||
void log(const QString &text, bool isHTML=false)
|
||||
{
|
||||
@ -128,7 +129,7 @@ private:
|
||||
|
||||
QString getFossilPath();
|
||||
|
||||
bool abortOperation; // FIXME: No GUI for it yet
|
||||
bool operationAborted;
|
||||
UICallback *uiCallback;
|
||||
QString currentWorkspace;
|
||||
QString fossilPath; // The value from the settings
|
||||
|
@ -198,7 +198,7 @@ MainWindow::MainWindow(Settings &_settings, QWidget *parent, QString *workspaceP
|
||||
if(workspacePath && !workspacePath->isEmpty())
|
||||
openWorkspace(*workspacePath);
|
||||
|
||||
abortOperation = false;
|
||||
operationAborted = false;
|
||||
|
||||
rebuildRecent();
|
||||
}
|
||||
@ -612,7 +612,7 @@ void MainWindow::scanWorkspace()
|
||||
workspaceFiles.clear();
|
||||
pathSet.clear();
|
||||
|
||||
abortOperation = false;
|
||||
operationAborted = false;
|
||||
|
||||
if(scan_files)
|
||||
{
|
||||
@ -626,7 +626,7 @@ void MainWindow::scanWorkspace()
|
||||
ignore = settings.GetFossilValue(FOSSIL_SETTING_IGNORE_GLOB).toString().replace(',',';');
|
||||
}
|
||||
|
||||
if(!scanDirectory(all_files, wkdir, wkdir, ignore, abortOperation))
|
||||
if(!scanDirectory(all_files, wkdir, wkdir, ignore, operationAborted))
|
||||
goto _done;
|
||||
|
||||
for(QFileInfoList::iterator it=all_files.begin(); it!=all_files.end(); ++it)
|
||||
@ -2154,7 +2154,8 @@ void MainWindow::setBusy(bool busy)
|
||||
//------------------------------------------------------------------------------
|
||||
void MainWindow::onAbort()
|
||||
{
|
||||
abortOperation = true;
|
||||
operationAborted = true;
|
||||
bridge.abortOperation();
|
||||
// FIXME: Rename this to something better, Operation Aborted
|
||||
log("<br><b>* "+tr("Terminated")+" *</b><br>", true);
|
||||
}
|
||||
|
@ -252,7 +252,7 @@ private:
|
||||
class QAction *recentWorkspaceActs[MAX_RECENT];
|
||||
class QProgressBar *progressBar;
|
||||
class QShortcut *abortShortcut;
|
||||
bool abortOperation;
|
||||
bool operationAborted;
|
||||
|
||||
Settings &settings;
|
||||
QStringList workspaceHistory;
|
||||
|
Reference in New Issue
Block a user