pivot-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sandro Martini (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PIVOT-754) Pivot displays ugly gray box sometimes before it loads the applet
Date Sat, 11 Jun 2011 10:06:03 GMT

    [ https://issues.apache.org/jira/browse/PIVOT-754?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13047874#comment-13047874

Sandro Martini commented on PIVOT-754:

Hi all,
> I don't think it is needed to distribute proguarded jars. I suggested only proguarding
and packing the applications used as examples on the site, and reviewing if they are deployed
That was my plan. 
But to avoid licensing problems etc (I can try to verify in the meantime with legal-discuss,
just to close the discussion on it), maybe we could publish the pack200 version of our jars
(signed and not signed) in the web site (and only there), so our demos and examples could
have smaller downloads ... but wait, I see our client-side jars are approx. 4.2 MB  (with
our default build options, so they will contain debug info) and the same in pack200 version
is less than 2.0 MB (stripping out debug info) so probably could be useful to put them in
the same folder of web site and enable its usage in our pages, but I repeat only for web demos
and tutorials ...

On a profile for ProGuard maybe we could try to put a sample of it in our svn ...

Both things are now under this ticket:

> The first time I ran the examples, the progress bar disappeared too early, and the application
was still downloading, while presenting me an ugly gray box.
On this I don't know if we could do something, probably it's domain of the JVM+OS, but we
can take a look to see what is possible.

> Pivot displays ugly gray box sometimes before it loads the applet
> -----------------------------------------------------------------
>                 Key: PIVOT-754
>                 URL: https://issues.apache.org/jira/browse/PIVOT-754
>             Project: Pivot
>          Issue Type: Bug
>          Components: wtk
>    Affects Versions: 2.0
>         Environment: Observed both on Linux and Windows Vista, Firefox 3.x and Firefox
> Java 6 update 25.
>            Reporter: Piotr Kołaczkowski
>            Priority: Minor
>             Fix For: 2.0.1
>         Attachments: pivot-graybox.patch
> When the applet starts, a progress bar is displayed. When the applet finishes downloading,
the progress bar disappears, leaving a gray box until the pivot toolkit loads the application.
Even for the simpliest application displaying an empty window, pivot requires about 0.3 s
to start (on Core2Duo 2.2 GHz), so the gray box effect can be easily seen. The gray box effect
does not happen always, but in about half of the cases.
> Below I submit patch we made to the BrowserApplicationContext.java file. Seems like setting
the applet's background to white and delaying the add(displayHost) call as late as possible
does the trick:
> [code]
> 51a52
> >         private boolean displayHostInstalled = false;
> 151c152,154
> <                 add(displayHost);
> ---
> > 
> >                 // Don't add it now, add it later, to avoid ugly gray box:
> >                 //add(displayHost);
> 160c163,164
> <                 setBackground(null);
> ---
> >                 // Huh? WTF?
> >                 // setBackground(null);
> 191a196
> >                         installDisplayHostIfNeeded();
> 245a251,257
> >         private void installDisplayHostIfNeeded() {
> >             if (!displayHostInstalled) {
> >                 this.add(displayHost);
> >                 displayHostInstalled = true;
> >             }
> >         }
> > 
> 247a260
> >             this.setBackground(Color.white);
> 309a323
> >             installDisplayHostIfNeeded();
> [/code]

This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

View raw message