jcberquist / sublimetext-cfml

CFML (ColdFusion and Lucee) package for Sublime Text
MIT License
115 stars 24 forks source link

Support for dot notation method 'Goto Definition' similar to invoke notation. #123

Open NjnaGrimsdottir opened 6 years ago

NjnaGrimsdottir commented 6 years ago

Currently the system supports right clicking on the method name and doing Goto Definition such as in code like:

<cfinvoke 
 component="Portals"
 method="GetPortalType"
 returnvariable="nPortalResponse">
    <cfinvokeargument name="PortalID" value="#FORM.PortalID#">
</cfinvoke>

Would it be also possible to support the same functionality if that method were being called via:

<cfset var oPortals = createObject("Portals")> 
<cfset nPortalResponse = oPortals.GetPortalType(PortalID=FORM.PortalID)>

and then right clicking on the 'GetPortalType' part of the call above.

This is likely more difficult to determine type since it's not clearly defined as 'method'.

Just an idea since that functionality is wonderful.

jcberquist commented 6 years ago

I agree that Goto Definition is wonderful, and it is actually a core Sublime Text feature. I would have expected that you could right click on "GetPortalType" in either example and it would have offered you the "Goto Definition" option in the menu. At least, if it worked in one case it ought to work in the other.