[RFC] findProjectForUrl() returning >1 Project

Matt Rogers mattr at kde.org
Fri Apr 6 01:57:25 UTC 2007


On Apr 5, 2007, at 8:06 PM, Andreas Pakulat wrote:

> On 05.04.07 19:18:51, Matt Rogers wrote:
>> On Apr 5, 2007, at 6:51 AM, Andreas Pakulat wrote:
>>> My idea is that the projectForUrl() function in ProjectController  
>>> can
>>> return a list of projects instead of 1 project. For many cases this
>>> would be just a 1-element-list, but in the above mentioned cases it
>>> is a
>>> list of projects to which the url belongs. For things like the
>>> user-actions from Quanta this means they have to decide wether they
>>> want:
>>>
>>> a) work on the first item in the list only
>>> b) work on all items in the list always
>>> c) ask the user, presenting a list of projects
>>
>> That list thing is a bad idea. I would instead, suggest that we use
>> the parent->child relationship in the model to determine which
>> project the url is in, if we can. Sorry, no code for this, it's just
>> my idea.
>
> You're missing the point: The url is part of 2 or more projects. Thats
> the problem at hand.
>
> Andreas
>

i don't think i'm missing the point. if the url comes from a project  
model item, the parent -> child relationship there should allow us to  
accurately determine what project the url belongs to since they  
should have different model items. of course, this might not work in  
all cases, but like i said, it's just an idea. :)
--
Matt






More information about the KDevelop-devel mailing list