|
Isis 3 Programmer Reference
|
Go to the documentation of this file.
25 #include <QFileDialog>
26 #include <QInputDialog>
27 #include <QMessageBox>
29 #include "Directory.h"
30 #include "MosaicSceneItem.h"
31 #include "MosaicSceneWidget.h"
49 QAction::setText(tr(
"&Rename Project..."));
50 QUndoCommand::setText(tr(
"Rename Project"));
70 QAction::setText(tr(
"&Rename Project..."));
71 QUndoCommand::setText(tr(
"Rename Project"));
120 return (context == ProjectContext);
142 newName = QInputDialog::getText(NULL, tr(
"Enter Project Name"),
143 tr(
"Please enter the new project name"), QLineEdit::Normal,
147 QMessageBox::critical(NULL, tr(
"Invalid Project Name"),
148 tr(
"Project name [%1] is not valid").arg(newName));
159 QUndoCommand::setText(tr(
"Rename Project from [%1] to [%2]").
171 return !nameToCheck.isEmpty();
RenameProjectWorkOrder(QString newName, Project *project)
Creates a work order to rename the project using the given new project name.
virtual bool setupExecution()
This sets up the state for the work order.
Unless noted otherwise, the portions of Isis written by the USGS are public domain.
Provide Undo/redo abilities, serialization, and history for an operation.
Change the project's GUI name.
static bool isNameValid(QString nameToCheck)
Check the validity of the given (proposed) project name.
void setInternalData(QStringList data)
Sets the internal data for this WorkOrder.
virtual RenameProjectWorkOrder * clone() const
This method clones the current RenameProjectWorkOrder and returns it.
~RenameProjectWorkOrder()
Destructor.
bool dependsOn(WorkOrder *other) const
This WorkOrder is only dependent on another RenameProjectWorkOrder.
virtual bool setupExecution()
Setup this WorkOrder for execution.
The main project for ipce.
virtual void undoExecution()
Changes the project name back to the old name.
bool m_isUndoable
Set the workorder to be undoable/redoable This is defaulted to true - his will allow the workorder to...
virtual bool isExecutable(Context context)
This method returns true if the user clicked on the project name on the project tree,...
virtual void execute()
This will rename the project.
Project * project() const
Returns the Project this WorkOrder is attached to.
QString name() const
Get the project's GUI name.
void setName(QString newName)
Change the project's name (GUI only, doesn't affect location on disk).
QStringList internalData() const
Gets the internal data for this WorkOrder.
Context
This enumeration is for recording the context of the current Workorder (whether it is part of a proje...
void setClean(bool value)
Function to change the clean state of the project.
This is free and unencumbered software released into the public domain.