CustomProjectPart Class Reference
This is the custom build tools part. More...
#include <customprojectpart.h>
Inheritance diagram for CustomProjectPart:


Public Member Functions | |
CustomProjectPart (QObject *parent, const char *name, const QStringList &) | |
~CustomProjectPart () | |
QStringList | allMakeEnvironments () const |
QString | currentMakeEnvironment () const |
bool | isDirty () |
QStringList | distFiles () const |
Returns a list of files that are part of the distribution but not under project control. | |
Protected Member Functions | |
virtual void | openProject (const QString &dirName, const QString &projectName) |
This method is invoked when the project is opened (i.e. | |
virtual void | closeProject () |
This method is invoked when the project is about to be closed. | |
virtual QString | projectDirectory () const |
Returns the canonical toplevel directory of the project. | |
virtual QString | projectName () const |
Returns the name of the project. | |
virtual QString | mainProgram (bool relative=false) const |
Retuns the currently selected main program The returned string can be: if run/directoryradio == executable The executable name if run/directoryradio == build The path to executable relative to build directory if run/directoryradio == custom or relative == false The absolute path to executable. | |
virtual QString | activeDirectory () const |
Returns the path (relative to the project directory) of the active directory. | |
virtual QStringList | allFiles () const |
Returns a list of all files in the project. | |
virtual void | addFile (const QString &fileName) |
Adds a file to the project. | |
virtual void | addFiles (const QStringList &fileList) |
Adds a list of files to the project. | |
virtual void | removeFile (const QString &fileName) |
Removes a file from the project. | |
virtual void | removeFiles (const QStringList &fileList) |
Removes a list of files from the project. | |
virtual QString | buildDirectory () const |
Returns the canonical build directory of the project. | |
virtual QString | runDirectory () const |
Retuns the currently selected run directory The returned string can be: if run/directoryradio == executable The directory where the executable is if run/directoryradio == build The directory where the executable is relative to build directory if run/directoryradio == custom The custom directory absolute path. | |
virtual QString | runArguments () const |
Retuns a QString with the run command line arguments. | |
virtual DomUtil::PairList | runEnvironmentVars () const |
Retuns a PairList with the run environment variables. | |
Private Slots | |
void | projectConfigWidget (KDialogBase *dlg) |
void | contextMenu (QPopupMenu *popup, const Context *context) |
void | slotAddToProject () |
void | slotRemoveFromProject () |
void | slotChooseActiveDirectory () |
void | slotBuild () |
void | slotCompileFile () |
void | slotClean () |
void | slotExecute () |
void | updateTargetMenu () |
void | targetMenuActivated (int id) |
void | updateMakeEnvironmentsMenu () |
void | makeEnvironmentsMenuActivated (int id) |
void | slotCommandFinished (const QString &command) |
void | slotCommandFailed (const QString &command) |
Private Member Functions | |
void | populateProject () |
void | saveProject () |
void | startMakeCommand (const QString &dir, const QString &target) |
QString | makeEnvironment () const |
Private Attributes | |
QString | m_projectDirectory |
QString | m_projectName |
QStringList | m_sourceFiles |
QPopupMenu * | m_targetMenu |
KSelectAction * | m_makeEnvironmentsSelector |
QStringList | m_targets |
QStringList | m_contextAddFiles |
QStringList | m_contextRemoveFiles |
QString | m_contextDirName |
QMap< QString, QDateTime > | m_timestamp |
bool | m_executeAfterBuild |
QString | m_buildCommand |
bool | m_lastCompilationFailed |
Detailed Description
This is the custom build tools part.
Put a more detailed description of your part in these lines. It can span over several lines. You can even use some html commands in these lines like: This is code
, html links link text, and images.
- Unmaintained:
- This part is currently un-maintained
- Feature(s):
- Describe the first feature
Describe the second feature ...
Describe the last feature
- Bug:
- bugs in customproject component at Bugzilla database
Describe a the 1st bug that you know of, but probably hasn't been reported yet. ..
Describe a the nth bug that you know of, but probably hasn't been reported yet.
- Requirement(s):
- Describe a the 1st requirement of your part.
Describe a the 2nd requirement of your part. ...
Describe a the nth requirement of your part.
- Todo:
- Describe a the 1st TODO of your part.
Describe a the 2nd TODO of your part. ...
Describe a the nth TODO of your part.
- F.A.Q.:
- First frequenly asked question about your part ? Answer.
Second frequenly asked question about your part ? Answer. ...
Last frequenly asked question about your part ? Answer.
- Note:
- First note text.
Second note text. ...
Last note text.
- Warning:
- First warning text.
Second warning text. ...
Last warning text.
Definition at line 30 of file customprojectpart.h.
Constructor & Destructor Documentation
|
|
|
Definition at line 135 of file customprojectpart.cpp. |
Member Function Documentation
|
Returns the path (relative to the project directory) of the active directory. All newly generated classes are added here. Implements KDevProject. Definition at line 458 of file customprojectpart.cpp. References KDevPlugin::projectDom(), and DomUtil::readEntry(). |
|
Adds a file to the project. The given file name must be relative to the project directory. Implements KDevProject. Definition at line 486 of file customprojectpart.cpp. References addFiles(). |
|
Adds a list of files to the project. Provided for convenience when adding many files. The given file names must be relative to the project directory. Implements KDevProject. Definition at line 494 of file customprojectpart.cpp. References KDevProject::addedFilesToProject(), kdDebug(), m_sourceFiles, and saveProject(). Referenced by addFile(), and slotAddToProject(). |
|
Returns a list of all files in the project. The files are relative to the project directory. Implements KDevProject. Definition at line 465 of file customprojectpart.cpp. Referenced by distFiles(), isDirty(), and slotCommandFinished(). |
|
Definition at line 852 of file customprojectpart.cpp. References DomUtil::elementByPath(), and KDevPlugin::projectDom(). Referenced by currentMakeEnvironment(), CustomMakeConfigWidget::CustomMakeConfigWidget(), CustomMakeConfigWidget::envNameChanged(), makeEnvironmentsMenuActivated(), and updateMakeEnvironmentsMenu(). |
|
Returns the canonical build directory of the project. If the separate build directory is not supported, this should return the same as projectDiretory(). Implements KDevProject. Definition at line 532 of file customprojectpart.cpp. References projectDirectory(), KDevPlugin::projectDom(), and DomUtil::readEntry(). Referenced by mainProgram(), projectConfigWidget(), runDirectory(), slotBuild(), slotClean(), targetMenuActivated(), and updateTargetMenu(). |
|
This method is invoked when the project is about to be closed.
Implements KDevProject. Definition at line 349 of file customprojectpart.cpp. References saveProject(). |
|
|
Definition at line 874 of file customprojectpart.cpp. References allMakeEnvironments(), KDevPlugin::projectDom(), and DomUtil::readEntry(). Referenced by CustomMakeConfigWidget::CustomMakeConfigWidget(), makeEnvironment(), and updateMakeEnvironmentsMenu(). |
|
Returns a list of files that are part of the distribution but not under project control.
Implements KDevProject. Definition at line 891 of file customprojectpart.cpp. References allFiles(), and projectDirectory(). |
|
Definition at line 831 of file customprojectpart.cpp. References allFiles(), m_timestamp, and projectDirectory(). Referenced by slotExecute(). |
|
Retuns the currently selected main program The returned string can be: if run/directoryradio == executable The executable name if run/directoryradio == build The path to executable relative to build directory if run/directoryradio == custom or relative == false The absolute path to executable.
Implements KDevProject. Definition at line 429 of file customprojectpart.cpp. References buildDirectory(), KDevPlugin::projectDom(), and DomUtil::readEntry(). Referenced by slotExecute(). |
|
Definition at line 539 of file customprojectpart.cpp. References currentMakeEnvironment(), DomUtil::PairList, KDevPlugin::projectDom(), EnvVarTools::quote(), and DomUtil::readPairListEntry(). Referenced by startMakeCommand(). |
|
Definition at line 790 of file customprojectpart.cpp. References allMakeEnvironments(), KDevPlugin::projectDom(), and DomUtil::writeEntry(). |
|
This method is invoked when the project is opened (i.e. actually just after this class has been instantiated). The first parameter is the project directory, which should afterwards be returned by the projectDirectory() method. The second parameter is the project name, which is equivalent with the project file name without the .kdevelop suffix. Reimplemented from KDevProject. Definition at line 262 of file customprojectpart.cpp. References DomUtil::createElementByPath(), DomUtil::elementByPath(), m_projectDirectory, m_projectName, m_sourceFiles, main(), KDevPlugin::mainWindow(), DomUtil::makeEmpty(), KDevProject::openProject(), populateProject(), KDevPlugin::projectDom(), KMessageBox::questionYesNo(), DomUtil::readEntry(), and DomUtil::writeEntry(). |
|
Definition at line 312 of file customprojectpart.cpp. References kdDebug(), m_projectDirectory, and m_sourceFiles. Referenced by openProject(). |
|
Definition at line 139 of file customprojectpart.cpp. References KDialogBase::addVBoxPage(), buildDirectory(), KDevPlugin::projectDom(), and CustomBuildOptionsWidget::setMakeOptionsWidget(). |
|
Returns the canonical toplevel directory of the project.
Implements KDevProject. Definition at line 370 of file customprojectpart.cpp. Referenced by buildDirectory(), contextMenu(), distFiles(), isDirty(), and slotCommandFinished(). |
|
Returns the name of the project.
Implements KDevProject. Definition at line 376 of file customprojectpart.cpp. |
|
Removes a file from the project. The given file name must be relative to the project directory. Implements KDevProject. Definition at line 509 of file customprojectpart.cpp. References removeFiles(). |
|
Removes a list of files from the project. Provided for convenience when removing many files. The given file names must be relative to the project directory. Implements KDevProject. Definition at line 517 of file customprojectpart.cpp. References kdDebug(), m_sourceFiles, KDevProject::removedFilesFromProject(), and saveProject(). Referenced by removeFile(), and slotRemoveFromProject(). |
|
Retuns a QString with the run command line arguments.
Implements KDevProject. Definition at line 453 of file customprojectpart.cpp. References KDevPlugin::projectDom(), and DomUtil::readEntry(). Referenced by slotExecute(). |
|
Retuns the currently selected run directory The returned string can be: if run/directoryradio == executable The directory where the executable is if run/directoryradio == build The directory where the executable is relative to build directory if run/directoryradio == custom The custom directory absolute path.
Implements KDevProject. Definition at line 398 of file customprojectpart.cpp. References buildDirectory(), KDevPlugin::projectDom(), and DomUtil::readEntry(). Referenced by slotExecute(). |
|
Retuns a PairList with the run environment variables.
Implements KDevProject. Definition at line 383 of file customprojectpart.cpp. References DomUtil::PairList, KDevPlugin::projectDom(), and DomUtil::readPairListEntry(). Referenced by slotExecute(). |
|
Definition at line 354 of file customprojectpart.cpp. References m_projectDirectory, m_projectName, and m_sourceFiles. Referenced by addFiles(), closeProject(), and removeFiles(). |
|
Definition at line 243 of file customprojectpart.cpp. References addFiles(), and m_contextAddFiles. Referenced by contextMenu(). |
|
Definition at line 606 of file customprojectpart.cpp. References buildDirectory(), m_lastCompilationFailed, and startMakeCommand(). Referenced by slotExecute(). |
|
Definition at line 255 of file customprojectpart.cpp. References m_contextDirName, KDevPlugin::projectDom(), and DomUtil::writeEntry(). Referenced by contextMenu(). |
|
Definition at line 638 of file customprojectpart.cpp. References buildDirectory(), and startMakeCommand(). |
|
Definition at line 824 of file customprojectpart.cpp. References k_funcinfo, kdDebug(), and m_lastCompilationFailed. |
|
Definition at line 797 of file customprojectpart.cpp. References allFiles(), kdDebug(), m_buildCommand, m_executeAfterBuild, m_timestamp, KDevProject::projectCompiled(), projectDirectory(), and slotExecute(). |
|
Definition at line 613 of file customprojectpart.cpp. References KParts::PartManager::activePart(), KURL::isLocalFile(), kdDebug(), KDevPlugin::partController(), KURL::path(), startMakeCommand(), and KParts::ReadOnlyPart::url(). |
|
Definition at line 644 of file customprojectpart.cpp. References KDevPlugin::appFrontend(), isDirty(), kdDebug(), m_executeAfterBuild, mainProgram(), DomUtil::PairList, KDevPlugin::partController(), KDevPlugin::projectDom(), EnvVarTools::quote(), DomUtil::readBoolEntry(), runArguments(), runDirectory(), runEnvironmentVars(), KDevPartController::saveAllFiles(), slotBuild(), and KDevAppFrontend::startAppCommand(). Referenced by slotCommandFinished(). |
|
Definition at line 249 of file customprojectpart.cpp. References m_contextRemoveFiles, and removeFiles(). Referenced by contextMenu(). |
|
Definition at line 560 of file customprojectpart.cpp. References m_buildCommand, makeEnvironment(), KDevPlugin::makeFrontend(), KDevPlugin::partController(), KDevPlugin::projectDom(), KDevMakeFrontend::queueCommand(), KProcess::quote(), DomUtil::readBoolEntry(), DomUtil::readEntry(), DomUtil::readIntEntry(), and KDevPartController::saveAllFiles(). Referenced by slotBuild(), slotClean(), slotCompileFile(), and targetMenuActivated(). |
|
Definition at line 759 of file customprojectpart.cpp. References buildDirectory(), m_targets, and startMakeCommand(). |
|
Definition at line 765 of file customprojectpart.cpp. References allMakeEnvironments(), KSelectAction::clear(), currentMakeEnvironment(), m_makeEnvironmentsSelector, KDevPlugin::projectDom(), DomUtil::readEntry(), KSelectAction::setCurrentItem(), and KSelectAction::setItems(). |
|
Definition at line 690 of file customprojectpart.cpp. References buildDirectory(), kdDebug(), m_targetMenu, m_targets, KDevPlugin::projectDom(), and DomUtil::readEntry(). |
Member Data Documentation
|
Definition at line 98 of file customprojectpart.h. Referenced by slotCommandFinished(), and startMakeCommand(). |
|
Definition at line 92 of file customprojectpart.h. Referenced by contextMenu(), and slotAddToProject(). |
|
Definition at line 94 of file customprojectpart.h. Referenced by contextMenu(), and slotChooseActiveDirectory(). |
|
Definition at line 93 of file customprojectpart.h. Referenced by contextMenu(), and slotRemoveFromProject(). |
|
Definition at line 97 of file customprojectpart.h. Referenced by slotCommandFinished(), and slotExecute(). |
|
Definition at line 99 of file customprojectpart.h. Referenced by slotBuild(), and slotCommandFailed(). |
|
Definition at line 90 of file customprojectpart.h. Referenced by updateMakeEnvironmentsMenu(). |
|
Definition at line 86 of file customprojectpart.h. Referenced by openProject(), populateProject(), and saveProject(). |
|
Definition at line 87 of file customprojectpart.h. Referenced by openProject(), and saveProject(). |
|
Definition at line 88 of file customprojectpart.h. Referenced by addFiles(), openProject(), populateProject(), removeFiles(), and saveProject(). |
|
Definition at line 89 of file customprojectpart.h. Referenced by updateTargetMenu(). |
|
Definition at line 91 of file customprojectpart.h. Referenced by targetMenuActivated(), and updateTargetMenu(). |
|
Definition at line 96 of file customprojectpart.h. Referenced by isDirty(), and slotCommandFinished(). |
The documentation for this class was generated from the following files:
- buildtools/custommakefiles/customprojectpart.h
- buildtools/custommakefiles/customprojectpart.cpp