projectmanager interface

Andreas Pakulat apaku at gmx.de
Fri Dec 26 19:07:58 UTC 2008


On 25.12.08 02:35:17, Aleix Pol wrote:
> - why do we need the removeFileFromTarget when we have a removeFile? we can
> check if it is from an item using
> dynamic_cast<ProjectTargetItem*>(it->parent()).
> - why do we have addFileToTarget and addFile(toFolder)? and the target case
> has a ProjectFileItem as a parameter instead of a KUrl :S

Matt answered to these both.

> - why do we add everything but targets that are created? because they're not
> in the FS? :S

Its more like files/folders are existing things added to the project
but targets are created "from zero" by the plugin.

> - why don't we just merge these methods that just pass the same and we pass
> a ProjectBaseItem as the parent?

As Matt said addFileToProject doesn't necessarily imply adding it to a
target. So the separation does make sense. The fact that we currently add
all files in a project directory doesn't mean thats going to stay this way
forever.

> - create target should change. We should tell the builddir if we want to
> create a lib target or an executable target.

I guess an enum about that would be good, yes. This is just an oversight
from when we splitted ProjectTargetItem into subclasses...

Andreas

-- 
Change your thoughts and you change your world.




More information about the KDevelop-devel mailing list