[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 583: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 639: sizeof(): Parameter must be an array or an object that implements Countable
Gephi forumsPlease post new questions on facebook group too (https://www.facebook.com/groups/gephi) 2011-05-03T03:56:10+01:00 https://www.forum-gephi.org/app.php/feed/topic/1104 2011-05-03T03:56:10+01:002011-05-03T03:56:10+01:00 https://www.forum-gephi.org/viewtopic.php?t=1104&p=3305#p3305 <![CDATA[Attaching a Panel to a Perspective]]>
I am trying to attach a module panel to a perspective, following the wiki: http://wiki.gephi.org/index.php/HowTo_a ... dule_panel

As suggested by the wiki, in a module I added a new window (MyPanelTopComponent.java) with class name MyPanel and mode as "layoutmode".

To register it in a perspective, I accessed the source code for MyPanelTopComponent.java, and edited it to include the following:

CODE:

@ConvertAsProperties(dtd = "-//org.gephi.desktop.perspective//MyPanel//EN",autostore = false)@ServiceProvider(service=PerspectiveMember.class)public final class MyPanelTopComponent extends TopComponent implements PerspectiveMember {......... public boolean open(Perspective perspective) {        return perspective instanceof LaboratoryPerspective;    }    public boolean close(Perspective perspective) {        return true;    }}
As I understand it, this should attach the panel "MyPanelTopComponent" to the perspective "LabratoryPerspective", however I see it in all 3 perspectives.

I've tried setting the return value for the method "close" to false, but this does not seem to have any impact

The wiki states
Specifically use close() method if you want your panel to be visible on several perspectives.
This seems to imply that close() does not have to be used at all, and this would result in the panel being associated with only one panel, is that correct?

Statistics:Posted by aurora — 03 May 2011 03:56


]]>