Announcement Announcement Module
Collapse
No announcement yet.
Help About Dialog and images Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Help About Dialog and images

    I have a problem displaying an image when I start application thru WebStart.

    So if I specify in about dialog's text <img src="image:about.main"> it will not display the image, only in the case where my application was started thur JWS. If I start it locally everything is working fine.

    Does anyone have an idea of what is wrong here?

  • #2
    Do the other images in your application work properly?

    I ask because I deploy my application using JWS and all the images work fine. I do not, however, use the RCP supplied about box, so maybe it's a problem just with that component.

    Larry.

    Comment


    • #3
      yes all other images are fine.

      I am quie sure it is something to do with images: prefix, if I put the image on web server and specify http://web.server.com/image/img.gif works fine.

      The thing is AboutBox uses HtmlPane which in turn extends JTextPane which in turn uses javax.swing.text.html.HTMLEditorKit and I am pretty sure there has to be some thing to tweak there. I just do not know what :-)

      Anyone has any idea?

      Comment


      • #4
        Are you by chance specifying a value for java.protocol.handler.pkgs anywhere in your application?

        It appears that there is a subtle bug in the installImageUrlHandler method. It is doing a comparison like this: if (packagePrefixList != "")

        Now, this won't actually compare against an empty string, it will pretty much always evaluate to true. This by itself shouldn't cause a problem as it would force the addition of the org.springframework.richclient package to the list. It will potentially create a bogus list since if the current property value is null, then you would end up with a new property value of "null|org.springframework.richclient".

        I don't see how this would break anything directly, but it is certainly wrong.

        Have you debugged down through the openConnection method in the image Handler class? That would be the determining factor. Unfortunately, I don't have a good testbed for this at the moment, so I can't reproduce your problem.

        Thanks,
        Larry.
        Last edited by lstreepy; Nov 29th, 2005, 02:21 PM.

        Comment


        • #5
          Ok, I've done a bit more digging on this and as best as I can tell, for some reason, the custom image protocol handler is not being used by the URLStreamHandlerFactory when JWS is used to start the application.

          I know that this just confirms what you already knew, but I think it narrows the problem scope. I don't know a lot about JWS, so I don't know what it might be doing that would screw up the normal discovery of custom protocol handlers.

          Not much help, but maybe a someone else knows more about JWS?

          EDIT: Short answer - it's busted

          Check out this link to read a bug report on the JDK regarding this problem: http://bugs.sun.com/bugdatabase/view...bug_id=4648098

          Thanks,
          Larry.
          Last edited by lstreepy; Nov 29th, 2005, 04:47 PM.

          Comment


          • #6
            thanks Larry,

            I will try to dig into this later on this week. I just was not sure if it is SWING related or something else. As I am not familiar with SWING much, I was hoping it is SWING related, so I have a good excuse not to dig :-); but it does not smell like it ...

            Comment


            • #7
              It isn't a problem with either RCP or Swing - It's a problem in the core java libraries. If that matters

              Larry.

              Comment

              Working...
              X