This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 15914 - Toolbar: Can't add icons from outside debuggercore
Summary: Toolbar: Can't add icons from outside debuggercore
Status: CLOSED FIXED
Alias: None
Product: debugger
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: All All
: P2 blocker (vote)
Assignee: issues@debugger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-09-26 07:59 UTC by Torbjorn Norbye
Modified: 2001-10-05 15:29 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Torbjorn Norbye 2001-09-26 07:59:19 UTC
I can add my top component now using code like this:

        w = new View2SupportHack (
	    IpeDebugger.getText("TITLE_StackWindow"), // NOI18N
            "/org/netbeans/core/resources/callstack", // NOI18N
            "com.sun.forte.developer.ipe.debugger.StackWindow", // NOI18N
            false, // has no splitter
            true, // is in toolbar
            true,  // visible
            false  // separated
        );

However, this only works if the icon resource above (/org/netbeans/core/..)
is part of core or debuggercore. If it's a path in my module (e.g. loaded
by a different classloader) I get this exception:

Mon Sep 24 12:35:15 PDT 2001: java.lang.IllegalArgumentException: Icon:
 /com/sun/forte/developer/ipe/debugger/rtc.gif does not exist!
java.lang.IllegalArgumentException: Icon:
/com/sun/forte/developer/ipe/debugger/rtc.gif does not exist!
        at
org.netbeans.modules.debugger.support.nodes.ToolbarView.setViews(ToolbarView.java:182)
        at
org.netbeans.modules.debugger.support.nodes.DebuggerWindow.showViews(DebuggerWindow.java:341)
        at
org.netbeans.modules.debugger.support.nodes.DebuggerWindow.setViews(DebuggerWindow.java:245)
        at
org.netbeans.modules.debugger.support.nodes.DebuggerWindow.addNotify(DebuggerWindow.java:126)
        at java.awt.Container.addImpl(Container.java:374)
        at java.awt.Container.add(Container.java:228)


As a possible solution, either consider allowing me to specify a classloader
as part of the constructor, or perhaps just add an alternative constructor
where I can supply the actual Image object (which won't be loaded lazily,
that's okay for me.)
Comment 1 Jan Jancura 2001-09-27 13:14:03 UTC
in main trunk