anonymous gray activity circles
Chris Marshall
jns-cmarshall at comcast.net
Sat Jan 3 16:38:08 EST 2009
Thanks for the reply. Unfortunately, I'm
not a python programmer so searching through
the source entails quite a learning curve...
Perhaps someone with real knowledge of the
internals can suggest an approach or more
specifics about where to look.
--Chris
Tony Anderson wrote:
> Hi,
>
> I didn't notice about your use of OpenGL. My remarks referred to GTK.
> However, what I think is happening is that the application is creating a
> new window. On non-sugar systems, they appear as separate windows.
> However, in the case of Sugar, I think it is expected that application
> will work in a single window. The result is in some sense 'undefined'.
> You will need to look at the source code and find where the source code
> recreates a new window and change it to repaint the current window
> (canvas?). Keep in mind I am reporting as an activity developer, not
> from a real knowledge of the internals.
>
> Tony
>
> Chris Marshall wrote:
>> Yes, but these are un-sugarized programs
>> and they still generate gray circles.
>> Doesn't that imply that window creation
>> outside of sugar is being detected and
>> acted upon?
>>
>> --Chris
>>
>> Tony Anderson wrote:
>>> Compare:
>>>
>>> http://laguna.fmedic.unam.mx/~daniel/pygtutorial/pygtutorial/getting-started.html
>>>
>>>
>>> which creates a top-level window and
>>>
>>> http://wiki.laptop.org/go/PyGTK/Hello_World_Tutorial
>>>
>>> as a sugar activity.
>>>
>>> The first has the line:
>>>
>>> window = GtkWindow(WINDOW_TOPLEVEL) # create a top level window
>>>
>>> while the latter has:
>>>
>>> # Create the main container
>>> self._main_view = gtk.VBox()
>>>
>>> Sugar has already created the top-level window with an empty VBox, so
>>> the activity only needs to pack that VBox with widgets.
>>>
>>> Essentially to eliminate the grey circle, you need to modify the
>>> initialization code (with the two tutorials as a guide).
>>>
>>> Tony
>>>
>>>
>>>
>>> Chris Marshall wrote:
>>>> Two specific questions come to mind:
>>>>
>>>> (1) How does Sugar know that a new top level
>>>> window has been instantiated? Is there a
>>>> hook from the X server or what?
>>>>
>>>> (2) What sort of cleanup is needed to make
>>>> the anonymous gray circle go away? Do
>>>> you have to notify Sugar or what?
>>>>
>>>> I'm trying to implement some code that uses
>>>> OpenGL via the Mesa library on the XO. As
>>>> the code re-generates display graphics, the
>>>> gray circles keep accumulating. I would
>>>> like to keep the number of circles equal
>>>> to the number of actual top level windows
>>>> and not the total number used across the
>>>> session.
>>>>
>>>> Thanks,
>>>> Chris
>>>>
>>>> Tony Anderson wrote:
>>>>> I believe that these circles result from the activity initiating a
>>>>> new top-level window. Sugar provides an activity with a window. It
>>>>> is expected that the activity will pack it's widgets into a vbox in
>>>>> that window. Imported activities naturally create a top-level window.
>>>>>
>>>>> Tony
>>>>>
>>>>>
>>>>> Message: 3
>>>>> Date: Tue, 30 Dec 2008 21:37:47 -0500
>>>>> From: Chris Marshall <jns-cmarshall at comcast.net>
>>>>> Subject: Re: anonymous gray activity circles
>>>>> To: greg at laptop.org
>>>>> Cc: OLPC Development <devel at lists.laptop.org>
>>>>> Message-ID: <495ADAFB.40402 at comcast.net>
>>>>> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>>>>>
>>>>> Greg Smith wrote:
>>>>> > > Hi Chris,
>>>>> > >
>>>>> > > Unless someone else has seen this, I think we need more detail
>>>>> on how to
>>>>> > > reproduce it.
>>>>>
>>>>> os767 and Firefox-6 activity
>>>>> start firefox
>>>>> click on a file link to download
>>>>> exit firefox after
>>>>> left a gray circle
>>>>>
>>>>> (Actually, it almost always leaves behind one
>>>>> or more circles but I have not done exhaustive
>>>>> testing to determine how many or under what
>>>>> conditions. It would be easier to start from
>>>>> an understanding of how the circle gets there
>>>>> to begin with (what is being used to trigger
>>>>> the circle's appearance)...
>>>>>
>>>>> --Chris
>>>>>
>>>>> > > Can you write down the steps it takes to get a "gray activity
>>>>> circle"?
>>>>> > > Include the version of XO software you are running:
>>>>> > > http://wiki.laptop.org/go/What_release_am_I_running%3F
>>>>> > >
>>>>> > > It may be that you are double clicking to start an activity.
>>>>> That can
>>>>> > > cause a second activity instance to try and start then fail
>>>>> and leave an
>>>>> > > icon in the frame. That's the only thing that comes to mind
>>>>> without more
>>>>> > > detail.
>>>>> > >
>>>>> > > Thanks,
>>>>> > >
>>>>> > > Greg S
>>>>> > >
>>>>> > > *********************
>>>>> > >
>>>>> > > From: jns-cmarshall at comcast.net
>>>>> > > Subject: anonymous gray activity circles
>>>>> > > To: devel at lists.laptop.org
>>>>> > >
>>>>> > > Is there a way to prevent the
>>>>> > > anonymous gray activity circles
>>>>> > > in the frame? Some X apps
>>>>> > > seem to accumulate circles with
>>>>> > > no way i have been able to
>>>>> > > determine to remove "dead" ones.
>>>>> > > I tried to google the list but was
>>>>> > > not able to generate useful links.
>>>>> > >
>>>>> > > --Chris
>>
>> .
>>
>
>
> ------------------------------------------------------------------------
>
>
> No virus found in this incoming message.
> Checked by AVG - http://www.avg.com
> Version: 8.0.176 / Virus Database: 270.10.2/1872 - Release Date: 1/2/2009 1:10 PM
>
More information about the Devel
mailing list