NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Click Through to Class : Find Declaration


Joined: 15 Sep 2005
Posts: 51
Location: Birmingham, UK
Reply with quote
In the latest version of PhpEd, 5242, Find Declaration (Ctrl-Left Click) appears to have stopped working, anybody able to confirm?

Dimitri, if a confirmed bug are you able to confirm how long before this can be fixed? I'm not too keen on going back to the previous section because of bug 0002298.

(One of my developers is still using 5240 and click-through works on their setup)
View user's profileFind all posts by BlackGasSend private messageVisit poster's website
Guru master

Joined: 05 Jul 2004
Posts: 659
Location: Belgium
Reply with quote
Nope, still works here. Are you sure file you are clicking in belongs to the active project?
View user's profileFind all posts by BlizzSend private messageVisit poster's website


Joined: 15 Sep 2005
Posts: 51
Location: Birmingham, UK
Reply with quote
Yep, active project.

Works within the same file but doesn't open up additional files.

I've even tried refreshing code explorer to see if that helsp but nope, nothing.
View user's profileFind all posts by BlackGasSend private messageVisit poster's website


Joined: 15 Sep 2005
Posts: 51
Location: Birmingham, UK
Reply with quote
OK, I've done a little more testing and just had one of my developers install 5242 to confirm.

Snippet from my front controller.

Code:

switch($view) {
 
  case 'home':
    $page = new page_admintemplate($view);
    $content = new logicadmin_home($view);
    $page->add_content($content->get_html());
    $page->create_page();
    echo $page->get_page();
  break;



Ctrl clicking on page_admintemplate no longer works yet Ctrl clicking on add_content opens up my home class so the issue only seems to occur with the new keyword.
View user's profileFind all posts by BlackGasSend private messageVisit poster's website


Joined: 29 May 2008
Posts: 5
Reply with quote
It's not working for me either Crying or Very sad

-
Best regards, Caspar
View user's profileFind all posts by casparSend private message


Joined: 21 Oct 2004
Posts: 81
Location: UK
Reply with quote
It's also happening to me. It happens, it appears, on any class name so "Find Declaration" fails on the bold text but works on the italic. Sorry for the lack of CODE tags but I want the formatting.

Paste this into a new PHP5 file in build 5242:
--------------------------------------------------
class Bar {
public static $staticProperty;
public static function staticMethod() {}
public static function method() {}
}

$foo = new Bar();
Bar::staticMethod();
Bar::$staticProperty;
$foo->method();
--------------------------------------------------

I hadn't noticed before now, but the static property also fails.
View user's profileFind all posts by QuboidSend private message


Joined: 15 Sep 2005
Posts: 51
Location: Birmingham, UK
Reply with quote
Are we able to get confirmation and an estimated time for the fix.

I've had to go back to a previous version because this bug is incredibly counter productive.
View user's profileFind all posts by BlackGasSend private messageVisit poster's website
Site Admin

Joined: 13 Jul 2003
Posts: 8334
Reply with quote
Quote:
Are we able to get confirmation and an estimated time for the fix

I'm not sure what fix you mean.
I tried all the samples mentioned above using 5242, and all worked fine. No problems so far.

On the other but closely related matter, please do not expect any reaction on the bugreports posted on these forums. Please read and follow the rules. Should you need support please contact support team.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 15 Sep 2005
Posts: 51
Location: Birmingham, UK
Reply with quote
Fair enough I will submit a bug report but it will be no different to what I have already posted here.

I initially posted here in the forums because I wanted to check with the community and nusphere whether or not the bug could be confirmed as a bug, so far 2 other users have confirmed the issue so I feel safe to submit an official bug report, I dodn't feel that there was any point sending through something to support that could be due to my setup and that alone.
View user's profileFind all posts by BlackGasSend private messageVisit poster's website


Joined: 29 May 2008
Posts: 5
Reply with quote
Hey Dimitri and forum,

This is (at least for me) very easy to reproduce. And like BlackGas I find it very counter productive.

To reproduce the bug setup a project with two files. One in the projects root folder and another in a subfolder, like the following:

/index.php <- file in the root folder
/includes/classes.php <- file in the subfolder

Set the content of the two files to the following:

index.php
Code:

<?php
// file index.php
include('includes/classes.php');
$my_class = new test_class;
?>


classes.php
Code:

<?php
// file includes/classes.php
class test_class
{
   public function __construct() {}
}
?>


With index.php open ctrl-clicking "test_class" will not bring you into the classes.php file. Hope this helps.

-
Best regards, Caspar
View user's profileFind all posts by casparSend private message


Joined: 29 May 2008
Posts: 5
Reply with quote
Hi again,

There seems to be a problem with subclasses as well. With the setup from last post add a new file called classes2.php in the includes subfolder.

Change the content to:

classes2.php
Code:

<?php
class extended_test_class extends test_class
{
   public function test_function() {}
}
?>


Clicking "test_class" in this file will not bring you to classes.php

There's also problems with member functions. If the content of index.php is changed to:

index.php
Code:

<?php
// file index.php
include('includes/classes.php');
class my_class
{
   var $instance;
   
   public function __construct()
   {
      $this->instance = new test_class;
      $this->instance->test_function();
   }
}
?>


ctrl-clicking "test_function()" will not bring you into classes2.php. Actually the status bar will show the following error:

Quote:
Failed to find "my_class::instance" constant



These examples all work fine in the the earlier versions of phpED.

-
Bes regards, Caspar
View user's profileFind all posts by casparSend private message


Joined: 21 Oct 2004
Posts: 81
Location: UK
Reply with quote
You guys are talking about different pages - definition in one, usage in another. Copy my code and see if it happens in a single page please, so we can rule out anything to do with reading other project files.
View user's profileFind all posts by QuboidSend private message
Click Through to Class : Find Declaration
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic